Dr. Mark Humphrys

School of Computing. Dublin City University.

Home      Blog      Teaching      Research      Contact

Search:

CA216      CA249      CA318

CA400      CA651      CA668


Linux Quiz 4

NOT for marks. Just for practice.
I give this in the style of a form in which you can organise your answers. But N.B. There is nowhere to "submit" to. Your answers are lost when you log out.
If you want to keep your answers, save them in a text file.


  1. I need a command to make a file called myprog in my home directory executable. What command will work?

  2. What does it mean for a directory to be executable?

  3. If your directory is executable but not readable, what does it mean?

  

file and directory permissions for web files (public_html)

To test these, make a web page in your public_html directory.
If you do not already have a web page there, this command will make one:
  echo "My web page" > $HOME/public_html/index.html
You can then view the web page through the address:
  http://student.computing.dcu.ie/~youruserid 
  
  1. Is my web site visible if I set the directory permissions as follows: chmod go-rwx public_html

  2. Is my web site visible if I set the directory permissions as follows: chmod go-rx+w public_html

  3. Is my web site visible if I set the directory permissions as follows: chmod go-rw+x public_html

  4. Is my web site visible if I set the directory permissions as follows: chmod o-rw+x public_html

  5. Is my web page visible if I set the permission as follows: chmod -rwx file.html

  6. Is my web page visible if I set the permission as follows: chmod u+rwx file.html

  7. Is my web page visible if I set the permission as follows: chmod +r file.html

  8. What is the minimal protection that your public_html directory needs?