Making a standardize VM for installation

IT_Architect

Verified User
Joined
Feb 27, 2006
Messages
1,091
I would like to know if there is a good way to make a standarized VM that has DA pre-installed. I tried copying one over from another install. What I noticed is when I did an admin restore, the users seem to have restored fine, but not admin.

I get the error:
"Error extracting /home/admin/backups/backup/home.tar.gz : scripts/: Can't restore time
scripts/purge_system_acct_emails.sh: Can't unlink already-existing object
tar: Error exit delayed from previous errors."

I don't know if anyone here has done this before or what they did or ... I will say the main domain, server name, etc. will change also.

Thanks!
 
Hello,

VPS providers do offer installation of virtual servers from images with a pre-installed Directadmin, i.e. you can order a VPS with a pre-installed Directadmin. In very general words it's a snapshot of a Linux box with Directadmin and minimum things pre-configured, then later at a moment of creating of a new VM you need to run scripts (automatically, pre-configured) to change passwords: system for admin, root, mysql for da_admin, root, roundcube.

I configured virtual servers for my customers from which later they created images for future installs. An image does not need anything special, just a minimal set of what you want to have.

Depending on what virtualization system you use, please read official docs and community guides on how to create images with a pre-installed set of software.
 
...later at a moment of creating of a new VM you need to run scripts (automatically, pre-configured) to change passwords: system for admin, root, mysql for da_admin, root, roundcube. I configured virtual servers for my customers...Depending on what virtualization system you use, please read official docs and community guides on how to create images with a pre-installed set of software.
I didn't know that docs existed in that area. I will check that out. It sounds like that admin is one you need to configure by hand and is not something you can restore from a previous install as in upgrading to a now OS and new install of DA. I would guess that the procedure wouldn't be that different for ESXi than a VPS. The only real difference is ESXi is a separate instance of the OS and VPS is a shared instance. I wouldn't expect DA to know the difference between bare metal, VM, or VPS from other than a licensing perspective.

Thanks!
 
Last edited:
Or you you mean that Directadmin community create an image and share it?
No, not at all. With such variation in environment and preferences I don't see how I could anyway, and DA probably would have done it for us if they could. This is just for my own use so I don't have to do from-scratch installs every time I want to make a VM, which isn't that often. I accidentally blew away a VM with snapshots I could have used. Copying one, stripping the domains, etc. didn't work so good. A lot of details go into a good setup, and details get missed the second, third, fourth, time etc., and it takes a lot of time. I do have documented step by step of how I've done them, but since I'm starting over again, I wanted to get the best practices from guys like you on this forum.

Thanks TONS!!!
 
Oh duh! I just noticed when I went to use the links, they were for ESXi. I know how to do that, and even better. Just do a regular install and leave the snapshots in place so you can rewind anywhere, including before DA was installed. I was looking for a way to change everything on a copy of an ESXi VM, already set up for another server, then change the admin domain, certs, and pull in the backups. The problem I had was not restoring the other domains to the new server, it was restoring admin over the current admin from the other server. Maybe you cannot do that, I don't know. When I tried as mentioned in the first post, I got the error:

"Error extracting /home/admin/backups/backup/home.tar.gz : scripts/: Can't restore time
scripts/purge_system_acct_emails.sh: Can't unlink already-existing object
tar: Error exit delayed from previous errors."
 
The error does not look familiar to me, so I don't have a ready solution for the case.

Directadmin does not forbid restoring any users including admin by default.

Some ideas to get more clues, details:

- check directadmin logs
- try the restore process in a debug mode

or contact directadmin support over tickets to get a free help from them.
 
The error does not look familiar to me, so I don't have a ready solution for the case.
I will try it again later. Admin would not be too impractical to be reconstructed by hand.

Thanks for all of your help!
 
By the way scripts/purge_system_acct_emails.sh is a script under /home/admin/ or what is it from?

I don't have
purge_system_acct_emails.sh on my end.

What are the permissions on it?
 
By the way scripts/purge_system_acct_emails.sh is a script under /home/admin/ or what is it from? I don't have purge_system_acct_emails.sh on my end. What are the permissions on it?
Interesting! That may be my problem.

Thanks!
 
Back
Top