Results 1 to 10 of 10

Thread: Making a standardize VM for installation

  1. #1
    Join Date
    Feb 2006
    Posts
    842

    Making a standardize VM for installation

    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!

  2. #2
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    12,494
    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.

  3. #3
    Join Date
    Feb 2006
    Posts
    842
    Quote Originally Posted by zEitEr View Post
    ...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 by IT_Architect; 11-01-2018 at 02:03 PM.

  4. #4
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    12,494
    Here are the links I've found in the top of results from Google:

    - How to Customize an ESXi image using VMware Image Builder
    - How to build custom ESXi installation image - LearnVMware.online
    - Using vSphere ESXi Image Builder CLI

    Sure, you can find even more.


    Or you you mean that Directadmin community create an image and share it? If this is the case you'd better contact Directadmin sales, as publishing such an image might violate their licensing rules.

  5. #5
    Join Date
    Feb 2006
    Posts
    842
    Quote Originally Posted by zEitEr View Post
    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!!!

  6. #6
    Join Date
    Feb 2006
    Posts
    842
    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."

  7. #7
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    12,494
    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.

  8. #8
    Join Date
    Feb 2006
    Posts
    842
    Quote Originally Posted by zEitEr View Post
    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!

  9. #9
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    12,494
    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?

  10. #10
    Join Date
    Feb 2006
    Posts
    842
    Quote Originally Posted by zEitEr View Post
    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!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •