Skip to main content

CPANEL-35244 - backup_user_list API call not working with weekly backups

Comments

10 comments

  • cPanelLauren
    Can you show me what is listed in /backup/2020-08-16/
    0
  • Techs-Y
    Hi, thank you for your reply. 2020-08-16 backup was overwritten so I will show you another one weekly: [CODE=bash]# whmapi1 backup_date_list --- data: backup_set: - 2020-09-10 - 2020-09-08 - 2020-09-06 - 2020-09-05 - 2020-09-03 - 2020-09-01 - 2020-08-30 - 2020-08-23 metadata: command: backup_date_list reason: OK result: 1 version: 1 # whmapi1 backup_user_list restore_point=2020-08-30 --- metadata: command: backup_user_list reason: "Invalid restore point: 2020-08-30" result: 1 version: 1 # stat /backup/weekly/2020-08-30/ File: "/backup/weekly/2020-08-30/" Size: 0 Blocks: 0 IO Block: 16384 directory Device: 28h/40d Inode: 50924650 Links: 2 Access: (0755/drwxr-xr-x) Uid: ( 0/ root) Gid: ( 0/ root) Access: 2020-08-30 02:00:02.415626000 +0200 Modify: 2020-08-30 02:00:02.468762000 +0200 Change: 2020-08-30 02:00:02.468762000 +0200 Birth: -
    As you may see there is no folder /backup/2020-08-30/ but /backup/weekly/2020-08-30/ is there and backups are also there, but WHM API for some reason don't see them.
    0
  • Techs-Y
    Hello, I think, I figured out the behavior of this bug. WHM API for some reason don't expect backups at the /backups/weekly folder. I did some tests and found out that the search is performed only in /backup and /backup/monthly folders when I call whmapi1 backup_user_list restore_point= command. Below I will attach an example. Maybe someone knows a place where I can change the code to include /backup/weekly folder? It would also be great if the cPanel developers fix this bug in next versions. Thank you. Let's say we have a weekly backup from 2020-10-04 and it is located at /backup/weekly folder. When I call whmapi1 backup_user_list restore_point=2020-10-04 I'm receiving "Invalid restore point": [CODE=bash]# whmapi1 backup_user_list restore_point=2020-10-04 --- metadata: command: backup_user_list reason: "Invalid restore point: 2020-10-04" result: 1 version: 1
    But if I append correct path to the command I will receive correct response: [CODE=bash]# whmapi1 backup_user_list restore_point=weekly/2020-10-04 --- data: user: - status: active username: user metadata: command: backup_user_list reason: OK result: 1 version: 1
    0
  • imorandin
    Hi, I have the same problem! Ignacio
    0
  • cPRex Jurassic Moderator
    @imorandin - are you seeing the "invalid restore point" errors as well?
    0
  • imorandin
    @cPRex : yes, that's correct. To "fix" the problem temporarily in my script I did this: [CODE=bash]if [ -d "/backup/$DATE/accounts/$USER" ] || [ -d "/backup/weekly/$DATE/accounts/$USER" ] || [ -d "/backup/monthly/$DATE/accounts/$USER" ]; then # THE BACKUP DOES EXIST, DO SOMETHING fi
    0
  • cPRex Jurassic Moderator
    Thanks for the additional details. I'm doing some testing on this today and I'll reply with an update once I have more details.
    0
  • cPRex Jurassic Moderator
    Alrighty - I did some testing on my end and confirmed that /backup/weekly does not get interpreted by the API call. I've created case CPANEL-35244 for our team to work on this issue, and if you're signed in to our ticket system you can follow along by watching this article:
    0
  • cPRex Jurassic Moderator
    Just posting an update - this will be included in one of the future 92 builds. I don't have an exact version number at this time, but it should be the next build that goes public, which will be 92.0.7.
    0
  • cPRex Jurassic Moderator
    Just providing an update on this - case CPANEL-35244 has been resolved and will be included in the next release of cPanel - 92.0.7 :D
    0

Please sign in to leave a comment.