Try to find out what the following commands are doing:
cat
pr
more
less
ls
wget
Use your newly obtained knowledge to solve the following tasks.
Download the file passwd from http://users.ugent.be/˜pdawyndt/hpc/passwd.
Display the content of this file in four different ways, using commands from the above list. What is the difference between the four approaches?
The output from two of the commands scrolls rapidly across the screen. A simple, more conveniently arranged way of doing is to write the output of a command to a file. Page 135 of the reference book explains how this can be done using I/O redirection. Use this technique to write the content of the password file to the file nicepassword, and take care that the content of this file is arranged in three columns and has a nice left margin of 5 spaces (use your imagination to decide how this should be done).
Using pipelining (see page 141 of the reference book) it is also possible to take care that the output of a command is better organized. Make sure the content of the password file is shown page per page, in such a way that each page is provided with a header containing file name, date and page number.
When was the file nicepassword last modified?
Try to make a hard link terminal in your home directory that refers to the special file of your terminal. Observe what is happening and try to explain it.
Repeat the previous task, but now using a symbolic link.
Show a list of advanced information (owner, date last modified, ... ) about the content of your home
directory. Repeat the same exercise, taking care that symbolic links are not written out. In other words,
instead of
terminal -> <pathname terminal special file>
only the file name terminal should be shown in the output.