[Filetree - GAM]

455 views
Skip to first unread message

Maxi Mainero

unread,
Oct 19, 2021, 9:37:19 AM10/19/21
to GAM for Google Workspace
Hi! 
I want to generate a report with all the files and ACL that has the organization.
For the moment, we are generating something like that:
  1. Print all the teamdrives: "gam user <email superadmin user> print|show teamdrives asadmin > teamdrives.csv"
  2. Then, we read line per line and execute: "gam user user show drivefileacl {teamdrive} asadmin" to get the owners of individual teamdrives.
  3. After that, we get the file tree with the shared drive ID and the owner user with: gam user {user} show filetree select {id} fields id
  4. And finally, we get the ACL for each file of the tree.
There is another method more simple to generate it?

Thanks!
Regards.

Ross Scroggs

unread,
Oct 19, 2021, 11:21:44 AM10/19/21
to google-ap...@googlegroups.com

--
You received this message because you are subscribed to the Google Groups "GAM for Google Workspace" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/06d578dd-8371-4e2e-968f-01fdab4ad9d5n%40googlegroups.com.


--

Maxi Mainero

unread,
Oct 19, 2021, 1:08:35 PM10/19/21
to GAM for Google Workspace
OMG! Perfect Ross!

Thanks!
Regards.

Maxi Mainero

unread,
Oct 25, 2021, 7:47:27 AM10/25/21
to GAM for Google Workspace
Hi! 
There is a problem when i want to generate the filelistperms.csv in step 5 and 8 (i test with both methods in GetTeamDriveFileACLs.py), the script get freeze and no response after time running.

I want to see if Google has a limit of queris or the script gets failed and don't print the error in the console.

Thanks!
Regards.


Ross Scroggs

unread,
Oct 25, 2021, 10:31:52 AM10/25/21
to google-ap...@googlegroups.com
Maxi,

This could run for hours; how many Shared Drives are there? 
You might want to run this script first to get an idea of how many files you're dealing with.

Ross



--
Reply all
Reply to author
Forward
0 new messages