SA387 - Solaris - TCPIP Network Administration - Oh - 1099
SA387 - Solaris - TCPIP Network Administration - Oh - 1099
SA387 - Solaris - TCPIP Network Administration - Oh - 1099
SA-387
Copyright 1999 Sun Microsystems, Inc., 901 San Antonio Road, Palo Alto, California 94303, U.S.A. All rights reserved.
This product or document is protected by copyright and distributed under licenses restricting its use, copying, distribution, and decompilation. No part of this
product or document may be reproduced in any form by any means without prior written authorization of Sun and its licensors, if any.
Third-party software, including font technology, is copyrighted and licensed from Sun suppliers.
Parts of the product may be derived from Berkeley BSD systems, licensed from the University of California. UNIX is a registered trademark in the U.S. and other
countries, exclusively licensed through X/Open Company, Ltd.
Sun, Sun Microsystems, the Sun Logo Sun, Solaris, SunATM, Sun Quad FastEthernet, SunFastEthernet, SunFDDI, SunTRI, Solstice AdminSuite, SunNet Manager,
OpenWindows, and SunSoft are trademarks or registered trademarks of Sun Microsystems, Inc. in the U.S. and other countries.
All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC International, Inc. in the U.S. and other countries. Products
bearing SPARC trademarks are based upon an architecture developed by Sun Microsystems, Inc.
UNIX is a registered trademark in the U.S. and other countries, exclusively licensed through X/Open Company, Ltd.
The OPEN LOOK and Sun Graphical User Interface was developed by Sun Microsystems, Inc. for its users and licensees. Sun acknowledges the pioneering efforts
of Xerox in researching and developing the concept of visual or graphical user interfaces for the computer industry. Sun holds a non-exclusive license from Xerox
to the Xerox Graphical User Interface, which license also covers Sun’s licensees who implement OPEN LOOK GUIs and otherwise comply with Sun’s written
license agreements.
U.S. Government approval required when exporting the product.
RESTRICTED RIGHTS: Use, duplication, or disclosure by the U.S. Govt is subject to restrictions of FAR 52.227-14(g) (2)(6/87) and FAR 52.227-19(6/87), or DFAR
252.227-7015 (b)(6/95) and DFAR 227.7202-3(a).
DOCUMENTATION IS PROVIDED "AS IS" AND ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS, AND WARRANTIES, INCLUDING ANY
IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT, ARE DISCLAIMED, EXCEPT TO THE
EXTENT THAT SUCH DISCLAIMERS ARE HELD TO BE LEGALLAY INVALID.
About ThisCourse
Course Goal
The Solaris Operating Environment – TCP/IP Network
Administration course teaches you the advanced
administration skills required to plan, create, administer, and
troubleshoot a local area network (LAN).
Course Overview
• Hands-on experience with:
• Network configuration
• Network planning
• Network troubleshooting
• Topics include:
• Domain Name Service (DNS)
• Sendmail
• DHCP
Network
Models
Subnetting
Internet Routing
Layer
Client/Server
Transport Client-Server
Layer Model
Applications
Introduction Domain
to Network Name
DHCP Management System
Tools
LAN Network
Planning Trouble-
shooting
Module Overview
• Module 1 – "Network Models"
• Module 2 – "Introduction to Local Area Networks"
• Module 3 – "Ethernet Interface"
• Module 4 – "ARP and RARP"
• Module 5 – "Internet Layer"
• Module 6 – "Routing"
Module Overview
• Module 7 – "Transport Layer"
• Module 8 – "Client-Server Model"
• Module 9 – "DHCP"
• Module 10 – "Introduction to Network Management
Tools"
• Module 11 – "Domain Name System"
• Module 12 – "Email Fundamentals"
Module Overview
• Module 13 – "Introduction to sendmail"
• Module 14 – "Common Mail Tasks"
• Module 15 – "LAN Planning"
• Module 16 – "Networking Troubleshooting"
Module Pacing
Module Day 1 Day 2 Day 3 Day 4 Day 5
"Network Models" A.M.
"Routing" P.M.
"DHCP" P.M.
• NIS+
• Solaris OS tuning
Introductions
• Name
• Company affiliation
• Title, function, and job responsibility
• Networking experience
• Reasons for enrolling in this course
• Course expectations
Module 1
Network Models
Overview
• Objectives
• Relevance
Network Models
• ISO/OSI reference model
• Presentation layer
• Session layer
• Transport layer
• Network layer
• Physical layer
Message
Process A Process B
Layer 7: Layer 7:
Physical Layer
• Regulates the transmission of data bits
Network Layer
• Performs routing
• Supports the following protocol:
• CLNS/CONS (OSI)
Transport Layer
• Handles the transport of messages
• Supports following protocol:
Session Layer
• Controls the exchange of messages
• Synchronizes packets
• Re-establishes interrupted connections
Presentation Layer
• Stipulates transfer syntax
• Represents data based on architecture
• Supports XDR
Application Layer
• Represents the application process
• Supports following common protocols:
TCP/IP
• Is a set of protocols
• Allows cooperating computers to share network
resources
• Supports wide range of platforms and networks
TCP/IP Layers
• Application layer
• Transport layer
• Internet layer
• Hardware layer
Hardware Layers
Presentation
Session
Application Transport
Network
Transport Data Link
Internet Physical
Network Interface
Hardware
Presentation
Session
Application Transport
Network
Transport Data Link
Internet Physical
Network Interface
Hardware
Internet Layer
Presentation
Session
Application Transport
Network
Transport Data Link
Internet Physical
Network Interface
Hardware
Transport Layer
Presentation
Session
Application Transport
Network
Transport Data Link
Internet Physical
Network Interface
Hardware
Application Layer
Presentation
Session
Application Transport
Network
Transport Data Link
Internet Physical
Network interface
Hardware
Peer-to-Peer Communication
End system End system
Application Application
AH User data AH User data
Message
Network Network
NH I-PDU NT Frame NH I-PDU NT
Interface Interface
Module 2
Overview
• Objectives
• Relevance
• LAN architecture
• Hardware
• Software
LAN Topology
• Bus
• Star
• Ring
Bus Configuration
Star Configuration
Hub
Ring Configuration
LAN Components
• Backbone
• Segment
• Repeater
• Hub
• Bridge
• Switch
• Router
• Gateway
• Concentrator
Ethernet Components
• Ethernet controller
• Transceiver
• Transceiver cable
• Ethernet
• Fast Ethernet
• FDDI
• Token Ring
• Gigabit Ethernet
LAN Methodologies
• Ethernet – IEEE 802.3
Network Media
• 10BASE-5
• 10BASE-2
• 10BASE-T
• 100BASE-TX
• 100BASE-T4
• 100BASE-FX
Multimode Ethernet
100BaseT4
100BaseT
Token Ring
Category 3 Category 5
1-Gbits/sec Ethernet
Concentrator Fiber
Fiber
PC
ATM-622 Category 3
Fiber Category 5
10BaseT 100BaseT
Lab Configuration
zoo subnet veggie subnet fish subnet
128.50.1.0 128.50.2.0 128.50.3.0
lion-r swordfish-r3
128.50.2.250 128.50.3.250
lion onion-r2
128.50.1.250 128.50.2.251
Module 3
Ethernet Interface
Overview
• Objectives
• Relevance
Introduction to Ethernet
• Is the most widely installed local area network
technology
Application layer
Transport layer
Internet layer
Hardware layer
• Switched Ethernet
• Ethernet packet
Access Method
CSMA/CD:
• Resolves conflicts due to multiple machines
simultaneously accessing common medium
• Senses collisions
CSMA/CD Flowchart
Host has
message
Multiple access
Carrier sense
Traffic on
network? Yes
No
Send message
Collision detect
Was there
a collision? No
Yes Success
Switched Ethernet
• Reduces the number of collisions on a network
• Has central hub replace backbone medium
Hub
10BASE-T Hub
10BASE-T
Ethernet Switch
Hub
10BASE-T
100BASE-T
10BASE-T Hub
10BASE-T
Hub
Ethernet Address
• Is host’s unique network interface address
• Is administered by IEEE and assigned in manufacturing
• Is 48 bits long
• Displays as 12 hexadecimal digits using colon notation
• Has first three octets as vendor-specific identifier
• Has last three octets as network interface-specific
identifier
Example:
08:00:20:1e:56:7d
Sending Messages
• Three types of Ethernet addresses
• Unicast address
• Broadcast address
• Multicast address
Ethernet Frame
• Preamble
• Destination address
• Source address
• Type
• Data
• Cyclical redundancy check (CRC)
Octet location: 1–6 7–12 13–14 15–1514 (the maximum) Last 4 octets
Application data
Transport
Application data
header
Transport segment
Internet Transport
Application data
header header
Internet datagram
Internet layer
Fragments
Hardware layer
• Jabbers
• Bad CRC
• netstat
• ifconfig
snoop
# snoop broadcast
Using device /dev/le (promiscuous mode)
skunk --> 128.50.255.255 RUSERS C
zebra --> 128.50.255.255 RUSERS C
mil02lab -> (broadcast) RIP R (25 destinations)
mil02lab -> (broadcast) RIP R (25 destinations)
mil02lab -> (broadcast) RIP R (25 destinations)
snoop -v
# snoop -v broadcast
Using device /dev/hme (promiscuous mode)
ETHER: ----- Ether Header -----
ETHER:
ETHER: Packet 1 arrived at 15:28:16.62
ETHER: Packet size = 60 bytes
ETHER: Destination = ff:ff:ff:ff:ff:ff, (broadcast)
ETHER: Source = 8:0:20:e:d:56, Sun
ETHER: Ethertype = 0806 (ARP)
ETHER:
ARP: ----- ARP/RARP Frame -----
ARP:
ARP: Hardware type = 1
ARP: Protocol type = 0800 (IP)
.
snoop -V
# snoop -V cherries
Using device /dev/hme (promiscuous mode)
________________________________
wrapper -> cherries ETHER Type=0800 (IP), size = 98 bytes
wrapper -> cherries IP D=129.150.165.123 S=129.150.165.114 LEN=84, ID=7780
wrapper -> cherries ICMP Echo request
________________________________
cherries -> wrapper ETHER Type=0800 (IP), size = 98 bytes
cherries -> wrapper IP D=129.150.165.114 S=129.150.165.123 LEN=84, ID=5905
cherries -> wrapper ICMP Echo reply
netstat -i
# netstat -i
Name Mtu Net/Dest Address Ipkts Ierrs Opkts Oerrs Coll Queue
lo0 8232 loopback localhost 5248 0 5248 0 0 0
le0 1500 128.50.0.0 mule 77553 4 39221 2 2103 0
ifconfig
# ifconfig hme
hme0: flags=863<UP,BROADCAST,NOTRAILERS,RUNNING,MULTICAST>
mtu 1500 inet 129.150.65.124 netmask ffffff00
broadcast 129.150.65.255 ether 8:0:20:80:d0:a7
Module 4
Overview
• Objectives
• Relevance
Application layer
Transport layer
Internet layer
Hardware layer
ARP
Destination IP address
• ARP table
• ARP request
• ARP reply
ARP Request
# snoop -v arp
ETHER:
ETHER:
ARP Request
ARP: ----- ARP/RARP Frame -----
ARP Reply
# snoop -v arp
ETHER: ----- Ether Header -----
ETHER:
ETHER: Packet 2 arrived at 16:15:29.64
ETHER: Packet size = 60 bytes
ETHER: Destination = 8:0:20:75:6e:6f, Sun
ETHER: Source = 8:0:20:75:8b:59, Sun
ETHER: Ethertype = 0806 (ARP)
ETHER:
ARP Reply
ARP: Hardware type = 1
ARP: Protocol type = 0800 (IP)
ARP: Length of hardware address = 6 bytes
ARP: Length of protocol address = 4 bytes
ARP: Opcode 2 (ARP Reply)
ARP: Sender's hardware address = 8:0:20:75:8b:59
ARP: Sender's protocol address = 128.50.1.3, rhino
ARP: Target hardware address = 8:0:20:75:6e:6f
ARP: Target protocol address = 128.50.1.2, mule
• arp -d hostname
• arp -f filename
• Diskless systems
• JumpStart™ systems
RARP Request
# snoop -v rarp
Using device /dev/le (promiscuous mode)
ETHER: ----- Ether Header -----
ETHER:
ETHER: Packet 1 arrived at 16:29:55.70
ETHER: Packet size = 64 bytes
ETHER: Destination = ff:ff:ff:ff:ff:ff, (broadcast)
ETHER: Source = 8:0:20:75:8b:59, Sun
ETHER: Ethertype = 8035 (RARP)
RARP Request
ARP: ----- ARP/RARP Frame -----
RARP Reply
# snoop -v rarp
ETHER:
RARP Reply
ARP: ----- ARP/RARP Frame -----
• /etc/inet/hosts file
• /etc/ethers file
Module 5
Internet Layer
Overview
• Objectives
• Relevance
Introduction to Internet
• The early days
• Berkeley Software Distribution
• Rapid growth
• The future
Application layer
Transport layer
Internet layer
Hardware layer
Internet Layer
• Internet Protocol
• Datagrams
• Internet Control Message Protocol
• Fragmentation
10
110
1 11 0
IPv4 Netmasks
• Explicitly identifies network number
• Class A – 255.0.0.0
• Class B –- 255.255.0.0
• Class C – 255.255.255.0
Reasons to Subnet
• Isolation of traffic
• Security
• Localization of protocols
• Administration
Defining Subnets
• Address hierarchy
Two-level hierarchy
Network number Host number
Three-level hierarchy
Network number Subnet number Host number
Subnet Mask
• Defines the extended-network-number
Network Host
number number
197 8 43 211
IPv4 class C address 11000101 00001000 00101011 11010011
12.3.1.0
12.3.2.0
12.1.0.0
12.3.3.0
12.2.0.0 .
12.3.0.0 .
. .
12.0.0.0 .
. 12.3.252.0 12.3.254.32
12.252.0.0 12.3.253.0 12.3.254.64
.
12.253.0.0 12.3.254.0 .
.
12.254.0.0
12.3.254.160
12.3.254.192
128.50.0.0 255.255.255.0
197.8.43.0 255.255.255.240
Configuring a Subnet
• Router setup
• Host setup
/sbin/init
2. The /sbin/init process reads the /etc/inittab configuration file,
which runs, among other scripts, the /sbin/rcS script.
/sbin/rcS
/etc/rcS.d/S30rootusr.sh
/sbin/ifconfig Command
• Configures network interfaces
# ifconfig le0
le0: flags=863<UP,BROADCAST,NOTRAILERS,RUNNING,MULTICAST> mtu 1500
inet 128.50.1.2 netmask ffff0000 broadcast 128.50.255.255
ether 8:0:20:75:6e:6f
Module 6
Routing
Overview
• Objectives
• Relevance
Introduction to Routing
• Mechanism used to forward packets from one network
to another
Application layer
Transport layer
Internet layer
Hardware layer
Routing Schemes
• Table-driven routing
• Static routing
• Dynamic routing
• Default routing
Routing Algorithm
• Check LAN for destination hosts
Does the
No network number
Yes
match a local interface
network number?
Is
Yes there a
default entry Yes
in the routing table?
Encapsulate the packet
setting the destination
Ethernet address to that Encapsulate the packet
of the router associated setting the destination
with the routing table Ethernet address to that
entry and deliver the of the default router found
No
in the routing table
packet through the inter-
and deliver the packet
face connected to the Generate a routing error through the interface
router message through ICMP
connected to the router
Gateway Protocols
• Exterior Gateway Protocols
AS
EGP
EGP
EGP
AS
AS
BGP
AS
BGP BGP
AS
AS
IGP
AS
IGP
AS
IGP
AS
• Multiple paths
Router
Source Destination
host host
Router Router
Metric = 2 (discarded)
Stability Features
• Hop-count limit
• Hold-down state
• Split horizons
/usr/sbin/in.routed
• Start in.routed process in quiet mode
# /usr/sbin/in.routed -q
# /usr/sbin/in.routed -s
# /usr/sbin/in.routed -v /var/adm/routelog
/usr/sbin/in.rdisc
• Non-router host
# /usr/sbin/in.rdisc -s
• Router host
# /usr/sbin/in.rdisc -r
Multihomed Host
• A host with more than two network interfaces that does
not run routing protocols or forward IP packets
• NFS servers
• Database servers
• Firewall gateways
Routing Initialization
No
DHCP client
Yes or
/etc/notrouter
Do not act as a
router
No
Start /usr/sbin/in.routed -s (RIP)
> 2 inet entries or Yes
point-to-point or Start /usr/sbin/in.rdisc -r (RDISC)
/etc/gateways
Turn on ip_forwarding in device /dev/ip
No
Turn off ip_forwarding in device /dev/ip
Response from
Yes
in.rdisc -s Start /usr/sbin/in.rdisc -s
solicitation ?
No
Start in.routed -q
Routing Table:
Destination Gateway Flags Ref Use Interface
----------- ------- ----- --- ---- ---------
localhost localhost UH 0 2272 lo0
128.50.1.0 bear U 3 562 le0
128.50.2.0 potato-r UG 10 1562 le0
128.50.3.0 skunk UG 3 562 le0
224.0.0.0 bear U 3 0 le0
/etc/inet/networks File
A Sample File
fish 128.50.3.0 The_School fish-net
veggie 128.50.2.0 The_Vegetables veggie-net
zoo 128.50.1.0 The_Animals zoo-net
# netstat -r
Routing Table:
Destination Gateway Flags Ref Use Interface
----------- ------- ----- ---- ---- ----------
localhost localhost UH 0 2272 lo0
zoo bear U 3 562 le0
veggie potato-r UG 10 1562
fish skunk UG 3 562 le0
224.0.0.0 bear U 3 0 le0
/etc/gateways File
• Is used by in.routed to build its routing table
Router Configuration
• Create a /etc/hostname.interface file
lion-r1 lion-r2
128.50.1.250 128.50.2.250
lion
(router)
mule tomato
128.50.1.2 128.50.2.2
horse pea
128.50.1.1 128.50.2.1
Module 7
Transport Layer
Overview
• Objectives
• Relevance
• Data segmenting
Application layer
Transport layer
Internet layer
Hardware layer
Types of Protocols
• Connectionless
• Is very fast
• Connection oriented
• Is highly reliable
Reliable Protocols
• Requires transmission acknowledgment
Sender Receiver
Send packet 1
Receive packet 1
Receive
Acknowledgment. 1
Send packet 2 Receive packet 2
Receive
Acknowledgment. 2
Send packet 3 Packet lost
Timeout
Resend packet 3
Receive packet 3
Unreliable Protocols
• No transmission acknowledgment
Sender Receiver
Send packet 1
Send packet 2
Send packet 3
Packet lost
Send packet 4
Transport Protocols
• Transport Control Protocol (TCP)
TCP
Certified
UDP
• Non-acknowledged
• Datagrams
• Buffered transfer
• Congestion window
Module 8
Client-Server Model
Overview
• Objectives
• Relevance
Application Layer
Application layer
Transport layer
Internet layer
Hardware layer
ONC+ Technologies
• Is Sun™’s open systems distributed computing
environment
RPC
application
programs
TI-RPC XDR
TLI Sockets
ONC+ Technologies
• XDR
• TLI
• Sockets
• XDR
• NFSTM
• NIS+
Port Numbers
• Address space
• Arbitrary port
• Well-known port
• Unique port number
• /etc/inet/services
• Reserved ports
/etc/inet/servicesExtract
ftp-data 20/tcp
ftp 21/tcp
telnet 23/tcp
smtp 25/tcp mail
sunrpc 111/udp rpcbind
sunrpc 111/tcp rpcbind
/etc/inet/inetd.conf File
100232/10 tli rpc/udp wait root /usr/sbin/sadmind \
sadmind rusersd/2-3 tli rpc/datagram_v,circuit_v wait root \
/usr/lib/netsvc/rusers/rpc.rusersd rpc.rusersd
Status Commands
• /usr/bin/rpcinfo
• /usr/bin/netstat -a
/usr/bin/rpcinfo -p
# rpcinfo -p [hostname]
/usr/bin/rpcinfo -b
# rpcinfo -b mountd 1
192.9.200.10.199 servera
192.9.200.13.187 serverb
/usr/bin/rpcinfo -u
# rpcinfo -u servera mountd
/usr/bin/netstat -a
# /usr/bin/netstat -a
UDP
Local Address State
-------------- ------
*.route Idle
*.* Unbound
*.sunrpc Idle
*.nfsd Idle
TCP Remote
Local Address Address Swind Send-Q Rwind Recv-Q State
-------------- ------- ----- ------ ----- ------ -----
*.* *.* 0 0 8576 0 Idle
*.ftp *.* 0 0 8576 0 LISTEN
*.telnet *.* 0 0 8576 0 LISTEN
*.login *.* 0 0 8576 0 LISTEN
*.sunrpc *.* 0 0 8576 0 LISTEN
chesapeake.login yogi.1023 16384 0 16384 0 ESTABLISHED
Module 9
DHCP
Overview
• Objectives
• Relevance
DHCP Features
• Automatic management of IP addresses
• Support for BOOTP clients
• Programmable lease times
• Dynamic IP addresses used to selected Ethernet
hardware addresses
• Dynamically allocated pool or pools of IP addresses on
the same network
• Two or more dynamic IP address pools on separate IP
networks (or subnets)
DHCP Client/Server
The DHCP protocol has two functions with regard to the
client:
Server Side
• DHCP server manages the IP address space of networks
directly connected to that server.
Server Databases
• dhcp_network – Client identifier to an IP address and
the associated configuration parameters of that address
• dhcptab – Information related to client configuration
dhcp_network Examples
Client_ID Flags Client_IP Server_IP Lease Macro
Symbol Characteristics
Context|Code|Type|Granularity|Maximum
Macro Definitions
• Client Class
• Network
• IP Address
• Client Identifier
• LeaseTim
• LeaseNeg
• 0 (Dynamic)
• 1 (Permanent)
• 2 (Manual)
• 4 (Unusable)
dhcptab Examples
Name Type Value
Troubleshooting DHCP
• snoop command
• DHCP client debug mode
• DHCP server debug mode
• Reboot
• DHCP server daemon
lion lion-r
128.50.1.250 128.50.2.250
DHCP client DHCP client
(Router)
mule tomato
128.50.1.2 128.50.2.2
horse pea
128.50.1.1 128.50.2.1
DHCP client
DHCP server
Module 10
Introduction to Network
Management Tools
Overview
• Objectives
• Relevance
Network Management
• ISO defined
• Configuration management
• Fault management
• Performance management
• Accounting management
• Security management
• Management system, network management
application, and device to manage
Simple Network
Management Protocol
• IP based, uses UDP
• SNMP functions
• Get
• Set
• Trap
• SNMP structure
• Structure of management information (SMI)
• Object identifier (OID)
org (3)
dod (6)
internet (1)
sun (42)
system (1) interfaces (2) at (3) ip (4) ...
sunMib (3)
sysContact (4)
sunSystem (1)
hostID (2)
Simple Network
Management Protocol
• Management Information Base (MIB)
• ASN.1
SNMP-based Management
Applications
• Solstice Site Manager™
• Solstice Domain Manager™
• Solstice Enterprise Manager™
• Solstice Enterprise Agents™
Module 11
Overview
• Objectives
• Relevance
• Second-level domains
• Lower-level domains
Zones of Authority
• Is the portion of the name space for which a server is
authoritative
• Consists of domains and all associated data
• Can be one or more domains
Controlling authority
NIC Nameless root
horse fish
50
1
sa380.edu. domain
Pointer 1
Zone
DNS Servers
• Root servers
• Primary (master) servers
• Secondary (slave) servers
• Caching-only servers
• Forwarding servers
DNS Answers
• Authoritative
• Are from primary or secondary authoritative servers
• May not be correct
• Are “as good as it gets”
• Are typically correct
• Non-authoritative
• Are from cache of non-authoritative server
• Are typically correct
• May be incorrect
Client Resolver
• Simplified interfaces to the local DNS server
• Queries to local DNS server
• /etc/resolv.conf
• Local DNS server replies
Resolution Process
2
Client /etc/inet/hosts
(resolver) file
3
1 NIS+ hosts
database
4 /etc/nsswitch.conf file
hosts: files nisplus dns 13
/etc/resolv.conf file 5
search corp.sun.com eng.sun.com sun.com
nameserver 128.50.1.101
Local
nameserver
12 6
10 8
11 9 7
internic. Cache
net. root
net. nameserver nameserver
nameserver
BIND
• Most frequently used DNS implementation
• Available at http://www.isc.org/bind.html
• Solaris 7 implements BIND Version 8.1.2
• Latest BIND version may not be supported
options { /var/named
DIRECTORY “/var/named”;
}; named.root
zone “.” in {
type hint;
file “named.root”;
}; domain-info
zone “zoo.edu” in {
type master;
file “domain-info”;
}; inverse-domain-info
zone “1.50.128.in-addr.arpa” in {
type master;
file “inverse-domain-info”;
}; loopback-domain-info
zone “0.0.127.in-addr.arpa” in {
type master;
file “loopback-domain-info”;
};
/var/named/named.root File
• Specifies name-to-address mappings root servers
• Provides “hints” as to the identity of root servers
• Uses hints to determine actual root servers
• Reuses hints when cache information times out
• Is available at
ftp://ftp.rs.internic.net/domain/named.root
. 3600000 IN NS A.ROOT-SERVERS.NET.
; formerly NS1.ISI.EDU
.3600000 IN NS B.ROOT-SERVERS.NET.
; End of File
domain-info File
; Information for the "forward" domain zoo.edu.
; The SOA record must be present and must be first.
@ IN SOA horse.zoo.edu.
hostmaster.zoo.edu. (
1 ; Serial number
43200 ; Refresh timer - 12 hours
3600 ; Retry timer - 1 hour
604800 ; Expire timer - 1 week
86400 ; Minimum timer - 1 day
)
; Define name servers for this domain.
IN NS horse.zoo.edu ; primary
IN NS pea.veggie.edu ; secondary
IN NS tuna.fish.edu ; secondary
domain-info File
pea.veggie.edu. IN A 128.50.2.1
tuna.fish.edu. IN A 128.50.3.1
; Define name to address mappings for this domain.
lion IN A 128.50.1.250
lion-r1 IN A 128.50.1.250
lion-r2 IN A 128.50.2.250
rino IN A 128.50.1.3
mule IN A 128.50.1.2
horse IN A 128.50.1.1
; CNAME aliases.
www IN CNAME two
; Loopback domain definition (required).
localhost IN A 127.0.0.1
inverse-domain-info File
; Information for the "inverse" domain 1.50.128.in-addr.arpa.
@ IN SOA horse.zoo.edu.
hostmaster.zoo.edu. (
1 ; Serial number
43200 ; Refresh timer - 12 hours
3600 ; Retry timer - 1 hour
604800 ; Expire timer - 1 week
86400 ; Minimum timer - 1 day
)
; Define name servers for this domain.
IN NS horse.zoo.edu. ; primary
IN NS pea.veggie.edu. ; secondary
IN NS tuna.fish.edu. ; secondary
inverse-domain-info File
; Define address to name mappings for this domain.
loopback-domain-info File
; Information for the loopback domain 127.in-addr.arpa.
@ IN SOA horse.zoo.edu.
hostmaster.zoo.edu. (
1 ; Serial number
43200 ; Refresh timer - 12 hours
3600 ; Retry timer - 1 hour
604800 ; Expire timer - 1 week
86400 ; Minimum timer - 1 day
)
; Define name servers for this domain.
IN NS horse.zoo.edu.
; Define appropriate mappings for this domain.
1.0.0 IN PTR localhost.zoo.edu.
/etc/nsswitch.conf
• Name resolution method and ordering
• Example
hosts: files nisplus dns
/etc/resolv.conf
• Search list when names are not FQDN
• Example
; resolv.conf file for DNS clients of the zoo.edu.domain.
search zoo.edu edu
nameserver 128.50.1.1 ; Primary Master Server for zoo
nameserver 128.50.1.250 ; Root server (not usually a good idea!)
nslookup
• Send queries to and display replies from any resource
record types
nslookup Examples
horse# nslookup
Default Server: horse.zoo.edu
Address: 128.50.1.1
> lion.zoo.edu.
Server: horse.zoo.edu
Address: 128.50.1.1
Name: lion.zoo.edu
Address: 128.50.1.250
> set type=ns
> zoo.edu.
...
zoo.edu. nameserver = horse.zoo.edu
horse.zoo.edu internet address = 128.50.1.1
> set type=ptr
> 128.50.1.1
...
1.1.50.128.in-addr.arpa name = horse.zoo.edu
DNS Security
• Using BIND configuration file
• Restricting queries
• Restricting all queries
• Restricting queries in a particular zone
• Preventing unauthorized zone transfers
• Authorizing zone transfer
• Authorizing global zone transfer
• $ORIGIN domain.name.
• h2n
• DIG
DNS Resources
• info.bind newsgroup
• www.internic.net.
• RFCs
lion onion
Root server Root server
Module 12
Email Fundamentals
Overview
• Objectives
• Relevance
• Has a history
• Routing
• Mail host
• Relay host
• Gateway
• Mail server
• Mail client
UA
mailtool Relay host A
MTA
Sendmail
mail host A
Mailer
UA
mailtool
Relay host B
Network B
Elements of an Address
• Recipient
• Delimiter
• Destination address
Alias Resolution
$HOME/.mailrc aliases
mailtool
/usr/bin/mailx
/usr/lib/sendmail
Resolve to
local mailer
Other mail transports Local /etc/mail/aliases
$HOME/.forward file
• Files
• $HOME/.mailrc file
• /etc/mail/aliases file
• Network Information Services Plus (NIS+) aliases
• Network Information Services (NIS) aliases map
• .forward file
.forward Examples
\bob
/export/home/bob/mail.backup
Postmaster: root
• Alias files
• Mailbox
• Postmaster alias
/var/mail
• On-line access
• Disconnected access
Module 13
Introduction to sendmail
Overview
• Objectives
• Relevance
sendmail Overview
• History of sendmail
• Definition and features of sendmail
• Security issues with sendmail
• Functions of sendmail processing
• Changes to sendmail under the Solaris 7 OS
• Directory structure for sendmail
• Configuration files for sendmail
• The stopping and starting of sendmail
History of sendmail
• Orginally written by Eric Allman at University of
California, Berkley
• V8.7 and later written in conjunction with Internet Task
Force (IETF)
• sendmail version 8.9.1 is distributed with Solaris 7
Definition of sendmail
• It collects a message from a program, like mailx or
dtmail.
• It edits the header of the message as required by the
destination mailer.
• It calls the appropriate mailers to deliver or queue
messages for network transmission.
• When mailing to a file, sendmail delivers directly.
Features of sendmail
• It supports UNIX System V mail, UNIX Version 7 mail,
and Internet mail.
• It uses existing software for delivery whenever possible.
• It can be configured to handle complex environments
using configuration files.
• Groups can maintain their own mailing lists.
• Individual forwarding can be specified without
modifying the domain-wide alias file.
• Each user can specify a custom mailer to process
incoming mail.
sendmail Processing
• Argument processing and address parsing
• Scanning of the arguments
• Processing of the option specifications
• Message collection
• Envelope, message header, and message body
• Message delivery
• Queue for retransmission
• Return to sender
m4 Preprocessor
• Translates the simplified sendmail configuration
language to the terse native configuration used in the
file sendmail.cf
• Directories under /usr/lib/mail contain m4 macros,
such as:
• VERSIONID(mail-v7sun.mc)
• OSTYPE(solaris2.ml)
• DOMAIN(solaris-generic)
• MAILER([local,smtp])
• FEATURE (relay_entire_domain)
Module 14
Overview
• Objectives
• Relevance
Overview of Mail
• Debugging sendmail with mconnect
• Using simple Mail Transfer Protocol (SMTP)
• Testing the mail configuration
• Verifying a user
• Expanding an alias or list
• Setting up the postmaster alias
• Administering the mail configuration
• Defining SPAM
• Detecting masquerading hosts
• Use mailx -v
• mconnect
• telnet
Verifying a User
• The VRFY command can be used to verify that the server
knows about the user.
• It used by network managers instead of SMTP clients.
• The VRFY command can be considered a security risk by
some organizations.
SPAM
• Defining
• Forging a mail header
• Deciphering email headers
• Using trace tools
• Disabling SPAM
• Stopping SPAM with sendmail
Host Masquerading
• Hide hostnames
• MASQUERADE_AS(host.domain)
• MASQUERADE_DOMAIN(otherhost.domain)
• FEATURE(masquerade_envelope)
• EXPOSED_USER(usernames)
• Enable host masquerading
Module 15
LAN Planning
Overview
• Objectives
• Relevance
Planning Considerations
• Relationship of the LAN to the organization’s goals
• Generic function
• Industry standards
• Design specifications
• Mission-critical requirements
• Network loads
• Shared resources
• Future growth
• Network media
• Suppliers
• Policy
• Management team
• Performance
• Flexibility
• Reliability
• Security
10BASET Twisted-pair may already be present in an office building and may be the
least expensive way to provide a 10BASET network. Data-grade twisted-
pair should be used for all new structures.
10BASE2 Thin Ethernet is easier to handle than 10BASE2. It has less distance
capabilities than 10BASE2 and 10BASET and may not be appropriate
for LANs spanning many rooms.
10BASET Twisted-pair is easy to install and allows for flexibility in network design
since it is much easier to route around ceilings and into offices than
10BASE5 or 10BASE2.
Category 5 Like 10BASET, Category 5 twisted-pair is easy to install and allows for
(100BASET) flexibility in network design since it is much easier to route around ceil-
ings and into offices than 10BASE5 or 10BASE2.
Reliability
Cable Type Ease of Troubleshooting
10BASE5 Thick Ethernet is difficult to troubleshoot.
10BASET Some manufacturers offer intelligent 10BASET hubs that support the
Simple Network Management Protocol (SNMP). These devices offer
powerful network management capabilities, such as the ability to
remotely shut down a port of an offending host.
Category 5 Category 5 initially requires much more testing during the installation
(100BASET) phase. Once the media has passed testing, it is considered very reliable.
Intelligent Category 5 hubs that support the Simple Network Manage-
ment Protocol (SNMP) are standard.
LAN Topology
• Network mapping
• Hierarchy
• Network segmentation
• Performance
• Security
• Management
• Flexibility
Gateway
Backbone: 129.145.6.0
Backbone: 129.145.6.0
Backbone: 129.145.5.0
Larger server
Gateway
Large server/router
Blueprinting a LAN
• Is similar to LAN topology but it is more detailed
Module 16
Network Troubleshooting
Overview
• Objectives
• Relevance
Troubleshooting
• General troubleshooting guidelines
• Define problem in your own words
• Locate lowest level of failure
• Take nothing for granted
• Back up, document, and test
• Make permanent changes
Troubleshooting Tools
• ping
• Use ICMP echo
• Use ping -s
• Broadcast ping (255)
Troubleshooting Tools
• ifconfig
• Display status of interface
• Use two versions
• Use plumb
Troubleshooting Tools
• arp
• Trace duplicate IP addresses
• Determine manufacturer of Ethernet card
• Check arp table
Troubleshooting Tools
• snoop
• Use for remote troubleshooting
• Write to file
• Use three modes
• View specific packets
Troubleshooting Tools
• ndd
• Be very careful
• Perform routing/IP forwarding
• Check interface speed
• Check interface mode
Troubleshooting Tools
• netstat
• View routing tables (-r)
• Display IP addresses instead of host names (-n)
• Use verbose mode (-v)
Troubleshooting Tools
• traceroute
• Route network traffic
• Acquire benchmark
• Use ttl and ICMP
• Display IP addresses (-n)
Connectivity Problems
• Logical line of questioning
• Global or isolated problem
• Changes
• What connectivity, if any, exists
• snoop uses
Troubleshooting Techniques
• Work up or down through the TCP/IP model layers
• Application layer
• Transport layer and Internet layer
• Network Interface layer
• Physical layer
Troubleshooting Scenarios
• Use multi-homed system which acts as a core router
• Use traceroute
• Create /etc/notrouter
Troubleshooting Scenarios
• Faulty cable
• Router log files
• Replace cable
Internet
rtr-1 rtr-2
A B
net-1 net-2
Troubleshooting Scenarios
• Duplicate IP address
• ping failed
• traceroute failed
• arp cache incomplete
• Reconfigured IP address
Duplicate IP Address
Internet
rtr-1 rtr-2
A B
Routing .....................................................................................................................................6-1
Overview .................................................................................................................................................. 6-2
Introduction to Routing ......................................................................................................................... 6-3
Internet TCP/IP Layer ........................................................................................................................... 6-4
Routing Schemes ..................................................................................................................................... 6-5
Routing Algorithm .................................................................................................................................. 6-6
Kernel Routing Process .......................................................................................................................... 6-7
Autonomous System (AS) ...................................................................................................................... 6-8
Gateway Protocols .................................................................................................................................. 6-9
Exterior Gateway Protocol ................................................................................................................... 6-10
Border Gateway Protocol .................................................................................................................... 6-11
Interior Gateway Protocols .................................................................................................................. 6-12
Open Shortest Path First (OSPF) ......................................................................................................... 6-13
Routing Information Protocol ............................................................................................................. 6-14
Least Cost Path ...................................................................................................................................... 6-15
Stability Features ................................................................................................................................... 6-16
/usr/sbin/in.routed ..................................................................................................................................................... 6-17
Network Router Discovery (RDISC) .................................................................................................. 6-18
/usr/sbin/in.rdisc .......................................................................................................................................................... 6-19
Multihomed Host .................................................................................................................................. 6-20
Routing Initialization ............................................................................................................................ 6-21
Displaying the Routing Table ............................................................................................................. 6-22
/etc/inet/networks File .................................................................................................................. 6-23
Manually Manipulating Routing Table ............................................................................................. 6-24
DHCP .......................................................................................................................................9-1
Overview .................................................................................................................................................. 9-2
Dynamic Host Configuration Protocol ................................................................................................ 9-3
How DHCP Uses BOOTP ...................................................................................................................... 9-4
DHCP FEATURES .................................................................................................................................. 9-5
DHCP Client/Server .............................................................................................................................. 9-6
Server Side ................................................................................................................................................ 9-7
SERVER DATABASES ........................................................................................................................... 9-8
dhcp_network ENTRY FORMAT ........................................................................................................ 9-9
dhcp_network Examples ..................................................................................................................... 9-10
dhcptab Entry Format ......................................................................................................................... 9-11
Symbols and Macros ............................................................................................................................. 9-12
Symbol Characteristics ........................................................................................................................ 9-13
Macro Definitions .................................................................................................................................. 9-14
Lease Time Policy .................................................................................................................................. 9-15
Lease Flags (dhcp_network) ................................................................................................................ 9-16
dhcptab Examples ................................................................................................................................ 9-17
DHCP ADMINISTRATION COMMANDS ...................................................................................... 9-18
DHCP SERVER CONFIGURATION .................................................................................................. 9-19
CONFIGURING DHCP ON THE SERVER ...................................................................................... 9-20
CONFIGURING DHCP ON THE CLIENT ....................................................................................... 9-21
Troubleshooting DHCP ....................................................................................................................... 9-22
DHCP Lab Network Configuration ................................................................................................... 9-23
Introduction to Network
Management Tools ...............................................................................................................10-1
Overview ................................................................................................................................................ 10-2
Network Management ......................................................................................................................... 10-3
Simple Network
Management Protocol ....................................................................................................................... 10-4
SNMP-based Management Applications .......................................................................................... 10-7
Solstice Site Manager ............................................................................................................................ 10-8
Solstice Domain Manager .................................................................................................................... 10-9
Solstice Enterprise Manager .............................................................................................................. 10-10
Ce produit ou document est protégé par un copyright et distribué avec des licences qui en restreignent l’utilisation, la copie, la distribution, et la décompilation. Aucune partie de ce
produit ou document ne peut être reproduite sous aucune forme, par quelque moyen que ce soit, sans l’autorisation préalable et écrite de Sun et de ses bailleurs de licence, s’il y en a.
Le logiciel détenu par des tiers, et qui comprend la technologie relative aux polices de caractères, est protégé par un copyright et licencié par des fournisseurs de Sun.
Des parties de ce produit pourront être dérivées du systèmes Berkeley 4.3 BSD licenciés par l’Université de Californie. UNIX est une marque déposée aux Etats-Unis et dans d’autres
pays et licenciée exclusivement par X/Open Company Ltd.
Sun, Sun Microsystems, le logo Sun, Solaris, SunATM, Sun Quad FastEthernet, SunFastEthernet, SunFDDI, SunTRI, Solstice AdminSuite, SunNet Manager, OpenWin-
dows, et SunSoft. Solstice Enterprise Agents, NFS, JumpStart, Sun OS, ONC+, Solstice Site Manager, Solstice Domain Manager, Solstice Enterprise Manager, Sol-
stice Enterprise Agents, et Solstice Internet Mail Server. sont des marques de fabrique ou des marques déposées de Sun Microsystems, Inc. aux Etats-Unis et dans d’autres pays.
Toutes les marques SPARC sont utilisées sous licence sont des marques de fabrique ou des marques déposées de SPARC International, Inc. aux Etats-Unis et dans d’autres pays.
Les produits portant les marques SPARC sont basés sur une architecture développée par Sun Microsystems, Inc. IBM®, DECnet®, AppleTalk®, et Novell®.
UNIX est une marques déposée aux Etats-Unis et dans d’autres pays et licenciée exclusivement par X/Open Company, Ltd.
L’interfaces d’utilisation graphique OPEN LOOK et Sun™ a été développée par Sun Microsystems, Inc. pour ses utilisateurs et licenciés. Sun reconnaît les efforts de pionniers de Xerox
pour larecherche et le développement du concept des interfaces d’utilisation visuelle ou graphique pour l’industrie de l’informatique. Sun détient une licence non exclusive de Xerox sur
l’interface d’utilisation graphique Xerox, cette licence couvrant également les licenciés de Sun qui mettent en place l’interface d’utilisation graphique OPEN LOOK et qui en outre se
conforment aux licences écrites de Sun.
LA DOCUMENTATION EST FOURNIE “EN L’ETAT” ET TOUTES AUTRES CONDITIONS, DECLARATIONS ET GARANTIES EXPRESSES OU TACITES SONT FORMELLEMENT
EXCLUES, DANS LA MESURE AUTORISEE PAR LA LOI APPLICABLE, Y COMPRIS NOTAMMENT TOUTE GARANTIE IMPLICITE RELATIVE A LA QUALITE MARCHANDE, A
L’APTITUDE A UNE UTILISATION PARTICULIERE OU A L’ABSENCE DE CONTREFAÇON.