On Thu, 14 Dec 2006, Walter Faleiro wrote:
> Folks,
> I have an application that runs tied with hostid of the system. Recently
> reformatting the drive changed the hostid to 7f0100.
I.e. the IP address 127.0.0.1.
> Is there anyway I can change the hostid in 7.2? I tried a few posts
> but unlike FreeBSD and Solaris there seems to be little hope for
> me.
I think you just need to change /etc/hosts so that 'hostname' returns
a name whose first IPv4 address is 127.0.0.1.
Alternatively, just write a tiny object file to implement your
gethostid() function, returning whatever you want, and LD_PRELOAD it
when running your application.
regards,
--
Paul Jakma paul at clubi.iepaul at jakma.org Key ID: 64A2FF6A
Fortune:
An age is called Dark not because the light fails to shine, but because
people refuse to see it.
-- James Michener, "Space"
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!