In Unix, the command to enable execution permission for file "mylife" by all…
2015
In Unix, the command to enable execution permission for file "mylife" by all is________ .
- A.
Chmod ugo + X mylife
- B.
Chmod a + X mylife
- C.
Chmod + X mylife
- D.
All of the above
Attempted by 49 students.
Show answer & explanation
Correct answer: D
Answer: Use chmod a+x mylife (other equivalent forms listed below also work).
chmod a+x mylife — adds execute permission for all (a = user, group, others).
chmod ugo+x mylife — explicitly lists user (u), group (g) and others (o); +x adds execute permission.
chmod +x mylife — when no class is specified, chmod applies the change to all classes (equivalent to a+x).
Note: Use lowercase 'chmod' and do not put spaces between the class, operator and mode. For example, write chmod a+x mylife rather than Chmod a + X mylife.
Loading lesson…