From LedHed's Wiki
Jump to: navigation, search
 
 
(3 intermediate revisions by the same user not shown)
Line 21: Line 21:
 
== Red Hat / Fedora ==
 
== Red Hat / Fedora ==
  
== Solaris ==
+
'''GUI'''
 +
RedHat/Fedora has a nice GUI tool for configuring your NIC
 +
the package is called 'system-config-network'
 +
 
 +
'''Command Line'''
 +
To change IP, Mask, & Gateway edit /etc/sysconfig/networking/devices/ifcfg-<interface name>
 +
 
 +
Example:
 +
vi /etc/sysconfig/networking/devices/ifcfg-eth0
 +
DEVICE=eth0
 +
BOOTPROTO=none
 +
BROADCAST=10.0.0.255
 +
HWADDR=ff:41:06:da:66:b4
 +
'''IPADDR=10.0.0.1'''
 +
'''NETMASK=255.255.255.0'''
 +
NETWORK=10.0.0.0
 +
ONBOOT=yes
 +
TYPE=Ethernet
 +
USERCTL=no
 +
PEERDNS=yes
 +
'''GATEWAY=10.0.0.254'''
 +
IPV6INIT=no
 +
 
 +
== Gentoo ==
 +
 
 +
/etc/conf.d/net
  
 
== BSD ==
 
== BSD ==
 +
 +
/etc/rc.conf
 +
 +
== Solaris ==
 +
 +
/etc/hostname.interface
 +
 +
<br>
 +
<br>
 +
----
 +
----
 +
<br>
 +
== Configuring DNS Name Servers ==
 +
 +
'''All Distros'''<br>
 +
DNS name servers are stored in /etc/resolv.conf
 +
 +
Example:
 +
#DNS Name Servers
 +
nameserver 10.0.0.1
 +
nameserver 10.0.0.2
 +
 +
 +
If the DNS name servers are Windows DNS servers and you can't resolve Windows Hostnames add this line to resolv.conf:
 +
search domain.tld
 +
where domain.tld is the fully qualified domain name of your windows AD domain.
 +
  
  

Latest revision as of 15:37, 26 March 2010

Each Linux Distro handles Network Interface configuration a little differently


Debian

To change IP, Mask, & Gateway edit /etc/network/interfaces

Example:

#Primary Network Interface
iface eth0 inet static
  address     10.0.0.100
  netmask     255.255.255.0
  gateway     10.0.0.254
  network     10.0.0.0

Then run (as root/su)

/sbin/ifdown -a && /sbin/ifup -a

This restarts all interfaces


Red Hat / Fedora

GUI RedHat/Fedora has a nice GUI tool for configuring your NIC the package is called 'system-config-network'

Command Line To change IP, Mask, & Gateway edit /etc/sysconfig/networking/devices/ifcfg-<interface name>

Example: vi /etc/sysconfig/networking/devices/ifcfg-eth0

DEVICE=eth0
BOOTPROTO=none
BROADCAST=10.0.0.255
HWADDR=ff:41:06:da:66:b4
IPADDR=10.0.0.1
NETMASK=255.255.255.0
NETWORK=10.0.0.0
ONBOOT=yes
TYPE=Ethernet
USERCTL=no
PEERDNS=yes
GATEWAY=10.0.0.254
IPV6INIT=no

Gentoo

/etc/conf.d/net

BSD

/etc/rc.conf

Solaris

/etc/hostname.interface






Configuring DNS Name Servers

All Distros
DNS name servers are stored in /etc/resolv.conf

Example:

#DNS Name Servers
nameserver 10.0.0.1
nameserver 10.0.0.2


If the DNS name servers are Windows DNS servers and you can't resolve Windows Hostnames add this line to resolv.conf:

search domain.tld

where domain.tld is the fully qualified domain name of your windows AD domain.