Skip to contentSkip to conversation

How to get the masses (IRIX<->Linux) (fwd)

DISCUSSION Ariel Faigon 2 participants 2 messages Jul 10, 1997 – Jul 11, 1997 MIPS

lore
Share & tools
lore
#0 lore raw

[I'm forwarding this very helpful hint from Christian to the list
not sure if all our audience, especially those outside SGI are aware of all these options.]

Now since after setting nvram it'll always boot Linux ;-) the question is how to toggle two different (Linux/IRIX) nvram settings in a friendly trivial way...

Looks like a SILO option after the wakup/reboot would be the best.

Press 1 to boot IRIX [default]
Press 2 to boot Linux

----- Forwarded message from Christian Reisch -----

From [email protected] Thu Jul 10 14:52:45 1997
Sender: [email protected]
Date: Thu, 10 Jul 1997 14:52:39 -0700
From: Christian Reisch <[email protected]>
To: Ariel Faigon <[email protected]>
Subject: Re: How to get the masses (IRIX<->Linux)

Quoted 7 lines · Ariel Faigon

% su
# at 5am July 3
/usr/sbin/wakeupat 6pm Thursday /etc/shutdown -y
<Ctl-d> (control - d) This will submit the job. # exit

Quoted 5 lines

If we could rewrite wakeupat or reboot to take some extra boot options or alternatively run some Linux loader (SILO/MILO) from IRIX then 2) should be easy.

I think irix decides where to boot from from these nvram variable...

SystemPartition=pci(0)scsi(0)disk(1)rdisk(0)partition(8) OSLoadPartition=pci(0)scsi(0)disk(1)rdisk(0)partition(0) OSLoader=sash
OSLoadFilename=/unix
OSLoadOptions=auto

You could write a script to fudge them with the nvram command then shutdown and wake up. Unfortunately I don't have the disk/time to play with it at the moment

6

----- End of forwarded message from Christian Reisch -----

Signature · 1 line
Peace, Ariel
#1 lore raw
Quoted 9 lines · Ariel Faigon

Subject: Re: How to get the masses (IRIX<->Linux) (fwd) [I'm forwarding this very helpful hint from Christian to the list
not sure if all our audience, especially those outside SGI are aware of all these options.]

Now since after setting nvram it'll always boot Linux ;-) the question is how to toggle two different (Linux/IRIX) nvram settings in a friendly trivial way...

Quoted 6 lines

Looks like a SILO option after the wakup/reboot would be the best.

Press 1 to boot IRIX [default]
Press 2 to boot Linux

-- End of excerpt from Ariel Faigon

Actually, we frequently have two versions of IRIX that we need to boot each from a different disk drive. We have a shell script which root can run which sets up nvram so that the next time we reboot, it will come up in the other OS. Here's the script below:

#!/bin/sh
#
# Usage: switch_os 6.2 switches to 6.2
# switch_os 6.5 switches to 6.5

if [ $# -lt 1 ] ; then
echo "Usage: switch_os <6.2|6.5>"
exit
fi
if [ $1 != "6.2" -a $1 != "6.5" ] ; then
echo "Usage: switch_os <6.2|6.5>"
exit
fi
if [ $1 = "6.2" ] ; then
sys_part="scsi(0)disk(1)rdisk(0)partition(8)"
os_load="scsi(0)disk(1)rdisk(0)partition(0)"
else
sys_part="scsi(0)disk(3)rdisk(0)partition(8)"
os_load="scsi(0)disk(3)rdisk(0)partition(0)"
fi
echo "rebooting venus to use $1 in 5 seconds..."
sleep 5
/sbin/nvram SystemPartition $sys_part
/sbin/nvram OSLoadPartition $os_load
/etc/reboot

Signature · 11 lines
		Chris Carlson

	+------------------------------------------------------+
	| Also, [email protected]                                |
	|   Work:   (714) 224-4530                             |
	|   Vnet:       6-678-4530     FAX:    (714) 833-9503  |
	|                                                      |
	| Trivia fact: an electroencephalogram shows that a    |
	| human brain and a bowl of quivering lime Jell-O have |
	| the same waves.  [Time Magazine, Mar 17, 1997]       |
	+------------------------------------------------------+