User Tools

Site Tools


network_install_vagrant

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

network_install_vagrant [2019/01/29 00:59] (current)
raion Imported from MW install
Line 1: Line 1:
 +=====Network Install Vagrant=====
  
 +====Requirements====
 +  *Download the IRIX disk images from a reputable source such as the irix.cc FTP, archive.org,​ or make CD images from the original install media if you have it (i'm not going to cover that here!).
 +  *Download ‘Vagrant’ for the OS of whatever machine you’re running it on. PC, Mac or Raspberry Pi, grab it here: https://​www.vagrantup.com/​downloads.html
 +  *Download '​irixboot'​ from GitHub here: https://​github.com/​halfmanhalftaco/​irixboot
 +
 +====Set Up Vagrant====
 +  *Assuming you downloaded irixboot as a single zip file, open irixboot-master.zip from wherever you downloaded it and unzip wherever you want, keeping in mind this folder will have to also store the CD images for the install.
 +  *Copy the text from below into the ‘irixboot-master’ folder as a file called Vagrantfile with no extension. Amend the commented bits as necessary.
 +<​code>​
 +# irixboot
 +# vagrant configuration
 +# (c) 2018 Andrew Liles
 +# Annotated & commented 2018 by Kai Robinson
 +# https://​github.com/​halfmanhalftaco/​irixboot
 +# LICENSE: MIT
 +
 +#####
 +# Change these settings to match your environment
 +#####
 +
 +irixversion = '​6.5'​ # Change to 5.3 or 6.2 if you have install media for that. 
 +
 +clientname = '​octane'​ # Change this to whatever is the system type, ie, indy/​octane/​fuel
 +clientdomain = '​household.net'​ # You might need to setup your household router with a domain name - even if it's bogus like this, just so that the SGI is happy.
 +clientip = '​172.16.10.112'​ # Assign this IP address to the SGI Machine, both on the Router (assign IP by MAC), and using the setenv command in the command monitor. ​
 +clientether = '​08:​00:​69:​13:​9E:​37'​ # Get the MAC address by typing printenv in the command monitor.
 +netmask = '​255.255.255.0'​ # Self-explanatory,​ subnet mask for your network.
 +
 +hostip = '​172.16.10.101'​ # The IP of the machine that Vagrant will be running the VM on - the NIC is bridged, so they share the same IP address. ​
 +bridgenic = '​eth0'​ # Try not to change this, it should be left alone if possible. ​
 +
 +#####
 +# Nothing else needs to be changed, leave it all alone if possible. Refer to the readme document :)
 +#####
 +
 +installdisk = '​./​installdisk.vdi'​
 +
 +Vagrant.configure("​2"​) do |config|
 +
 +  config.vm.box = "​debian/​contrib-jessie64"​
 +  config.vm.box_version = "​8.11.0"​
 +  config.vm.network "​public_network",​ ip: hostip, bridge: bridgenic
 +  config.vm.post_up_message = [ "​irixboot running at ", hostip ]
 +  ​
 +  config.vm.provider "​virtualbox"​ do |v|
 +   unless File.exist?​(installdisk)
 + v.customize ['​createhd',​ '​--filename',​ installdisk,​ '​--size',​ 50 * 1024]
 +   end
 +   v.customize ['​storageattach',​ :id, '​--storagectl',​ 'SATA Controller',​ '​--port',​ 1, '​--device',​ 0, '​--type',​ '​hdd',​ '​--medium',​ installdisk]
 +
 +   # this workaround was required for my case because the config.vm.network :bridge argument does not see all of my interfaces for some reason.
 +   # v.customize ['​modifyvm',​ :id, '​--bridgeadapter2',​ "​Intel(R) Ethernet Connection (2) I219-V - VLAN : RETRO"​]
 +  end
 +  ​
 +  config.vm.synced_folder "​.",​ "/​vagrant",​ type: "​virtualbox"​
 +  config.vm.provision "​shell",​ path: "​scripts/​init.sh"​
 +  config.vm.provision "​shell",​ path: "​scripts/​dist.sh",​ run: '​always',​ args: irixversion
 +  config.vm.provision "​shell",​ path: "​scripts/​boot.sh",​ run: '​always',​ args: [clientname,​ clientip, clientether,​ clientdomain,​ netmask, hostip]
 +end</​code>​
 +
 +  *Copy the entire disk image directory (6.5.30 or 6.5.22 depending on the machine) into the ‘irix’ directory in ‘irixboot-master’,​ this is setup with all the right images for a full installation of the relevant IRIX version.
 +  *Follow this as the disk structure (6.5.30 shown as an example):
 +<​code>​
 +irix
 +└── 6.5
 +    ├── apps
 +    │   ​└── IRIX.6.5.Applications.img
 +    ├── apps30
 +    │   ​├── Applications.image
 +    │   ​└── Complementary_Applications.image
 +    ├── foundation
 +    │   ​├── IRIX.6.5.Foundations.CD1.img
 +    │   ​└── IRIX.6.5.Foundations.CD2.img
 +    ├── nfs
 +    │   ​└── ONC3_NFSv3_6.2-6.5.img
 +    └── overlay30
 +        ├── Installation_Tools_and_Overlays1.image
 +        ├── Overlays2.image
 +        └── Overlays3.image</​code>​
 +Once the files are copied, all you need to do is open a command prompt into the same folder as the ‘Vagrantfile’ (CMD or Powershell as administrator,​ cd irixboot-master) and type: vagrant up
 +Vagrant will use the ‘Vagrantfile’ you’ve configured to download the correct Debian ISO, configure it as a VM and automount all the EFS formatted SGI IRIX CD images in loopback mode, and serve them over TFTP & BOOTP.
 +  *On your router, set the IP address you specified for your SGI in the Vagrantfile to be statically assigned by MAC, to make sure the IP remains the same.
 +  *On the SGI machine, in the command monitor, type: <​code>​printenv</​code>​ This will list the MAC address and any IP address, if set.
 +  *Also on the SGI machine, in the command monitor, type: <​code>​setenv netaddr [IP Address]
 +setenv notape 1</​code> ​
 +
 +====Beginning the installation====
 +
 +If you have a MIPSIII system (pre R5000) then you need to use sashARCS/​fx.ARCS. Otherwise, sash64/​fx.64, ​
 +
 +On the SGI, in the command monitor, type the following below in bold to launch fx, the IRIX disk partition tool, from the Vagrant VM:
 +
 +<​code>>>​bootp():​overlay30/​stand/​fx.64 -x</​code>​
 +or
 +<​code>>>​bootp():​overlay22/​stand/​fx.arcs -x</​code>​
 +This will launch the disk formatting utility. To format a disk ready for IRIX installation,​ destroying all partitions, type as shown:
 +
 +<​code>​
 +----- please choose one (? for help, .. to quit this menu)-----
 + ​[exi]t ​             [d]ebug/ ​           [l]abel/ ​           [a]uto
 + ​[b]adblock/ ​        ​[exe]rcise/ ​        ​[r]epartition/ ​     [f]ormat
 +fx> label/​show/​partition
 +
 +----- partitions-----
 +part  type       ​cyls ​          ​blocks ​       Megabytes ​  ​(base+size)
 +  0: efs        8 + 103      2528 + 32548       1 + 16
 +  1: rawdata ​ 111 + 259     35076 + 81844      17 + 40
 +  6: efs      370 + 7553   ​116920 + 2386748 ​   57 + 1165
 +  8: volhdr ​    0 + 8           0 + 2528        0 + 1
 + 10: entire ​    0 + 7923        0 + 2503668 ​    0 + 1222
 +
 +----- please choose one (? for help, .. to quit this menu)-----
 + ​[exi]t ​             [d]ebug/ ​           [l]abel/ ​           [a]uto
 + ​[b]adblock/ ​        ​[exe]rcise/ ​        ​[r]epartition/ ​     [f]ormat
 +fx> exercise/​sequential
 +
 +fx/​exercise/​sequential:​ modifier = (rd-only) wr-o
 +fx/​exercise/​sequential:​ starting block# = ((0)) 0
 +fx/​exercise/​sequential:​ nblocks = ((2501140)) 2501140
 +fx/​exercise/​sequential:​ nscans = (1)
 + * * * * * W A R N I N G * * * * *
 +about to destroy data on disk dksc(0,1,)! ok? yes
 +sequential pass 1: scanning [(0), (35076))
 +........... 10.......... 20.......... 30.......... 40.......... ​
 +50.......... 60.......... 70.......... 80.......... 90.......... ​
 +100..</​code>​
 +
 +Notice the nblocks here reads 2501140? This is the entire disk, minus the size of the volume header in blocks (2528).
 +
 +This process will take HOURS. Even on a fast machine, it’s writing 4K blocks at a time of zero’s, several times over, to erase the disk. I left my Octane running overnight to do this.
 +
 +If you only want to format a single partition, in this instance, partition 0, use the following commands:
 +
 +<​code>​
 +----- please choose one (? for help, .. to quit this menu)-----
 + ​[exi]t ​             [d]ebug/ ​           [l]abel/ ​           [a]uto
 + ​[b]adblock/ ​        ​[exe]rcise/ ​        ​[r]epartition/ ​     [f]ormat
 +fx> label/​show/​partition ​
 +
 +----- partitions-----
 +part  type       ​cyls ​          ​blocks ​       Megabytes ​  ​(base+size)
 +  0: efs        8 + 103     2528 + 32548       1 + 16
 +  1: rawdata ​ 111 + 259     35076 + 81844      17 + 40
 +  6: efs      370 + 7553   ​116920 + 2386748 ​   57 + 1165
 +  8: volhdr ​    0 + 8           0 + 2528        0 + 1
 + 10: entire ​    0 + 7923        0 + 2503668 ​    0 + 1222
 +
 +----- please choose one (? for help, .. to quit this menu)-----
 + ​[exi]t ​             [d]ebug/ ​           [l]abel/ ​           [a]uto
 + ​[b]adblock/ ​        ​[exe]rcise/ ​        ​[r]epartition/ ​     [f]ormat
 +fx> exercise/​sequential
 +
 +fx/​exercise/​sequential:​ modifier = (rd-only) wr-o
 +fx/​exercise/​sequential:​ starting block# = ((0)) 2528
 +fx/​exercise/​sequential:​ nblocks = ((2501140)) 32548
 +fx/​exercise/​sequential:​ nscans = (1)
 + * * * * * W A R N I N G * * * * *
 +about to destroy data on disk dksc(0,1,)! ok? yes
 +sequential pass 1: scanning [(2528), (35076))
 +........... 10.......... 20.......... 30.......... 40.......... ​
 +50.......... 60.......... 70.......... 80.......... 90.......... ​
 +100..</​code>​
 +
 +Ta-da! The disk is now formatted and ready for installation. However, you need to partition it. At the prompt, you need to execute the instruction in bold:
 +
 +<​code>​----- please choose one (? for help, .. to quit this menu)-----
 + ​[exi]t ​             [d]ebug/ ​           [l]abel/ ​           [a]uto
 + ​[b]adblock/ ​        ​[exe]rcise/ ​        ​[r]epartition/ ​     [f]ormat
 +fx> repartition/​rootdisk</​code>​
 +
 +When asked what type of filesystem you want, type: XFS. At the next prompt, type yes. After this has finished running, quit fx by typing exit.
 +
 +You’ll be back at the System Maintenance menu. Choose the option Install System Software -> Remote Directory. Use the hostname of the machine you set in the Vagrantfile (ie, irixboot) and then overlay30/​dist for the install location. You should then see something that looks like this:
 +
 +<​code>​
 +Setting $netaddr to 172.16.10.112 (from server )
 +Copying installation program to disk.
 +Setting $netaddr to 172.16.10.112 (from server )
 +......... 10% ......... 20% ......... 30% ......... 40% ......... 50%
 +......... 60% ......... 70% ......... 80% ......... 90% ......... 100%
 +
 +Copy complete
 +Setting $netaddr to 172.16.10.112 (from server )
 +Setting $netaddr to 172.16.10.112 (from server )
 +IRIX Release 6.5 IP30 Version 05190108 System V
 +Copyright 1987-1998 Silicon Graphics, Inc.
 +All Rights Reserved.</​code>​
 +
 +There’s still more to do on the partitioning front, however. Because IRIX needs to properly setup partitions, you’ll be asked to create the filesystem properly at a screen like below. The highlighted answers in bold need to be entered.
 +
 +<​code>​
 +Mounting file systems:
 +
 +/​dev/​dsk/​dks0d1s0:​ Invalid argument
 +/​hw/​node/​io/​gio/​hpc/​scsi_ctlr/​0/​target/​1/​lun/​0/​disk/​volume/​char:​ [Alert] Illegal request: Illegal field in CDB (asc=0x24, asq=0x0), Block #40601
 +No valid file system found on: /​dev/​dsk/​dks0d1s0
 +This is your system disk: without it we have nothing
 +on which to install software.
 +Make new file system on /​dev/​dsk/​dks0d1s0 [yes/​no/​sh/​help]:​ yes
 +
 +About to remake (mkfs) file system on: /​dev/​dsk/​dks0d1s0
 +This will destroy all data on disk partition: /​dev/​dsk/​dks0d1s0.
 +
 +        Are you sure? [y/n] (n): y
 +
 +        Block size of filesystem 512 or 4096 bytes? 4096</​code>​
 +       
 +You’ll then see something like the following.
 +       
 +<​code>​
 +Doing: mkfs -b size=4096 /​dev/​dsk/​dks0d1s0
 +meta-data=/​dev/​rdsk/​dks0d1s0 ​    ​isize=256 ​   agcount=8, agsize=237520 blks
 +data     ​= ​                      ​bsize=4096 ​  ​blocks=1900160,​ imaxpct=25
 +         ​= ​                      ​sunit=0 ​     swidth=0 blks
 +log      =internal log           ​bsize=4096 ​  ​blocks=1000
 +realtime =none                   ​extsz=65536 ​ blocks=0, rtextents=0
 +unwritten flagging is enabled
 +
 +Trying again to mount /​dev/​dsk/​dks0d1s0 on /root.
 +
 +/​hw/​node/​io/​gio/​hpc/​scsi_ctlr/​0/​target/​1/​lun/​0/​disk/​volume/​char:​ [Alert] Illegal request: Illegal field in CDB (asc=0x24, asq=0x0), Block #0
 +UX:make: INFO: `scsi' is up to date.
 +    /​dev/​miniroot ​           on  /
 +    /​dev/​dsk/​dks0d1s0 ​       on  /​root</​code>​
 +
 +Only after this lot, can you finally actually run the installer...
 +
 +The installer will begin at long last! Enter the relevant information as shown in bold. 
 +
 +<​code>​Invoking software installation.
 +
 +What is the hostname (system name) of your machine? octane
 +What is the network address of octane? 172.16.10.112
 +What is the netmask for 172.16.10.112?​
 +Press Enter for the IP class default [0xffffff00]:​ # hit enter here
 +Starting network with hostname: octane, at ip address: 172.16.10.112</​code>​
 +
 +
 +0xffffff00 equates to 255.255.255.0 - if you use a different subnet configuration,​ you can work it out for hexadecimal using this calculator: http://​tuxgraphics.org/​toolbox/​network_address_calculator_add.html
 +
 +The inst tool will run and show the following:
 +
 +<​code>​Default distribution to install from: 172.16.10.101:/​overlay30/​dist
 +
 +For help on inst commands, type "help overview"​.
 +
 +
 +Inst 4.1 Main Menu
 +
 + 1. from [source ...]            Specify location of software to be installed
 + 2. open [source ...]            Specify additional software locations
 + 3. close [source ...]           Close a software distribution location
 + 4. list [keywords] [names] ​     Display information about software subsystems
 + 5. go                           ​Perform software installation and removal now
 + 6. install [keywords] [names] ​  ​Select subsystems to be installed
 + 7. remove [keywords] [names] ​   Select subsystems to be removed
 + 8. keep [keywords] [names] ​     Do not install or remove these subsystems
 + 9. step [keywords] [names] ​     Interactive mode for install/​remove/​keep
 +10. conflicts [choice ...]       List or resolve installation conflicts
 +11. help [topic] ​                Get help in general or on a specific word
 +12. view ...                     Go to the View Commands Menu
 +13. admin ...                    Go to the Administrative Commands Menu
 +14. quit                         ​Terminate software installation
 +
 +Inst></​code>​
 +
 +You now need to tell the installer about the location of all the CD’s - it’s aware of the 1st IRIX overlay CD, as it’s booted from it, but you need to actually tell it where to find the rest of the files. Assuming you followed the same naming convention as earlier, it’s relatively straightforward.
 +
 +The command to use is open (the syntax below assumes that your server is named irixboot):
 +
 +<​code>​
 +Inst> open irixboot:​foundation/​dist
 +Reading product descriptions .. 100% Done.
 +Inst> </​code>​
 +
 +Depending on the hardware, you may be asked for the IP address of the server...again.
 +
 +Repeat this command for each directory to be read in. If it asks you to scroll through any readme text, just press the space bar to read another page.
 +
 +open irixboot:​nfs/​dist
 +
 +open irixboot:​apps/​dist
 +
 +open irixboot:​apps30/​dist
 +
 +open irixboot:​overlay30/​dist
 +
 +On the overlays directory, it will ask whether you want to install the "​Maintenance"​ (compatibility) or "​Feature"​ (features) stream. Choose "​Feature"​.
 +
 +If you have decided to install the development tools from images, add these too, before the overlay30/​dist directory. However, they are not essential to the running of the machine.
 +
 +Once all of the CD’s have been opened, execute these commands:
 +
 +<​code>​
 +Inst> keep *
 +
 +Inst> install standard
 +
 +Inst> install prereqs
 +No matches for "​prereqs"​ were found</​code>​
 +
 +This last error is fine - don’t worry about it.
 +
 +Finally, you want to let ‘er rip, right?
 +
 +<​code>​Inst>​ go </​code>​
 +
 +Ah-ah-ah, you didn’t say the magic word!
 +
 +More than likely, you’ll find a conflict, hopefully just one or two packages that rely on the development CD’s for particular data. Use the conflicts commands ‘a’ option to choose not to install the conflicting package, i.e.
 +
 +<​code>​Inst>​ conflicts 1a 2a 3a</​code>​
 +
 +Now, once you’ve done that, you should be able to run the go command again without any conflicts appearing, and then it’ll start actually copying files to the hard disk.
 +
 +Depending on the hardware, it may take anything from 25 minutes to 2 hours to install IRIX. You’ll be dropped back to the inst prompt.
 +
 +<​code>​Inst>​ quit</​code>​
 +
 +t this point, leave the machine to reboot. It will resequence the ELF files and prepare the system for first time booting.
 +
 +I know, it’s long winded, but these systems are so stupidly resilient, it wasn’t considered normal to ever need to install IRIX more than once, maybe twice, during the lifecycle of the machine.
network_install_vagrant.txt · Last modified: 2019/01/29 00:59 by raion