LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Password
Solaris / OpenSolaris This forum is for the discussion of Solaris, OpenSolaris, OpenIndiana, and illumos.
General Sun, SunOS and Sparc related questions also go here. Any Solaris fork or distribution is welcome.

Notices


Reply
  Search this Thread
Old 01-12-2007, 03:39 AM   #1
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Rep: Reputation: 112Reputation: 112
Can the disk order be changed after installation in Solaris?


I am trying to swap the disk order of a Solaris disk installed as the 1st disk and to be booted as the 5th disk, so far without much luck.

The reason is historical as I installed it separately before on its own disk and now want to use it in a 5-disk box.

I am booting it with Grub which under the normal circumstance permits a user to swap the disks on-the-fly. I know it works as I can boot 3 Dos and 5 Windows with the technique. It is standard stuff as Lilo the other Linux boot loader also has the same facility.

I vaguely remember seeing a documentation saying Solaris doesn't follow the Bios rules or something to that effect.

Can someone confirm is the disk order changeable after installation? or aware of a scheme that I can accomplish it?

It isn't a big deal to do a re-install but I am starting to lear Solaris again and this is important for me to know/understand.
 
Old 01-12-2007, 08:53 AM   #2
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.3, Oracle Linux, Mint, Tribblix
Posts: 9,731

Rep: Reputation: 448Reputation: 448Reputation: 448Reputation: 448Reputation: 448
What is the problem you are trying to solve ?

Normally, Solaris doesn't use the BIOS numbering to order its disks (as you remember to have read), so it should be immune to the issue you are describing.

The first disk where you installed Solaris is always /dev/dsk/c0[t0]d0d0 , whatever its physical location is.
 
Old 01-12-2007, 09:16 AM   #3
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Original Poster
Rep: Reputation: 112Reputation: 112
Are you suggesting that when I installed Solaris when the PC has only one disk as the primary master the system can still boot if it is attached as the secondary slave, with the original primary master position given to another hard disk, in addition another disk connected to the secondary master position?

As far as the Bios is concerned I now have 4 disks (the above two plus 2 Sata) in front of the Solaris disk but the preceding 4 disks has no Solaris or BSD inside.

Your reply suggests that the disk order doesn't matter at all. When Solaris boots as there is no other Solaris could be found the 5th disk will be the regarded as the first disk as recorded originally in the installation. Is this correct?
 
Old 01-12-2007, 09:50 AM   #4
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.3, Oracle Linux, Mint, Tribblix
Posts: 9,731

Rep: Reputation: 448Reputation: 448Reputation: 448Reputation: 448Reputation: 448
Quote:
Originally Posted by saikee
Are you suggesting that when I installed Solaris when the PC has only one disk as the primary master the system can still boot if it is attached as the secondary slave, with the original primary master position given to another hard disk, in addition another disk connected to the secondary master position?
No, I'm not. Perhaps am I misunderstanding your setup. I thought the disk location hadn't changed and new disks were inserted in the meanwhile. (eg. disk installed as secondary in the third controller with no other disk, then 4 disks add on the first and second controller). In that case the disk would have stayed as c0d0p0 under Solaris, but moved from hda to hde with Linux.
Quote:
As far as the Bios is concerned I now have 4 disks (the above two plus 2 Sata) in front of the Solaris disk but the preceding 4 disks has no Solaris or BSD inside.

Your reply suggests that the disk order doesn't matter at all. When Solaris boots as there is no other Solaris could be found the 5th disk will be the regarded as the first disk as recorded originally in the installation. Is this correct?
Only if you didn't physically unplug/replug the disk to a new location.

What happen if you try to boot on this fifth disk ?
 
Old 01-12-2007, 10:43 AM   #5
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Original Poster
Rep: Reputation: 112Reputation: 112
I haven't tried it out yet in full anger but the initial trials failed if I igored the disk order.

It is just in Grub if I installed a system in the 1st disk (hd0) and subsequently boot it as the 5th disk the Bios setting can be temporarily altered by these two statements (inside menu.lst)
Code:
map (hd0) (hd4)
map (hd4) (hd0)
The Bios setting reverts back once the system exists.

When I boot Solaris this way it stops and Grub doesn't know what to do.
 
Old 01-12-2007, 04:23 PM   #6
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.3, Oracle Linux, Mint, Tribblix
Posts: 9,731

Rep: Reputation: 448Reputation: 448Reputation: 448Reputation: 448Reputation: 448
Sorry, but I still do not know from your answer what you did with the Solaris disk (was it physically moved or not ?).

How does Solaris stops ? Does it starts booting and fails with an error message ?

What do you mean by "grub doesn't know what to do" ?
 
Old 01-12-2007, 06:22 PM   #7
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Original Poster
Rep: Reputation: 112Reputation: 112
Yes.

There was only one disk during Solaris installation and it was the master disk of the primary IDE channel. In Linux term that would be the hda position.

The disk still boots if I return to this arrangement.

In the new set up now I have it moved to the secondard slave position (or hdd position in Linux). The hda and hdc are filled with hard disks where hdb is always the DVD drive.

Have it been a Dos or Windows (including Vista) I could add the two Grub commands in Post #5 and the system would boot back as though it is from the hda position.

Solaris doesn't seem to obey the Bios information.

Grub usually responds to every command with a message and no message means OK. In this case it hangs without a message. There was no connection made to Solaris partition as far as I could tell.
 
Old 01-13-2007, 06:07 AM   #8
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.3, Oracle Linux, Mint, Tribblix
Posts: 9,731

Rep: Reputation: 448Reputation: 448Reputation: 448Reputation: 448Reputation: 448
Okay. According to what I read in the documentation, the grub map command is targeted to chainload O/Ses which, like DOS/Windows, aren't able to boot from any disk but the first one.

Solaris, like linux, hasn't that limitation so this remapping is unnecessary. Solaris is booted directly by grub and not chainloaded anyway.

I'm still missing one piece of information, what grub are you using ? The one on the Solaris disk or another ?
 
Old 01-13-2007, 08:24 AM   #9
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Original Poster
Rep: Reputation: 112Reputation: 112
I am using GNU/Grub 0.97 which is the standard one use in Linux. It can be installed onto a floppy, a data-only partition or a CD enable it to operate without an operating system attached to it. Highly recommended as I haven't found a PC system that cannot be booted by it.

To put Grub on a floppy requires stage1 and stage2 to be "dd" out from a directory that contains these two files. Any Linux Live CD that supports Grub will have it and the steps are outlined in Chapther 3.1 of the Grub Manual. The version of Grub I found from Solaris Express was Grub 0.97, if my memory served me right.

Grub does have a new version called Grub 2 but I haven't tried it out yet. I have not seen it used on distro yet.

I have downloaded Solaris 10 of the 11/06 version and will try to make it a permanent distro in the box.

Last edited by saikee; 01-13-2007 at 08:25 AM.
 
Old 01-13-2007, 01:03 PM   #10
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.3, Oracle Linux, Mint, Tribblix
Posts: 9,731

Rep: Reputation: 448Reputation: 448Reputation: 448Reputation: 448Reputation: 448
Make sure the grub you use is the one provided with Solaris / OpenSolaris which is 0.95, as Sun contribution hasn't, as far as I know, been integrated in grub repository, or in the 0.97 release.

Grub 2 is planned to be used to boot Solaris in the future, but support isn't yet there.

Where is located the grub you are trying to use to boot Solaris ? on the first disk or on the Solaris one ?

In any case, as you physically moved the disk, you need to figure out the new names associated with the device and then fix some hard coded names in at least three files before being able to boot it.

The files I think of first are /etc/vfstab, /boot/grub/menu.lst and /boot/solaris/bootenv.rc

Beware that the vfstab file will use the /dev syntax (eg. /dev/dsk/c0d0s0), the menu.lst will use grub syntax: eg. root (hd<disk no>,<partition no>,x) and the bootenv.rc will use the /device syntax (eg. /pci@0,0/pci-ide@1f,2/ide@0/cmdk@0,0:a) ...
 
Old 01-13-2007, 02:00 PM   #11
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Original Poster
Rep: Reputation: 112Reputation: 112
jlliagre,

Thanks for the 3-files tip. I have been moving Linux around by editing the boot loader file which is /boot/grub/menu.lst for Grub or /etc/lilo.conf for Lilo plus the /etc/fstab. So the Solaris /etc/vfsatb must be the equivalent. Now I need to look for /boot/solaris/bootenv.rc too.

I haven't tried it but does the Solaris filing system supported by Linux or is there any a special way to mount it, other than specify the filing type with the -t parameter?

In answering your question of the Grub that boots Solaris I used one from a floppy but it is the same in the hard disk. This thread describes how I installed Grub into a data-only partition of hda3. Basically I boot difficult systems "manually" in a Grub prompt which you can get by pressing "c" key when the Grub screen first appears in Solaris. The instructions to boot each system are those inside the menu.lst except you omit the "title" statement which become superfluous and everything must end with a "boot" statement, whcih is a grren light to ask Grub to go ahead.

I have discovered an interesting point between Solaris Grub and the Linux Grub. You are correct in pointing out Solaris uses Grub 0.95 but it has been tweaked. This is because the normal Grub 0.95 sourced from Linux will respond to
Code:
root (hd0,2,a)
with "no such partition", whereas the Solaris Grub 0.95 will accept it.

This was how I how I found it out.

(1) Use Linux Grub 0.95 from a floppy to boot up Solaris's Grub 0.94 by (My Solaris is in 3rd partition of the 5th disk)
Code:
root (hd4,2)
chainloader +1 
boot
I then got Solaris booting screen

(2) I pressed "c" to get me into a Grub prompt (Solaris Grub 0.95 from now on)

(3) I asked Solaris Grub to show me how it boots Solaris by command
Code:
cat /boot/grub/menu.lst
The relevant section is
Code:
root (hd0,2,a)
kernel /platform/i86pc/multiboot
module /platform/i86pc/boot_archive
(4) I tried to change to "root (hd4,2,a)" which Grub accepted and fired up the other 2 statements.

It didn't boot because I did not know the need to edit the other 2 files you have just posted.

Nevertheless I got one step closer. So thanks again.
 
Old 01-13-2007, 05:18 PM   #12
jlliagre
Moderator
 
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.3, Oracle Linux, Mint, Tribblix
Posts: 9,731

Rep: Reputation: 448Reputation: 448Reputation: 448Reputation: 448Reputation: 448
Quote:
Originally Posted by saikee
I haven't tried it but does the Solaris filing system supported by Linux or is there any a special way to mount it, other than specify the filing type with the -t parameter?
Not sure I understand what you are asking for. Please rephrase if the answer is not in my last sentence in this posting.

Quote:
In answering your question of the Grub that boots Solaris I used one from a floppy but it is the same in the hard disk. This thread describes how I installed Grub into a data-only partition of hda3. Basically I boot difficult systems "manually" in a Grub prompt which you can get by pressing "c" key when the Grub screen first appears in Solaris. The instructions to boot each system are those inside the menu.lst except you omit the "title" statement which become superfluous and everything must end with a "boot" statement, whcih is a grren light to ask Grub to go ahead.

I have discovered an interesting point between Solaris Grub and the Linux Grub. You are correct in pointing out Solaris uses Grub 0.95 but it has been tweaked.
That is exactly what I meant in the beginning of my previous post with Sun contribution. Well, I wouldn't have said "tweaked", but "enhanced" to support Solaris native boot (i.e. ufs support).
Quote:
This is because the normal Grub 0.95 sourced from Linux
Grub is independant from Linux. It's a FSF project. Grub 0.95 or 0.97 are no more maintained now, so the future is with Grub 2. In the meantime you have to use Sun's version of grub to boot Solaris. Of course this version can still boot your Linux or other O/Ses.
Quote:
...

(4) I tried to change to "root (hd4,2,a)" which Grub accepted and fired up the other 2 statements.

It didn't boot because I did not know the need to edit the other 2 files you have just posted.
To edit them, the simplest way is to boot on a bootable Solaris CD or DVD (installation disk or live distro) and mount the on disk / partition. I'm not sure Linux can mount read-write UFS file-systems, and anyway wouldn't trust it that much.
 
Old 01-13-2007, 05:36 PM   #13
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Original Poster
Rep: Reputation: 112Reputation: 112
You last point answered the first point as I was just wondering how easy to mount a Solaria partition in Linux.
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
I'm multibooting and something has changed about disk order in GRUB, I think, help... brjoon1021 Linux - Distributions 13 12-09-2006 03:05 AM
Can I specify hard disk order? gzunk Linux - Hardware 1 09-25-2006 09:28 AM
Disk Geometry changed by GRUB causes XP boot failure ILoveTux Linux - Software 3 05-16-2006 09:19 AM
I changed the hard disk Gins Linux - General 8 11-22-2005 02:41 PM
SAN LUN disk device order jhumeston Linux - Software 1 07-28-2004 07:02 PM

LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris

All times are GMT -5. The time now is 01:50 PM.

Main Menu
Advertisement
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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration