Forums

Resolved
0 votes
I am moving my ClearOS Gateway to a new PC. I have already built and installed the latest version of ClearOS Home on the new machine and configured the IP's to match my current (Old Machine). I have saved a backup of the current config for a restore on the new machine. My question is what all is in the backup. Will I need to go to the Marketplace to get all the features I have installed on my current (old) machine or will the new machine get them from the backup (such as Gateway Management Home). I am trying to make the switch from old to new machine as quick and easy as possible so that I can just swap the Ethernet cables and perform a restore. Please let me know what all I would need to do. Thanks in advance for the help/info.
In Backup
Wednesday, March 27 2019, 07:11 PM
Share this post:

Accepted Answer

Wednesday, March 27 2019, 08:27 PM - #Permalink
Resolved
0 votes
The easiest option would probably have been to dd from disk to disk, but it does not work with RAID. You would then need to extend the disk partition. From the route you've gone down, you could have done a config restore very early on. Anyway, have a look at this howto as most of the stuff is relevant. It may be easiest to put your new server into standalone mode first otherwise you have to play around with firewalling and your NIC configurations.

In some ways, the biggest gotcha is the NIC interfaces. You must not end up with both the LAN and WAN on the same subnet or routing will fail. You virtually want to get everything set up then, right at the end, change your NIC configuration and even the mode (standalone/gateway) from the console.

If you keep your new machine in Gateway mode, you'll need to connect its WAN to your current LAN (watch out for subnet conflicts). If you do that, set up a temporary custom firewall rule in it like:
$IPTABLES -I INPUT -s your_current_LAN_subnet -j ACCEPT
You'll then get full access to ClearOS from the WAN.
The reply is currently minimized Show
Responses (5)
  • Accepted Answer

    Monday, June 17 2019, 08:25 PM - #Permalink
    Resolved
    0 votes
    You've missed the point Patrick; as the mail server is a VM, in the event of a (main) server crash, I don't need to get the parent server going immediately - I just copy the VM to a PC, run it up and I've no email downtime and I can repair the parent at my own convenience, instead of it being an immediate necessity.

    My system disk(s) run to 3G - I can image/restore those inside 5 minutes .. it takes longer to swap disks! - and I don't need big disks; only the data disks need to be any size at all. I just run up a live CD/DVD, run DD to an image (held on USB) - doesn't have to be done that often, just often enough to cope with major updates, otherwise you just do a normal update after restoring the image. I haven't tried it, but I suspect it'd be quite possible to run the system disk from a USB flash drive.

    Or have I misunderstood your point?
    The reply is currently minimized Show
  • Accepted Answer

    Monday, June 17 2019, 07:50 PM - #Permalink
    Resolved
    0 votes
    Richard George wrote:

    The nice thing about this is that I can get a backup of the complete email server VM by shutting down overnight, backing up the VM and restarting it the following morning. Makes disaster recovery a doddle! As it's a VM, it also means that in the event of a server crash, I can just temporarily move the mail-server VM to a PC and run it from there until I get the parent server running again.

    If I had the money(!), the file server would also be a VM - as it is, the /store (from app-storage) is held on mirrored disks, so if the system disk goes down (as it did over the weekend), I just needed to built a new system disk (from image) and I was back up and running.


    Maybe a suggestion.
    You can clone your system disk easily with a dual docking device.
    I’ve an Ewent EW7014 and clone my system disk once in a while and this takes approx 40 minutes.
    The reply is currently minimized Show
  • Accepted Answer

    Monday, June 17 2019, 07:12 PM - #Permalink
    Resolved
    0 votes
    Interesting.

    I've actually done away with the Gateway setup and just use routers/hubs with static LAN addresses.

    I've two COS7 boxes; one is a (4-core) file server (incl. Nextcloud), the other (16Gb [soon to be 32G] 8-core) is a DHCP, DNS, ProxyPass and VM server, with a COS7 VM acting solely as a mail server. The DHCP server specifies the router that's physically connected to the cable modem as the gateway. That router just forwards the necessary ports to either the mail server (IMAP/SMTP) or to the ProxyPass server for HTTP(S) routing/handling to either the mail server web interface, Nextcloud, or a webserver.

    The advantage of this that internet traffic goes straight to the router, IMAPS/SMTPS connections are sent direct to the mail server, whilst Nextcloud, webmail and webserver connections all get covered by LetsEncrypt certificates, even though the end-service is handled by different physical (or virtual) machines. Passwords for mail services are completely separate from file server or Windows Networking passwords - even usernames can be different.

    Works a treat.

    Oh - and the router/gateway (TP-LINK) has a built-in interface to Dyn.com - all you provide is the domain, username and password. It also has a built-in OpenVPN server.

    The nice thing about this is that I can get a backup of the complete email server VM by shutting down overnight, backing up the VM and restarting it the following morning. Makes disaster recovery a doddle! As it's a VM, it also means that in the event of a server crash, I can just temporarily move the mail-server VM to a PC and run it from there until I get the parent server running again.

    If I had the money(!), the file server would also be a VM - as it is, the /store (from app-storage) is held on mirrored disks, so if the system disk goes down (as it did over the weekend), I just needed to built a new system disk (from image) and I was back up and running.
    The reply is currently minimized Show
  • Accepted Answer

    Saturday, May 18 2019, 12:52 PM - #Permalink
    Resolved
    0 votes
    I have two ways of doing this.
    1. Move the current hard drive to the new hardware and repair the networking.
    2. Clonezilla the current hard drive and fix the networking in the new machine.

    Clonezilla is cool because you can clone a hard drive to a hardware RAID array.
    There are some LVM things you have to do to expand the LVMs to fill the larger partitions that Clonezilla made for you.
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, March 27 2019, 08:37 PM - #Permalink
    Resolved
    0 votes
    Thanks for the info and the link to the guide. Are the Marketplace apps and their settings in the backup?
    The reply is currently minimized Show
Your Reply