Mourning the loss of our friend, WhitPhil.
There's no such thing as a stupid question, but they're the easiest to answer.
JoinTour
Login
Search
 
Linux and Unix
Tag Cloud
access audio blue screen boot bsod connection crash dell desktop driver dvd email error excel excel 2003 firefox hard drive hardware hijackthis internet keyboard laptop malware monitor motherboard network networking outlook problem processor ram recovery router screen slow sound spyware tdlwsp.dll trojan upgrade vba video virus vista vundo windows windows 7 windows vista windows xp wireless
Search
Search for:
Tech Support Guy Forums > Operating Systems > Linux and Unix >
hard drives

Tip: Click here to scan for System Errors and Optimize PC performance
[ Sponsored Link ]

Closed Thread
 
Thread Tools
BTex's Avatar
Senior Member with 589 posts.
 
Join Date: May 2002
Location: Northern Virginia
Experience: Advanced
04-Mar-2003, 03:08 PM #1
hard drives
I added a second hard drive to my redhat box. it sees it in the hardware browser but how do i copy files to it I figure i have to mount it somhow but i cant figure it out


Just a Rookie

Last edited by BTex : 05-Mar-2003 07:32 AM.
codejockey's Avatar
Senior Member with 1,410 posts.
 
Join Date: Feb 2002
05-Mar-2003, 01:45 AM #2
Assuming that you have created one or more Linux filesystems on your second drive, you can mount one or more of them with a command such as:

mount -t ext2 /dev/hdb1 /mnt (assumes that /dev/hdb1 has an ext2 filesystem and that /mnt already exists).

If you are attempting to mount a Windoze filesystem, you would use:

mount -t vfat /dev/hdb1 /mnt (assumes that /dev/hdb1 has a vfat filesystem and that /mnt exists).

You can repeat this operation for as many filesystems as you'd like to mount. Note that you will likely need to be root in order to execute the mount command(s). For additional information, you might review the mount and fstab man pages; they contain lots of good info.

Hope this helps.
__________________
The slowest component still sits at the keyboard.
lynch's Avatar
Senior Member with 1,962 posts.
 
Join Date: Aug 2002
Location: Back East,Way Back East
05-Mar-2003, 05:14 AM #3
Copy and paste your /etc/fstab file here so we can look at it.That will tell us a lot about what may need to be done if codejockey's suggestions dont work.
lynch
BTex's Avatar
Senior Member with 589 posts.
 
Join Date: May 2002
Location: Northern Virginia
Experience: Advanced
05-Mar-2003, 01:38 PM #4
I did the mount like codejoskey posetd and now i still dont know whats next?
Here is the info that Lynch requested



LABEL=/ / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /proc proc defaults 0 0
none /dev/shm tmpfs defaults 0 0
/dev/hda3 swap swap defaults 0 0
/dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0
/dev/cdrom /mnt/cdrom iso9660 noauto,owner,kudzu,ro 0 0

the second drive is /dev/hdd
__________________
"I've noticed that everyone who is for abortion has already been born"
Ronald Reagan
lynch's Avatar
Senior Member with 1,962 posts.
 
Join Date: Aug 2002
Location: Back East,Way Back East
05-Mar-2003, 04:45 PM #5
Ok.You need to set the drive up:
(you should be root)
1.You need to make a mount point directory first.:
mkdir /mnt/hdd
2.You need to add this line to /etc/fstab:
/dev/hdd /mnt/hdd auto noauto,user,kudzu 0 0
*(I used the "user" option instead of "owner" so a regular user can mount the drive)
3.You can use the CLI method to mount this drive,as explained by codejockey or you can create a desktop link:
Right-click an empty part of the desktop and choose Create New>hard disc. Select the Device tab and choose the hard drive from the drop-down menu.On the first tab you can name the icon whatever you like.When you want to mount this drive just click the link.To unmount it,r-click and choose unmount from the menu.
That should do it.
lynch
__________________
seldom right,but never in doubt...
Here's a few links I find helpful:
Intro to Linux:A Hands-on Guide
USALUG
A little Linux help
OpenSUSE help+
Bash Commands

Last edited by lynch : 06-Mar-2003 05:37 AM.
codejockey's Avatar
Senior Member with 1,410 posts.
 
Join Date: Feb 2002
05-Mar-2003, 08:30 PM #6
OK, this is a new one on me ...

Why the symbolic link between /dev/hdd and /mnt/hdd? /dev/hdd is a device special file; /mnt/hdd is a directory. At first blush, I don't unserstand why this is needed (or even that it should be done -- I've never done this, BTW).

Lynch is absolutely correct in his suggestion to add your routine mounts to /etc/fstab, however. It makes things a lot easier.

As far as copying goes, what sort did you have in mind? You can copy individual files with the cp command, or entire directory trees with cp -R or find and cpio.

Any info appreciated.
__________________
The slowest component still sits at the keyboard.
lynch's Avatar
Senior Member with 1,962 posts.
 
Join Date: Aug 2002
Location: Back East,Way Back East
06-Mar-2003, 05:36 AM #7
Codejockey! Saved me again.
This is a hard drive:I make symlinks usually when adding cd burners because scsi emulation requires the cleaning up of old /dev/ links to make everything work.
Your absolutely right.The fstab entry is sufficient to point out the mount point.
I'll edit that reply so someone else doesnt try it.
lynch
__________________
seldom right,but never in doubt...
Here's a few links I find helpful:
Intro to Linux:A Hands-on Guide
USALUG
A little Linux help
OpenSUSE help+
Bash Commands

Last edited by lynch : 06-Mar-2003 05:43 AM.
BTex's Avatar
Senior Member with 589 posts.
 
Join Date: May 2002
Location: Northern Virginia
Experience: Advanced
06-Mar-2003, 10:55 AM #8
Thanks a bunch
Thanks for your patience and help I am still struggling to learn . Thanks again
BTex's Avatar
Senior Member with 589 posts.
 
Join Date: May 2002
Location: Northern Virginia
Experience: Advanced
06-May-2003, 04:06 PM #9
more hd ???
I can get the hard drive to mounted and copy files to it but when i shut down my machine i have to re add the hard drive and remount it?

any thoughts what am I doing wrong?
codejockey's Avatar
Senior Member with 1,410 posts.
 
Join Date: Feb 2002
07-May-2003, 12:45 AM #10
I suspect it's just a matter of tweaking your fstab entry (see lynch's instructions to create one). I gave Lynch's suggested entry a quick look, and would suggest you remove the "noauto" option (leave the "auto" option) and see if that improves things. Also, if you post your /etc/fstab file, we can get a look at it and probably sort out what's wrong.

You're nearly there! -- the fact that you can consistently mount, read and write to your second drive is excellent news -- hang in there!
__________________
The slowest component still sits at the keyboard.
BTex's Avatar
Senior Member with 589 posts.
 
Join Date: May 2002
Location: Northern Virginia
Experience: Advanced
07-May-2003, 08:00 AM #11
btex fstab
LABEL=/ / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /proc proc defaults 0 0
none /dev/shm tmpfs defaults 0 0
/dev/hda3 swap swap defaults 0 0
/dev/cdrom /mnt/cdrom udf,iso9660 noauto,owner,kudzu,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0
/dev/hdb1 /mnt/win auto user,kudzu 0 0
__________________
"I've noticed that everyone who is for abortion has already been born"
Ronald Reagan
codejockey's Avatar
Senior Member with 1,410 posts.
 
Join Date: Feb 2002
09-May-2003, 02:46 AM #12
It looks like your fstab entry is missing the field that specifies the filesystem type (third field). So, for example, your entry of:

/dev/hdb1 /mnt/win auto user,kudzu 0 0

should be:

/dev/hdb1 /mnt/win vfat auto,user,kudzu 0 0

(if /dev/hdb1 is a Windoze partition -- NOT NTFS)

or:

/dev/hdb1 /mnt/win ext2 auto,user,kudzu 0 0

if /dev/hdb1 is an ext2 filesystem.

Try the command: man fstab for more information about the format and significance of the fields in this file.

Hope this helps.
__________________
The slowest component still sits at the keyboard.
lynch's Avatar
Senior Member with 1,962 posts.
 
Join Date: Aug 2002
Location: Back East,Way Back East
09-May-2003, 05:24 AM #13
Mine looks like this(SuSE 8.1):
Code:
/dev/hda2            /                    reiserfs   defaults              1 1
/dev/hda1            swap                 swap       pri=42                0 0
devpts               /dev/pts             devpts     mode=0620,gid=5       0 0
proc                 /proc                proc       defaults              0 0
usbdevfs             /proc/bus/usb        usbdevfs   noauto                0 0
/dev/cdrom           /media/cdrom         auto       ro,noauto,user,exec   0 0
/dev/cdrecorder      /media/cdrecorder    auto       ro,noauto,user        0 0
/dev/hdd             /media/ls            auto       noauto,user           0 0
/dev/fd0             /media/floppy        auto       noauto,user,sync      0 0
I mount the last 4 devices via a desktop icon.
lynch
BTex's Avatar
Senior Member with 589 posts.
 
Join Date: May 2002
Location: Northern Virginia
Experience: Advanced
09-May-2003, 07:36 AM #14
Thanks
Thanks again guys
I new that you had to put the file system in there somwhere but didnt have a clue where
Thanks again
Randy
Closed Thread Bookmark and Share

THIS THREAD HAS EXPIRED.
Are you having the same problem? We have volunteers ready to answer your question, but first you'll have to join for free. Need help getting started? Check out our Welcome Guide.

Smart Search

Find your solution!



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
WELCOME TO TECH SUPPORT GUY! Are you looking for the solution to your computer problem? Join our site today to ask your question -- for free! Our site is run completely by volunteers who want to help you solve your computer problems. See our Welcome Guide to get started.

Thread Tools


You Are Using:
Server ID
Advertisements do not imply our endorsement of that product or service.
All times are GMT -5. The time now is 11:05 AM.
Copyright © 1996 - 2009 TechGuy, Inc. All rights reserved.
Powered by vBulletin, Copyright © 2000 - 2009, Jelsoft Enterprises Ltd.
Powered by Cermak Technologies, Inc.