LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-29-2009, 07:22 AM   #1
ziggy25
Member
 
Registered: Aug 2005
Distribution: Debian 5.2
Posts: 56

Rep: Reputation: 15
Simplifying change of Distribution or Upgrade.


Hi guys,

I am in the situation where i have had to make several upgrades or try out different distributions. This has meant that whenever i have to re-install the OS i have to re-install everything and recopy all my files after each linux installation.

What i would like to do is build a system in such a way that when i replace the linux operating system either via an upgrade, a clean install or a distribution change i would like not to have to make changes to any of my existing programs and files or if i have to, the changes should be minimal.

The kind of files i am talking about are a website running on Apache and Tomcat, a mysql database and some applications. Is this possible?

I know in Apache, it is possible to change the root directory of DOCROOT. I am not sure if the path to the database files for mysql can be redirected from the default location.

With Tomcat, i know that it can be reconfigured so that its AppBase is somewhere else.

Has anyone done something like this before? Presumabely it can be done by having a partition that will include everything which i need to be permanent.

I am not really sure if this will work so i would like to know if it is possible and if you've done it before and how? And what should i watch out for.

Ta
 
Old 07-30-2009, 12:51 AM   #2
neonsignal
Senior Member
 
Registered: Jan 2005
Location: Melbourne, Australia
Distribution: Debian Jessie (Fluxbox WM)
Posts: 1,387
Blog Entries: 52

Rep: Reputation: 355Reputation: 355Reputation: 355Reputation: 355
A lot of people mount their /home directory from a second partition, for this very reason, and if you use logical volume management, you can make it even more finegrained.

It is a bit harder where you have configured settings in /etc, but you have a few options. You can make use of user override settings wherever possible, so that you can keep the setting variations in the /home area (though not all applications make this easy). Or you could symbolically link relevant config files in /etc through to the second partition, so that after a new install you only had set up the links again.

Preserving applications, especially complex ones like apache and so on can be harder, because different distros have various conventions on where the components are stored (libraries, configurations, etc), so it is often easier just to reinstall. And worse, the dependencies will be different in different distros - different versions of the application, different library dependencies and different kernel versions. So you should be aiming at preserving settings and data, not the application itself.

If you can stick to a single distro, upgrades are not such an issue; admittedly configuration files are sometimes overwritten because there has been a significant change to the options. But this can be handled by keeping a backup of the /etc directory so that the settings can be reinstated on the upgrade.
 
Old 07-30-2009, 04:31 PM   #3
ziggy25
Member
 
Registered: Aug 2005
Distribution: Debian 5.2
Posts: 56

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by neonsignal View Post
A lot of people mount their /home directory from a second partition, for this very reason, and if you use logical volume management, you can make it even more finegrained.

It is a bit harder where you have configured settings in /etc, but you have a few options. You can make use of user override settings wherever possible, so that you can keep the setting variations in the /home area (though not all applications make this easy). Or you could symbolically link relevant config files in /etc through to the second partition, so that after a new install you only had set up the links again.

Preserving applications, especially complex ones like apache and so on can be harder, because different distros have various conventions on where the components are stored (libraries, configurations, etc), so it is often easier just to reinstall. And worse, the dependencies will be different in different distros - different versions of the application, different library dependencies and different kernel versions. So you should be aiming at preserving settings and data, not the application itself.

If you can stick to a single distro, upgrades are not such an issue; admittedly configuration files are sometimes overwritten because there has been a significant change to the options. But this can be handled by keeping a backup of the /etc directory so that the settings can be reinstated on the upgrade.
Ok i guess its not as simple as i thought it would be. At the moment i am using Debian and dont have any plans to change to another distribution. I thik for now i will try and stick with the simple things first and build in that.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Distribution Upgrade using aptitude cccc Debian 5 07-19-2009 08:23 PM
Upgrade distribution how to fatra2 Fedora 3 06-19-2009 02:01 AM
Distribution Upgrade locking up mickeyboa Ubuntu 1 10-28-2007 12:56 PM
Cannot Change GNOME Menu Items to add/change Item for Mozilla 1.2 After Upgrade metoome General 0 03-27-2004 01:19 AM
Cannot Change GNOME Menu Items to add/change Item for Mozilla 1.3 After Upgrade SForsgren Linux - General 4 03-27-2004 12:43 AM


All times are GMT -5. The time now is 02:42 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration