Networking

Checking the current settings:
ifconfig -a
The -a will make it show all interfaces (both up and down)

Bringing down an interface
ifconfig down
ie: ifconfig eth0 down
Note: You can also use ifdown

Bringing down an interface
ifconfig up
ie: ifconfig eth0 up
Note: You can also use ifup

Setting the IP, Netmask, and Gateway:
modify the /etc/sysconfig/network/ifcfg-eth[tab-complete] :
IPADDR='192.168.1.3'
NETMASK='255.255.255.0'
GATEWAY='192.168.1.1'

If your using DHCP:

modify the /etc/sysconfig/network/ifcfg-eth[tab-complete] :
BOOTPROTO='dhcp'

DHCP Client Usage:
dhcpcd -k : Sends SIGHUP signal to the dhcpcd process that is currently running. This will send a DHCP release, and destroy the dhcpcd cache.

dhcpcd -n : Sends SIGALRM signal to the dhcpcd process that is currently running which forces dhcpcd to try to renew the lease

Files: (These are usually tab delimited)
/etc/hosts: This is where you can create a lists of known hosts. This is refrenced before your DNS servers (see below)

Sample:
192.168.1.1 server.fqdn.org server

/etc/resolv.conf: The resolver is the DNS client used on most Linux and BSD systems. The first line is defines the domain(s) to use for DNS lookups when no domain is specified. The lines after defines the actual nameserver(s) to use.

Sample:
search server.fqdn.org
nameserver 192.168.1.2
nameserver 192.168.1.5

/etc/lmhosts: This is an import file if you are running SAMBA, the Windows file server package. This file lists the smb names of file servers on your network.

Sample:
192.168.1.4 windows-server

Comments

Popular posts from this blog

Webex Support with Windows 7

Upgrading to the Marlin firmware on the Anycubic Mega S

Installing TinyCore 8x Linux to the Hard Drive via Command Line