[GH-ISSUE #155] restoring issue #122

Open
opened 2026-02-27 08:14:27 +03:00 by kerem · 23 comments
Owner

Originally created by @killmasta93 on GitHub (Jan 16, 2021).
Original GitHub issue: https://github.com/lucascbeyeler/zmbackup/issues/155

Hi
currently trying to restore a full backup but it says restore completed but does not restore

zimbra@mail:/root$ zmbackup -l
+---------------------------+------------+----------+----------------------------+
|       Session Name        |    Date    |   Size   |        Description         |
+---------------------------+------------+----------+----------------------------+
| alias-20210110003005      | 01/10/2021 | 5.0M     | Alias Backup               |
| alias-20210111003014      | 01/11/2021 | 5.0M     | Alias Backup               |
| alias-20210112003002      | 01/12/2021 | 5.0M     | Alias Backup               |
| alias-20210113003006      | 01/13/2021 | 5.0M     | Alias Backup               |
| alias-20210114003008      | 01/14/2021 | 5.0M     | Alias Backup               |
| alias-20210115003003      | 01/15/2021 | 5.0M     | Alias Backup               |
| alias-20210116003011      | 01/16/2021 | 5.0M     | Alias Backup               |
| full-20210109121427       | 01/09/2021 | 6.9G     | Full Backup                |
| full-20210110013003       | 01/10/2021 | 6.9G     | Full Backup                |
| inc-20210111013006        | 01/11/2021 | 21M      | Incremental Backup         |
| inc-20210112013006        | 01/12/2021 | 19M      | Incremental Backup         |
| inc-20210113013001        | 01/13/2021 | 71M      | Incremental Backup         |
| inc-20210114013002        | 01/14/2021 | 38M      | Incremental Backup         |
| inc-20210115013008        | 01/15/2021 | 37M      | Incremental Backup         |
| inc-20210116013012        | 01/16/2021 | 69M      | Incremental Backup         |
+---------------------------+------------+----------+----------------------------+
zimbra@mail:/root$ zmbackup -r -m  full-20210110013003  sistemas@mydomain.com
Restore mail process with session full-20210110013003 started at Sat Jan 16 12:09:25 -05 2021
Restore mail process with session full-20210110013003 completed at Sat Jan 16 12:09:25 -05 2021

image

Then i tried to restore with this option but screwd my zimbra server, i had to restore from backup


zimbra@mail:/root$ zmbackup -r  full-20210110013003  sistemas@mydomain.com
Restore LDAP process with session full-20210110013003 started at Sat Jan 16 12:16:00 -05 2021

Error during the restore process for account n/gin/gteman/g@mydomain. Error message below:
n/gin/gteman/g@mydomain.com: /mnt/full-20210110013003/n/gin/gteman/g@mydomain.ldiff: No such file or directorygrep: /mnt/full-20210110013003/n/gin/gteman/g@mydomain.ldiff: No such file or directory
awk: cmd. line:1: print $2
awk: cmd. line:1: ^ syntax error
Restore LDAP process with session full-20210110013003 completed at Sat Jan 16 12:16:00 -05 2021
Restore mail process with session full-20210110013003 started at Sat Jan 16 12:16:00 -05 2021
Restore mail process with session full-20210110013003 completed at Sat Jan 16 12:16:01 -05 2021

Originally created by @killmasta93 on GitHub (Jan 16, 2021). Original GitHub issue: https://github.com/lucascbeyeler/zmbackup/issues/155 Hi currently trying to restore a full backup but it says restore completed but does not restore ``` zimbra@mail:/root$ zmbackup -l +---------------------------+------------+----------+----------------------------+ | Session Name | Date | Size | Description | +---------------------------+------------+----------+----------------------------+ | alias-20210110003005 | 01/10/2021 | 5.0M | Alias Backup | | alias-20210111003014 | 01/11/2021 | 5.0M | Alias Backup | | alias-20210112003002 | 01/12/2021 | 5.0M | Alias Backup | | alias-20210113003006 | 01/13/2021 | 5.0M | Alias Backup | | alias-20210114003008 | 01/14/2021 | 5.0M | Alias Backup | | alias-20210115003003 | 01/15/2021 | 5.0M | Alias Backup | | alias-20210116003011 | 01/16/2021 | 5.0M | Alias Backup | | full-20210109121427 | 01/09/2021 | 6.9G | Full Backup | | full-20210110013003 | 01/10/2021 | 6.9G | Full Backup | | inc-20210111013006 | 01/11/2021 | 21M | Incremental Backup | | inc-20210112013006 | 01/12/2021 | 19M | Incremental Backup | | inc-20210113013001 | 01/13/2021 | 71M | Incremental Backup | | inc-20210114013002 | 01/14/2021 | 38M | Incremental Backup | | inc-20210115013008 | 01/15/2021 | 37M | Incremental Backup | | inc-20210116013012 | 01/16/2021 | 69M | Incremental Backup | +---------------------------+------------+----------+----------------------------+ ``` ``` zimbra@mail:/root$ zmbackup -r -m full-20210110013003 sistemas@mydomain.com Restore mail process with session full-20210110013003 started at Sat Jan 16 12:09:25 -05 2021 Restore mail process with session full-20210110013003 completed at Sat Jan 16 12:09:25 -05 2021 ``` ![image](https://user-images.githubusercontent.com/13953629/104818240-5b47c900-57f4-11eb-9a1b-349560714a05.png) Then i tried to restore with this option but screwd my zimbra server, i had to restore from backup ``` zimbra@mail:/root$ zmbackup -r full-20210110013003 sistemas@mydomain.com Restore LDAP process with session full-20210110013003 started at Sat Jan 16 12:16:00 -05 2021 Error during the restore process for account n/gin/gteman/g@mydomain. Error message below: n/gin/gteman/g@mydomain.com: /mnt/full-20210110013003/n/gin/gteman/g@mydomain.ldiff: No such file or directorygrep: /mnt/full-20210110013003/n/gin/gteman/g@mydomain.ldiff: No such file or directory awk: cmd. line:1: print $2 awk: cmd. line:1: ^ syntax error Restore LDAP process with session full-20210110013003 completed at Sat Jan 16 12:16:00 -05 2021 Restore mail process with session full-20210110013003 started at Sat Jan 16 12:16:00 -05 2021 Restore mail process with session full-20210110013003 completed at Sat Jan 16 12:16:01 -05 2021 ```
Author
Owner

@lucascbeyeler commented on GitHub (Jan 16, 2021):

Hi, which version?

<!-- gh-comment-id:761615830 --> @lucascbeyeler commented on GitHub (Jan 16, 2021): Hi, which version?
Author
Owner

@killmasta93 commented on GitHub (Jan 16, 2021):

thanks for the reply running 1.2.5

<!-- gh-comment-id:761621961 --> @killmasta93 commented on GitHub (Jan 16, 2021): thanks for the reply running 1.2.5
Author
Owner

@lucascbeyeler commented on GitHub (Jan 18, 2021):

That's probably Zimbra - their API is broken for backing and restoring data for a long time.

<!-- gh-comment-id:762256889 --> @lucascbeyeler commented on GitHub (Jan 18, 2021): That's probably Zimbra - their API is broken for backing and restoring data for a long time.
Author
Owner

@killmasta93 commented on GitHub (Jan 18, 2021):

thanks for the reply, so im able to restoring running this command

su - zimbra -c "zmmailbox -z -m sistemas@mydomain.com postRestURL '//?fmt=tgz&resolve=skip' /mnt/full-20210110013003/sistemas@mydomain.com.tgz";

<!-- gh-comment-id:762281735 --> @killmasta93 commented on GitHub (Jan 18, 2021): thanks for the reply, so im able to restoring running this command `su - zimbra -c "zmmailbox -z -m sistemas@mydomain.com postRestURL '//?fmt=tgz&resolve=skip' /mnt/full-20210110013003/sistemas@mydomain.com.tgz";`
Author
Owner

@lucascbeyeler commented on GitHub (Jan 18, 2021):

possible - give it a try. Worst case scenario I change the code to use this CLI command instead

<!-- gh-comment-id:762355231 --> @lucascbeyeler commented on GitHub (Jan 18, 2021): possible - give it a try. Worst case scenario I change the code to use this CLI command instead
Author
Owner

@killmasta93 commented on GitHub (Jan 18, 2021):

so the above command works to restore, but the zmbackup command line does not

<!-- gh-comment-id:762376430 --> @killmasta93 commented on GitHub (Jan 18, 2021): so the above command works to restore, but the zmbackup command line does not
Author
Owner

@HcKTR commented on GitHub (Jan 19, 2021):

Hello, thank you for your return. I haven't tried it yet. I took note of this command.

<!-- gh-comment-id:762764454 --> @HcKTR commented on GitHub (Jan 19, 2021): Hello, thank you for your return. I haven't tried it yet. I took note of this command.
Author
Owner

@killmasta93 commented on GitHub (Feb 1, 2021):

yeah thats why for now only restoring mailbox using the command, waiting till the new update to fix this issue

su - zimbra -c "zmmailbox -z -m sistemas@mydomain.com postRestURL '//?fmt=tgz&resolve=skip' /mnt/full-20210110013003/sistemas@mydomain.com.tgz";

<!-- gh-comment-id:771243834 --> @killmasta93 commented on GitHub (Feb 1, 2021): yeah thats why for now only restoring mailbox using the command, waiting till the new update to fix this issue `su - zimbra -c "zmmailbox -z -m sistemas@mydomain.com postRestURL '//?fmt=tgz&resolve=skip' /mnt/full-20210110013003/sistemas@mydomain.com.tgz";`
Author
Owner

@lucascbeyeler commented on GitHub (Feb 6, 2021):

Hi,

I did not release yet a new version but for the latest commit I'm using zmmailbox. Could you please try again with that version and see if the problem persists?

<!-- gh-comment-id:774524140 --> @lucascbeyeler commented on GitHub (Feb 6, 2021): Hi, I did not release yet a new version but for the latest commit I'm using zmmailbox. Could you please try again with that version and see if the problem persists?
Author
Owner

@killmasta93 commented on GitHub (Feb 8, 2021):

thanks for the reply, should i update it? and retry this command?
zimbra@mail:/root$ zmbackup -r -m full-20210110013003 sistemas@mydomain.com

<!-- gh-comment-id:774838787 --> @killmasta93 commented on GitHub (Feb 8, 2021): thanks for the reply, should i update it? and retry this command? ` zimbra@mail:/root$ zmbackup -r -m full-20210110013003 sistemas@mydomain.com`
Author
Owner

@lucascbeyeler commented on GitHub (Feb 8, 2021):

yes, please

<!-- gh-comment-id:775298422 --> @lucascbeyeler commented on GitHub (Feb 8, 2021): yes, please
Author
Owner

@killmasta93 commented on GitHub (Feb 9, 2021):

so i tried the following updated to 1.2.6 and restored another mailbox but i got this

zimbra@mail:/root/zmbackup$ zmbackup -r -m /mnt/full-20210207013003 contabilidad@mydomain.com
Nothing to do. Closing...

i checked the size


-rwxr-xr-x 1 zimbra zimbra 1.1K Feb  7 01:30 contabilidad@mydomain.ldiff
-rwxr-xr-x 1 zimbra zimbra  72M Feb  7 01:31 contabilidad@mydomain.tgz

Thank you

<!-- gh-comment-id:775648488 --> @killmasta93 commented on GitHub (Feb 9, 2021): so i tried the following updated to 1.2.6 and restored another mailbox but i got this ``` zimbra@mail:/root/zmbackup$ zmbackup -r -m /mnt/full-20210207013003 contabilidad@mydomain.com Nothing to do. Closing... ``` i checked the size ``` -rwxr-xr-x 1 zimbra zimbra 1.1K Feb 7 01:30 contabilidad@mydomain.ldiff -rwxr-xr-x 1 zimbra zimbra 72M Feb 7 01:31 contabilidad@mydomain.tgz ``` Thank you
Author
Owner

@lucascbeyeler commented on GitHub (Feb 10, 2021):

zimbra@mail:/root/zmbackup$ zmbackup -r -m full-20210207013003 contabilidad@mydomain.com

<!-- gh-comment-id:776755969 --> @lucascbeyeler commented on GitHub (Feb 10, 2021): zimbra@mail:/root/zmbackup$ zmbackup -r -m full-20210207013003 contabilidad@mydomain.com
Author
Owner

@lucascbeyeler commented on GitHub (Mar 14, 2021):

Closing the ticket because of inactivity - if the problem persists please feel free to reopen.

<!-- gh-comment-id:798889530 --> @lucascbeyeler commented on GitHub (Mar 14, 2021): Closing the ticket because of inactivity - if the problem persists please feel free to reopen.
Author
Owner

@killmasta93 commented on GitHub (Mar 17, 2021):

thanks for the reply, and sorry for the late reply, so i retied and got this error

zimbra@mail:/mnt$ zmbackup -r -m inc-20210315013001 contabilidad@mydomain.com
Restore mail process with session inc-20210315013001 started at Tue Mar 16 22:08:05 -05 2021Error during the restore process for account contabilidad@tixx/xx.com.co. Error message below:
contabilidad@tixx/xx.com.co: ERROR: account.NO_SUCH_ACCOUNT (no such account: contabilidad@tixx/xx.com.co)

Restore mail process with session inc-20210315013001 completed at Tue Mar 16 22:08:17 -05 2021
<!-- gh-comment-id:800758531 --> @killmasta93 commented on GitHub (Mar 17, 2021): thanks for the reply, and sorry for the late reply, so i retied and got this error ``` zimbra@mail:/mnt$ zmbackup -r -m inc-20210315013001 contabilidad@mydomain.com Restore mail process with session inc-20210315013001 started at Tue Mar 16 22:08:05 -05 2021Error during the restore process for account contabilidad@tixx/xx.com.co. Error message below: contabilidad@tixx/xx.com.co: ERROR: account.NO_SUCH_ACCOUNT (no such account: contabilidad@tixx/xx.com.co) Restore mail process with session inc-20210315013001 completed at Tue Mar 16 22:08:17 -05 2021 ```
Author
Owner

@lucascbeyeler commented on GitHub (Apr 4, 2021):

You are using -m option for an account that does not exist. That´s the issue

<!-- gh-comment-id:813014274 --> @lucascbeyeler commented on GitHub (Apr 4, 2021): You are using -m option for an account that does not exist. That´s the issue
Author
Owner

@killmasta93 commented on GitHub (Apr 4, 2021):

Thanks for the reply. it says the account does not exist but it does, i tried another account to see what happens, whats odd is that not sure why it shows like n/gky

zimbra@mail:/mnt$ zmbackup -r -m inc-20210403013002 sky@mydomain.com.co
Restore mail process with session inc-20210403013002 started at Sun Apr  4 17:53:50 -05 2021Error during the restore process for account n/gky@txxx/gcue.com.co. Error message below:
n/gky@tiren/gcue.com.co: ERROR: account.NO_SUCH_ACCOUNT (no such account: n/gky@txxx/gcue.com.co)

Restore mail process with session inc-20210403013002 completed at Sun Apr  4 17:54:00 -05 2021

-rwxr-xr-x 1 zimbra zimbra 1.3K Apr 3 01:34 sky@mydomain.com.co.tgz

Thank you

<!-- gh-comment-id:813112030 --> @killmasta93 commented on GitHub (Apr 4, 2021): Thanks for the reply. it says the account does not exist but it does, i tried another account to see what happens, whats odd is that not sure why it shows like n/gky ``` zimbra@mail:/mnt$ zmbackup -r -m inc-20210403013002 sky@mydomain.com.co Restore mail process with session inc-20210403013002 started at Sun Apr 4 17:53:50 -05 2021Error during the restore process for account n/gky@txxx/gcue.com.co. Error message below: n/gky@tiren/gcue.com.co: ERROR: account.NO_SUCH_ACCOUNT (no such account: n/gky@txxx/gcue.com.co) Restore mail process with session inc-20210403013002 completed at Sun Apr 4 17:54:00 -05 2021 ``` ` -rwxr-xr-x 1 zimbra zimbra 1.3K Apr 3 01:34 sky@mydomain.com.co.tgz` Thank you
Author
Owner

@lucascbeyeler commented on GitHub (Apr 5, 2021):

I mean not the file, I mean the account inside zimbra server... -m is just to restore the e-mails and nothing more. And that´s not Zmbackup error - that´s your mailserver error

<!-- gh-comment-id:813285401 --> @lucascbeyeler commented on GitHub (Apr 5, 2021): I mean not the file, I mean the account inside zimbra server... -m is just to restore the e-mails and nothing more. And that´s not Zmbackup error - that´s your mailserver error
Author
Owner

@killmasta93 commented on GitHub (Apr 7, 2021):

thanks for the reply, but the account sky@mydomain.com.co does exist

image

<!-- gh-comment-id:814566687 --> @killmasta93 commented on GitHub (Apr 7, 2021): thanks for the reply, but the account sky@mydomain.com.co does exist ![image](https://user-images.githubusercontent.com/13953629/113804459-2cbaf980-9724-11eb-8b09-a2457c292827.png)
Author
Owner

@wh4u commented on GitHub (Apr 14, 2021):

The same behavior occurred to me also

<!-- gh-comment-id:819576512 --> @wh4u commented on GitHub (Apr 14, 2021): The same behavior occurred to me also
Author
Owner

@killmasta93 commented on GitHub (Apr 25, 2021):

any updates?

<!-- gh-comment-id:826382689 --> @killmasta93 commented on GitHub (Apr 25, 2021): any updates?
Author
Owner

@killmasta93 commented on GitHub (May 17, 2021):

bump?

<!-- gh-comment-id:842688226 --> @killmasta93 commented on GitHub (May 17, 2021): bump?
Author
Owner

@tofuSCHNITZEL commented on GitHub (Aug 30, 2022):

zimbra@mail:/root$ zmbackup -r full-20210110013003 sistemas@mydomain.com
Restore LDAP process with session full-20210110013003 started at Sat Jan 16 12:16:00 -05 2021

Error during the restore process for account n/gin/gteman/g@mydomain. Error message below:
n/gin/gteman/g@mydomain.com: /mnt/full-20210110013003/n/gin/gteman/g@mydomain.ldiff: No such file or directorygrep: /mnt/full-20210110013003/n/gin/gteman/g@mydomain.ldiff: No such file or directory
awk: cmd. line:1: print $2
awk: cmd. line:1: ^ syntax error
Restore LDAP process with session full-20210110013003 completed at Sat Jan 16 12:16:00 -05 2021
Restore mail process with session full-20210110013003 started at Sat Jan 16 12:16:00 -05 2021
Restore mail process with session full-20210110013003 completed at Sat Jan 16 12:16:01 -05 2021

this is fixed here:
github.com/tofuSCHNITZEL/zmbackup@d5028344fe
the bash replacement was not working as intended

<!-- gh-comment-id:1232160626 --> @tofuSCHNITZEL commented on GitHub (Aug 30, 2022): > zimbra@mail:/root$ zmbackup -r full-20210110013003 sistemas@mydomain.com > Restore LDAP process with session full-20210110013003 started at Sat Jan 16 12:16:00 -05 2021 > > Error during the restore process for account n/gin/gteman/g@mydomain. Error message below: > n/gin/gteman/g@mydomain.com: /mnt/full-20210110013003/n/gin/gteman/g@mydomain.ldiff: No such file or directorygrep: /mnt/full-20210110013003/n/gin/gteman/g@mydomain.ldiff: No such file or directory > awk: cmd. line:1: print $2 > awk: cmd. line:1: ^ syntax error > Restore LDAP process with session full-20210110013003 completed at Sat Jan 16 12:16:00 -05 2021 > Restore mail process with session full-20210110013003 started at Sat Jan 16 12:16:00 -05 2021 > Restore mail process with session full-20210110013003 completed at Sat Jan 16 12:16:01 -05 2021 > ``` this is fixed here: https://github.com/tofuSCHNITZEL/zmbackup/commit/d5028344feb83342d73e5977dfc138c404a913cc the bash replacement was not working as intended
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/zmbackup#122
No description provided.