On This Page
This set of Operating System Architecture Multiple Choice Questions & Answers (MCQs) focuses on Operating System Architecture Set 9
Q1 | The first set of the three permissions (rw) pertains to the owner of the file, indicating that the owner has
- executable permission only
- write and executable permissions
- both read and executable permissions.
- both read and write permissions
Q2 | Which of the following commands is used to save the output of the who command in a file named user.lst, as well as display it?
- who | tee user.lst
- who > user.lst
- who >> user.lst
- who < user.lste
Q3 | Which of the following shell's wildcards are used to match any number of characters including none?
- [ijk]
- [!ijk]
- ?
- *
Q4 | Which symbol will be used with grep command to match the pattern pat at the end of a line?
- ^pat
- $pat
- pat$
- pat^
Q5 | Which command is used to display all the lines with the string 'sales' from the file empl.lst?
- cut sales empl.lst
- /sales > empl.lst
- grep sales empl.lst
- cat | /sales > empl.lst
Q6 | Which of the following commands is note the vi Input mode command?
- rch
- r
- s
- j
Q7 | Which of the following commands is used to remove files?
- erase
- delete
- rm
- dm
Q8 | Which command is used with vi editor to save file and remain in the editing mode?
- :q
- :w
- q!
- :x
Q9 | Which of the following commands is used to have a two-way communication with any person who is currently logged in?
- mesg
- write
- grep
Q10 | Which command is used with vi editor to move the cursor to the left?
- i
- j
- k
- h
Q11 | Which command is used to terminate all processes in your own system except the login shell?
- kill 1
- kill 0
- cancel all
- cancel 1
Q12 | Which command is used to link the files?
- ik
- in
- cp
- tar
Q13 | Which of the following signs is used to back up over typing errors in vi?
- @
- #
- $
- !
Q14 | Which of are following internal commands is used in mail to forward mail to user in user-list?
- r user-list
- m user-list
- d user-list
- e user-list
Q15 | Which of the following commands is used to display the filenames in multiple columns?
- ls
- ls -1
- ls -x
- lc
Q16 | Which of the following features of UNIX may be used for inter process communication?
- signals
- pipes
- semaphore
- all of these
Q17 | The command echo welcome > /dev / tty
- echoes welcome in all the terminals that are switched on.
- echoes welcome in all the terminals that are logged on.
- echoes welcome only in the terminal in which it is run.
- both (a) and ©
Q18 | dev/null
- is a file
- has write permission for all
- is the unix built- in dustbin
- all of these
Q19 | The permission bits of a file noname. can be set to _rws_ _x_ _x by the command.
- chmod 711 noname
- chmod go -rw noname
- chmod 2711 noname
- none of the above
Q20 | /bin/passwd has the user execution permission set to 's' because
- this facility assigns to the user, permissions of the program owner. temporarily
- it should allow users who don\t have write permission to/etc/passwd to write to it
- /etc/passwd is write protected
- all of these
Q21 | If one doesn't want anyone else to read or write to a file named datfile, except through a program in a file filex , then he may use
- chmod u+s filex ; chmod go_rw datfile
- chmod 4711 filex ; chmod go_rw datfile
- chmod 4711 datfile ; chmod go_rw filex
- both (a) and (b)
Q22 | Writing a C program that accepts input from keyboard, rather than from a file is advantageous because
- keyboard is a file that is already open
- it can be used in a pipe, if it writes to stdout
- both (a) and (b)
- none of the above
Q23 | Consider the following command that invokes the executable file a.out, with the following command line arguments a .out God loves youargv( [1][2] )corresponds to the character
- e
- o
- y
- d
Q24 | Which of the following string functions can be used to find the last occurrence of a given character in a given string?
- strncmp
- strncpy
- strchr
- none of the above
Q25 | Consider the program main ( ){printf("He arose a victor from\n"); system ("date") ;printf("the dark domain");}If a.out is the executable code corresponding to the above source code, then the command a.out > out f
- redirects the output of date to file out f
- displays the output of date on the screen
- prints everything on the screen
- prints the two messages on the screen