LAB 10: REDIRECTION

 <  Day Day Up  >  

  1. What are the names of the three file streams associated with your terminal?

  2. What is a file descriptor?

  3. What command would you use to do the following:

    1. Redirect the output of the ls command to a file called lsfile ?

    2. Redirect and append the output of the date command to lsfile ?

    3. Redirect the output of the who command to lsfile ? What happened ?

  4. Perform the following:

    1. Type cp all by itself. What happens?

    2. Save the error message from the above example to a file.

    3. Use the find command to find all files, starting from the parent directory, of type directory . Save the standard output in a file called found and any errors in a file called found.errs .

    4. Take the output of three commands and redirect the output to a file called gottem_all .

    5. Use a pipe(s) with the ps and wc commands to find out how many processes you are currently running.

 <  Day Day Up  >  


UNIX Shells by Example
UNIX Shells by Example (4th Edition)
ISBN: 013147572X
EAN: 2147483647
Year: 2004
Pages: 454
Authors: Ellie Quigley

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net