Useful Linux Commands for Xubuntu 2nd Ethernet Card Setup

This post is a list of Xubuntu Linux commands that helped me setup a second Ethernet Card with a static IP in Xubuntu.  I used it for my Zoneminder security camera system and the blog post here has the specifics on the Xubuntu setup file and my hardware.

LINUX COMMANDS

Check what network cards are installed.
# ifconfig
ifconfig working 20160321

Check whether you have any Ethernet cards/ports configured.
# dmesg | grep eth

Check whether the built-in driver, r8169.ko(or r8169.o for linux kernel 2.4.x), is installed.  NOTE:  the r8169 was installed on my system and I did not re-install it the 2nd time I installed Zoneminder on Xubuntu 14.04.4 LTS:
# lsmod | grep r8169
or
# lsmod

Check your network settings with lshw:
# sudo lshw -c Network
lshw command

ip route show AND route -n
Got this from the Ubuntuforum post here when troubleshooting my network setup.

1
2
3
4
5
6
7
8
9
10
11
12
seccam@seccam-hp-dc7800p:~$ ip route show
default via 192.168.0.2 dev eth1 
169.254.0.0/16 dev eth1 scope link metric 1000 
192.168.0.0/24 dev eth1 proto kernel scope link src 192.168.0.113 
192.168.13.0/24 dev eth0 proto kernel scope link src 192.168.13.13 
seccam@seccam-hp-dc7800p:~$ route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 192.168.0.2 0.0.0.0 UG 0 0 0 eth1
169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 eth1
192.168.0.0 0.0.0.0 255.255.255.0 U 0 0 0 eth1
192.168.13.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
seccam@seccam-hp-dc7800p:~$ ip route show
default via 192.168.0.2 dev eth1 
169.254.0.0/16 dev eth1 scope link metric 1000 
192.168.0.0/24 dev eth1 proto kernel scope link src 192.168.0.113 
192.168.13.0/24 dev eth0 proto kernel scope link src 192.168.13.13 
seccam@seccam-hp-dc7800p:~$ route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 192.168.0.2 0.0.0.0 UG 0 0 0 eth1
169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 eth1
192.168.0.0 0.0.0.0 255.255.255.0 U 0 0 0 eth1
192.168.13.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0

Note, using ‘route -v’ also works.

NIC card drivers

This section is not a Linux command, other than a file with the driver installation directions for a RealTek r8169 ethernet card driver package.  It’s here just in case I need to look for it one day.

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code lang=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre lang="" extra="">