Top 150+ Solved Linux Programming MCQ Questions Answer
Q. Which command is used to make all files and sub-directories in the directory (prog)executable by all users?
a. chmod –R a+xprogs
b. chmod –x a+xprogs
c. chmod -1 a+xprogs
d. chmod –R 222 progs
Q. The chmodugo+rw note command can be represented in octal notation as
a. chmod 555 note
b. chmod 666 note
c. chmod 333 note
d. chmod 444 note
Q. Which of the following commands is used to view the file 24 lines at a time?
a. pg
b. 1p
c. cat
d. /p
Q. The second set of the three permissions (r-) indicates that
a. group has read permission only
b. other has read permission only
c. group has write permission only
d. owner has read permission only
Q. The dmesg command
a. Shows user login logoff attempts
b. Shows the syslog file for info messages
c. Kernel log messages
d. Shows the daemon log messages
Q. The command “mknodmyfifo b 4 16”
a. Will create a block device if user is root
b. Will create a block device for all users
c. Will create a FIFO if user is not root
d. None of the above
Q. Which command is used to record a user login session in a file ?
a. macro
b. read
c. script
d. none of the above
Q. Which command is used to display the unix version ?
a. uname -r
b. uname -n
c. uname -t
d. kernel
Q. Using which command you find resource limits to the session?
a. rlimit
b. ulimit
c. setrlimit
d. getrlimit
Q. Find / -name ‘*’ will
a. List all files and directories recursively starting from /
b. List a file named * in /
c. List all files in / directory
d. List all files and directories in / directory
Q. In which directory can you store system user default files used for creating userdirectories?
a. /usr/tmp
b. /etc/default
c. /etc/skel
d. /etc/users