SOLVED Backup transport errors when backing up to Google Drive - Token refresh failed

Operating System & Version
CENTOS 7.9 virtuozzo
cPanel & WHM Version
v98.0.10

jasoncollege24

Well-Known Member
Mar 25, 2012
46
11
58
Portsmouth, Virginia, United States
cPanel Access Level
Root Administrator
After restoring from a backup late last year, I had problems with backing up to Google Drive, so had to redo the setup for that back in May of this year. Backups have been working fine, until now.

This morning, I received an error in my email. it included a portion of the generated logs.

Code:
Unable to send “/backup/monthly/2021-11-01/system_files.tar” to destination “drive-backups”
Unable to send “/backup/monthly/2021-11-01/accounts/accountname.tar.gz” to destination “drive-backups”
Unable to send “/backup/monthly/2021-11-01/accounts/.master.meta” to destination “drive-backups”
Unable to prune transport “drive-backups”
Unable to remove outdated backup: Token refresh failed at /usr/local/cpanel/3rdparty/perl/532/lib/perl5/cpanel_lib/OAuth/Cmdline.pm line 83
I logged into WHM, and tried to validate, and got the following.

Code:
Validation for transport “drive-backups” failed: Could not create path directory “/public_html/backups/”: Token refresh failed at /usr/local/cpanel/3rdparty/perl/532/lib/perl5/cpanel_lib/OAuth/Cmdline.pm line 83
I double checked, and that path is there. I created it myself, when I set this up.

Per other related issues on the forum, I've checked to ensure that IP6 is not enabled, and it is not. I only have IP4 addresses available on my server. I saw elsewhere that there was a change to the Google Drive API, which was supposed to take effect in September. I have backups happen on the 1st of every month, and this didn't happen on Oct first.

Any help would be greatly appreciated.

Edit: Apparently October's backup never got saved either, and is completely lost, but i've got no errors from that one.
 
Last edited:

quietFinn

Well-Known Member
Feb 4, 2006
2,028
542
493
Finland
cPanel Access Level
Root Administrator
Code:
Validation for transport “drive-backups” failed: Could not create path directory “/public_html/backups/”: Token refresh failed at /usr/local/cpanel/3rdparty/perl/532/lib/perl5/cpanel_lib/OAuth/Cmdline.pm line 83
I think the path can't start with "/".
 

jasoncollege24

Well-Known Member
Mar 25, 2012
46
11
58
Portsmouth, Virginia, United States
cPanel Access Level
Root Administrator
@quietFinn in the backup GUI, the given path has no leading / that's just what the output gives. GUI won't let you lead with a slash, even if you try. :)

@cPanelAnthony Thank you! That wasn't the actual problem, but it pointed me in the right direction to locate it. This was all me. When I set it up the second time, I created a new auth for it, but placed it on the wrong project, accidentally attempting to connect it to my Google Assistant, instead of Drive. Entering/Generating the original credentials used from the original project, and re-validating resolved this instantly. How do I mark this as Solved?
 

jasoncollege24

Well-Known Member
Mar 25, 2012
46
11
58
Portsmouth, Virginia, United States
cPanel Access Level
Root Administrator
This issue resurfaced again, with the exact same message, when I moved the backup destination folder up one level, and validating (created "backups" in my home directory, and pointed the destination to that directory, instead of the one in my public_html directory... trying to make backups publicly inaccessible for the short time they're there).

I checked quotas, and they are higher than those recommended in the link concerning Google API limits (20,000 requests per 100 seonds), and the API in use is correct this time.
 

jasoncollege24

Well-Known Member
Mar 25, 2012
46
11
58
Portsmouth, Virginia, United States
cPanel Access Level
Root Administrator
Apparently this forum doesn't allow editing of posts. I reverted the destination back to the original (working) destination, and tried again, with the same results. Also, it turns out this problem was never actually resolved. The backup for December 1st was never copied to the intended destination, or to my Google Drive.

I'm thinking I might just need to forget this option, as it neither seems intuitive, or stable.
 
  • Like
Reactions: cPanelAnthony