Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have FC5 on a IBM machine that runs as a dedicated file server. It's got a 300GB IDE hard drive that stores everything, including backups. I want to add a new 40GB IDE hard drive so I can move the backups to that drive and keep it isolated.
I have absolutely no idea how to add the new drive, mount it to either home or home2, anything for that matter, as long as I can create a share using SMB.
I know how to physically add the drive though.
One more thing, as it stands, the drive is currently formatted in NTFS, was a windows hard drive so I'll need to know how to format it as well.
I have no GUI on my box.
I always appreciate the great help that people get on this site, it's priceless.
Regards,
genesis
Last edited by fmcgenesis; 11-12-2007 at 04:03 PM.
well first you need to find out where it is in /dev.
that can vary a bit, if this is your second hard drive and if its not sata (from what you said its not)
its more than likely /dev/hdb
to be sure you can do #cfdisk /dev/hdb (MAKE SUR YOU DONT MODIFY ANYTHING UNLESS YOU WANT TO) this is the partition table,
Im sure there is an easier way but that the one i used.
usualy /dev/hda is primary disk, hdb slave, hdc CDROM, hdd cdrom slave but this can vary depending of your system.
now to format
mkfs.*fstype (mkfs.ext2, mkfs.ext3, mkfs.reiserfs)
so if you want a ext3 filesystem on that drive
mkfs.ext2 /dev/hdb (or whichever it is)
to mount:
mount *dev *mount point
eg:
mount /dev/hdb /mnt
will mount /dev/hdb to /mnt directory
just be carefull when using cfdisk and mkfs, cfdisk you can use to create partition but make sure you have the right drive
and mkfs well, dont do it on the wrong disk
Thanks, sounds simple assuming there's no detection process, I just turn the machine off, plug the drive on slave, boot it up and format, mount the right drive. I haven't done this and I can't till the end of the day, where would I find the contents of this drive, like /home - where would I move my files to?
EDIT: Doing a #cfdisk /dev/hdb or hda just returns to prompt.
Last edited by fmcgenesis; 11-12-2007 at 04:25 PM.
yes, but make sure you find the right drive, it shoudl be two hard, if you have one 300gb and one 40gb
where its going to be mounted is your choice. this is done with mount /dev... /....
let say your drive is /dev/hdb, you format with:
sudo mkfs.ext3 /dev/hdb
and you want that drive for backup, so you create a backup directory in /home/BAK like this:
sudo mkdir /home/BAK
then you would mount it like this:
sudo mount /dev/hdb1 /home/BAK
*notice the "1" this is the partition number
then change the permission on that directory:
sudo chmod +w /home/BAK
now you can move your file into that disk like this
cp (file) /home/BAK
That sounds ok to me, think i'll have no problems. But, is there a way to see my current list of devices? Currently I don't have the second HD plugged in.
Thanks a lot for the help, it was a piece of cake. This was the first time I've ever added a harddrive to an existing linux installation and it's apparently just as easy as adding a harddrive in windows.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.