LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Can't mount sdb1 (https://www.linuxquestions.org/questions/linux-newbie-8/cant-mount-sdb1-527940/)

Fixed_it 02-12-2007 06:09 PM

Can't mount sdb1
 
I have FC6 on an old box w. 2 80Gb SATA hard drives.
Quote:

[root@localhost ~]# fdisk -l

Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 9729 78043770 8e Linux LVM

Disk /dev/sdb: 82.3 GB, 82348277760 bytes
255 heads, 63 sectors/track, 10011 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sdb1 1 10011 80413326 8e Linux LVM
So the system (sda) is ext3 I believe, and the other (sdb) is VFAT32. I want to mount it in the fstab, so this is the line I entered
Quote:

/dev/sdb1 /mnt/share vfat defaults 0 0
However at bootup I get "mount: /dev/sdb1 not a valid block device" error. I am confused as to what I did wrong. I first though I included it in the LVM, but I dont think that is it
Quote:

[root@localhost ~]# pvdisplay
/dev/sdb1: open failed: No such device or address
/dev/hdb: read failed after 0 of 2048 at 0: Input/output error
--- Physical volume ---
PV Name /dev/sda2
VG Name VolGroup01
PV Size 74.43 GB / not usable 22.62 MB
Allocatable yes
PE Size (KByte) 32768
Total PE 2381
Free PE 1
Allocated PE 2380
PV UUID Z10Xuq-MA89-oKQ8-4EwM-a2kM-fo5Q-X4U80n
SO I am at a loss now and would like any help you can give

Thanks

wildar 02-12-2007 06:26 PM

Quote:

[root@localhost ~]# fdisk -l

Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 9729 78043770 8e Linux LVM

Disk /dev/sdb: 82.3 GB, 82348277760 bytes
255 heads, 63 sectors/track, 10011 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sdb1 1 10011 80413326 8e Linux LVM

Looks to me /dev/sdb1 is a Linux file system. Just to test, try mounting with this:
'mount -t ext2 /dev/sdb1 /mnt/share' or 'mount -t ext3 /dev/sdb1 /mnt/share'

kstan 02-12-2007 07:08 PM

err.. sdb1 is a LVM file system and you can't mount directly, you need to mount the logical partition. Please read more in LVM.

God luck.

Fixed_it 02-13-2007 07:12 AM

Wildar.. I will try it later when I get home.

kstan...I did read on LVM. Thats why I posted the output of pvdisplay, which says that sdb is not in the volume. I understand the fdisk says it is. so this is why I am confused. The LVM man says to list all drives in the LVM use the pvdisplay command, and sdb doesn't appear, only sda. Am I interpreting this incorrectly?

Thanks

Fixed_it 02-13-2007 06:23 PM

There seems to be some hardware issues here. I can not mount this drive at all. mount says that it is not a valid block device, no matter what file system I try. I know it is vfat32, I can format it to my hearts content in gparted with no problem. I can't do anything with it as a logical volume, it doesnt show up in pvdisplay and if I try the gui LV management I cant perform any operations on it. sdb1 shows up as an unitialized entry, and if I attempt to initialize it I get the following
Quote:

pvcreate command failed. Command attempted: "/usr/sbin/pvcreate -M 2 /dev/sdb1" - System Error Message: /dev/sdb1: open failed: No such device or address
Can't open /dev/sdb1 exclusively. Mounted filesystem?
so its not a logical volume either.
Any other ideas??

Thanks again

saikee 02-13-2007 07:14 PM

fdisk has confirmed that the sdb1 partition type "is" indeed LVM which cannot be mounted by the ordinary "mount" command.

I don't think OP's opinion is better than that by the fdisk program.

If it shows up nothing may be it is empty and what is the point of mounting it anyway?

Fixed_it 02-14-2007 08:39 AM

Whats the point of mounting an empty hard drive-? Well my though was to put stuff on it. Call me crazy, but I was gonna give it a whirl. If this is part of the LVM then why can I not find it or perform logical volume modifications on it?

saikee 02-14-2007 09:26 AM

When a hard drive is empty it can have a partition but not yet formatted. This is the most common reason for a Linux to refuse to mount it.

If a partition has no filing system inside Linux can't mount it because Linux needs to know what tool is needed to read it. Could it be a fat16 Dos partition, or a fat32, or an Ext3, or reiserfs or xfs system....... Different filing systems have different ways of storages and tracking systems.

You couldn't possibly do it if you were Mr. Linux yourself. If a smart arxe comes along and writes files on it what filing system would you choose for an unformatted partition?

I don't use LVM as could not advise on it but it does require a different way of mounting it. Linux in fact needs to load a driver just to be able to see it. I see only hassle and no benefit from LVM so I stay away.

Fixed_it 02-14-2007 01:50 PM

Ok that makes sense, but when I format in gparted as a vfat and I get no errors, what exactly have I done? I dont see any advantage in LVM for me, but I dont really want to reinstall to get rid of it. I suppose I will research how to not use it in FC7 and hopefully by then I will figure it out and upgrade when it comes out. What do you suggest is the best way to just add a drive to a system then?
Thanks for you insight and patience

saikee 02-14-2007 03:50 PM

It is easier than you think if you want get rid of the LVM.

In FC6 invoke Grub by typing
Code:

sudo grub
you can omit "sudo" if you are logging in as root.

You can then investigate the partitions of your two Sata by commands
Code:

geometry (hd0)
geometry (hd1)

(hd0) is your sda and should have 2 partition with Type ID 0x7 and 0x8e respectively.

(hd1) is your sdb with only one partition Type ID 0x8e indicating it is a LVM which you want to get rid of.
You can do so by altering the partition ID to Type 0xc for fat32, just like that by command
Code:

parttype (hd1,0) 0xc
You then check partitions again by the 2 geometry commands. At this point you should reboot to validate the sdb1 partition change.

On a reboot to FC6 you can format /dev/sdb1 with fat32 filing system with command
Code:

mkdosfs -F32 /dev/sdb1
You can mount the partition now and use it.

Fixed_it 02-15-2007 07:42 PM

I am sure it is just me...
I follow your directions which seemed nearly idiot proof- alas I found a way!
not sure what I am doing wrong but i confirm the change to the map with the geometry command, all is well. And then ...
Quote:

[root@localhost dev]# mkdosfs -F32 /dev/sdb1
mkdosfs 2.11 (12 Mar 2005)
/dev/sdb1: No such device or address
[root@localhost dev]#
but there is a device! I can see it, so I guess It is not that it is not there, but rather I am not doing this right.
Again I need a little more of your patience and I can be back to breaking things :)
Thanks

saikee 02-16-2007 02:32 AM

Did you rebooted after altering the geometry of a fat partition?

Fixed_it 02-16-2007 04:43 AM

Yes I did.

saikee 02-16-2007 05:36 AM

Paste terminal output of "fdisk -l" here.

It is possible FC6 is protecting the LVM against inadvertent damage. In such a case you can boot to a Live CD, use the terminal program cfdisk or fdisk to delete sdb1, create at the same place a partition, select Type c and write the partition table.

Since you have two LVM locations you could also have used both disks sda and sdb to form one LVM. In such a case you may need to break up the LVM to free sdb1. Only you know what has been arranged in your PC.

Fixed_it 02-16-2007 09:21 PM

Well here you go..
Quote:

[root@localhost ~]# fdisk -l

Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 9729 78043770 8e Linux LVM

Disk /dev/sdb: 82.3 GB, 82348277760 bytes
255 heads, 63 sectors/track, 10011 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sdb1 1 10011 80413326 c W95 FAT32 (LBA)
I guess I dont know what the "c" ID is and the (LBA), for the sdb1.


All times are GMT -5. The time now is 04:55 AM.