Koozali.org: home of the SME Server

New Device

Luis

New Device
« on: February 17, 2002, 06:28:51 PM »
Hi All,
This may be a basic question to some, but I'm a newbie at Linux.
I've attached a second hard drive (an external scsi drive) to my SME Server.
During boot up, the scsi card and drive are recognized.
My question is, how do I now make the server 'see' this new device so that I can mount it? Any help would be appreciated.
Thanks.

Chaloner Hale

Re: New Device
« Reply #1 on: February 17, 2002, 08:01:57 PM »
I had wanted to add a second SCSI drive for a while. I followed some instructions found in a recent posting in this forum and ended up successful. I thought I would share the specific steps I took so that others would have a clear picture of exactly how to do it.

THIS IS FOR SCSI devices, but could be adapted for IDE drives.

By running /sbin/fdisk the following is output;

fdisk /dev/hda (for the first IDE disk)
or: fdisk /dev/sdc (for the third SCSI disk)

So for a second SCSI drive I will use /dev/sdb and for
a second IDE drive I would use /dev/hdb

So, I then used
/sbin/fdisk /dev/sdb and ensured there were no partitions defined, deleting all existing partitions until the drive was empty. In fdisk, I used "p" (print partition), "d" (delete partition) and "w" (write partition and quit) until there were no more partitions defined. I did not create any partitions on the drive.

I then used;

/sbin/mkfs /dev/sdb and it ended successfully.

I then:

created an iBay called MP3 and enabled it for the web using the server-manager.

I then;

edited /etc/fstab with vi (use whatever I guess) and looked for the following line;

LABEL=/boot /boot ext2 defaults 1 2

I inserted the following line just after the above line;

/dev/sdb /home/e-smith/files/ibays/mp3/html ext2 defaults 1 2

and used "w" and then "q" to exit.

I then rebooted the server after proper shutdown and enabled the mp3 iBay as an MP3 jukebox.

I then set appropriate permissions for this iBay using chmod, chown, and chgrp. I copied over a few music files over my network to the samba share, tested the mp3 jukebox and it works.

I used df to see the "disk free" on my drives and it outputs;

[root@iserver /etc]# df
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/sda6 17369424 1836228 14650868 12% /
/dev/sda1 10887 5859 4466 57% /boot
/dev/sdb 8817288 140724 8228660 2% /home/e-smith/files/ibays/mp3/html


It works just fine. Thanks for the previous posting related to this topic.

Luis

Re: New Device
« Reply #2 on: February 18, 2002, 07:48:41 AM »
Hi Chaloner,
Thanks for the post. But I still can't get the server to 'see' my scsi drive.
I have already have an IDE drive ('hda'), so I assume my second drive (SCSI) should be 'sda'. When I execute the command: /sbin/fdisk /dev/sda, I get the message: 'Unable to open /dev/sda'
When I run dmesg, I get: scsi : 0 hosts.
Any idea on how to get the server to even recognize I have a scsi drive attached?
The boot up process recognizes the scsi card and drive but once booted, Linux does not 'see' it.
I'm sure, once the server can 'see' it, the rest of your instructions should go smoothly (hopefully :-))
Thanks.

Kelvin

Re: New Device
« Reply #3 on: February 18, 2002, 12:16:42 PM »
Use lsmod and see if your scsi driver is loaded. If not, then manually load it, then try and access the scsi hdd.

If this works, try manually adding the driver into the relevant file (modules.conf ? -- sorry, I'm a relative newbie as well).


Kelvin

Luis

Re: New Device
« Reply #4 on: February 19, 2002, 06:14:22 PM »
Hi All,
Thanks to all that replied. I figured it out from pieceing together other posts (related to installing new devices). You were right Kelvin, it involved editing the 'modules.conf' file.
See Darryl May's instructions on installing a scsi tape drive: http://forums.contribs.org/index.php?topic=1982.msg6614#msg6614.
I modified the instructions for an external Scsi drive and controller.
For the controller I used: 'advansys' and for the Scsi drive I used: 'sd'.
Once the system could 'see' my scsi drive, I followed Chaloner's steps.
And all is fine now :-)
Thanks!