CmpE130HW01 - >" Again use" more" to view the...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
CmpE130 Fall 2009 HW1 1 of 1 CmpE130 Homework 1 Due date : 3 Sept. 2009 In the following questions, show the U NIX commands you use and the results (all, or partial if it is long). 1. Show the U NIX command syntax required to produce a directory listing containing the .bash_profile file that is located in your home directory. 2. Redirect the standard output from the U NIX " date " command so that this output is put in a file named " info ". 3. Append the output from the " ps -ef " command to the file created in the last step, " info ". (Use the " >> " symbol.) Then use " more " to view the contents of the file (" more info "). 4. Now, re-direct the output of the " set " command to the file named " info ". In this step of the exercise, use the re-direction symbol "
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: > ". Again, use " more " to view the contents of the file. How has the file changed? Why? 5. List the files in the directory " /bin " that end in " sh ". What command did you use? 6. You want to know the number of files and directories located in your home directory. To do this, you can combine the command " ls -al " and " wc -l " in a pipeline, feeding the standard output from the ls command in to the standard input of the wc command. Write the pipeline command in the proper order below, and test it at your terminal. 7. File permissions in U NIX are frequently specified as an octal number. Why is octal the preferred base for this purpose?...
View Full Document

This note was uploaded on 09/21/2009 for the course CMPE 130 taught by Professor Mrobinson during the Fall '09 term at San Jose State.

Ask a homework question - tutors are online