GAMADV-X Recursively transfer ownerhsip of files and subfolders - Correct syntax?

1,856 views
Skip to first unread message

Blutarsky

unread,
Aug 29, 2018, 10:06:36 AM8/29/18
to GAM for G Suite
Hi there Ross, what is the correct syntax for claiming (transferring) ownership from any user/group to the superadmin? I see the help here https://github.com/taers232c/GAMADV-X/wiki/Collections-of-Users however I am confused! Could you throw in a syntax sample?

Blutarsky

unread,
Aug 29, 2018, 10:15:37 AM8/29/18
to GAM for G Suite
I mean how to transfer ownership of files , subfiles and subfolders froma given folder........

Ross Scroggs

unread,
Aug 29, 2018, 10:46:13 AM8/29/18
to google-ap...@googlegroups.com
1) To transfer a users files/folders (all or a subset) to another user:

2) To transfer ownership, typically in a shared folder, from one user to another:

I think that you're describing 1

gam <UserTypeEntity> transfer drive <UserItem> [select <DriveFileEntity>]

        [(targetfolderid <DriveFolderID>)|(targetfoldername <DriveFolderName>)] [targetuserfoldername <DriveFolderName>] [targetuserorphansfoldername <DriveFolderName>]

        [keepuser | (retainrole reader|commenter|writer|editor|none)] [noretentionmessages]

[nonowner_retainrole reader|commenter|writer|editor|current|none] [nonowner_targetrole reader|commenter|writer|editor|current|none|source]

        (orderby <DriveFileOrderByFieldName> [ascending|descending])*

        [preview] [todrive <ToDriveAttribute>*]


gam user old...@domain.com transfer drive new...@domain.com select drivefilename  "Put Folder Name Here" targetuserfoldername "Destination Folder Name" targetuserorphansfoldername "Destination Folder Name for Orphans" ... specify role options

Test with a small folder

Ross




--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/7f4d508a-b959-4b3d-afd0-89c8344ae389%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--

Blutarsky

unread,
Aug 29, 2018, 11:35:15 AM8/29/18
to GAM for G Suite
Hi there Ross, thanks for helping!

Two questions:

  1. I thought only Gam Adv-XTD could perform transfers! Should I switch to Gam ADV-X? What's the difference between the two?
  2. Can i run the command using "all users" for UserTypeEntity?

On Wednesday, August 29, 2018 at 4:46:13 PM UTC+2, Ross Scroggs wrote:
1) To transfer a users files/folders (all or a subset) to another user:

2) To transfer ownership, typically in a shared folder, from one user to another:

I think that you're describing 1

gam <UserTypeEntity> transfer drive <UserItem> [select <DriveFileEntity>]

        [(targetfolderid <DriveFolderID>)|(targetfoldername <DriveFolderName>)] [targetuserfoldername <DriveFolderName>] [targetuserorphansfoldername <DriveFolderName>]

        [keepuser | (retainrole reader|commenter|writer|editor|none)] [noretentionmessages]

[nonowner_retainrole reader|commenter|writer|editor|current|none] [nonowner_targetrole reader|commenter|writer|editor|current|none|source]

        (orderby <DriveFileOrderByFieldName> [ascending|descending])*

        [preview] [todrive <ToDriveAttribute>*]


gam user old...@domain.com transfer drive new...@domain.com select drivefilename  "Put Folder Name Here" targetuserfoldername "Destination Folder Name" targetuserorphansfoldername "Destination Folder Name for Orphans" ... specify role options

Test with a small folder

Ross




On Wed, Aug 29, 2018 at 7:15 AM Blutarsky <riccar...@gmail.com> wrote:
I mean how to transfer ownership of files , subfiles and subfolders froma given folder........

On Wednesday, August 29, 2018 at 4:06:36 PM UTC+2, Blutarsky wrote:
Hi there Ross, what is the correct syntax for claiming (transferring) ownership from any user/group to the superadmin? I see the help here https://github.com/taers232c/GAMADV-X/wiki/Collections-of-Users however I am confused! Could you throw in a syntax sample?

--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.


--

Zachary Tyler Raposo

unread,
Aug 29, 2018, 1:57:32 PM8/29/18
to GAM for G Suite
Hello Ross,

To piggyback off this since I have a very similar situation that looks to be resolvable with the command you gave gam user us...@domain.com transfer drive us...@domain.com select drivefilename "TestFolder" targetuserfoldername "NewFolderName" targetuserorphansfoldername "OrphanedFilesFolderName" retainrole writer The only problem, if you can call it a problem, is that when I use targetuserorphansfoldername "OrphanedFilesFolderName" I do not get anything back with a folder name OrphanedFilesFolderName but all the subfolders in the parent folder NewFolderName retained the same structure. So I guess my question is how and where would I see the targetuserorphansfoldername "OrphanedFilesFolderName" folder or am I just misunderstanding the targetuserorphansfoldername syntax?

Thank you,
Zachary


On Wednesday, August 29, 2018 at 7:46:13 AM UTC-7, Ross Scroggs wrote:
1) To transfer a users files/folders (all or a subset) to another user:

2) To transfer ownership, typically in a shared folder, from one user to another:

I think that you're describing 1

gam <UserTypeEntity> transfer drive <UserItem> [select <DriveFileEntity>]

        [(targetfolderid <DriveFolderID>)|(targetfoldername <DriveFolderName>)] [targetuserfoldername <DriveFolderName>] [targetuserorphansfoldername <DriveFolderName>]

        [keepuser | (retainrole reader|commenter|writer|editor|none)] [noretentionmessages]

[nonowner_retainrole reader|commenter|writer|editor|current|none] [nonowner_targetrole reader|commenter|writer|editor|current|none|source]

        (orderby <DriveFileOrderByFieldName> [ascending|descending])*

        [preview] [todrive <ToDriveAttribute>*]


gam user old...@domain.com transfer drive new...@domain.com select drivefilename  "Put Folder Name Here" targetuserfoldername "Destination Folder Name" targetuserorphansfoldername "Destination Folder Name for Orphans" ... specify role options

Test with a small folder

Ross




On Wed, Aug 29, 2018 at 7:15 AM Blutarsky <riccar...@gmail.com> wrote:
I mean how to transfer ownership of files , subfiles and subfolders froma given folder........

On Wednesday, August 29, 2018 at 4:06:36 PM UTC+2, Blutarsky wrote:
Hi there Ross, what is the correct syntax for claiming (transferring) ownership from any user/group to the superadmin? I see the help here https://github.com/taers232c/GAMADV-X/wiki/Collections-of-Users however I am confused! Could you throw in a syntax sample?

--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.


--

Ross Scroggs

unread,
Aug 29, 2018, 2:01:52 PM8/29/18
to google-ap...@googlegroups.com
Zachary,

I only build the folder (targetuserorphansfoldername "OrphanedFilesFolderName") if there actually are some orphans.

Ross

To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.


--

--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.

To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.

For more options, visit https://groups.google.com/d/optout.


--

Zachary Tyler Raposo

unread,
Aug 29, 2018, 2:15:10 PM8/29/18
to GAM for G Suite
Thank you very much for the quick reply back and clarification.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.


--

--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.


--

Blutarsky

unread,
Sep 2, 2018, 12:04:12 PM9/2/18
to GAM for G Suite
This did it (with GAM-ADV-XTD):

gam user newowner@mydomain claim ownership drivefolderIDxxxxx


On Wednesday, August 29, 2018 at 4:46:13 PM UTC+2, Ross Scroggs wrote:
1) To transfer a users files/folders (all or a subset) to another user:

2) To transfer ownership, typically in a shared folder, from one user to another:

I think that you're describing 1

gam <UserTypeEntity> transfer drive <UserItem> [select <DriveFileEntity>]

        [(targetfolderid <DriveFolderID>)|(targetfoldername <DriveFolderName>)] [targetuserfoldername <DriveFolderName>] [targetuserorphansfoldername <DriveFolderName>]

        [keepuser | (retainrole reader|commenter|writer|editor|none)] [noretentionmessages]

[nonowner_retainrole reader|commenter|writer|editor|current|none] [nonowner_targetrole reader|commenter|writer|editor|current|none|source]

        (orderby <DriveFileOrderByFieldName> [ascending|descending])*

        [preview] [todrive <ToDriveAttribute>*]


gam user old...@domain.com transfer drive new...@domain.com select drivefilename  "Put Folder Name Here" targetuserfoldername "Destination Folder Name" targetuserorphansfoldername "Destination Folder Name for Orphans" ... specify role options

Test with a small folder

Ross




On Wed, Aug 29, 2018 at 7:15 AM Blutarsky <riccar...@gmail.com> wrote:
I mean how to transfer ownership of files , subfiles and subfolders froma given folder........

On Wednesday, August 29, 2018 at 4:06:36 PM UTC+2, Blutarsky wrote:
Hi there Ross, what is the correct syntax for claiming (transferring) ownership from any user/group to the superadmin? I see the help here https://github.com/taers232c/GAMADV-X/wiki/Collections-of-Users however I am confused! Could you throw in a syntax sample?

--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.


--
Reply all
Reply to author
Forward
0 new messages