IRIX XLV Plexing (RAID1)
[Published on , last updated on ]Modifying the XLV binaries to ignore licence checks
This article will show you how to modify the XLV binaries on IRIX to ignore licence checks, which will enable support for XLV plexing (software RAID-1, a.k.a. mirroring).
I am publishing this because IRIX is now dead and no longer supported by SGI (it was discontinued in 2013). Every commercial user of IRIX that had wanted to get a plexing licence already has one by now, so publishing this doesn't hurt SGI financially. This information is intended for hobbyists who wouldn't have had the money to purchase a licence, even if it was still possible to do so. If anyone from SGI is reading this and has any objections, send me an e-mail and I'll remove the article.
Result:
- enables support for XLV plexing without needing a licence.
Prerequisites:
- a machine running IRIX 6.5.xx,
- hexedit (or another hex editor),
- 5 minutes of your time.
NB: Tested on IRIX 6.5.30, offsets may differ on XLV binaries shipped with other versions of IRIX (or if any XLV patches have been applied).
Instructions:
- Make backup copies of
xlv_mgr
andxlv_assemble
:# cd /sbin # cp xlv_mgr xlv_mgr.original # cp xlv_assemble xlv_assemble.original
- Locate the offset of the function
check_plexing_license()
inxlv_mgr
andxlv_assemble
:# dis -F check_plexing_license xlv_mgr | head | tail -4 check_plexing_license: 0x100166f4: 3c 02 00 07 lui v0,7 0x100166f8: 27 bd fe 50 addiu sp,sp,-432 0x100166fc: 24 42 24 98 addiu v0,v0,9368
Offset in this case is 0x166f4.# dis -F check_plexing_license xlv_assemble | head | tail -4 check_plexing_license: 0x10009d98: 3c 02 00 04 lui v0,4 0x10009d9c: 27 bd fe 50 addiu sp,sp,-432 0x10009da0: 24 42 42 44 addiu v0,v0,16964
Offset in this case is 0x9d98. - Open
xlv_mgr
in hexedit:# hexedit xlv_mgr
- Go to position 0x166f4 (this is the entry point of the function
check_plexing_license()
):
return166f4
- Replace
3C 02 00 07 27 BD FE 50
with03 E0 00 08 24 02 00 01
.
This replaces the first two instructions in the function with a "return 1;
" equivalent — this causes the licence check to always succeed. - Press ctrl X to save the file and exit.
- Open
xlv_assemble
in hexedit:# hexedit xlv_assemble
- Go to position 0x9d98 (again, this is the entry point of the function
check_plexing_license()
):
return9d98
- Replace
3C 02 00 04 27 BD FE 50
with03 E0 00 08 24 02 00 01
.
Same idea as before. - Press ctrl X to save the file and exit.
- Enjoy! :)
See Creating a Plexed XLV Logical Volume for Root for instructions on how to create a mirror of your root drive using XLV.