DOC PREVIEW
Linux Networking

This preview shows page 1-2-3-4-5-6 out of 19 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 19 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 19 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 19 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 19 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 19 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 19 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 19 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

Linux NetworkingIowa State UniversityOffice of Academic Information TechnologyUNIX and the Internet grew up together. In thisclass, we'll look at UNIX networking as practicedin Linux, beginning with the basics of hownetworking works. We'll show you two ways toconfigure networking, and how to debug networkproblems. Finally, we'll look briefly at wirelessnetwork setup and the future of the Internet, Ipv6.There are a number of different protocols that canbe used to communicate on a network, but UNIX(and therefore Linux) has historically preferred theTCP/IP protocol set. Linux is ecumenical, though;it can also communicate with Microsoft Windows,Novell Netware and Mac OS through theirrespective native protocols. This class, however,will concentrate on TCP/IP and leave the others foranother time.There are a number of good references to Linuxnetworking. The best I've seen is the LinuxNetwork Administrator's Guide, available fromO'Reilly. For Red Hat Linux, the first two URLsare the manuals pertinent to networking. The thirdURL is a good compendium of online tutorials onTCP/IP.Networking●Networking uses the TCP/IP protocol by default, but Linux can use other protocols to interact with other operating systems:MS Networking (samba)Novell Netware (ipx)AppleShare (netatalk)Networking References●Much more info on TCP/IP available at:Linux Network Administrator's Guide by Dawson, Bautts and Purdy (O'Reilly)http://www.redhat.com/docs/manuals/enterprise/RHEL-4-Manual/sysadmin-guide/http://www.redhat.com/docs/manuals/enterprise/RHEL-4-Manual/ref-guide/http://www.freeprogrammingresources.com/tcp.htmlLinux Networking●How Networking Works●Configuring Networking in Linux●Using redhat-config-network●Network debugging●Wireless networking●IPv6Linux Networking●How Networking Works●Configuring Networking in Linux●Using redhat-config-network●Network debugging●Wireless networking●IPv6Linux Networking Page 2Like most things in UNIX, network interfaces aretreated as files under the /dev directory.Unfortunately, you can't just cat networkdevices and expect predictable results; there arespecial commands for working with them.The first network device we'll discuss is lo, theloopback device. It is used for testing purposesand for accessing servers running on the localmachine. That's handy when you want to usesoftware that works with a Web or databaseserver, but you don't want it accessible byeveryone on the Internet.Ethernet and wireless cards are the most commonnetwork devices nowadays, and Linux treats themidentically, giving them the names /dev/eth0,/dev/eth1, etc. I'll probably lump themtogether under “Ethernet interfaces” or “networkcards”. The software for Ethernet interfaces isusually loaded into the kernel during startup withthe insmod command. Some older networkcards may not work (or give reasonableperformance) unless their modules are compiledinto the kernel.The first Ethernet card will usually be detectedwhen you install Linux, but others will have to beadded by hand. If the Red Hat installer doesn'tfind it and you're not sure what it is, try bootingup a Knoppix disk. The Knoppix hardwaredetection routines are really good.Point to Point Protocol is used for Internetconnections over serial interfaces, usuallymodems. As a general rule, making a PPPconnection involves using an application likewvdial or kdial, and the /dev/pppN devicebecomes active when the connection is actuallymade. (It's also possible to run a PPP daemon ona Linux machine to provide your own dialupaccess, but that's beyond the scope of this class.Network Interfaces●All interfaces treated as devices, found under /dev/devname●lo -- loopback deviceUsed for testing and accessing servers running on the local machine.Named “localhost” with IP 127.0.0.1Ethernet/wireless interfaces●eth0, eth1, ...Ethernet and wireless cardsMost common connections on campusDrivers are usually loaded as a module during startup (using insmod) but some older drivers may have to be compiled into the Linux kernel to work correctly. Usually detected at installation unless you add them later.PPP interfaces●ppp0, ppp1, ...Point-to-point protocol, usually telephone modemAppears when you invoke the PPP client daemon, usually by running something like wvdial or kdial, to connect to an Internet service providerLinux Networking Page 3There are lots of other interfaces, many of whichare hardly ever used unless you're trying to makea connection to an old machine that doesn't haveEthernet available (or you need to transfer theEthernet driver to in the first place). In that case,a LapLink parallel cable and a plip server (easyenough to set up) make for a relatively simpleconnection between two machines. I include this slide just so you know:• The terms I'm using;• That a MAC address has nothing to do with aMacintosh (although all modern Macs do haveMAC addresses);• I'm going to be discussing version 4 of the IPprotocols, so IP addresses are 32 bits long. I'lltouch on IPv6, which uses 128 bit addresses,at the end of the course.In the days of 10Base2 (coax) Ethernets andbridging hubs, a subnet of computers was sort oflike people in a crowded room. When a machinewanted to send information somewhere, it wastransmitted to the subnet and all the machines onthe subnet “heard” the packet go by. Nowadays,using switches instead of hubs, the traffic fromeach machine goes to the switch and the switchforwards packets only to the machines they'reintended for. It's more secure because packetsniffing becomes impossible (unless you cancompromise the switch somehow) and it makesyour computer run better because it doesn't haveto decide what to do with all those packets thatweren't intended for it.Other interfaces●tk0, tk1... Token ring interfaces●sl0, sl1... SLIP (serial, usually modem, outdated and replaced by PPP)●plip0... Parallel-Line Interface Protocol(parallel port, like LapLink)●cipebc0... Crypto IP Encapsulation (IP tunnel)●isdn0... ISDN modems●ax0, ax1... AX.25 (for amateur radio buffs)Naming of Parts●NIC: Network Interface Card, the hardware that connects the machine to the network (might be built in to motherboard, might be a PCI or ISA or PCCard addon)●MAC Address: hardware address of the NIC, assigned by the card manufacturer when the card is madeEx: 00:0a:95:a7:62:d8●IP Address: 32-bit address relating machine to its "physical" location on the network (also called IP number)IP


Linux Networking

Download Linux Networking
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Linux Networking and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Linux Networking 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?