LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 12-20-2004, 05:49 PM   #1
linoj
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Rep: Reputation: 0
adding hard drive


Hi,

I'm adding a new harddrive to my linux system (RH8) (and then will be upgrading to RH9). My existing hd is pretty full.

My question is how to alllocate partitions.

My inclination is to make one big partition, mount it perhaps as /usr2 and then make symbolic links from any directories that I want to move over to the new disk. This might include my html directory, or mysql data files, or backup files in a home/something directory. That way I won't have to worry about reconfiguring other apps as I discover they've broken because their files moved to a different mount point.

Does this make sense?
Is there a performance hit in relying on symbolic links? for things like my html directory (which is only used for local development, not on the internet) and other file server type functions.

TIA

linoj
 
Old 12-20-2004, 07:34 PM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
You should really look into longterm solutions.. making symlinks to me would not be a good idea.

If you have some way of backing up the important data off the first disk, you should either look into LVM and other setups if your needing more space, then add the second disk, reinstall with a proper long term solution to fit your needs.

/usr is for applications on the server/machine.. where is most of your space taken up on the existing machine? Is it /usr, /home, etc?

More details get better replies.
 
Old 12-20-2004, 07:49 PM   #3
linoj
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Original Poster
Rep: Reputation: 0
/dev/hda1 45.4 MB /boot 29.6 MB 35.1%
/dev/hda2 4.3 GB /usr 908 MB 79%
/dev/hda5 1.8 GB /home 334 MB 82%
/dev/hda6 372 MB / 246 MB 34%
/dev/hda7 250 MB /var 63.6 MB 75%

The basic problem is /var and /home were running out of space, so I linked to directories on /usr which had plenty (until now).

/home is mostly used to backup desktop systems on the network

presently I have symbolic links setup for

several directories under /var/www/html are linked to ones on /usr

I also linked /var/mysql to a directory on /usr

I've added a new 120 GB drive, so there's plenty of new space.

Also, I'm running RH8, and have the disks for RH9, I plan to upgrade as soon as the disk is setup.

What do you think?
 
Old 12-20-2004, 07:56 PM   #4
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
/var is a pseudo type file system, which stands for various.. and mainly log files, files that change all the time, etc.

This is what I would do in your case:

1. Install the new drive.
2. Format and create the filesystem on it. (either creating one big partition or several for each of the below)
3. Move your mysql database to its own directory on it (or create its own partition and mount)
4. Create a fairly large partition for your /home backups or just move home there altogether on its own partition.
5. Move your httpd directory I assume is hosting your webserver over with its own directory or partition that is mounted, etc.
6. Remove your symlinks and redirect your applications/services to point to the newly created directories/mounts, etc.

The one reason I say remove your symlinks is that if one of those partitions fail, it takes down whatever was linked there as well, etc.
 
Old 12-20-2004, 08:20 PM   #5
linoj
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Original Poster
Rep: Reputation: 0
thanks, man

the reason I skirted around this is because I don't know how to reconfigure mysql where to look for its files, same with apache for the web files, etc. oh well, it's just time. Any hints?

If I move the /home there with it's own partition, what do with the 'old' /home partition? can I give that space to /var somehow?

linoj
 
Old 12-20-2004, 08:24 PM   #6
linoj
LQ Newbie
 
Registered: Dec 2004
Posts: 14

Original Poster
Rep: Reputation: 0
the other consideration is I'm running on a 5 year old system (dual PII) and it's drive is just as old, so I want to put any "live data" on the new disk and nothing critical on the old one, so when (not if) the system dies I can move the disk over to a new box with my work and backups etc.
 
Old 12-25-2004, 12:51 PM   #7
Vincent_Vega
Member
 
Registered: Nov 2003
Location: South Jersey
Distribution: Slackware, Raspbian, Manjaro
Posts: 826

Rep: Reputation: 31
I believe that once you have successfully moved your /home partition to the new drive you can just change /etc/fstab to mount that partition (/dev/hda5) as /var also, adding that extra space to the exisiting /var partition (/dev/hda7). /var will then just appear as a single directory.
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding a second hard drive AxXium Slackware 9 03-24-2006 02:27 AM
Adding Hard Drive Cynthia Blue Linux - Hardware 3 12-19-2004 01:06 PM
Adding a Hard Drive texmansru47 Slackware 2 12-13-2004 11:19 AM
adding a hard drive Serena Linux - General 2 07-19-2003 05:39 PM
Adding Second Hard Drive Micro Linux - General 3 01-26-2003 09:37 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 02:26 PM.

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
Open Source Consulting | Domain Registration