First Assignment.docx



Technology of PrivacyFall 2017Problem Set OneDUE: Thursday, September 7, 2017, 1:20 PM Ungraded AssignmentThroughout the semester, you will be required to complete short, technology-focused assignments. In homage to undergraduate science and math education, these assignments are called “problem sets.” These assignments won’t be assigned or due every week.These will do some or all of the following: give you hands-on exposure to technologies discussed in class, thus reinforcing the lesson; give the professor feedback about how well the class is understanding the material; and preview technical material to be discussed in a future class (or to use the parlance of the day, “flipping” the classroom).You must hand in your assignment electronically, sometimes via email, Box, or Canvas, and sometimes on the class’s shared server. These assignments will not be graded, but missing or incomplete assignments will count against the participation component of a student’s final grade.For these ungraded assignments, you should feel free to work with classmates or discuss them on the class discussion board.In our next class, Class Two, we will be interacting with one another in the Unix shell. Before class, you are expected to show mastery of basic Unix commands, particularly those relating to files and directories.Handing In Problem Set One: The instructions below tell you what to do to hand in this assignment.All of the skills required to complete the following are described in the required text for the class, William E. Shotts, Jr., The Linux Command Line chapters one to six.Locate the ssh program on your computer, or install it if it is missing. I have posted instructions on how to do this to the class web page at Begin an ssh session with the class’s server, tp..Using the username and password you generated in class, log in to your new account.At the prompt, type “script script.<username>”. Replace <username> with your username. So if you were user xyz42, you would type “script script.xyz42” to begin saving a transcript of everything you are doing.Note: You can split up your work on this over more than one session. But if you do, just give the script a different name each session (e.g. during the second session, use the command “script script.xyz42.b”.Use “mkdir” to create a directory called “work” in your home directory.Use “cd” to change into the work directory.Use “cp” to copy the file /usr/share/dict/american-english into your work directory.Use “mv” to rename this file to “words”Use “wc” to count the number of words in the fileUse “grep” to print a list of all words in the file that contain the string “apple”.Use a pipeline and the “wc” command to count how many words are output by that grep command.Use “head” and “tail” to print the first 10 lines of the file.Use “head” to print the first 20 lines of the fileUse “mkdir” to create a subdirectory of “work” called “secret”.Use the “chmod” command to change the permissions on “secret” so that only you can access, read, and write into that directory.Use “ls” to print the files in the current working directory.Use “pwd” to print the current working directory.Use “ls –l” to print more details about files in the current working directory. Use “man ls” to decipher this data.Question: How does the output of “ls –lh” differ from “ls –l”?More advanced: These next few questions are much more difficult. Take your best stab at answering these, but don’t worry if you can’t figure them out:Question: There are only two letters in the English alphabet that does not occur repeated in any word in the American English dictionary word list. Identify either of these two letters. (You’re not expected to do this using only a single command.)For the letter that appears repeated most often, use the “>” redirect to store those words in a file called “words.most”.For the letter that appears least often (excluding the two letters that does not occur repeated at all), use the “>” redirect to store those words in a file called “words.least”.Use “ps” to list all processes you are running.Use “top” to list all processes in another format.The final two steps allow you to submit proof of completion of this assignment.When you are finished, type “exit” to quit the typescript/logging program.Copy the filename you chose in step 4 (e.g. script.xyz42) into the directory ~ohm/inbox/If you created more than one script in step 4 (if you required more than one session to finish this assignment), copy all files you created into the directory ~ohm/inbox/ ................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download