Previous Section  < Day Day Up >  Next Section

LAB 22: REDIRECTION

  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:

    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. What happens when you type cp all by itself?

    5. How do you save the error message from the above example to a file?

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

    7. What is noclobber? How do you override it?

    8. Take the output of three commands and redirect the output to a file called gottemall.

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

    Previous Section  < Day Day Up >  Next Section