Problem
User is trying to run 64bit version of Xcentrisity Business Information Server (XBiS) and was getting the following error when XBiS was started. What does the error mean?
Syntax error on line 547 of /opt/freeware/etc/httpd/conf/httpd.conf: Syntax error on line 2 of /opt/freeware/etc/httpd/conf/mod_xbis.conf: Cannot load /usr/local/liant/bis/mod_xbis/mod_xbis24.so into server: \\t0509-022 Cannot load module /usr/local/liant/bis/mod_xbis/mod_xbis24.so.\\n\\t0509-026 System error: Cannot run a file that does not have a valid format.
Resolution
The important part of the error message was:
Cannot run a file that does not have a valid format.
The above error was caused by a byte architecture mismatch between XBiS and Apache. The XBiS product was a 64bit version and the Apache product was a 32bit version. The resolution of the issue was to install and use the 64bit Apache product.
Another way to resolve this issue is to use the 32bit version of XBiS. The important point is that both Apache and XBiS must be same byte architecture.
Determining the bitism of shared objects or executable files
The following command can be used within a Linux/Unix/AIX environment to find out information about the module:
file <module name>
For Apache, the module that needs to be checked is the Apache Web Server module, httpd. The command will need to be executed from the directory where the httpd binary is located.
For a 64bit executable, if the following command is run, the output would be as follows:
file /usr/local/liant/bis/xbis/mod_xbis/mod_xbis24.so
/usr/local/liant/bis/xbis/mod_xbis/mod_xbis24.so: 64-bit XCOFF executable or object module not stripped
For a 64bit shared object, an example of the important part of the output would be as follows:
/home/products/visualcobol/lib/soap64.so: ELF 64-bit LSB shared object, x86-64, version 1 (GNU/Linux), dynamically linked,
For a 32bit executable, an example of the output would be as follows:
/opt/freeware/sbin/httpd: executable (RISC System/6000) or object module
Another possible output for a 32bit module (in this case cobol32) would be:
/home/products/visualcobol/bin/cobrun32: ELF 32-bit LSB executable, Intel 80386d
For a 32bit shared object, an example of the important part of the output would be as follows:
/home/products/visualcobol/lib/soap.so: ELF 32-bit LSB shared object, Intel 80386, version 1 (GNU/Linux), dynamically linked,
Incident: # 3179975