Operating System - HP-UX
1833788 Members
2507 Online
110063 Solutions
New Discussion

Re: set hostname & node name longer then 8 char

 
SOLVED
Go to solution
Ratzie
Super Advisor

set hostname & node name longer then 8 char

I am installing hp11.11 and set the host name on install to abcdefghij (10 char) but, it complained on install, and when I do a uname it shows up as:
HP-UX unknown B.11.11

I believe this has to do with the nodename only being 8, so how can I make the system happy and still keep the longer then 8 char hostname?
3 REPLIES 3
VK2COT
Honored Contributor
Solution

Re: set hostname & node name longer then 8 char

Hello,

You should not do it on HP-UX 11.11
server.

Some SAM features and other things will break
(believe me, I tested it).

From memory (I do not play with 11.11
much these days), you could set longer than
8-character hostnames on the command line,
but you still have problems as described
above.

a) Set the hostname up to eight characters
and then

b) Add aliases in DNS any way you
want (even longer names).

Cheers,

VK2COT
VK2COT - Dusan Baljevic
Bill Hassell
Honored Contributor

Re: set hostname & node name longer then 8 char

There are two network names in HP-UX: nodename and hostname. Normally, they are the same. The man page for hostname explains the differences. The startup variable NODENAME is the UUCP name which is returned by uname -n, while the HOSTNAME variable sets the networking (ARPA, NFS, etc) name, which can be 64 chars long (see /usr/include/sys/param.h for MAXHOSTNAMELEN). HOSTNAME can be much longer than 8 characters BUT only if you define an 8-character or less NODENAME in the /etc/rc.config.d/netconf file, like this:

NODENAME=myhost08
HOSTNAME=myreallylonghostname

And of course for networking, the /etc/hosts file provides all the hostname aliases you might need -- assuming you put files then dns in /etc/nsswitch.conf. There is no limit to the number of different names you can give to your system, but NODENAME *MUST* be assigned 8 characters or less. There are so many items that will break if you exceed this rule that you don't ever want to do it.


Bill Hassell, sysadmin
Ratzie
Super Advisor

Re: set hostname & node name longer then 8 char

I will tread lightly.
Actually, change everything to 8 chars.

I just thought they would have updated this in 11.11