1837246 Members
4761 Online
110115 Solutions
New Discussion

Re: SWAP IP AND HOSTNAME

 
SOLVED
Go to solution
Nobody's Hero
Valued Contributor

SWAP IP AND HOSTNAME

I am getting ready to swap two systems.HP5 will become HP14 and Vice versa. I copied th hosts and netconf files to a different system so I can configure the lan card. Is there an easy way to change the hostname or do I just need to configure the lan card?
UNIX IS GOOD
8 REPLIES 8
Jean-Louis Phelix
Honored Contributor
Solution

Re: SWAP IP AND HOSTNAME

hi,

You could use "set_parms hostname"

Regards,
It works for me (© Bill McNAMARA ...)
Nobody's Hero
Valued Contributor

Re: SWAP IP AND HOSTNAME

So to change the hostname to hp5, issue `set_parms hp5` ??? will a reboot be required, will this be perm.?
UNIX IS GOOD
Ken Hubnik_2
Honored Contributor

Re: SWAP IP AND HOSTNAME

set_parms hostsname

This will ask you for the new hostname
Pete Randall
Outstanding Contributor

Re: SWAP IP AND HOSTNAME

Hi Robert,

I would use set_parms for both the hostname and the ip address (set_parms hostname and set_parms ip_address). It will ask you after each if you want to reboot. Reply no the first time and yes the second. Check your network config files after the reboot just to make sure.

Pete

Pete
James R. Ferguson
Acclaimed Contributor

Re: SWAP IP AND HOSTNAME

Hi:

You can manually change the hostname by editting 'etc/rc.config/netconf' and '/etc/hosts'. Therein too, is your IPaddress for your LAN card. Your 'GATEWAY' and/or network mask may need changing too. Make all of your changes and reboot.

If you are running DNS then you may need to change (at least) '/etc/mail/sendmail.cw' too.

Another option is to run:

# /sbin/set_parms

Regards!

...JRF...

...JRF...
Ken Hubnik_2
Honored Contributor

Re: SWAP IP AND HOSTNAME

key in
setparms hostname

Then it will prompt you for the new name. Yes, it will require a reboot.
Jean-Louis Phelix
Honored Contributor

Re: SWAP IP AND HOSTNAME

hi,

No, just use set_parms hostname, it will bring a menu, but even if you don't really NEED a reboot, you can read in the man page that :

The system must be rebooted after the hostname is changed for it to take full effect.

Regards
It works for me (© Bill McNAMARA ...)
Ken Hubnik_2
Honored Contributor

Re: SWAP IP AND HOSTNAME

Sorry but I forgot the underscore

set_parms hostname