Sunday, October 15, 2006

mount WD drive on clarkconnect (redhat 2.4)

# uname -a
Linux mycomputer.org 2.4.20-35.cc

to mount this on redhat clarkconnect server,
I first needed to add a usb card, so I bought this one that worked fine:
Zonet 4+1Port USB2.0 PCI Card(VIA Chipset) Model ZUH2215V
It has a via chipset VT6212L which is compatible w/ linux.


Then logged in,
less /etc/sysconfig/hwconf
.
.
.
-
class: HD
bus: SCSI
detached: 0
device: sda
driver: ignore
desc: "Wd 1600JB External"
host: 0
id: 0
channel: 0
lun: 0
generic: sg0
-

.
.


Note the device is "sda" hence its /dev/sda

so lets check the file system type:
# fdisk /dev/sda

Command (m for help): p
Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 1 19457 156288321 7 HPFS/NTFS


Command (m for help): q

----
so its NTFS, so I'll have to format the disk, since my kernel doesn't support ntfs. I could install a new kernel, but I really want this usb disk to work only on this box.

delete partition:
# fdisk /dev/sda
Command (m for help): p
Disk /dev/sda: 160.0 GB, 160041885696 bytes255 heads, 63 sectors/track, 19457 cylindersUnits = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System/dev/sda1 1 19457 156288321 7 HPFS/NTFS
Command (m for help): d
Selected partition 1

Command (m for help): n
Command action e extended p
primary partition (1-4)1
Command action e extended p
Partition number (1-4): 1
First cylinder (1-19457, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-19457, default 19457):
Using default value 19457

Command (m for help): w
The partition table has been altered!


# /sbin/mkfs.ext3 /dev/sda1

# mkdir /mnt/usb0
# mount /dev/sda1 /mnt/usb0


# mount
.
.
.
/dev/sda1 on /mnt/usb0 type ext3 (rw)

# df -hvFilesystem Size Used Avail Use% Mounted on

/dev/sda1 147G 33M 140G 1% /mnt/usb0

yippE!


No comments: