Please consider a donation to the Higher Intellect project. See https://preterhuman.net/donate.php or the Donate to Higher Intellect page for more info. |
SPARC Linux Netbooting
1. Net Booting
To net boot you need need another computer on our network which you can use to provide the root (at least) file system for your Sparc-Linux machine. The machine can be any machine that is capable of providing RARP, tftp, and NFS services. Henceforth this machine will be called the server. The machine that you booting Sparc-Linux on will be called the client.
1.1 Setting up RARP
RARP (Reverse Address Resolution Protocol) is how you client will figure out what IP address to use.
SunOS and Solaris Servers
Under SunOS and Solaris you need to ensure that the ethernet hardware address for the client is listed in the ethers database (either in the /etc/ethers file, or via NIS/NIS+) and in the hosts database. Then you need to start the RARP daemon:
For Sunos: /usr/etc/rarpd -a For Solaris: /usr/sbin/rarpd -a
Linux Servers
Under Linux you need to populate the kernel's rarp table. To do this execute something like this:
/sbin/rarp -s phoenix 00:00:c0:49:af:50 /sbin/arp -s 137.82.51.3 00:00:c0:49:af:50
1.2 Setting up TFTP on the Server
TFTP (Trivial FTP) is used by the client to load the kernel over the network. To enable TFTP on the server you need to ensure that the tftp service is uncommented in your /etc/inetd.conf file. The line should look something like:
tftp dgram udp wait root /usr/etc/in.tftpd in.tftpd -s /tftpboot
The argument following in.tftpd will specify the directory where it will look for the files that the client requests. After uncommenting it you will need to get your inetd process to reread the file:
kill -HUP <em/inetd-PID/>
1.3 Putting the kernel in the TFTP directory
First off you need to get the latest kernel image. These can be found in ftp://vger.rutgers.edu/pub/linux/Sparc/images.
You then need to unzip this file and place it in the directory that
you specified for tftp. (e.g. /tftpboot) When the client tries to load
the kernel it will look for a file named by a standard convention. The
name is the IP address of the sparc in hex with no dots followed by
the architecture of the client in all caps (e.g. ".SUN4C"
)
An example for a machine with IP 194.77.26.181 would be:
C24D1AB5.SUN4C
1.4 Making a Root Directory for the Client
You will also need a root directory for your client. The easiest way
to provide this is to create a root directory on the tftp server. By
default the kernel will look for the root directory in a subdirectory
or the tftp directory named for its IP address. For example if your
client has the IP address: 137.82.53.69 and your tftp directory is
/tftpboot
then make a subdirectory:
/tftpboot/137.82.53.69
The easiest way to fill up the root
directory is to get Miguels root directory tarball from:
ftp://vger.rutgers.edu/pub/linux/Sparc/userland/easy.nfs.root-2.tar.gz
.
To untar and install it:
cd /tftpboot mkdir 137.82.53.69 cd 137.82.53.69 gzip -dc easy.nfs.root-2.tar.gz | tar xvf -
1.5 Sharing the TFTP Directory
For the client to mount the root directory using nfs, the server must export the directory.
For Solaris:
Make an entry in /etc/dfs/dfstab something like: (assuming the client's name is pearl
share -F nfs -o root=pearl,rw=pearl -d "tftpboot" /tftpboot
and do a shareall
For SunOS:
Make an entry in /etc/exports something like: (assuming the client's name is pearl
/tftpboot -access=pearl,root=pearl
and do a exportfs -a
For Linux:
make an entry in /etc/exports something like: (assuming the client's name is pearl
/tftpboot pearl(rw,insecure,no_root_squash)
1.6 Actually Booting the Client
Now to actually boot the client. Start up the computer and interupt what even boot process that it starts by default. You can do this by holding down the STOP (L1) key and hitting A.
You are now at the Sparc boot PROM prompt. You should have an
ok prompt. If you have an older machine you will have a
>
prompt, to get the newer prompt type n.
To boot from the network simply type:
boot net
You should see the kernel loading, many messages about the hardware you have and end up with a root prompt.
1.7 A simple example
For the example the server is a Solaris machine, the client is IP 137.82.53.69 and named dodo.
On the server make the tftp directory:
mkdir /share/tftpboot
Edit /etc/dfs/dfstab add the line:
share -F nfs -o root=dodo,rw=dodo /share/tftpboot
and share the directory:
shareall
Edit /etc/inetd.conf uncommenting:
tftp dgram udp wait root /usr/sbin/in.tftpd in.tftpd -s /share/tftpboot
Restart inetd (121 is the PID of inetd):
kill -HUP 121
Start the rarpd daemon (dodo is already listed in ethers and hosts)
/usr/sbin/in.rarpd -a
Got the easy.nfs.root-2.tar.gz and vmlinux-960610.gz. Install them:
cp vmlinux-960610.gz /share/tftpboot cd /share/tftpboot gunzip vmlinux-960610.gz mv vmlinux-960610 89523545.SUN4M mkdir 137.82.53.69 cd 137.82.53.69 gzip -dc easy.nfs.root-2.tar.gz | tar xvf -
On the client: boot net and it boots to a root prompt.