LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Mount error (https://www.linuxquestions.org/questions/linux-newbie-8/mount-error-706998/)

an_sush 02-23-2009 09:58 PM

Mount error
 
Hi All,
I m on RHL5 and have a disk(/dev/sdb) which is unmounted:
Code:

# fdisk -l

Disk /dev/sda: 36.4 GB, 36401479680 bytes
255 heads, 63 sectors/track, 4425 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        2637    21077280  83  Linux
/dev/sda3            2638        3159    4192965  82  Linux swap / Solaris
/dev/sda4            3160        4425    10169145    5  Extended
/dev/sda5            3160        4425    10169113+  83  Linux

Disk /dev/sdb: 73.4 GB, 73407488000 bytes
255 heads, 63 sectors/track, 8924 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

  Device Boot      Start        End      Blocks  Id  System

mount command gives me following:
Code:

# mount
/dev/sda2 on / type ext3 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
/dev/sda5 on /data type ext3 (rw)
/dev/sda1 on /boot type ext3 (rw)
tmpfs on /dev/shm type tmpfs (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)

when i try to mount it gives me following error:
Code:

# mount -t ext3 /dev/sdb /data
mount: wrong fs type, bad option, bad superblock on /dev/sdb,
      missing codepage or other error
      In some cases useful info is found in syslog - try
      dmesg | tail  or so

and dmesg | tail gives me following output:
Code:

# dmesg | tail
usb 2-2: USB disconnect, address 2
usb 3-2: new low speed USB device using uhci_hcd and address 2
usb 3-2: configuration #1 chosen from 1 choice
input: HID 04b3:3108 as /class/input/input3
input: USB HID v1.00 Mouse [HID 04b3:3108] on usb-0000:00:1d.1-2
FAT: Unrecognized mount option "umask=ooo" or missing value
hfs: unable to find HFS+ superblock
VFS: Can't find ext3 filesystem on dev sdb.
VFS: Can't find ext3 filesystem on dev sdb.
VFS: Can't find ext3 filesystem on dev sdb.

I have created /data and with 777 permission. I am running all the commands with root user. Kindly help me in mounting this unmounted disk

David the H. 02-23-2009 10:11 PM

According to fdisk, your sdb drive doesn't have any mountable partitions. The /dev/sdb alone points to the physical drive, which is usually not mountable. The partitions on the drive are given numbers, /dev/sdb1, /dev/sdb2, /dev/sdb5, etc.

It appears that this drive is still unformatted. You probably need to to partition and format it using fdisk, gparted or something.

an_sush 02-23-2009 10:15 PM

Quote:

Originally Posted by David the H. (Post 3455132)
It appears that this drive is still unformatted. You probably need to to partition and format it using fdisk, gparted or something.

Can you help me with this? formatting and patitioning of this drive without disturbing the existing filesystem

Drakeo 02-23-2009 10:15 PM

ok here you go sdb mean you have a second disk not a partition ok that said lets get that new disk mounted. type open a terminal as root type cfdisk /dev/sdb now lets create a linux partition and format it to 82 ext2 and write it. If this has been done all ready then to boot. open your /etc/fstab file with your favorite editor. kedit ot gedit what ever.
and place this in there
Quote:

/dev/sdb1 /mnt/sdb1 ext2 defaults 1 2
now go to /mnt/ and create a folder sdb1
and then open your terminal and type as root mount /dev/sdb1.
the reason it does not see you disk is it need to be formated or it is not in the fstab or the fs is corrupted. if it is a IDE drive make sure it it set to cable select or slave
every time you boot it should mount automatically and the user can use it if he has disk in his group.

Drakeo 02-23-2009 10:23 PM

does it have a ext3 already then it will be sdb1 not sdb

an_sush 02-23-2009 10:24 PM

Quote:

Originally Posted by Drakeo (Post 3455135)
ok here you go sdb mean you have a second disk not a partition ok that said lets get that new disk mounted. type open a terminal as root type cfdisk /dev/sdb now lets create a linux partition and format it to 82 ext2 and write it. If this has been done all ready then to boot. open your /etc/fstab file with your favorite editor. kedit ot gedit what ever.
and place this in there
now go to /mnt/ and create a folder sdb1
and then open your terminal and type as root mount /dev/sdb1.
the reason it does not see you disk is it need to be formated or it is not in the fstab or the fs is corrupted. if it is a IDE drive make sure it it set to cable select or slave
every time you boot it should mount automatically and the user can use it if he has disk in his group.

here is where i was struck:
Code:

# cfdisk /dev/sdb
-bash: cfdisk: command not found
# fdisk /dev/sdb

The number of cylinders for this disk is set to 8924.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
  (e.g., DOS FDISK, OS/2 FDISK)

Command (m for help): m
Command action
  a  toggle a bootable flag
  b  edit bsd disklabel
  c  toggle the dos compatibility flag
  d  delete a partition
  l  list known partition types
  m  print this menu
  n  add a new partition
  o  create a new empty DOS partition table
  p  print the partition table
  q  quit without saving changes
  s  create a new empty Sun disklabel
  t  change a partition's system id
  u  change display/entry units
  v  verify the partition table
  w  write table to disk and exit
  x  extra functionality (experts only)

Command (m for help):

I dont know which option to select. Also u m8 have noticed above cfdisk is no valid command so i tried fdisk. was i wrong here?

Drakeo 02-23-2009 10:24 PM

correct mount would be to # mount -t ext3 /dev/sdb1 /data

Drakeo 02-24-2009 06:13 PM

you said fdisk I said cfdisk it is a little easier to use I think must be root
Quote:

RHEL5 no cfdisk crazy wow


All times are GMT -5. The time now is 11:05 PM.