Faking AIX oslevel's for software installation
brian_s 270002K5X3 Visits (4675)
Over the years I've come across software that during the installation checks the AIX verison/oslevel before installation. If it detects a AIX oslevel it doesn't recognize, a lot of software will flat out refuse to install. For example, if the software was intended to be run on AIX 5.3 and you are trying to install it on AIX 6.1 the installation program might detect this and refuse to install. Some software might even check for a specific technology level and refuse to install on other TL versions.
If the software installation program is a shell script, the easiest and best way to force an install is to look through the installation shell script and find where it is checking the oslevel. Then either modify or comment out the applicable parts of the shell script to allow it to install on your version of AIX. However, if the installation program is a binary program this won't be a possibility. You can use the "file" command to check if a program is a shell script or a binary executable.
Another option is to try temporarily changing the AIX oslevel command. If the installation program is calling the "oslevel" command to determine what AIX version you are on, you can fake it out by creating your own custom "oslevel" command temporarily. To do this, first rename the /usr/bin/oslevel command to something like "osl
Basically you've just created a fake, hard coded oslevel command that you can have report any OS level that the software installation is expecting. When you run oslevel now it will return whatever you hard coded in to the script. Now you do NOT want to leave your system in this state permanently - this would just be a temporary change during the software installation and then you would want to restore the original oslevel command as soon as possible.
The software might also be calling the "uname -v" and/or "uname -r" commands, and you could also create a temporary shell script to replace uname to temporarily fake out this command as well. For example, if you wanted uname to appear to return the results from an AIX 5.2 server you could use this shell script to replace the uname program:
When you run this modified uname script with the "-v" flag it would display 5, and when you run it with a "-r" flag it would display 2 (i.e. AIX 5.2). Again, this would only be a temporary change you would want to make for the software installation and then you would want to restore the original uname command.
These methods will allow you to fake out the AIX version for the vast majority of software installation programs, however some applications might use different methods to determine the oslevel such as making system calls. In these cases there might not be an easy way to fake the AIX version. If you are having a hard time determining how the installation program is determining the AIX level you could try to run the installation program with "truss" to see what system calls it is making.
Like I mentioned earlier there are a variety of situations you might be in where you need to install software on a version of AIX that the software doesn't support. However, always keep in mind that this would not be supported by the software vendor and the software might not work or have other unexpected results. Also, always remember to restore your original oslevel and/or uname commands if you hard code them to return other information.