LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
LinkBack Search this Thread
Old 01-21-2013, 02:49 AM   #1
WiseDraco
Member
 
Registered: Nov 2006
Location: Europe,Latvia,Riga
Distribution: slackware,slax, exMandriva
Posts: 358

Rep: Reputation: 28
SATA0 port on motherboard kaput


Hello!
I purchase asus p5b motherboard for upgrade a small slackware based home server, but on this mb is physically broken first SATA port - one from totally 4. i be live with 3 ports ( two sata hdd in soft mirror for system, and one bigger sata for fileserver), but want to know, it is not do problems with my system disc configurations? if broken be 3 or 4. channel ports, i be no worry, but first....?
also i try to install slack 14 on hdd in second sata port - in setup process it likes as sda, and when i try install lilo, it says, disk geometry is different, use a -P ignore, and finally lilo not installed on mbr ( and at all) - this problem is because first disc is in second sata port, or it not matter?
 
Old 01-21-2013, 09:22 PM   #2
Ser Olmy
Senior Member
 
Registered: Jan 2012
Distribution: Slackware
Posts: 1,822

Rep: Reputation: Disabled
The fact that it's the first SATA port is of no significance. Linux will assign /dev/sda to the first available disk, regardless of physical port number.

The disk geometry warning from Lilo and any problems related to the installation of the boot loader is also not related to the SATA port. Try repartitioning the drive with a different partitioning tool.
 
Old 01-22-2013, 12:02 AM   #3
Erik_FL
Member
 
Registered: Sep 2005
Location: Boynton Beach, FL
Distribution: Slackware
Posts: 793

Rep: Reputation: 245Reputation: 245Reputation: 245
Disk geometry is different means that the hard disk reports different Cylinders, Heads and Sectors than the BIOS. You can avoid the warning by adding "lba32" to the "lilo.conf" file. LILO will use LBA mode and should not care about disk geometry.

LILO not installed to the MBR is telling you that a "map" file was created for loading LILO. LILO usually stores the sector map in the first hard disk track's unused sectors. You can ignore the warning. If you do things that change the position of LILO's files on disk then you may have to re-install LILO.

Here are some suggestions for you if you do have problems because the first port is being assigned a BIOS drive ID.

BIOS drive IDs are assigned like this.

0x80 First hard disk
0x81 Second hard disk
0x82 Third hard disk
0x83 Fourth hard disk
...

In the BIOS you can disable the "Auto" disk detection for the first SATA port. Set the drive type to NONE, or in some cases set the parameters to zero to disable detection of any drive on the port.

In the BIOS, make sure that you have the correct hard disk set as the first boot disk. That should assign BIOS ID 0x80 to the first boot disk.

Your BIOS might assign a drive ID to the broken SATA port even though there is no disk attached. In that case you might have a gap in the drive IDs. For example, 0x80, 0x82, 0x83, 0x84 ... You can find out the BIOS drive IDs using a GRUB (0.97 Legacy) boot CD or floppy. Use the "native" command mode from the GRUB boot disk (press "C" at the GRUB boot menu). Then you can enter a "find" command to find a file on one of the disks to determine the disk's BIOS drive ID.

GRUB command
Code:
find /boot/vmlinuz
GRUB will print out the names of all the partitions where the file is found.

GRUB assigns disk drive names like this "(hd0)", "(hd1)", "(hd2)". GRUB assigns partition numbers like this "(hd0,0)", "(hd0,1)". For example, "(hd1,1)" is the second partition on the second hard disk (ID 0x81).

Changing BIOS settings, like which disks are enabled for booting, and the boot priority (order) may change the BIOS disk drive IDs. In some cases you may not be able to change the BIOS disk drive IDs except perhaps the first one. Make sure that you have your BIOS set the way you want before installing boot loaders. If you change those BIOS settings you may have to reinstall the boot loaders.

Once you know the BIOS drive IDs you can tell LILO which ones to use if necessary.

LILO example to set BIOS IDs for drives.
Code:
disk=/dev/sda
     bios=0x80
disk=/dev/sdb
     bios=0x82
disk=/dev/sdc
     inaccessible
Drive "/dev/sdb" in the example is assigned to BIOS drive ID 0x82 instead of the usual ID of 0x81. You have to set LILO's parameters to agree with what the BIOS does. Changing "lilo.conf" does not change how the BIOS assigns the drive ID's. It changes which BIOS drive ID's LILO will use for accessing the drives.

Hopefully you will find that LILO figures out the BIOS IDs correctly and you will have no problems.

Usually, Linux assigns the same device names like "/dev/sdb" the same way every time that you boot. In some cases, removing a drive can cause the device names to change. To avoid a problem in the boot parameters and "fstab" file, use a UUID to identify a disk instead of a device name. If your first disk port stays broken all the time then you should not have trouble with device names changing.

You can also force the device name assignments by editing or creating files in "/etc/udev/rules.d". That should only be necessary if you are running scripts or programs that access devices using the names.
 
Old 01-22-2013, 02:10 AM   #4
WiseDraco
Member
 
Registered: Nov 2006
Location: Europe,Latvia,Riga
Distribution: slackware,slax, exMandriva
Posts: 358

Original Poster
Rep: Reputation: 28
Thank you for explanation, especially Erik_FL. i print this out and read again in free time. Broken port is first SATA (SATA0) and as i remember it cannot disable from bios - i try this, but there is only autodetect, as i remember.
about UUID - it seems not work in LiLo - i try LiLo work via Labels and UUID in 13.37 and 14.0 version, and no success ( i installed Linux on external USB HDD, and in that case, especially when i attach it to different computers, it assigns different name each time - sdb , sdc , sdd, as so in that situation work via disklabels or UUID will be very good solution, but i found, Labels and UUID not work in LiLo - in fstab all is ok via labels, but not in lilo...
also things wit bios assigned ID looks not so good, as in old times, when PATA rules - there alway primary master = hda, secondary master = hdc and so on - not any automatic drive letters reassign and so on.
Thank you again...
PS. port is broken physically, it is not misdetecting non - existent drives or so on, only problem with it - i cannot connect any hdd or oanother device to sata0 port. try to repair it may be expensive and without warranties, therefore i ask a question about what necessary it is for my config - two system disk as soft raid1 and one disk for fileserver...
 
Old 01-22-2013, 07:10 AM   #5
commandlinegamer
Member
 
Registered: Dec 2007
Posts: 68

Rep: Reputation: 11
I usually try to connect up my drives to the sata ports in the order I would want them to boot, so first drive - sata0, second - sata1 and so on. And if sata0 were not available I would start with sata1, and so forth.

I have a workshop machine with two PATA hard disks for the OS (Slack, naturally). Normally, if no other drives are attached they are /dev/sda and /dev/sdb. But I use this machine for diagnostics, so often have sata drives attached, which then take precedence.

So, to make sure the machine boots properly I use UUIDs. My lilo.conf looks like this:

Code:
boot = /dev/sda
append=" vt.default_utf8=0"
prompt
timeout = 50
vga = normal
image = /boot/vmlinuz-generic-smp-2.6.37.6-smp
  initrd = /boot/initrd.gz
  root = "UUID=c01ed0c7-1a6e-4c96-abc5-7a6d2c7b2af6"
  label = lnxgen
  read-only
image = /boot/vmlinuz
  root = /dev/sda2 # Fallback for use in emergency
  label = linorg
  read-only
Obviously, you'd need to edit with the appropriate UUID for your root.

Last edited by commandlinegamer; 01-22-2013 at 07:12 AM.
 
Old 01-22-2013, 08:09 AM   #6
WiseDraco
Member
 
Registered: Nov 2006
Location: Europe,Latvia,Riga
Distribution: slackware,slax, exMandriva
Posts: 358

Original Poster
Rep: Reputation: 28
Quote:
Originally Posted by commandlinegamer View Post

So, to make sure the machine boots properly I use UUIDs. My lilo.conf looks like this:

Code:
boot = /dev/sda
append=" vt.default_utf8=0"
prompt
timeout = 50
vga = normal
image = /boot/vmlinuz-generic-smp-2.6.37.6-smp
  initrd = /boot/initrd.gz
  root = "UUID=c01ed0c7-1a6e-4c96-abc5-7a6d2c7b2af6"
  label = lnxgen
  read-only
image = /boot/vmlinuz
  root = /dev/sda2 # Fallback for use in emergency
  label = linorg
  read-only
Obviously, you'd need to edit with the appropriate UUID for your root.
thank you! try to test lilo.cfg with UUID as in your example.
 
Old 01-22-2013, 10:30 AM   #7
TSquaredF
Member
 
Registered: Dec 2005
Location: "The South Coast of Texas"
Distribution: Slackware64-current
Posts: 488
Blog Entries: 1

Rep: Reputation: 55
One note: You MUST use an initrd, as commandlinegamer did, to get root=UUID=whatever or root=LABEL=whatever recognized in the boot process. The code to recognize UUID/ROOT is in the init script generated by the initrd (thanks, Eric), but not in the init script that is in LILO (or grub).
Regards,
Bill
 
Old 01-22-2013, 01:13 PM   #8
Erik_FL
Member
 
Registered: Sep 2005
Location: Boynton Beach, FL
Distribution: Slackware
Posts: 793

Rep: Reputation: 245Reputation: 245Reputation: 245
The UUID only works for mounting disks in Linux. As TSquaredF stated, the root file-system is special and requires an initrd to locate and mount it using the UUID. Boot loaders usually can't find files by using disk UUIDs.

The files in LILO specified for "image" and "initrd" cannot be located by UUID, since they are located when LILO is installed, and not during booting.

Code:
image = /boot/vmlinuz
  initrd = /boot/initrd.gz
LILO saves the location of the files (sectors and BIOS disk ID) when LILO is installed. If "vmlinuz" or "initrd.gz" above are links to files, then LILO saves the location of the "real" file. If the link is changed later, LILO must be reinstalled. Otherwise LILO will keep using the old file that was in the link when LILO was installed.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Motherboard capability question - Pinholes for dual USB port, but only single used Dogs General 6 10-18-2010 07:20 AM
what if a motherboard has no VGA port? newbiesforever General 2 06-03-2008 02:20 AM
Affero kaput? bulliver LQ Suggestions & Feedback 1 11-18-2005 01:26 PM
Ethernet port on ABIT Nvidia Nforce2 motherboard doesnt recognised in linux movanns Linux - Hardware 4 04-27-2005 03:23 AM
CD-RW kaput! kabads Linux - General 5 09-29-2002 02:59 PM


All times are GMT -5. The time now is 05:25 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration