Thanks for GAM and Advanced GAM. Amazing!
We migrate ex-employees email to a Google Group but I'm looking for a way to better automate it.
I installed GAM on Google Cloud Shell for the speed increase instead of shunting data to up and down our 100/40 fibre connection. I could host GAM on one of our VPS servers in a USA data centre but I'd expect Google Cloud Shell would still be faster. The Google cloud session times-out every 500-1500 messages and/or the command fails with
googleapiclient.errors.MediaUploadSizeError: Media larger than: 26214400
Which I understand means the attachments make the individual email bigger than what google groups can handle.
Ex-employees have 1gb-90gb of email depending on how long they've been with the company.
command I'm using is
gam user user...@company.tld archive messages grou...@company.tld doit
- I can't work out how to limit migration to say 500 email batches then start the second and subsequent batch. obviously
[max_to_forward <Number>]
- should i be prefetching a list of message_ids and then feeding back in 500 message id batches? If so how? Alternatively identify emails >25mb, copy and remove the attachment to Drive, then run the archive command?
- What is the best practice for this migration? with some logging for error. e.g. chats generate this runtime error, but the job continues
User: user...@company.tld, Message: 1750cf0909b88d63, Archive Failed: Unable to parse the raw message (1487/4880)
Regards
Paul