Tips & Tricks



32bit vs. 64bit Version

Most SGI systems do indeed use 64bit CPUs, but that doesn't mean that the architecture allows them to run 64bit IRIX. The following list shows which machines do run IRIX64:

32bit CPU, 32bit IRIX:
   - Professional Iris
   - PowerSeries
   - Personal Iris

64bit CPU, 32bit IRIX:
   - Crimson
   - Indigo
   - Indigo 2 (R4x00)
   - Indy
   - O2 / O2+

64bit CPU, 64bit IRIX:
   - Indigo 2 (R8000 and R10000)
   - Challenge/Onyx (IP19, R4x00)
   - Challenge/Onyx (R8000 and R10000)
   - Octane / Octane 2
   - Origin 200
   - Origin 2000 / Onyx 2
   - Origin 300
   - Origin 3000 / Onyx 3000
   - Fuel

Use uname -s to see which version of IRIX you are running.

(Re)scanning SCSI devices

Recommended Reading: man scsiha, man ioconfig

Let's assume your CD-ROM (SCSI ID #2) is on the external SCSI adapter of an Indigo 2 (SCSI Bus #1) and it was not switched on when the machine was booted. To rescan the SCSI Bus use scsiha -p 1 and then rebuild the /hw graph ioconfig -f /hw. After this the CD-ROM can be mounted using mount /dev/dsk/dksc1d2s0 /CDROM - if you want automatic mounting restart mediad.

A word of warning: Unless the manuals say something else, do never plug/unplug SCSI drives while the system is operating! Doing so is likely to do harm to the drive and/or system.

Setting up the Timezone

German Setup

Setting /etc/TIMEZONE is not well documented (in my opinion) for systems in Germany. A working setting is:



For the general setup of /etc/TIMEZONE or the TZ environment variable please refer to the environ(5) manpage.

Accessing Volume Headers

Simply duplicating the disk contents by xfsdump or by using a tar backup isn't enough when trying to clone a rootdrive.

The following example assumes that the source disk is SCSI ID #1 on controller #0 and that the target disk is SCSI ID #2 on the same controller. Both disks are partitioned as root drives and the contents of the source disk have been transferred to the target drive.

Step One: Extracting sash and ide executables from the volume header.

dvhtool -v get sash /stand/sash /dev/rdsk/dks0d1vh
dvhtool -v get ide /stand/ide /dev/rdsk/dks0d1vh 

Step Two: Writing the files to the volume header of the target disk.

dvhtool -v create /stand/sash sash /dev/rdsk/dks0d2vh
dvhtool -v create /stand/ide ide /dev/rdsk/dks0d2vh

Step Three: Verify that the files have been written.

dvhtool -v list /dev/rdsk/dks0d2vh 

Deleting the Root Password

The basic idea is to boot from the installation CD-ROM and edit the user/password database on the system. So the first step is to find the appropriate boot media for the machine and attach a CD-ROM drive to the system.

Now when the system is powered on stop the boot process immediatly after the POST. Press ESC or click on the button to enter the maintenance menu. From there select "Install system software" and wait until the system presents you the inst menu. Switch into the "admin" section and use "shell" to invoke a subshell in which you will have root access to the system.

The existing root drive is now mounted as /root. So the files you want to edit are /root/etc/passwd and (if it exists) /root/etc/shadow. The install tools may not come with a useable editor, so you can try the one that is installed on the disk (e.g. /root/bin/vi).

Distribution Tape

How to make a backup of a distribution tape.

For doing a backup of Silicon Graphics distribution tapes no fiddling around with dd or tools like that is required. IRIX has distcp which is written exactly for the purpose of copying distribution sets from one media to another.

distcp -v /dev/tape /dist/tape

The command above copies the distribution data from /dev/tape to the directory /dist/tape where you can keep it as backup or which can be used to export to other machines for network installation.

How to write a distribution tape.

Writing a previously copied distribution to tape is also very easy. It is actually done just the other way around:

distcp -v /dist/tape /dev/tape

A Gotcha

Recent tests seem to indicate that distcp adds version specific headers to the files downloaded from tapes. This means that for example copying a tape from 4D1-4.0.x on an IRIX 6.2 machine renders the files useless for 4D1-4.0.0.

Base Installation

Doing a base installation for a different hardware platform.

Consider the following problem: You want to install IRIX from scratch on old/slow hardware or on machines where installation via network or from CD are not an option. This quick hint indicates where the solution lies.

By default the IRIX installer (inst) does a software installation for the machine it is currently running on. You can check this in the admin by typing the hardware command which will show you the selected platform flags. The most relevant here are CPUBOARD, GFXBOARD and SUBGR.


To install IRIX for a different platform these settings need to be changed, which cannot be done from within inst. This guide assumes the fresh disk is the boot device and inst has been invoked from a valid installation source (not a running system).

Setting the parameters requires inst to be restarted. This can be accomplished by quitting it and going into a shell instead of rebooting when asked for it. From there it is possible to start a new instance of inst including the parameters on the command line. Here is an example for installing IRIX 5.3 over network for use on a Crimson Reality Engine:

inst -r /root -m SUBGR=IP17 -m GFXBOARD=VENICE -m CPUBOARD=IP17 -f

Before proceeding check the hardware settings again, the selected choices should show up no matter of the hardware inst is really running on:

Admin> hardware


Further Reading.

As further reading man 1M inst is suggested. This manpage also explains the variables and options used.


Custom Login Icons

Recommended Reading: man visuallogin, man clogin

Use chkconfig to make sure that visuallogin is set to on and noiconlogin to off. The icons (SGI RGB format, at least 100x100 pixels) can be placed in the following locations:


$USER is the loginname of the user, $HOME the home directory.

Color Depth

To change the color depth to 24 bit, /usr/lib/X11/xdm/Xservers has to be modified. Typically the line for the main display includes -pseudomap 4sight, which has to be replaced with -depth 24 -class TrueColor. The following is an example:

:0 secure /usr/bin/X11/X -bs -nobitscale -c -solidroot sgilightblue -cursorFG red -cursorBG white \
-depth 24 -class TrueColor

For this change to take effect you either have to reboot the system or restart the X Server. A simple way of restarting the X server is issuing the following line as root:


Custom Toolchest

How to change Toolchest as a User

Recommended reading: man toolchest

Every user can add personal entries to the Toolchest by editing the .auxchestrc file in his or her homedirectory (create the file if it does not exist).

How to add entries to existing menus

Let's start with an example:

Menu System
  no-label f.separator
  "Gmemusage" "/usr/sbin/gmemusage"

This adds two new items to the bottom of the existing "System" menu. The first is a separator line, the second is a call to /usr/sbin/gmemusage, that will appear with "Gmemusage" as a label.

How to add a new menu

Again we start with an example (plus we assume that you have read the part on expanding existing menus):

Menu Stats
  no-label f.separator
  "Gmemusage" "/usr/sbin/gmemusage"

Menu ToolChest
  "Stats" Stats

This will add a new menu labelled "Stats" to the Toolchest. Note that the name given to the menu is referenced in the end of the "Stats" Stats line. This is neccessary. What is not neccessary is that the label matches this name.

Autostarting Applications

How to have one or more application started when logging in on the graphics console.

This is pretty easy. As a user edit (or create) the file .sgisession in your home directory. Put the call to your applications in that file like that:


When you log in all commands given in that file are executed automatically.

Console Based Applications in Toolchest

How to call console applications from Toolchest or at login.

The straightforward approach would be to simply enter the path and the filename, but that will run the application in the background - rather useless for a console based newsreader or mailclient. The appropriate way of invoking such an application is to start an xterm (personally I prefer something else like winterm) and have it start the desired application once it is loaded. An example of winterm calling slrn:

winterm -e /usr/local/bin/slrn

This will leave you with a terminal window including the application. The window will close as soon as the application is terminated. If you are also using winterm you can add descriptions that will appear as title in the window (-t name) and when displayed in the iconbox (-n name).

winterm -n slrn -t slrn /usr/local/bin/slrn

Custom Background

How to load a custom background

Loading a custom background is easy if you are using a tool like xloadimage, which is available from the download section. This tool has tons of options to convert an image file into something suitable for using as a background (can add border and such).

xloadimage -onroot your_image.jpg

This puts the image in the background and tiles it if it's resolution is smaller than the one you have selected for your monitor. xloadimage has an builtin interactive help feature which is invoked by calling xloadimage -help.

How to add the image to the background menu

This requires some steps in preparation. First -unless you have done it before- you have to copy /usr/lib/X11/system.backgrounds into your home directory where you have to name it .backgrounds (also chmod/chown it so you can edit it).

Open the file with your favourite editor but do not delete the existing entries unless you don't want them to appear in your menu anymore. The following is an example entry from my .backgrounds file. It adds an entry named "Sky" which loads the image file pict0580.jpg using the xloadimage program.

background "Sky"
   command "-execute /usr/local/bin/xloadimage -onroot -fork /usr/people/gerhard/.background-files/pict0580.jpg"
   default "-execute /usr/local/bin/xloadimage -onroot -fork /usr/people/gerhard/.background-files/pict0580.jpg"
   exeok "/usr/local/bin/xloadimage"
   readok "/usr/people/gerhard/.background-files/pict0580.jpg"

Doing the same with an application

Now imagine you want one of these shiny programs run on your background. In the example I'm going to use powerflip to display a turning SGI logo on the background (hint: change -R to -Rs if you want a static image and have a look at man powerflip for more options).

background "FlipLogo"
   command "-execute /usr/demos/bin/powerflip -R /usr/demos/data/yaodl/logo.ydl"
   default "-execute /usr/demos/bin/powerflip -R /usr/demos/data/yaodl/logo.ydl"
   exeok "/usr/demos/bin/powerflip"
   readok "/usr/demos/data/yaodl/logo.ydl"

Restart Desktop

In these rare cases (never happened to me) you can force the system to restart X by pressing [Ctrl] + [Shift] + [F12] + [/] at the same time ([/] on the numpad btw.). If you have a network connection to the machine or have a serial terminal attached you could also log in from there and try to restart X. In all these cases data loss (unsaved data) is going to happen.


Additional Network Devices

Some SGI systems have more than one network interface. The relevant files for the configuration of these are netif.options and ifconfig-n.options (n = number of device) located in /etc/config as well as the /etc/hosts file. In the example we assume that we are adding an FDDI interface to a system - it will be the third network interface. The name of the interface is fddi0 (check with netstat -i) and it will be assigned as IP address. The hostname is example.

The first step is to add the required information to /etc/config/netif.options. Note that there are some means provided for automatic configuration - the comments have the details on that. Adding the third interface of our example is as simple as modifying the lines related to that interface:


In this case you have to add a line to /etc/hosts which assigns an IP address to the name given in if3addr (note that you cannot $HOSTNAME in /etc/hosts). The line we add in our example is:    fddi-example
If you don't want to specify any advanced settings like different subnets for your interfaces you are done and can reboot the systems. These advanced settings can be put into files named ifconfig-n.options in /etc/config (n = number of interface). Usually there are some advanced settings to be made to make real use of the additional networking interfaces.