Solved

Adding Hard Disk to Linux

Posted on 1997-09-07
1
216 Views
Last Modified: 2013-12-15
I have used up all the space on my existing HD, and have added another to my system.  I have partitioned with Linux
Fdisk.  I need to format it and get my system(slackware 3) to recognize it.  What are the steps, and how do I complete them...also, does it require rebuilding the kernel?
0
Comment
Question by:racy
1 Comment
 

Accepted Solution

by:
asmodean earned 50 total points
ID: 1629704
It is very easy to add a second hard disk to linux.
You have performed the first step. I assume you partitioned
the disk as type "Linux native".

Next, you need to frmat the disk. This is done using the
"mke2fs" command.

You can type "mke2fs /dev/hdX" to format an ide hard disk.
X is "a" for the first drive, "b" for the second, and so on.
type "man mke2fs" to see some options you can give it, but it
should do a good job in its default configuration. Be warned that
ALL data on the disk you are formating will be lost.

Lastly, you need to modify the /ets/fstab file to tell linux to
mount your disk when it starts up. You need to add a line
of this form to it:

/dev/hdb2       /        ext2        defaults   1   1

The above line means
mount /dev/hdb2 (the second partition of drive 2) in the
directory / using the ext2fs filesystem. Dont worry about the
last three parameters, they are ok being set to "defaults 1 1"

The above line means that drive hdb2 will contain everything
starting with the directory "/" and going deeper. You will need
to choose a directory to mount your new drive on. A good thing
to do is to move the /home directory to your new disk.


k
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Over the last ten+ years I have seen Linux configuration tools come and go. In the early days there was the tried-and-true, all-powerful linuxconf that many thought would remain the one and only Linux configuration tool until the end of times. Well,…
Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question