|
Page 6 of 7
ping
Ping can help you
figure out if a remote machine on the network is up and connected.
Ping sends ICMP messages to the remote machine, and prints the
details if it gets a reply from the remote machine. Sometimes
system administrators disable ICMP messages on their machines,
which means that a ping won't get a reply from that particular
machine, even it is present on the network, so be sure that the
remote machine you're interested in does reply to ICMP messages
before assuming that it is down.
$ping
google.com
PING google.com
(72.14.207.99) 56(84) bytes of data.
64 bytes from
eh-in-f99.google.com (72.14.207.99): icmp_seq=1 ttl=238 time=265
ms
64 bytes from
eh-in-f99.google.com (72.14.207.99): icmp_seq=2 ttl=238 time=269
ms
64 bytes from
eh-in-f99.google.com (72.14.207.99): icmp_seq=3 ttl=238 time=272
ms
64 bytes from
eh-in-f99.google.com (72.14.207.99): icmp_seq=4 ttl=238 time=263
ms
hexdump
The hexdump utility
is useful for seeing the contents of a binary file in a
human-readable format, which can be ASCII, hexadecimal, octal, or
decimal. For example, to see what the contents of the executable
/bin/ls looks like in hex and ASCII, use:
$hexdump -C
/bin/ls
00000000 7f 45 4c 46
01 01 01 00 00 00 00 00 00 00 00 00 |.ELF............|
00000010 02 00 03 00
01 00 00 00 80 9c 04 08 34 00 00 00 |............4...|
00000020 0c 5c 01 00
00 00 00 00 34 00 20 00 0a 00 28 00 |.......4. ...(.|
00000030 1f 00 1e 00
06 00 00 00 34 00 00 00 34 80 04 08 |........4...4...|
00000040 34 80 04 08
40 01 00 00 40 01 00 00 05 00 00 00 |4...@...@.......|
.
.
.
The information on
the left is the contents of the file in hex, while the text between
the bars is the ASCII representation. Hexdump is useful for
searching text strings within an executable file for which source
code might not be available. It can help you locate specific error
messages and where they occur in a file.
|