Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 03-04-2001, 08:42 PM   #1
LQ Newbie
Registered: Mar 2001
Posts: 1

Rep: Reputation: 0

I just installed a new hard drive and I need to know how to partition it and access it from within Linux 7......can someone help me I'm sure it's such an easy command.....I just want to add the new drive to provide more space to my existing Linux workstation.

Old 03-05-2001, 05:27 PM   #2
Senior Member
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
The most difficult part about adding more space to Linux is where to add the space. Ask yourself, where do you want the extra space? /usr, /home, /var? I have seperate partitions for /home, /var, and /usr. Just as an example, I'll use /home and /usr as the mount points for your new drive.

Use the command 'fdisk /dev/hd?' where ? is the new drive to partition. Create two new partitions for what ever size. The use the 'mkfs /dev/hd?1' to create a ext2 filesystem for each of the partitions. (replace the 1 with a 2 for the second). Then mount the new partition under /mnt (for lack of a better place), and copy the existing data there.

mount /dev/hd?1 /mnt

cd /home
cp -a * /mnt ( is the -a correct? )

That will copy everything in /home to the new partition. Unmount the partition 'umount' and do the same with /usr. Now mv /home to /home.bak (whatever) and mkdir /home. Same for /usr.

modify the /etc/fstab file to mount the new filesystems when the system boots.

/dev/hdb2 /usr ext2 defaults 1 1
/dev/hdb1 /home ext2 defaults 1 1


Since I may have left something out, please go out to and find a HOW-TO before really doing this.

Easy command huh?


PS. It would be nice to be able to allocate space to any filesystem as needed, as you can on AIX. Less wasted space.


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
Adding a new hard drive ckr Mandriva 1 03-23-2005 02:12 PM
Adding a new drive raysr Linux - Hardware 2 12-30-2004 11:28 PM
Adding Hard Drive Cynthia Blue Linux - Hardware 3 12-19-2004 02:06 PM
Adding a hard drive Mack_T Linux - Hardware 10 09-21-2003 12:46 PM
Adding a new drive????? billkris Linux - Hardware 7 01-29-2003 08:22 PM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:14 AM.

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