Ackles
asked on
export linux system settings to clone configuration
Hi,
I want to know if there is a way to export all system settings from a linux box which can be later scripted to setup a new system?
I want all the system settings to be included.
Regards,
A
I want to know if there is a way to export all system settings from a linux box which can be later scripted to setup a new system?
I want all the system settings to be included.
Regards,
A
ASKER
CentOS
CentOs, same version to same version? Oldversion to new version? Which is your current version you are using?
ASKER
Currently its 6, but it could also be possible that we want to go for newer version
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
For a newer version you need to do more work,
the trick with syncing the packages might not work as sometimes packagenames change.
In this case if you want to switch to 7 you need to re-setup by hand, install all necessary software and copy config files of this packages. Sometimes the config files change options in newer releases so this will not always work and really depends on what software you are trying to migrate.
the trick with syncing the packages might not work as sometimes packagenames change.
In this case if you want to switch to 7 you need to re-setup by hand, install all necessary software and copy config files of this packages. Sometimes the config files change options in newer releases so this will not always work and really depends on what software you are trying to migrate.
ASKER
Thanks, I will Test it.
What about Network & firewall settings?
I am trying to stimulate that I can have all the config taken out of active system, so just in case if there is a failure I can quickly setup a new system with same configuration.
What about Network & firewall settings?
I am trying to stimulate that I can have all the config taken out of active system, so just in case if there is a failure I can quickly setup a new system with same configuration.
you best save contents of
/etc/
configs, etc.
/var/
e.g. databases.
Network settings are in files sitting in /etc/
firewall settings depending on what kind of firewall you are using. we use our own scripts here so ive no idea where and what the defaults for CentOS are exactly. But I'm guessing they are also somewhere in /etc/... As far as I remember, there are several different firewalls provided on RedHat based distros.
/etc/
configs, etc.
/var/
e.g. databases.
Network settings are in files sitting in /etc/
firewall settings depending on what kind of firewall you are using. we use our own scripts here so ive no idea where and what the defaults for CentOS are exactly. But I'm guessing they are also somewhere in /etc/... As far as I remember, there are several different firewalls provided on RedHat based distros.
For the scenario of a sudden need of resetup i really would suggest you use images.
As its much much faster as the other approach.
But it might not work if you need to clone to totally different hardware. If hardware is slightly different you can fix the clone after the image was cloned to the new hardware. This fixing mainly to fix the grub configuration, sometimes fstab and the drivers necessary for network, graphics(X11 if any), etc.
e.g. hardware to new to run CentOS 6, or disks cant be partitioned the same way on the new machine as the configuration is different (RAID controllers, SSD vs HDD, etc. pp)
As its much much faster as the other approach.
But it might not work if you need to clone to totally different hardware. If hardware is slightly different you can fix the clone after the image was cloned to the new hardware. This fixing mainly to fix the grub configuration, sometimes fstab and the drivers necessary for network, graphics(X11 if any), etc.
e.g. hardware to new to run CentOS 6, or disks cant be partitioned the same way on the new machine as the configuration is different (RAID controllers, SSD vs HDD, etc. pp)
ASKER
we have VM's so in case of failure, the hardware will always be same.
That is why I was thinking to have everything exported & make it automated....
Your thoughts?
A
That is why I was thinking to have everything exported & make it automated....
Your thoughts?
A
If you VMs its fine, then you can create an identical machine and just clone it with clonezilla.
its a 1 to 1 copy with identical configuration, Network, Packages, Firewall and apps.
Only for an upgrade to CentOS 7 you need to manually reinstall, install proper packages and copy over the configs of the services you are running.
its a 1 to 1 copy with identical configuration, Network, Packages, Firewall and apps.
Only for an upgrade to CentOS 7 you need to manually reinstall, install proper packages and copy over the configs of the services you are running.
depending on how you run your VMs you also could just clone the settings and the disk container of that server on the HOST machine that runs the VMs. This way is totally independent from the OS inside and you even dont need imaging tools.
A re-setup in a VM is wasted energy if you just want desaster recovery. use the tools the VM environment is offering.
(snapshots, machine cloning,...)
A re-setup in a VM is wasted energy if you just want desaster recovery. use the tools the VM environment is offering.
(snapshots, machine cloning,...)
What type of VM are you using?
virtualbox
Re-Setup same version of linux on just another box, then its quite easy. many distros have tools for this purpose. You should at first give little more details of what you want to perform exactly, with which version(s) of Linux.