Page 1 of 1

Problem permissions v-restore-user

Posted: Mon Oct 07, 2019 9:06 pm
by _javierobcn_
Hello using Vesta CP VersiĆ³n 0.9.8 (amd64) and Ubuntu 18.04.3 LTS

From the folder /backup, as sudo i run:

root@zzz:/backup# /usr/local/vesta/bin/v-restore-user xxx xxx.2019-10-05_15-25-02.tar

-- WEB --
2019-10-07 16:49:34 xxx

-- DNS --
2019-10-07 16:49:36 xxx

-- MAIL --
2019-10-07 16:49:36 xxx
tar (child): /backup/tmp.VcxJLEB6iX/mail/xxx/accounts.tar.gz: Cannot open: Permission denied
tar (child): Error is not recoverable: exiting now

gzip: stdin: unexpected end of file
tar: Child returned status 2
tar: Error is not recoverable: exiting now
Error: Can't unpack xxx mail account container


Any comment is welcome, the tar file seems correct, is not corrupted and i can decompress manually

Re: Problem permissions v-restore-user

Posted: Wed Oct 09, 2019 4:47 pm
by disc_over
Hello, same error here. Migrating user accounts to a new server can't finish, due to tar/untar/gzip permission error.

Vesta 0.9.8 (x86_64) Release 26 on CentOS Linux 7 (Core)

Error at:

Code: Select all

-- MAIL --
2019-10-09 18:25:47 domain.com
tar: /backup/tmp.40nbbnhTUx/mail/domain.com/accounts.tar.gz: No se puede open: Permiso denegado
tar: Error is not recoverable: exiting now
Error: Can't unpack domain.com mail account container
-
tar (child): /backup/tmp.40nbbnhTUx/web/domain.com/domain_data.tar.gz: No se puede open: Permiso denegado
tar (child): Error is not recoverable: exiting now
gzip: stdin: unexpected end of file
v-restore-user was called from /backup

I manually managed to restore mail and web accounts, but for users with dozens of domains/accounts is exhausting. I will be very pleased if anyone can provide a workaround fix to this issue :)

Re: Problem permissions v-restore-user

Posted: Thu Oct 10, 2019 2:15 pm
by disc_over
Hi again,

I reinstalled CentOS 7 + vesta. During the first backup restoration errors ocurred, as expected. Then tried restoring a dummy account with video files up to 1GB and it worked. After that, script v-restore-user worked for domains and mail accounts of anysize of anyuser.

However, with all backups vesta always appends this warning to /var/log/vesta/error.log

Code: Select all

2019-10-10 15:58:55 v-restore-user  'dummy' 'dummy.2019-10-10_04-22-08.tar' [Error 3]
I couldn't figure out what was wrong from the beginning to prevent this issue in future reinstalls/migrations -_-

Re: Problem permissions v-restore-user

Posted: Wed Dec 11, 2019 6:42 pm
by Pinakas
Change /backup permission folder from 700 to 755 and try...

Re: Problem permissions v-restore-user

Posted: Tue Jan 07, 2020 3:36 am
by danberlyoung
I was having the same problem and finally discovered what was causing my issue.

My backup file had been downloaded on my laptop twice and then uploaded to the server. So, the file I was trying to restore had "-2" appended to the basename and looked like this:

Code: Select all

mynewusername.2020-01-06_05-10-57-2.tar
I removed the "-2" so it looked like this and it worked.

Code: Select all

mynewusername.2020-01-06_05-10-57.tar
Hope this helps someone else. Vesta, how about a little more descriptive error message here?