Professional Documents
Culture Documents
Cis341
Cis341
Resources
CIS 341 AB1
Carl A. Janzen
Fall 2016
Contents
1 Introduction 2
1.1 Review from last class . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.2 Accounts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
1.3 Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
1.4 Managing Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
2 Wrap-Up 5
2.1 Review . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
2.2 Homework . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1 Introduction
1.1 Review from last class
Review
This is only an introduction to these topics. Throughout the course we will delve into more
details in all of these areas.
Find your way around: list directories, show file contents, find files in subdirectories or
locatedb, and search for pattern matches
Get help: accessing man and info pages, find related commands using apropos, access
package supplied documents in /usr/share/doc as well as online resources such as tldp
Type less: use history and tab completion features to reduce your typing load
Edit files properly: begin to use the most common vi commands to edit text files
I/O redirection: use pipes, fifos, the tee command, redirect standard error and standard
output, and record your session using script, ttyrec, or termrec
Checking file contents and paging: use tail, head, less, and wc to view or summarize
all or part of a text file
File management: change directories, print current directory, create and delete files
and directories, display a directory tree structure, and create links including symbolic
links
rsync use ssh (if necessary) to copy only the differences between two locations (optionally
deleting)
2/5
Windows
screen venerable console window manager, available on almost any system. Allows you to have
multiple windows, including split screen
tmux modern re-write of screen. Very similar key bindings, except they are all preceded by
Ctrl+B instead of Ctrl+A
1.2 Accounts
Become root
sudo sanitize environment, and run single command as root user
su switch user (by default, to become root, but can also be used to become other users)
1.3 Configuration
Setting defaults
/etc/skel Default settings for all users
Configuration Files
dotfiles it is customary for config files and directories to start with a dot
dotbot (github project) one of numerous utilities avaialable for quickly configuring a new
account
hardware
lspci -vv list pci bus details. Useful for listing your hardware (see also lshw)
/proc/cpuinfo cpu description
/proc/meminfo ram description
vmstat summary of allocated memory resources
free shows available ram
/dev device filesystem
network
netstat -pant list connections
ping verify connectivity
traceroute verify hops to destination
dig get detailed information about an address
tcpdump inspect network traffic (see also ettercap/wireshark)
route -n show active routes [ip] show/manipulate routes, addresses, etc
batch run a job when system load drops below 0.8 (see load)
2 Wrap-Up
2.1 Review
Remote file management: scp, rsync, git, sftp/lftp
2.2 Homework
Homework
Assignment 1 posted
5/5