



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




Unix Networking Commands
The following information consists of various UNIX networking and system administration commands that you may wish to learn. This is not a formal homework, it is just something I suggest you investigate at least a little for your own edification.
Please read the man pages and try to experiment with the commands when possible. You need root access to do some of the commands, but you can at least look at the man pages to see how the programs operate. For example, use
man arp
to read the man page on arp.
For now I just want you to be aware of the commands and have an idea of what they do. If you need to learn a program in more detail you at least have a place to start. Being a sysadmin is tough and it can take a long time to really learn how everything works.
Most of the programs for the UAA math system (i.e. saturn, mazzy) are stored in
/usr/sbin.
This will be different for other operating systems. For example, SunOS stores most of these in /usr/etc instead.
You might want to add /usr/sbin to your path if you can’t execute them. If you are using saturn with bash, then add :/usr/sbin to the end of your PATH in your .profile file.
Common System Administrator files and commands
Network Status commands
ÿ netstat
If you use the –n flag, host addressed will be numeric and avoid a DNS lookup, which might be faster in some cases. Combine with the other switches.
Network interfaces commands
ÿ ifconfig –a Show all interfaces ÿ ifconfig
ÿ ifconfig
Connectivity
ÿ ping
ÿ telnet host
7 – echo port, use control-] to get out 25 – SMTP, use to send mail 79 - Finger
ÿ telnet ip-number Can tell if inetd is functioning. With telnet you can use the ip number instead of the host name. If ip-number as opposed to telnet hostname works, you have problems with the name server. If you can ping, but you can't telnet, you have problems with getting processes running and possibly inetd configuration problems.
Routing
ÿ netstat –r Print routing tables. The routing tables are stored in the kernel and used by ip to route packets to non-local networks.
Other Useful Commands
ÿ ps aux or ps alx List of processes in action, usage varies from system to system.
“ps -aux | grep
ÿ ps List your processes in the foreground.
ÿ nslookup (or nslookup
ÿ ftp
ÿ rcp
ÿ rlogin
Important Files
/etc/hosts - names to ip addresses /etc/networks - network names to ip addresses /etc/protocols - protocol names to protocol numbers /etc/services - tcp/udp service names to port numbers Not all programs use these services.
ROOT ONLY daemons started at boot:
inetd inetd is the BSD mother daemon that listens on the apps in /etc/inetd.conf and makes connections for these other daemons.
sendmail Sendmail runs the SMTP mail protocol on tcp port 25. If you telnet to port 25, you are talking directly to sendmail. Some old configurations allowed forgeries to be made in this fashion (mail relaying) but that has been mostly disabled today.