On 32-bit Solaris builds of SDK software, a bug in the Solaris system libraries prevents /etc/hosts from being read properly if more than 256 file descriptors are in use. If you set SM_HOSTSFILE=1 in the environment, then /etc/hosts is read using application code, bypassing the system libraries as a work-around to this problem.


This work-around only handles IPv4 addresses in /etc/hosts. The work-around does not work for IPv6 addresses, and will not read /etc/ipnodes (or /etc/inet/ipnodes). IPv6 addresses obtained from DNS are handled properly in all cases. If it is necessary to obtain IPv6 addresses from /etc/ipnodes, you should use the 64-bit version of the product.

SM_HOSTSFILE is only available on Solaris versions of SDK software. It operates in both 32 and 64-bit builds, but since the 64-bit system libraries work properly, it is recommended that it not be set on 64 bit builds.