80 likes | 216 Vues
This document serves as an extensive resource on Linux network configuration, covering key components such as the `/etc/network/interfaces` for network card setup, routing best practices, and the use of NetworkManager. It discusses essential services like DNS using BIND, Network File System (NFS) for file sharing, and the Network Information System (NIS) for managing user data. Firewalls are addressed with a focus on netfilter and iptables for packet filtering, ensuring security between internal and external networks. Essential for network administrators and Linux enthusiasts.
E N D
Linux Networking #2 Dr. Michael L. Collard www.sdml.info/collard www.sdml.info/collard/linux collard@cs.kent.edu
Network Configuration • /etc/network/interfaces • Used by ifup, ifdown • NetworkManager replaces this # The loopback interface auto lo iface lo inet loopback # The first network card auto eth0 iface eth0 inet static address 131.123.42.38 netmask 255.255.255.224 broadcast 131.123.42.63 gateway 131.123.42.33 # dhcp iface eth1 inet dhcp
Routing • Typically use a dedicated router as a gateway • Computer as a gateway: • routed daemon – Uses RIP (Routing Information Protocol) • GNU Zebra – Uses RIP, OSPF (Open Shortest Path First), and BGP (Border Gateway Protocol)
Name Service • Translates names to IP addresses • DNS (Domain Name System) • BIND (Berkerly Internet Name Domain) name server • de facto standard open source name server • named BIND server • Clients: • dig • host
NFS (Network File System) • Distributed file system • Server – nfsd • exportfs, /etc/export – exported directories • /etc/hosts.allow, /etc/hosts.deny • nfsd • Client • mounts exported directory • mount servername:/projects /mnt/nfs/projects • Typically automounted
NIS (Network Information System) • Client-server directory service protocol for distributing system configuration data (user and host names) • Originally called: Yellow Pages (YP) • ypserv – server daemon • ypbind – client program • Integrated into system password operations
NIS+ • Sun replacement for NIS, implementation different from NIS • hierarchical • based Secure RPC (servers must authenticate clients and vice-versa) • may be replicated read-only • finer-grained permissions on data and operations • Sun recommends to switch to LDAP (Lightweight Directory Access Protocol)
Firewalls • Secure computer between an internal network and an external network • Set of rules – chains • netfilter – hooks in Linux kernel for filtering packets • iptables – set up, maintain, and list IP packet filter rules