This is part two of Linux commands multiple choice questions. These quizes should get you up to scratch for any Linux certificate, college module, etc. Just repeat the quiz over and over until you get 90% + and you will surely be ahead of the rest at exam time.
Ls and df
Ps and top
Ps and df
Df and top
Du and df
Rate this question:
An extended partition on a SCSI disk drive
A logical partition on a SCSI disk drive
An extended partition on an IDE disk drive
A primary partition on an IDE disk drive
A logical partition on an IDE disk drive
Rate this question:
Head -b file1
Head --bottom file1
Head -v file1
Tail file1
Tail -n 1 file1
Rate this question:
Ctrl-P and Enter
Ctrl-N and Enter
Ctrl-U and Enter
!-2
!2
Rate this question:
Fsck -ext2 /dev/hda5
Fsck /dev/hda5
E2fsck /dev/hda5
Fsck.ext2 /dev/hda5
Fsck.linux /dev/hda5
Rate this question:
Files on /home are consuming 98% of the physical disk.
File read/write activity on /home is consuming 98% of system I/O capacity.
Files on /home are consuming 98% of the /home filesystem.
Inodes on /home are nearly exhausted.
Inodes on /home are 98% free.
Rate this question:
/var
/tmp
/usr
/root
/etc
Rate this question:
The first four columns in the text are written to new files glaa, glab, glac, and glad.
The first four columns in the text are written to new files aagl, abgl, acgl, and adgl.
The lines of guest_list are evenly divided among new files glaa, glab, glac, and glad.
The lines of guest_list are evenly divided among new files glaa, glab, and glac.
The lines of guest_list are evenly divided among new files aagl, abgl, and acgl.
Rate this question:
Mount /dev/cdrom /dev/hdc
Mount -f linux /dev/hdc /mnt/cdrom
Mount -t iso9660 /dev/cdrom /mnt/cdrom
Mount -t linux /dev/cdrom /mnt/cdrom
Mount -t iso9660 /mnt/cdrom /dev/cdrom
Rate this question:
The write will fail, but the superuser can recover the entire file within seven days.
The write will fail, and the file will be truncated permanently.
The write will succeed, but the file will be truncated permanently.
The write will succeed, but the file will be available for only seven days.
The write will succeed, but the file will be truncated in seven days.
Rate this question:
Find "^#" /etc/rc.d/rc.local
Sed '/^#/ !d' /etc/rc.d/init.d/httpd
Grep ^# /etc/rc.d/init.d/httpd
Grep ^# /etc/passwd
Locate "^#" /etc/skel/.bashrc
Rate this question:
VAR1="fail" ; export VAR1
VAR1="fail" \ export VAR1
VAR1="fail"
Set VAR1="fail" ; enable VAR1
Export VAR1 \ VAR1="fail"
Rate this question:
Cmd1 | cmd2
...
Rate this question:
/etc
/home
/lib
/usr
/root
Rate this question:
Afile1 Afile1 Afile1 Afile1
Ls Afile1 Afile1 Afile1
Ls ls Afile1 Afile1
Ls ls $MYVAR Afile1
Ls ls ls $MYVAR
Rate this question:
It allows another command to be entered on the same line.
It causes the process to be stopped.
It restarts a stopped process.
It causes the process to be placed into the foreground.
It causes the process to be placed into the background.
Rate this question:
Grep
Egrep
Wc
Tr
Pr
Rate this question:
0
1
2
Undefined
Unknown
Rate this question:
The SUID bit will be set for /home/software.
The SGID bit will be set for /home/software, preventing access by those not a member of the software group.
The SGID bit will be set for /home/software, in order to keep group membership of the directory consistent for all files created.
The sticky bit will be set for /home/software.
The sticky bit will be applied to all files in /home/software.
Rate this question:
Chmod u=rwx,g=rx,o=r /home/jdoe/file1
Chmod ugo=rwx ~/file1
Chmod u=7,g=5,o=4 ~/file1
Chmod 754 \home\jdoe\file1
Chmod 754 /usr/jdoe/file1
Rate this question:
Ln -s
...
Rate this question:
Xd
Hd
Od
Xd
Dump
Rate this question:
Mv --copy /dir1/*.txt /dir2
Mv /dir1/*.txt /dir2
Cp -k /dir1/*.txt /dir2
Cp -p /dir1/*.txt /dir2
Cp -p /dir2 < /dir1/*.txt
Rate this question:
[L/linux]
?inux
\L\linux
[Ll]inux
[Ll]inux?
Rate this question:
Kill -9 4077
Kill -1 4077
Kill +9 4077
Kill 4078
Kill --die 4077
Rate this question:
Ctrl-C
Ctrl-B
Ctrl-B and then enter the bg command
Ctrl-Z
Ctrl-Z and then enter the bg command
Rate this question:
Fdisk.
...
Rate this question:
0750
0640
0027
1027
1640
Rate this question:
Tar cvf /dev/st0
Tar cvf /dev/ttyS0
Tar xvf /dev/st0
Tar xvf /dev/ttyS0
Tar rvf /dev/st0
Rate this question:
Put alias cp='cp -i' in ~/.bashrc.
Put alias cp='cp -i' in ~/.bash_profile.
Put alias cp='cp -p' in ~/.bashrc.
Put alias cp='cp -p' in ~/.bash_profile.
Put alias cp='cp -I' in ~/.bashrc.
Rate this question:
Tar
Wc
Tr
Nl
Ln
Rate this question:
It matches all letters and numbers.
It matches all letters and numbers except 9.
It matches all letters and numbers except 9 and 0, but only at the beginning of a line.
It matches 9, 0, and other nonletter and nonnumber characters.
It matches characters other than letters or numbers.
Rate this question:
Accounts jdoe and bsmith have no passwords.
Accounts jdoe and bsmith are disabled.
The passwords are in /etc/passwd-
The passwords are in /etc/shadow
The passwords are in /etc/shadow-
Rate this question:
Init 5. telinit 5 would also work, as they are both links to the same file.
...
Rate this question:
It prevents files from being deleted by anyone.
It marks files for deletion.
It prevents files from being deleted by nonowners except root.
It prevents files from being deleted by nonowners including root.
It marks files for archive.
Rate this question:
Enter linux eth0=irq11 at the LILO boot loader prompt.
Enter linux 3c509=irq11 at the LILO boot loader prompt.
Add options 3c509 irq=11 to /etc/conf.modules.
Add options irq=11 3c509 to /etc/conf.modules.
Add ifup -irq 11 eth0 to /etc/rc.d/rc.sysinit.
Rate this question:
Commands needed in the event of a system emergency of interest to all system users.
Commands of interest to all system users.
Commands needed in the event of a system emergency of interest mainly to the administrator.
Commands of interest mainly to the administrator.
Libraries needed in the event of an emergency.
Rate this question:
SUID.
...
Rate this question:
Nice.
...
Rate this question:
Cat displays files and tac does the same but in reverse order.
Cat concatenates files while tac splits a file into pieces.
Cat creates file catalogs while tac displays the catalogs.
The two commands are links to the same executable.
There is no relation or similarity between cat and tac.
Rate this question:
They are standard text characters used in the regular expression.
They are special control characters used in the regular expression.
They are used to display results after using a regular expression.
They are used by the shell to display graphics.
Metacharacters aren't used in regular expressions.
Rate this question:
1
2
3
4
5
Rate this question:
Du -s
Du -k
Df -h
Df -k
Df -m
Rate this question:
More inodes would be automatically created in the filesystem.
Quotas would become disabled on the filesystem.
The filesystem would be corrupted.
The filesystem would be marked read-only.
No writes would be possible on the filesystem until existing files were deleted.
Rate this question:
It can start the Windows NT Loader.
It is started using the lilo command.
It is the only boot loader available for Linux.
It can start multiple Linux kernels, but no foreign operating systems.
It resides entirely in the boot sector.
Rate this question:
> appends standard output to an existing file, and >> writes standard output to a new file.
> writes standard output to a new file, and >> appends standard output to an existing file.
> writes standard error to a new file, and >> appends standard error to an existing file.
> pipes standard output to a new file, and >> pipes standard output to an existing file.
> pipes standard output to an existing file and >> pipes standard error to a new file.
Rate this question:
Dpkg -r mypkg
Dpkg --remove mypkg
Dpkg --kill mypkg
Dpkg -R mypkg
Dpkg --purge mypkg
Rate this question:
Error -1 has occurred during X startup
Only the default font will be available to applications
An X font server is to be used
An X font server failed to initialize
No fonts were found by XFree86 or by a font server
Rate this question:
Dpkg -s mypkg
Dpkg -S mypkg
Dpkg -stat mypkg
Dpkg --stat mypkg
Dpkg --Status mypkg
Rate this question:
An X server is a high-performance system offering graphical programs over a network.
An X server sends its graphical output to a window manager.
An X server is under the control of a window manager.
A window manager is under the control of an X server.
A window manager is also known as an X server.
Rate this question:
Quiz Review Timeline +
Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.
Wait!
Here's an interesting quiz for you.