Linux Questions

Practice Linux MCQs with answers and explanations. Page 1 of 7.

Category
Computer Science
Topic
Linux
Page
1 / 7
Mode
Practice

Questions

Open any question to view the answer and explanation.

On Unix/Linux, which command counts the total number of lines, words, and bytes/characters in a file in one invocation?
Open
View answer
Which protocol from the options allows a user to retrieve email from a mail server to a local mail client (mail reader)?
Open
View answer
Within Network Information Service (NIS), which client-side component discovers and binds to an NIS domain/server and maintains that binding?
Open
View answer
According to the OSI reference model, which layer is Layer 1 responsible for transmitting raw bits over a physical medium?
Open
View answer
On Unix/Linux systems that use Name Service Switch (NSS), which configuration file specifies the order and sources (for example, files, DNS, NIS) for lookups like hosts and passwd?
Open
View answer
With TCP Wrappers on Unix/Linux, in which access control file would you allow all services for all hosts (for example, by placing 'ALL: ALL')?
Open
View answer
In classful IPv4 addressing, how many networks and how many hosts per network does a Class B address support (usable hosts)?
Open
View answer
On Red Hat–style Linux systems that use RPM, how would you correctly install the package file named ipchains-1.3.9-5.i386.rpm from the local filesystem?
Open
View answer
On a typical Linux system, which tools can be used to add a new local user account named 'Amit' (considering common distributions and admin utilities)?
Open
View answer
In traditional BSD-style printing on Unix/Linux, which command submits a print job (adds it to the printer queue)?
Open
View answer
Within the OSI networking model, which layer is responsible for dialogue control and token management between communicating hosts?
Open
View answer
On Unix/Linux command lines, which command is typically used to list the contents of directories (filenames, optionally with details)?
Open
View answer
On a typical Linux console (outside X11/Wayland), how do you switch among the multiple virtual consoles provided by the system?
Open
View answer
When creating a Linux installation boot floppy from an image, which tools are commonly used on Unix/Linux and on DOS/Windows respectively?
Open
View answer
On Unix/Linux, which command is designed to copy directory structures in and out of archives or between devices while preserving metadata and hierarchy?
Open
View answer
On Linux systems, in which directory are the default skeleton files stored that are copied into a new user's home directory at account creation time?
Open
View answer
In the vi editor, which motion command moves the cursor backward to the beginning of the previous word segment?
Open
View answer
In a Unix/Linux command-line session, which symbol is used to erase (kill) the entire line you have typed and keep you on the same command line without printing a new prompt?
Open
View answer
On a Linux system, which of the following is a valid command format for mounting a CD-ROM so that its ISO 9660 filesystem is accessible at /mnt/cdrom?
Open
View answer
On Red Hat–style Linux systems, which file is the primary Apache HTTP Server configuration file used to define global directives, virtual hosts, and modules?
Open
View answer

Practice smarter

Solve a few questions daily and revisit weak topics regularly to improve accuracy.