PDA

View Full Version : Trying to mount old drive.... and I am lost.


Issac-S
2005-10-09, 06:50 AM CDT
Ok, this is going to sound a little dumb, but here it goes. So over the last few days been working hard to get a new drive. Now that I have it, and FC 4 is installed to it seems that I have run into a small problem... can't seem to mount the old drive so that I can swap my data to this new beast of a hard drive.

When trying for mount /dev/hdb this seems to be my error.
[issac@localhost ~]$ mount /dev/hdb/
mount: can't find /dev/hdb in /etc/fstab or /etc/mtab

Anything that I should know about before before I start adding entries into fstab? And what might I need to do to start the big swap?
Again, it sounds dumb... since I have a good idea of what to do, but want to double check my finds before I start anything with the old drive (important data to be found in it, at least to me). I am still rather fresh to linux so please be gentle and... any help would be greatly apprecated. Thank you.

dox22
2005-10-09, 07:24 AM CDT
I don't understand, you have a new partition???, or a new hard drive???, type of format (ntfs/ext2/Fat)?.

for solve this error try to edit as root the file /etc/fstab

$mkdir /mnt/drive
$vi /etc/fstab


Add something like this:
/dev/hdb /mnt/drive auto defaults 0 0

Try to mount:

$mount /mnt/drive

Issac-S
2005-10-09, 07:35 AM CDT
I don't understand, you have a new partition???, or a new hard drive???, type of format (ntfs/ext2/Fat)?.

for solve this error try to edit as root the file /etc/fstab

$mkdir /mnt/drive
$vi /etc/fstab


Add something like this:
/dev/hdb /mnt/drive auto defaults 0 0

Try to mount:

$mount /mnt/drive
A new phsyical hard drive, not a new partition, The old drive (also running FC 4) is in the ext3 file system....
Hmmm, I think that was what I need to do... if anything I'm going to do a backup of things just in case this turns to be a massive failure and I lose data due to it. But thanks for the help.

linmix
2005-10-09, 07:44 AM CDT
I see no (normal) reason why mounting a drive would result in data loss.

However, before adding anything to fsatb ( and not because that might cause trouble, but rather to make sure the line you place there will actually work) I'd try to mount it 'manually' first:

As suggested by Issac-S first make the moutn point: (you will probably require root privileges to do so)
#mkdir /mnt/drive

then mount it:
#mount -t ext3 /dev/hdb /mnt/drive

if that works you're ready to add it to fstab.

Issac-S
2005-10-09, 09:30 AM CDT
However, before adding anything to fsatb ( and not because that might cause trouble, but rather to make sure the line you place there will actually work) I'd try to mount it 'manually' first:

As suggested by Issac-S first make the moutn point: (you will probably require root privileges to do so)
#mkdir /mnt/drive

then mount it:
#mount -t ext3 /dev/hdb /mnt/drive

if that works you're ready to add it to fstab.

You know, this has been turning out a little more complex than I thought orginally. Did try that line of command just a moment ago and I keep getting this...
[issac@localhost ~]$ mount -t ext3 /dev/hdb /mnt/drive
mount: /dev/hdb already mounted or /mnt/drive busy
Yes, I also tried it under root... keep getting the same message.

linmix
2005-10-09, 10:15 AM CDT
Maybe this is too obvious and you've already done this, but try

# umount /dev/hdb

also, make sure no browser windows (nautilus, konqueror) or shell or any other app for that matter is showing (=accessing) /mnt/device

Issac-S
2005-10-09, 10:29 AM CDT
Maybe this is too obvious and you've already done this, but try

# umount /dev/hdb

also, make sure no browser windows (nautilus, konqueror) or shell or any other app for that matter is showing (=accessing) /mnt/device
You know... this is going to be funny, but I did try that and got...
umount: /dev/hdb/: not mounted
In a word, annoying....

linmix
2005-10-09, 10:41 AM CDT
still with the relatively obvious:

# umount /mnt/device

# /sbin/fuser -k /dev/hdb (and /or /mnt/device)

Are you sure the drive is hdb and not hdc or hdd?

dwisianto
2005-10-09, 11:06 AM CDT
/sbin/fdisk -l
to list all available device

Issac-S
2005-10-09, 06:43 PM CDT
Still with the relatively obvious:

# umount /mnt/device

# /sbin/fuser -k /dev/hdb (and /or /mnt/device)

Are you sure the drive is hdb and not hdc or hdd?
I am sure... anyways...
I found the source to the problem. It was the simple matter that the old disk was parttioned, so despite my data beinf on /dev/hdb... it had a Logic Volume assigned to it. I simple replaced /dev/hdb to the logic volume that it was on (/dev/VolGroup00/LogVol00) and I got access to everything. Thanks for you all help.

linmix
2005-10-09, 10:50 PM CDT
I should hve writen more carefully. Mount command should be

#mount -t ext3 /dev/hdb[b]1[/] /mnt/drive (or whatever the corresponding partition number was)

Glad you managed to solve it.

Issac-S
2005-10-10, 09:57 AM CDT
I should hve writen more carefully. Mount command should be

#mount -t ext3 /dev/hdb[b]1[/] /mnt/drive (or whatever the corresponding partition number was)

Glad you managed to solve it.
Thanks... I should do this more often. Get more pratice in bash and so on.