Creating a backup from a non-virtualmin/webmin server

Hello all,

I’ve been trying to create a backup from a non-virtualmin/webmin server, but I’ve been having problems. I exported a domain and studied the format, and it seems pretty straightforward. However, whenever I import it, it skips every other user.

For example, if this were the user list:
A
B
C
D
E
F
G

It would actually put in:
A
C
E
G

It would skip:
B
D
F

Here’s a sample of the domain.com_mail_users file:
a.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/a:/dev/null:a@domain.com:0:-:-:-:-
b.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/b:/dev/null:b@domain.com:0:-:-:-:-
c.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/c:/dev/null:c@domain.com:0:-:-:-:-
d.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/d:/dev/null:d@domain.com:0:-:-:-:-

Here’s a sample of the domain.com_mail_plainpass file:
a.domain.com encrypted=encryptedpw
a.domain.com=plainpw
b.domain.com encrypted=encryptedpw
b.domain.com=plainpw
c.domain.com encrypted=encryptedpw
c.domain.com=plainpw
d.domain.com encrypted=encryptedpw
d.domain.com=plainpw

Here’s a sample of the domain.com_mail_cron file:
0

Here’s a sample of the domain.com_mail_aliases file:

Ok…any clues?

Thanks
Phillip

Nevermind! I figured it out. There needs to be a blank line inbetween each line in the domain.com_mail_users file. I believe thats used for something else as well. I was looking in the source code, but now I’ve forgotten :slight_smile:

WRONG domain.com_mail_users file:
"a.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/a:/dev/null:a@domain.com:0:-:-:-:-
b.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/b:/dev/null:b@domain.com:0:-:-:-:-
c.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/c:/dev/null:c@domain.com:0:-:-:-:-
d.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/d:/dev/null:d@domain.com:0:-:-:-:-"

RIGHT domain.com_mail_users file:
"a.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/a:/dev/null:a@domain.com:0:-:-:-:-

b.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/b:/dev/null:b@domain.com:0:-:-:-:-

c.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/c:/dev/null:c@domain.com:0:-:-:-:-

d.domain.com:encryptedpw:-1:-1::/home/domain.com/homes/d:/dev/null:d@domain.com:0:-:-:-:-

"