GkSeries.com

Linux Objective Type Questions and Answers | Linux Short Questions & Answers

(21) Which command is used to extract intermediate result in a pipeline
[A] tee
[B] extract
[C] exec
[D] none of the above
Answer: Option [A]
(22) Which command is used to extract a column from a text file
[A] paste
[B] get
[C] cut
[D] tar
Answer: Option [C]
(23) Which command is used to display disk consumption of a specific directory
[A] du
[B] ds
[C] dd
[D] dds
Answer: Option [A]
(24) Which command is used to perform backup in unix?
[A] backup
[B] cpio
[C] zip
[D] gzip
Answer: Option [B]
(25) Which command creates an empty file if file does not exist?
[A] cat
[B] touch
[C] ed
[D] read
Answer: Option [B]
(26) Which option of rm command is used to remove a directory with all its subdirectories
[A] –b
[B] –o
[C] –p
[D] –r
Answer: Option [D]
(27) Which command is used to identify file type?
[A] Type
[B] File
[C] Finfo
[D] Info
Answer: Option [B]
(28) Command used to determine the path of an executable file is
[A] which
[B] where
[C] wexec
[D] what
Answer: Option [A]
(29) Command used to count number of character in a file is
[A] grep
[B] wc
[C] count
[D] cut
Answer: Option [B]
(30) Which of these commands could you use to show one page of output at a time?
[A] less
[B] sed
[C] pause
[D] grep
Answer: Option [A]
31 Which commands will give you information about how much disk space each file in the current directory uses?
[A] ls -l
[B] ls -la
[C] du
[D] ls -a
Answer: Option [C]
32 Which of the following command output contains userid?
[A] ls
[B] help
[C] date
[D] ls –l
Answer: Option [D]
33 Which command is used to display all the files including hidden files in your current and its subdirectories ?
[A] ls –aR
[B] ls –a
[C] ls –R
[D] ls –l
Answer: Option [A]
34 Which of the following commands can be used to copy files across systems?
[A] ssh
[B] telnet
[C] rsh
[D] ftp
Answer: Option [D]
35 pwd command displays
[A] user password
[B] password file content
[C] present working directory
[D] none of the mentioned
Answer: Option [C]
36 Which of the following commands can be used to change default permissions for files and directories at the time of creation
[A] Chmod
[B] Chown
[C] Umask
[D] Chgrp
Answer: Option [C]
37 Which tar command option is used to list the files in a tape archive format?
[A] cvf
[B] tvf
[C] xvf
[D] ovf
Answer: Option [B]
38 Which of the following commands will allow the user to search contents of a file for a particular pattern
[A] touch
[B] grep
[C] find
[D] ls
Answer: Option [B]
39 Write the command to display the current date in the form dd/mm/yyyy.
[A] date +%d/%m/%Y
[B] date +”%d/%m/%Y”
[C] date +/%d/%m/20%y
[D] date +”/%d/%m/20%y”
Answer: Option [A]
40 The command syntax to display the file ‘sample.txt’ one page at a time is
[A] man sample.txt>more
[B] cat sample.txt
[C] cat sample.txt|more
[D] None of the above
Answer: Option [C]