Saturday, August 9, 2008

CHANGING HOST NAME - Linux

/etc/hosts

/etc/sysconfig/network

/etc/sysconfig/network-scripts/ifcfg-eth0 (depends on NIC name)

Then reboot.

or-

Use sysctl to change the hostname

Use:

sysctl kernel.hostname

to read the current hostname, and

sysctl kernel.hostname=NEW_HOSTNAME

to change it.

CHAGING IP ADDRESS IN LINUX.

vi /etc/sysconfig/network-scripts/ifcfg-eth0

vi /etc/sysconfig/network

And restart the interfaces...

/etc/init.d/network restart


Try /sbin/setup or /usr/sbin/setup

or edit /etc/network/interfaces

No comments: