Common network problems are of two types: those related to physical connectivity and those due to configuration error. The physical problems are as follows .
network adapter is not installed properly
in case of coaxial cable, terminator is not connected
a broken cable
LAN segment is too long
router machine is not working
The configuration problems are as follows.
one IP address is assigned to more than one station
wrong IP address is assigned to an adapter
incorrect netmask
incorrect routing entries
If you are facing any problem with LAN configuration, first try to use the ping command to send data packets to another machine on the network. This command sends ICMP packets to another system on the network that are echoed back. A typical response of the ping command, where you are trying to send ICMP packets to machine 192.168.2.34, is shown.
# ping 192.168.2.34 PING s124hp0a.ham.am.honda.com: 64 byte packets 64 bytes from 192.168.2.34: icmp_seq=0. time=2. ms 64 bytes from 192.168.2.34: icmp_seq=1. time=0. ms 64 bytes from 192.168.2.34: icmp_seq=2. time=0. ms 64 bytes from 192.168.2.34: icmp_seq=3. time=0. ms 64 bytes from 192.168.2.34: icmp_seq=4. time=0. ms 64 bytes from 192.168.2.34: icmp_seq=5. time=0. ms CTRL - C ----192.168.2.34 PING Statistics---- 6 packets transmitted, 6 packets received, 0% packet loss round-trip (ms) min/avg/max = 0/0/2 #
By default, this command continues to send ICMP packets until interrupted by the key combination. At this point, it shows how many packets are sent and how many of these returned from the system. If you don't receive any packets back, it indicates a problem.
Although there is no hard and fast rule for troubleshooting, I would suggest to check for physical problems if the ping fails. After that, you can use one of the following commands for specific checks.
Use lanscan to list installed LAN adapters.
Use the netstat -in command to list the assigned IP addresses of the installed software.
Use the netstat -rn command to check routing entries.
Before assigning a second IP address, use the ping 255.255.255.255 command to check if the IP address is assigned to another live machine. This commands sends ICMP packets to all machines on your network, and you get responses from all live machines.
Some commands list detailed information about the network. These can be used for low-level troubleshooting and fine-tuning. The netstat and lanadmin commands are as follows.
The netstat command can also be used to get statistics of network activity of each protocol. The following command shows statistics of each protocol on the network.
# netstat -sv tcp: 20456 packets sent 17910 data packets (4292600 bytes) 90 data packets (117386 bytes) retransmitted 2546 ack-only packets (1176 delayed) 0 URG only packets 0 window probe packets 0 window update packets 45 control packets 19044 packets received 12649 acks (for 4292621 bytes) 428 duplicate acks 0 acks for unsent data 11364 packets (945474 bytes) received in-sequence 1 completely duplicate packet (32 bytes) 0 packets with some dup, data (0 bytes duped) 1 out of order packet (32 bytes) 0 packets (0 bytes) of data after window 0 window probes 5945 window update packets 0 packets received after close 0 segments discarded for bad checksum 0 bad TCP segments dropped due to state change 20 connection requests 3 connection accepts 23 connections established (including accepts) 24 connections closed (including 1 drop) 1 embryonic connection dropped 12547 segments updated rtt (of 12547 attempts) 20 retransmit timeouts 0 connections dropped by rexmit timeout 0 persist timeouts 11 keepalive timeouts 0 keepalive probes sent 0 connections dropped by keepalive 0 connect requests dropped due to full queue 1 connect request dropped due to no listener udp: 0 incomplete headers 0 bad checksums 0 socket overflows ip: 21134 total packets received 0 bad IP headers 0 fragments received 0 fragments dropped (dup or out of space) 0 fragments dropped after timeout 0 packets forwarded 0 packets not forwardable icmp: 76 calls to generate an ICMP error message 0 ICMP messages dropped Output histogram: echo reply: 76 destination unreachable: 0 source quench: 0 routing redirect: 0 echo: 0 time exceeded: 0 parameter problem: 0 time stamp: 0 time stamp reply: 0 address mask request: 0 address mask reply: 0 0 bad ICMP messages Input histogram: echo reply: 571 destination unreachable: 22 source quench: 12 routing redirect: 0 echo: 76 time exceeded: 0 parameter problem: 0 time stamp request: 0 time stamp reply: 0 address mask request: 0 address mask reply: 0 76 responses sent igmp: 0 messages received 0 messages received with too few bytes 0 messages received with bad checksum 0 membership queries received 0 membership queries received with incorrect fields(s) 0 membership reports received 0 membership reports received with incorrect field(s) 0 membership reports received for groups to which this host belongs 0 membership reports sent #
The lanadmin command is used for interface adapter administration. It can be used for a number of tasks , including the following.
Display and change the physical address of a station.
Display and change the maximum transfer unit (MTU). The MTU shows the maximum number of bytes that can be transferred in one packet.
Display and change the speed setting. This can't be done on all adapters.
Display and clear the LAN adapter statistics. The statistics include inbound and outbound bytes since the last statistics clearing, different types of errors, types of packets, and so on.
Reset a network interface.
The command can be used with different options or in interactive mode. The following command displays the physical address of a LAN adapter having NM ID equal to 2 ( lan2 in the output of the lanscan command).
# lanadmin -a 2 Station Address = 0x080009f02610 #
The next command shows current MTU size .
# lanadmin -m 2 MTU Size = 1000 #
To change the MTU size of an adapter with NM ID 2, you can use the following command. Here both old and new MTU values are displayed.
# lanadmin -M 1500 2 Old MTU Size = 1000 New MTU Size = 1500 #
The current speed setting of an adapter can be displayed using the following command.
# lanadmin -s 2 Speed = 10000000 #
As I mentioned earlier, the lanadmin command can also be used in interactive mode. When you don't provide any command-line options, the command starts in this mode. It displays a number of subcommands and then waits for user input. In the following lanadmin interactive session, the words in boldface show user input. This session is used to display and then clear network statistics of an interface adapter with NM ID equal to 2. Statistics are once again displayed after clearing.
# lanadmin LOCAL AREA NETWORK ONLINE ADMINISTRATION, Version 1.0 Wed, Dec 1,1999 12:01:38 Copyright 1994 Hewlett Packard Company. All rights are reserved. Test Selection mode. lan = LAN Interface Administration menu = Display this menu quit = Terminate the Administration terse = Do not display command menu verbose = Display command menu Enter command: lan LAN Interface test mode. LAN Interface PPA Number = 1 clear = Clear statistics registers display = Display LAN Interface status and statistics registers end = End LAN Interface Administration, return to Test Selection menu = Display this menu ppa = PPA Number of the LAN Interface quit = Terminate the Administration, return to shell reset = Reset LAN Interface to execute its selftest specific = Go to Driver specific menu Enter command: ppa 2 Enter PPA Number. Currently 1: 2 LAN Interface test mode. LAN Interface PPA Number = 2 clear = Clear statistics registers display = Display LAN Interface status and statistics registers end = End LAN Interface Administration, return to Test Selection menu = Display this menu ppa = PPA Number of the LAN Interface quit = Terminate the Administration, return to shell reset = Reset LAN Interface to execute its selftest specific = Go to Driver specific menu Enter command: display LAN INTERFACE STATUS DISPLAY Wed, Dec 1,1999 12:01:52 PPA Number = 2 Description = lan2 Hewlett-Packard LAN Interface Hw Rev 0 Type (value) = ethernet-csmacd(6) MTU Size = 1500 Speed = 10000000 Station Address = 0x80009f02640 Administration Status (value) = up(1) Operation Status (value) = down(2) Last Change = 100 Inbound Octets = 4312 Inbound Unicast Packets = 0 Inbound Non-Unicast Packets = 0 Inbound Discards = 0 Inbound Errors = 0 Inbound Unknown Protocols = 0 Outbound Octets = 6468 Outbound Unicast Packets = 33 Outbound Non-Unicast Packets = 0 Outbound Discards = 0 Outbound Errors = 0 Outbound Queue Length = 0 Specific = 655367 Ethernet-like Statistics Group Index = 3 Alignment Errors = 0 FCS Errors = 0 Single Collision Frames = 0 Multiple Collision Frames = 0 Deferred Transmissions = 0 Late Collisions = 0 Excessive Collisions = 0 Internal MAC Transmit Errors = 0 Carrier Sense Errors = 11 Frames Too Long = 0 Internal MAC Receive Errors = 0 LAN Interface test mode. LAN Interface PPA Number = 2 clear = Clear statistics registers display = Display LAN Interface status and statistics registers end = End LAN Interface Administration, return to Test Selection menu = Display this menu ppa = PPA Number of the LAN Interface quit = Terminate the Administration, return to shell reset = Reset LAN Interface to execute its selftest specific = Go to Driver specific menu Enter command: clear Clearing LAN Interface statistics registers. LAN Interface test mode. LAN Interface PPA Number = 2 clear = Clear statistics registers display = Display LAN Interface status and statistics registers end = End LAN Interface Administration, return to Test Selection menu = Display this menu ppa = PPA Number of the LAN Interface quit = Terminate the Administration, return to shell reset = Reset LAN Interface to execute its selftest specific = Go to Driver specific menu Enter command: display LAN INTERFACE STATUS DISPLAY Wed, Dec 1,1999 12:02:04 PPA Number = 2 Description = lan2 Hewlett-Packard LAN Interface Hw Rev 0 Type (value) = ethernet-csmacd(6) MTU Size = 1500 Speed = 10000000 Station Address = 0x80009f02640 Administration Status (value) = up(1) Operation Status (value) = down(2) Last Change = 100 Inbound Octets = 0 Inbound Unicast Packets = 0 Inbound Non-Unicast Packets = 0 Inbound Discards = 0 Inbound Errors = 0 Inbound Unknown Protocols = 0 Outbound Octets = 0 Outbound Unicast Packets = 0 Outbound Non-Unicast Packets = 0 Outbound Discards = 0 Outbound Errors = 0 Outbound Queue Length = 0 Specific = 655367 Ethernet-like Statistics Group Index = 3 Alignment Errors = 0 FCS Errors = 0 Single Collision Frames = 0 Multiple Collision Frames = 0 Deferred Transmissions = 0 Late Collisions = 0 Excessive Collisions = 0 Internal MAC Transmit Errors = 0 Carrier Sense Errors = 0 Frames Too Long = 0 Internal MAC Receive Errors = 0 LAN Interface test mode. LAN Interface PPA Number = 2 clear = Clear statistics registers display = Display LAN Interface status and statistics registers end = End LAN Interface Administration, return to Test Selection menu = Display this menu ppa = PPA Number of the LAN Interface quit = Terminate the Administration, return to shell reset = Reset LAN Interface to execute its selftest specific = Go to Driver specific menu Enter command: quit #
The ppa 2 command is used to select an adapter with the name lan2 . As you can see, the number of Carrier Sense Errors is 11 before clearing the interface. When you use the display command after the clear command, its value changes to 0. This command is useful when you want to see what is happening on the network media in real time. For example, if you wait for one minute after clearing an interface and then repeat the display command, you can find out what happened during the previous minute. The interactive session can be terminated using the quit command.
The ndd command can be used to fine-tune TCP/IP protocol parameters. This command is used for in-depth troubleshooting and fine-tuning. The list of supported parameters is displayed using the following command.
# ndd -h supported SUPPORTED ndd tunable parameters on HP-UX: IP: ip_def_ttl - Controls the default TTL in the IP header ip_forward_directed_broadcasts - Controls subnet broadcasts packets ip_forward_src_routed - Controls forwarding of source routed packets ip_forwarding - Controls how IP hosts forward packets ip_fragment_timeout - Controls how long IP fragments are kept ip_icmp_return_data_bytes - Maximum number of data bytes in ICMP ip_ill_status - Displays a report of all physical interfaces ip_ipif_status - Displays a report of all logical interfaces ip_ire_hash - Displays all routing table entries, in the order searched when resolving an address ip_ire_status - Displays all routing table entries ip_ire_cleanup_interval - Timeout interval for purging routing entries ip_ire_flush_interval - Routing entries deleted after this interval ip_ire_gw_probe_interval - Probe interval for Dead Gateway Detection ip_ire_pathmtu_interval - Controls the probe interval for PMTU ip_ire_redirect_interval - Controls 'Redirect' routing table entries ip_pmtu_strategy - Controls the Path MTU Discovery strategy ip_reass_mem_limit - Maximum number of bytes for IP reassembly ip_send_redirects - Sends ICMP 'Redirect' packets ip_send_source_quench - Sends ICMP 'Source Quench' packets ip_strong_es_model - Controls support for 'Strong End-System Model' ip_udp_status - Reports IP level UDP fanout table TCP: tcp_conn_request_max - Max number of outstanding connection request tcp_ignore_path_mtu - Disable setting MSS from ICMP 'Frag Needed' tcp_ip_abort_cinterval - R2 during connection establishment tcp_ip_abort_interval - R2 for established connection tcp_ip_notify_cinterval - R1 during connection establishment tcp_ip_notify_interval - R1 for established connection tcp_ip_ttl - TTL value inserted into IP header tcp_keepalive_detached_interval - Send keepalive probes for detached TCP tcp_keepalive_interval - Interval for sending keepalive probes tcp_largest_anon_port - Largest anonymous port number to use tcp_recv_hiwater_def - Maximum receive window size tcp_recv_hiwater_lfp - Maximum receive window size for fast links tcp_recv_hiwater_lnp - Maximum receive window size for slow links tcp_rexmit_interval_initial - Initial value for round trip time-out tcp_rexmit_interval_initial_lnp - tcp_rexmit_interval_initial for LNP tcp_rexmit_interval_max - Upper limit for computed round trip timeout tcp_rexmit_interval_min - Lower limit for computed round trip timeout tcp_sth_rcv_hiwat - Sets the flow control high water mark tcp_sth_rcv_lowat - Sets the flow control low water mark tcp_syn_rcvd_max - Controls the SYN attack defense of TCP tcp_status - Get netstat-like TCP instances information tcp_time_wait_interval - How long stream persists in TIME_WAIT tcp_xmit_hiwater_def - The amount of unsent data that triggers TCP flow control tcp_xmit_hiwater_lfp - The amount of unsent data that triggers TCP flow control for fast links tcp_xmit_hiwater_lnp - The amount of unsent data that triggers TCP flow control for slow links tcp_xmit_lowater_def - The amount of unsent data that relieves TCP flow control tcp_xmit_lowater_lfp - The amount of unsent data that relieves TCP flow control for fast links tcp_xmit_lowater_lnp - The amount of unsent data that relieves TCP flow control for slow links UDP: udp_def_ttl - Default TTL inserted into IP header udp_largest_anon_port - Largest anonymous port number to use udp_status - Get UDP instances information. RAWIP: rawip_def_ttl - Default TTL inserted into IP header ARP: arp_cache_report - Displays the ARP cache arp_cleanup_interval - Controls how long ARP entries stay in the ARP cache #
Top |