Hi, I've done quite a few installs and tried to hack my way in at times.
Like this...
Code:
Can I just copy /etc, /var/log, /var/www, and /usr/local
to the new hard drive and all be running again?
But I have not had any success that way.
Some times it takes longer to sort out any bugs from older packages if they have been upgraded during install.
After partitioning and formatting the 250Gb drive,
It would not hurt to rsync the directories, for a foundation,
but if /etc is on the same partition as / it will be lost during install.
Same goes for /var/www and /var/log if on the / (root) partition.
I would back them up, and use the files I required as a reference and/or
replacement configs (once the appropriate (desired) packages are installed)
A good place for this would be the /home/<username>/<backup-dir-here> directory if it is on a separate partition from / (root) and /usr (also generally gets formatted, things can get crazy if not)
Then once the server is installed and running, copy the config files to /etc. You won't be able to use all of them, but some of them will certainly save you some time and brain-memory.
Your old programs installed in /usr/local (I have a separate partition for this to) may be rsync 'd saving permissions as it does.
Just some general knowledge about installs.
hope that helps you, regards Glenn
ps, my /etc/fstab file looks like this (just linux)...
Code:
# Entry for /dev/sda6 :
UUID=8f60d791-9082-4a55-b7ff-90767e62c5bc / ext3 relatime 1 1
# Entry for /dev/sda5 :
UUID=668a0c18-9a69-48d8-bc75-a956c8a0fe82 /boot ext3 relatime 1 2
tmpfs /dev/shm tmpfs noatime 0 0
# Entry for /dev/sdb10 :
UUID=2d7c228a-3eba-4b81-8f10-10dd9cfdea17 /home ext3 relatime 1 2
# Entry for /dev/sda13 :
UUID=13e6a9b5-a63a-459f-8132-19502ed2b9ef /home/glenn/local/Archive ext3 relatime 1 2
# Entry for /dev/sdb6 :
UUID=78461ae8-382a-478f-bd11-8ab1f7924997 /home/glenn/local/Music ext3 relatime 1 2
# Entry for /dev/sda8 :
UUID=554c552e-248b-4e62-8166-859a86d0a8f3 /home/glenn/local/vm1 ext3 relatime 1 2
# Entry for /dev/sdb7 :
UUID=04f903de-23c5-425e-907e-8812868038d3 /home/glenn/local/vm2 ext3 relatime 1 2
/dev/cdrom /media/cdrom auto umask=0,users,iocharset=utf8,ro,exec 0 0
/dev/fd0 /media/floppy auto umask=0,users,iocharset=utf8,noauto,exec,flush 0 0
# Entry for /dev/sda1 :
UUID=E098342C98340416 /mnt/win_c ntfs-3g defaults 0 0
UUID=c25946d4-790d-4ca8-8be1-84e56d6b0d54 /opt ext3 relatime 1 2
none /proc proc defaults 0 0
# Entry for /dev/sda10 :
UUID=ba99e8a3-9e8c-430c-b20a-b64377a2155c /tmp ext3 relatime 1 2
# Entry for /dev/sda9 :
UUID=e2db618a-acc5-41b0-a9c9-95035c2df816 /usr ext3 relatime 1 2
# Entry for /dev/sdb11 :
UUID=b2370f30-d7fe-451a-9aec-6b0c009f19e3 /usr/local ext3 relatime 1 2
# Entry for /dev/sda7 :
UUID=024e52ef-71a8-4db4-a562-73ef6b193bdc /var ext3 relatime 1 2
# Entry for /dev/sda12 :
UUID=5456da07-de09-47a1-bd4d-81b2a667e928 /var/ftp ext3 relatime 1 2
# Entry for /dev/sda14 :
UUID=1418aa89-dadb-4bba-92e1-d071bb3430ca /var/spool ext3 defaults 1 2
# Entry for /dev/sdb5 :
UUID=de2163aa-fc11-408a-97a9-15ed1a6fd616 /var/www ext3 relatime 1 2
# Entry for /dev/sdb2 :
UUID=24eda376-9395-4881-a4f6-2e0c6e624b74 swap swap defaults 0 0
I left a few out to save space here, but you see what I mean....
Many config files for users and /root are in their home dirs. Don't forget them.
I think I would ask them to backup the whole 80Gb to /home/....as is.
Code:
will the OS increase the swap partition size accordingly
No. Usually only with a default (clean) install, But you should separate the directories you want to keep separate from / and /usr
Cheers Glenn