CS 146 ====== Assignment #1 - Due First Lecture of Week 2 at beginning of lecture All of these questions should be answered while you are logged into the machine "odin.ics.uci.edu" (biggest machine of openlab cluster). Submit solutions from an openlab command-line using the command /home/cs146/bin/submit Type the above command with no arguments for help. Note that some of the questions have more than one correct answer (any one of which gets full marks). Each question is worth equal value. Explain how you got each answer---both your reasoning, and the actual command you used to get the answer. Feel free to edit this file and put your anwsers in it. You can also convert it to Word or PDF and submit that (using the command above). 1) What is your home directory? How did you find out (commands used)? 2) What is your UID? How did you find out (commands used)? 3) To what group(s) do you belong? How did you find out? 4) What is your "kill" character used for? 5) If you remove execute permission for yourself from a directory (see chmod(1)), are you still allowed to create files in that directory? Can you cd into it? Can you "ls" it? Can you "ls -l" it? NOTE: the answer can be different for an NFS-mounted (ie., remotely hosted) filesystem (such as your openlab HOME directory) and a locally hosted filesystem (such as you HOME directory on your own machine, or the /tmp directory on any machine). Try it for both. 6) If you make a hard link to a file, and then remove the original file, are the contents of the file actually removed? Why? How about if you make a symbolic link? Why? 7) Are you allowed to "mv" a directory? Are you allowed to "cp" a directory? If so, how? 8) How many mounted file systems are there on odin.ics.uci.edu? How did you find out? (Commands) 9) Using only "ls" (and maybe "grep"), can you find out the name of your login terminal? How? (Hint: cheat by first typing "who am i". Look also at the -L option of "ls".) 10) In slide 8 from lecture #1, assume binary 00000000 represents register D0. Then the address translation from "FFDC" to binary is incorrect. Correct it. What is the machine language (binary) representation of the MOVE instruction? What about MUL? (Before you ask: yes, different instructions can take up different numbers of bytes/words.)