How Much Do You Know About Linux? Trivia Quiz

Reviewed by Editorial Team
The ProProfs editorial team is comprised of experienced subject matter experts. They've collectively created over 10,000 quizzes and lessons, serving over 100 million users. Our team includes in-house content moderators and subject matter experts, as well as a global network of rigorously trained contributors. All adhere to our comprehensive editorial guidelines, ensuring the delivery of high-quality content.
Learn about Our Editorial Process
| By Golf_pro90
G
Golf_pro90
Community Contributor
Quizzes Created: 2 | Total Attempts: 379
| Attempts: 127
SettingsSettings
Please wait...
  • 1/85 Questions

    Identify the Linux command that renames a file named oldfile  to  newfile  in current working directory.

    • Cp oldfile newfile
    • Ren oldfile newfile
    • Mv oldfile newfile
    • Touch oldfile newfile
    • None of the above
Please wait...
About This Quiz

Test your knowledge on Linux with this trivia quiz! It covers essential commands and concepts, such as navigation, file operations, and user directory management. Perfect for anyone looking to enhance their Linux skills or prepare for certification exams.

How Much Do You Know About Linux? Trivia Quiz - Quiz

Quiz Preview

  • 2. 

    You use the ______ symbol to mark the beginning of a comment in a script.

    • #

    • $

    • !

    • >

    • None of the above

    Correct Answer
    A. #
    Explanation
    The correct symbol to mark the beginning of a comment in a script is the "#" symbol. This symbol is commonly used in programming languages to indicate that the following text is a comment and should be ignored by the compiler or interpreter. Comments are used to add explanatory notes or documentation to the code, making it easier for other programmers to understand the purpose or functionality of certain sections of the script.

    Rate this question:

  • 3. 

    Which of the following are all valid basic file permissions under Linux?

    • Read, Write, Hidden, Read Only, Execute

    • Read, Hidden, Execute

    • Read, System, Hidden, Archive

    • Read, Write, Execute

    • None of the above

    Correct Answer
    A. Read, Write, Execute
    Explanation
    The correct answer is "Read, Write, Execute." These are the three basic file permissions under Linux. "Read" allows a user to view the contents of the file, "Write" allows a user to modify or delete the file, and "Execute" allows a user to run the file as a program. These permissions can be set separately for the owner of the file, the group that the file belongs to, and other users. The other options listed in the question either include invalid permissions or do not include all three basic permissions.

    Rate this question:

  • 4. 

    ____________ is the symbol used to separate commands in a list, which are executed sequentially.

    • ;

    • >

    • >>

    • &&

    • None of the above

    Correct Answer
    A. ;
    Explanation
    The symbol ";" is used to separate commands in a list, which are executed sequentially. This means that each command will be executed one after the other, in the order they appear in the list.

    Rate this question:

  • 5. 

    Identify the linux command used to display the inode number of /etc/fstab

    • Ls /etc/stab

    • Ls -l /etc/fstab

    • Ls -a /etc/fstab

    • Ls -i /etc/fstab

    • None of the above

    Correct Answer
    A. Ls -i /etc/fstab
    Explanation
    The correct answer is "ls -i /etc/fstab". The "-i" option is used with the "ls" command to display the inode number of a file or directory. In this case, it is used to display the inode number of the /etc/fstab file.

    Rate this question:

  • 6. 

    What value of the variable name total will be displayed after executing the following statements? ((total=0)) for ((num1=1; num1<=3; num++)) do         for ((num2=1; num2<=2; num2++))         do                    for ((num3=10; num3 >=1; num--))                        ((total++))                        done            done done echo $total

    • 20

    • 30

    • 60

    • 120

    • None of the above

    Correct Answer
    A. 60
    Explanation
    The value of the variable total will be 60. This is because the nested loops are executed multiple times. The outer loop runs 3 times, the middle loop runs 2 times, and the inner loop runs 10 times. Each time the innermost loop runs, the total variable is incremented by 1. So, the total variable will be incremented 3 * 2 * 10 = 60 times.

    Rate this question:

  • 7. 

    The command find . -name practice would search from?

    • Root directory

    • Users home directory

    • Parent directory

    • Current directory

    • None of the above

    Correct Answer
    A. Current directory
    Explanation
    The command "find . -name practice" would search for files or directories with the name "practice" in the current directory. The dot (.) represents the current directory in this command.

    Rate this question:

  • 8. 

    The command that displays the name of current shell is ____________________.

    • Echo $SHELL

    • Cat /etc/shells

    • Uname -r

    • Cat /etc/fstab

    • None of the above

    Correct Answer
    A. Echo $SHELL
    Explanation
    The correct answer is "echo $SHELL" because the "echo" command is used to display the value of a shell variable, and "$SHELL" is a built-in environment variable that holds the name of the current shell. By running this command, the name of the current shell will be displayed on the terminal.

    Rate this question:

  • 9. 

    Login as joot, to change to login shell to /bin/csh  for user1, you type ____________.

    • Useradd -s /bin/csh user1

    • Echo $SHELL

    • Usermod -s /bin/csh user1

    • $SHELL=/bin/csh user1

    • None of the above

    Correct Answer
    A. Usermod -s /bin/csh user1
    Explanation
    To change the login shell to /bin/csh for user1, you would use the command "usermod -s /bin/csh user1". This command modifies the user's account information and sets the login shell to /bin/csh.

    Rate this question:

  • 10. 

    Identify the command that is used to delete an existing group in Linux

    • Groupdel

    • Gpasswd

    • Groupmod

    • Userdel

    • None of the above

    Correct Answer
    A. Groupdel
    Explanation
    The command "groupdel" is used to delete an existing group in Linux.

    Rate this question:

  • 11. 

    To immediately shutdown and halt a Linux machien from command line, you should:

    • Log in as root and type: shutdown -h now

    • Log in as root and type: shutdown -r now

    • Log in as root and type: stop linux -1

    • Turn power off and walk away

    • None of the above

    Correct Answer
    A. Log in as root and type: shutdown -h now
    Explanation
    The correct answer is "Log in as root and type: shutdown -h now". This command is used to shutdown and halt a Linux machine immediately. The "-h" option stands for halt, and "now" indicates that the shutdown should happen immediately. Logging in as root is necessary to have the required privileges to execute this command.

    Rate this question:

  • 12. 

    Given the following -rwxr-x-w- 2  paul students    127 Oct 5 13:37 filetwo Who is the owner of filetwo?

    • Paul

    • Students

    • Root

    • Files dont have owners

    • None of the above

    • Devins mom

    Correct Answer
    A. Paul
    Explanation
    The owner of the file "filetwo" is "paul" because "paul" is the first entry in the given file permissions string "-rwxr-x-w-".

    Rate this question:

  • 13. 

    What is the command used to quit without saving in vim?

    • :wq

    • :w

    • :q

    • :q!

    • None of the above

    Correct Answer
    A. :q!
    Explanation
    The command ":q!" is used to quit Vim without saving any changes made to the file. It forcefully exits the editor and discards any unsaved modifications.

    Rate this question:

  • 14. 

    Which of the following uses the bash shell for the command interpreter in a script?

    • /bin/bash

    • #/bin/bash

    • !/bin/bash

    • #!/bin/bash

    • None of the above

    Correct Answer
    A. #!/bin/bash
    Explanation
    The correct answer is "#!/bin/bash". This is because the "#!" symbol at the beginning of a script is called a shebang, and it specifies the interpreter to be used for executing the script. In this case, "/bin/bash" is the path to the bash shell, indicating that the bash shell should be used as the command interpreter for the script.

    Rate this question:

  • 15. 

    __________ is the operator that is used when you want one command to execute only if another command executes successfully.

    • *

    • ||

    • &&

    • >

    • None of the above

    Correct Answer
    A. &&
    Explanation
    The && operator is used when you want one command to execute only if another command executes successfully. This operator is commonly used in programming languages and shell scripting to create conditional statements and control the flow of execution. When the command on the left side of the && operator executes successfully, the command on the right side will be executed. If the command on the left side fails, the command on the right side will not be executed.

    Rate this question:

  • 16. 

    Which of the following commands deletes user1 from /etc/passwd and removes user1's home directory and any files stored in it?

    • Userdel user1

    • Userdel -r user1

    • Usermod -r user1

    • Usermod -d user1

    • None of the above

    Correct Answer
    A. Userdel -r user1
    Explanation
    The correct answer is "userdel -r user1." This command is used to delete a user account and its home directory. The option "-r" stands for "remove," which ensures that the user's home directory and any files stored in it are also deleted. The other options mentioned do not include the "-r" option, so they would not remove the home directory and its files.

    Rate this question:

  • 17. 

    The command that will set an option so a search of substitute ignores cases in vim:

    • :set hls

    • :set hls is

    • :set ic

    • :set noic

    Correct Answer
    A. :set ic
    Explanation
    The correct answer is ":set ic". This command sets the "ignorecase" option in vim, which means that when searching or substituting, the case of the text will be ignored. This allows for more flexible and inclusive searches, as it will match both uppercase and lowercase letters.

    Rate this question:

  • 18. 

    Based on /etc/fstab: /dev/sda1                     /                        ext3                defaults                              1    1 /dev/sda2                     swap                swap              defaults                              0    0 /dev/sda3                    /mnt/new          ext3                noauto                                2    2 /dev/fd0                      /mnt/floppy       ext2                auto, users                         0    0 /dev/cdrom                /mnt/cdrom       iso9660          auto, nouser                       0    0 To successfully mount /dev/cdrom , you should log on as _______.

    • Regular user

    • Root

    • Any user

    • None of the above

    Correct Answer
    A. Root
    Explanation
    To successfully mount /dev/cdrom, you should log on as root. Mounting a device requires administrative privileges, which are typically only granted to the root user.

    Rate this question:

  • 19. 

    What is the result of the following statements? ((g=5)) until [ $g -lt 1 ] do           echo $g          ((g--)) done

    • 5,4,3,2,1 displayed on separate lines

    • 5,4,3,2 displayed on separate lines

    • 4,3,2,1,0 displayed on separate lines

    • Nothing - syntax error

    • None of the above

    Correct Answer
    A. 5,4,3,2,1 displayed on separate lines
    Explanation
    The given code initializes the variable "g" to 5. Then, it enters a loop that continues until the value of "g" is less than 1. Inside the loop, it prints the value of "g" and decrements it by 1. This process continues until "g" becomes 0. Therefore, the result of the code is that the numbers 5, 4, 3, 2, and 1 are displayed on separate lines.

    Rate this question:

  • 20. 

    What is the file that stores encrypted user passwords?

    • /etc/passwd

    • /etc/group

    • /etc/shadow

    • /etc/inittab

    • None of the above

    Correct Answer
    A. /etc/shadow
    Explanation
    The file that stores encrypted user passwords is /etc/shadow. This file is commonly found in Unix-like operating systems and it contains the password hashes for user accounts. The passwords are stored in an encrypted format, providing an extra layer of security. Access to this file is restricted to the root user, ensuring that only authorized individuals can view or modify the password information.

    Rate this question:

  • 21. 

    What command can you use to remove a directory with files in it in Linux.

    • Rm

    • Rm -r

    • Rmdir

    • Rmdir -p

    • None of the above

    Correct Answer
    A. Rm -r
    Explanation
    The command "rm -r" is used to remove a directory with files in it in Linux. The "rm" command is used to remove files, and the "-r" option is used to remove directories recursively, meaning it will remove the directory and all its contents. Therefore, "rm -r" is the correct command to remove a directory with files in it.

    Rate this question:

  • 22. 

    What are the permissions in octal mode of the file fileone, given the file listing below: -rwxr-x-w- 2 steven studends   12 Feb 6 10:37 fileone

    • 421401001

    • Rwxrw-r-x

    • 762

    • 752

    • None of the above

    Correct Answer
    A. 752
    Explanation
    The file listing "-rwxr-x-w-" indicates that the owner has read, write, and execute permissions, the group has read and execute permissions, and others have write permissions. In octal mode, the permissions are represented as follows: read (4), write (2), and execute (1). Therefore, the owner has permissions 7 (4+2+1), the group has permissions 5 (4+1), and others have permissions 2 (2). Thus, the octal mode of the file fileone is 752.

    Rate this question:

  • 23. 

    What is the output of the following? echo "$(pwd)"

    • Current directory

    • Pwd

    • 'pwd'

    • Syntax error

    • None of the above

    Correct Answer
    A. Current directory
    Explanation
    The given command "echo "$(pwd)"" will output the current directory. The "$(pwd)" is a command substitution that will be replaced with the output of the "pwd" command, which stands for "print working directory". Therefore, the output will be the current directory in which the command is being executed.

    Rate this question:

  • 24. 

    You can keep your preferred settings by creating a ________ file in vim.

    • Vimrc

    • Bashrc

    • Man

    • History

    Correct Answer
    A. Vimrc
    Explanation
    In order to keep preferred settings in vim, you can create a "vimrc" file. This file allows you to customize the behavior and appearance of vim according to your preferences. By adding specific configurations and settings to the vimrc file, you can ensure that these preferences are applied every time you use vim.

    Rate this question:

  • 25. 

    Answer based on the output of fdisk -l /dev/sda: Disk /dev/sda: 16/1 GB, 16106127360 bytes 255 heads, 63 sectors/track, 1958 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device                     Boot                   Start                    End                 Blocks                Id                 System /dev/sda1                   *                         1                       1657                 13309821           83                  Linux /dev/sda2                                           1658                   1912                  2048284+          82                  Linux swap/Solaris /dev/sda3                                           1913                   1929                  56227+              5                    Extended /dev/sda5                                           1913                   1914                  16033+             82                   Linux swap/Solaris /dev/sda6                                           1915                   1916                  16033+             83                   Linux /dev/sda7                                           1917                   1919                  24066               83                   Linux The extended partition is __________?

    • /dev/sda1

    • /dev/sda2

    • /dev/sda3

    • /dev/sda5

    • None of the above

    Correct Answer
    A. /dev/sda3
    Explanation
    Based on the output of the fdisk command, the extended partition is /dev/sda3. This can be determined by looking at the "System" column, where the partition with the "Extended" system type is labeled as /dev/sda3.

    Rate this question:

  • 26. 

    What do you type to pause your script for two seconds?

    • Sleep 2

    • Wait 2

    • Pause 2

    • Devins weiner is the size of a leprechauns pinky

    • None of the above

    Correct Answer
    A. Sleep 2
    Explanation
    The correct answer is "sleep 2". In programming, the "sleep" command is used to pause the execution of a script for a specified amount of time. In this case, "sleep 2" means that the script will pause for 2 seconds before continuing with the next line of code.

    Rate this question:

  • 27. 

    Which of the following options for useradd command is used to prevent Linux from creating a group with the same name as username?

    • -N

    • -s

    • -d

    • -G

    • None of the above

    Correct Answer
    A. -N
    Explanation
    The option "-N" for the useradd command in Linux is used to prevent the system from creating a group with the same name as the username. This means that when a new user is added, a group with the same name will not be automatically created. This option is useful when the user wants to have more control over the group creation process and wants to manually manage the groups for each user.

    Rate this question:

  • 28. 

    The Linux command that allows for deleting a directory, but only if it is empty_____________.

    • Mv

    • Del

    • Rm

    • Rmdir

    • None of the above

    Correct Answer
    A. Rmdir
    Explanation
    The correct answer is "rmdir". The "rmdir" command in Linux is used to remove a directory, but it can only delete the directory if it is empty. If the directory contains any files or subdirectories, the "rmdir" command will not work and will display an error message.

    Rate this question:

  • 29. 

    Which of the following commands can be used to verify if user has been created in the file system?

    • Ls /home

    • Ls /root

    • Cat /etc/passwd|grep user1

    • Cat /etc/group|grep user1

    • None of the above

    Correct Answer
    A. Cat /etc/passwd|grep user1
    Explanation
    The command "cat /etc/passwd|grep user1" can be used to verify if a user named "user1" has been created in the file system. The "cat /etc/passwd" command displays the contents of the /etc/passwd file, which contains information about all the users on the system. The "|grep user1" part of the command filters the output and only displays the lines that contain "user1", allowing us to see if the user exists in the file system.

    Rate this question:

  • 30. 

    Login as root and run the following commands: groupadd group1 groupadd group2 useradd user1 useradd -G group1, group2 user3 useradd -G group2, user2 user3 useradd -g group2 user4 gpasswd -a user1 group1 gpasswd -d user2 group2 groups user4 What is the output produced by command: groups user4

    • Group1

    • Group2

    • User3

    • User4

    Correct Answer
    A. Group2
    Explanation
    The output produced by the command "groups user4" is group2. This is because the "groups" command displays the groups that a user belongs to, and in this case, user4 is only a member of group2.

    Rate this question:

  • 31. 

    Given the file permission  rw-r--r-- for a file names script1 , identify the chmod command that adds executable permissions for owner and group and removes read permission from others:

    • Chmod 750 script1

    • Chmod 760 script1

    • Chmod 770 script1

    • Chmod 754 script1

    • None of the above

    Correct Answer
    A. Chmod 750 script1
    Explanation
    The given file permission "rw-r--r--" means that the owner has read and write permissions, the group has only read permission, and others have only read permission. To add executable permissions for the owner and group and remove read permission from others, we need to use the chmod command with the permissions "750". This means that the owner will have read, write, and execute permissions, the group will have read and execute permissions, and others will have no permissions. Therefore, the correct answer is "chmod 750 script1".

    Rate this question:

  • 32. 

    You use the _______ statement to display all the elements in an array named labs.

    • Echo ${labs}

    • Echo ${labs[0]}

    • Echo ${labs[*]}

    • Echo ${labs[#]}

    • None of the above

    Correct Answer
    A. Echo ${labs[*]}
    Explanation
    The correct answer is "echo ${labs[*]}". This statement is used to display all the elements in an array named "labs". The asterisk (*) is used as a wildcard character to represent all the elements in the array.

    Rate this question:

  • 33. 

    Login as root to create a user account based on the following: username: user1 home directory: /home/userone What command should be used?

    • Useradd user1

    • Useradd -d /home/userone -m user1

    • Usermod -d /home/userone -m user1

    • Useradd -s /home/userone user1

    • I just killed your warlock...marklar (none of the above)

    Correct Answer
    A. Useradd -d /home/userone -m user1
    Explanation
    The correct answer is useradd -d /home/userone -m user1. This command is used to create a new user account with the specified username "user1" and sets the home directory to "/home/userone". The -d option specifies the home directory and the -m option creates the home directory if it does not already exist.

    Rate this question:

  • 34. 

    What is the result? for animal in cat dog bear do echo $animal done

    • The words "cat", "dog", "animal", and "bear" are displayed on one line

    • "animal" is displayed

    • "cat", "dog", and "bear" are displayed on separate lines

    • Nothing displays

    • None of the above

    Correct Answer
    A. "cat", "dog", and "bear" are displayed on separate lines
    Explanation
    The correct answer is "cat", "dog", and "bear" are displayed on separate lines. This is because the given code is a loop that iterates through the words "cat", "dog", and "bear" one by one and prints each word on a separate line using the "echo" command. Therefore, the output will be "cat", "dog", and "bear" displayed on separate lines.

    Rate this question:

  • 35. 

    Is the following the correct way of having a loop exit if 'Q' or 'q' was entered? while [  #CHOICE = 'Q' ] || [ $CHOICE = 'q' ]

    • Yes

    • No

    • Devins mom?

    Correct Answer
    A. No
    Explanation
    The given expression in the while loop checks if the variable CHOICE is equal to either 'Q' or 'q'. If it is, the loop will exit. Therefore, the correct answer is "no" because the given expression is the correct way to have the loop exit if 'Q' or 'q' was entered.

    Rate this question:

  • 36. 

    Would the following code in a script file print the contents of the variable $name? echo 'this is my $name'

    • Yes

    • No

    • Maybe so?

    Correct Answer
    A. No
    Explanation
    The code will not print the contents of the variable $name. This is because the variable is enclosed in single quotes within the echo statement, which prevents variable substitution. Therefore, the output will be "this is my $name" instead of the actual value stored in the variable.

    Rate this question:

  • 37. 

    Log in as root, and run the following commands: mkdir ~/test1 cd ~/test1 mkdir -p parent/child touch f1 f2 f3 cp f3 f4 mv f1 f2 f3 ./parent/child cp f4 ./parent/child/f5 cd parent cd ../../ pwd rmdir ~/test1/parent/child rm -r ~/test1/parent How many directories have been created (included deleted directories)?

    • 2

    • 3

    • 4

    • 5

    • None of the above

    Correct Answer
    A. 3
    Explanation
    The correct answer is 3. The directories "test1", "parent", and "child" have been created. The "parent" directory is later deleted, but it was still created at some point. So, a total of 3 directories have been created.

    Rate this question:

  • 38. 

    What is the order of execution to prepare a partition for data storage in Linux?

    • Mount, mkfs, fsck, fdisk

    • Fdisk, fsck, mkfs, mount

    • Fdisk, mkfs, fsck, mount

    • Fsck, fdisk, mount, mkfs

    • None of the above

    Correct Answer
    A. Fdisk, mkfs, fsck, mount
    Explanation
    The correct order of execution to prepare a partition for data storage in Linux is fdisk, mkfs, fsck, mount. First, fdisk is used to create and manage partitions on the disk. Then, mkfs is used to create a file system on the partition. After that, fsck is used to check and repair the file system for any errors. Finally, mount is used to mount the partition and make it accessible for data storage.

    Rate this question:

  • 39. 

    The command that displays all mounted devices ________________.

    • Mount

    • Cat /etc/fstab

    • Fdisk -l

    • Fsck

    • None of the above

    Correct Answer
    A. Mount
    Explanation
    The correct answer is "mount" because the "mount" command is used to display all mounted devices on a system. This command allows the user to see the file systems that are currently mounted and their corresponding mount points.

    Rate this question:

  • 40. 

    The following will execute _______ time(s) for ((num=1; num<=5; num++)) do echo $num done

    • 0

    • 1

    • 4

    • 5

    • None of the above

    Correct Answer
    A. 5
    Explanation
    The given code is a for loop that starts with num=1 and continues until num is less than or equal to 5. In each iteration of the loop, the value of num is printed using the echo command. Since the loop starts with num=1 and continues until num=5, it will execute 5 times. Therefore, the correct answer is 5.

    Rate this question:

  • 41. 

    What must you type in order for child shells to be able to use functions created in the parent shell?

    • Env

    • Export -f

    • Set

    • Name of the function

    • None of the above

    Correct Answer
    A. Export -f
    Explanation
    In order for child shells to be able to use functions created in the parent shell, you must type "export -f". This command exports the specified function to the environment, making it accessible to child shells.

    Rate this question:

  • 42. 

    What special variable is used to determine the exit status of a previously executed command?

    • $#

    • $0

    • $?

    • $9

    • None of the above

    Correct Answer
    A. $?
    Explanation
    The special variable used to determine the exit status of a previously executed command is "$?". This variable holds the exit code of the last command executed, where a value of 0 typically indicates success and any non-zero value indicates an error or failure. By checking the value of "$?", one can determine the success or failure of a command and take appropriate actions based on that.

    Rate this question:

  • 43. 

    Identify the environment variable that defines primary prompt.

    • PS1

    • PS2

    • SHELL

    • HOME

    • None of the above

    Correct Answer
    A. PS1
    Explanation
    The environment variable "PS1" defines the primary prompt in a Unix-like operating system. It specifies the format and content of the command prompt that appears when a user is ready to enter a command. By setting the value of "PS1", users can customize the appearance of their command prompt to suit their preferences or display additional information.

    Rate this question:

  • 44. 

    Which of the following would not place you in your home directory?

    • Cd

    • Cd ~

    • Cd ~/username

    • Cd /home/username

    • None of the above

    Correct Answer
    A. Cd ~/username
    Explanation
    The command "cd ~/username" would not place you in your home directory. This command would attempt to change the directory to a subdirectory named "username" within the home directory. To go directly to the home directory, the correct command would be "cd" or "cd ~". The other options "cd" and "cd /home/username" would also take you to the home directory.

    Rate this question:

  • 45. 

    What happens when you type the following command line at the given command prompt: user1@localhost : ~$ cd .

    • You remain in current directory

    • You change into the parent directory

    • You will get the error message "bash:...:unknown symbol"

    • You will create a directory name ".."

    • None of the above

    Correct Answer
    A. You remain in current directory
    Explanation
    When you type the command "cd ." at the command prompt, it means you are trying to change the directory to the current directory itself. Since you are already in the current directory, there is no need to change directories, so you remain in the current directory.

    Rate this question:

  • 46. 

    Identify the root user accounts home directory in Linux

    • /

    • /root/home

    • /home/root

    • /root

    • None of the above

    Correct Answer
    A. /root
    Explanation
    The root user in Linux has its home directory located at "/root". This is the default location where the root user's personal files and configurations are stored. The other options mentioned ("/", "/root/home", "/home/root") are incorrect as they do not represent the correct path to the root user's home directory.

    Rate this question:

  • 47. 

    Based on /etc/fstab: /dev/sda1               /                    ext3                   defaults         1 1 /dev/sda2             swap              swap                 defaults          0 0 /dev/sda3             /mnt/new       ext3                   noauto            2 2 /dev/fd0               /mnt/floppy    ext2                   auto, users     0 0 /dev/cdrom         /mnt/cdrom    iso9660             auto, nouser   0 0 Which device/partition is not mounted automatically during startup? 

    • /dev/sda1

    • /dev/sda2

    • /dev/sda3

    • /dev/fd0

    • /dev/cdrom

    Correct Answer
    A. /dev/sda3
    Explanation
    The device/partition that is not mounted automatically during startup is /dev/sda3. This is indicated by the "noauto" option specified in the /etc/fstab file for that device/partition.

    Rate this question:

  • 48. 

    Answer based on the output of fdisk -l /dev/sda: Disk /dev/sda: 16/1 GB, 16106127360 bytes 255 heads, 63 sectors/track, 1958 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device               Boot                Start               End                   Blocks                Id               System /dev/sda1            *                        1                 1657                   13309821           83                Linux /dev/sda2                                   1658             1912                    2048284+          82                Linux swap/Solaris /dev/sda3                                   1913             1929                    56227+              5                  Extended /dev/sda5                                   1913             1914                   16033+               82                Linux swap/Solaris /dev/sda6                                   1915             1916                   16033+              83                 Linux /dev/sda7                                   1917             1919                   24066                83                 Linux How many logical drives have been created?

    • 1

    • 2

    • 3

    • 4

    • None of the above

    Correct Answer
    A. 3
    Explanation
    Based on the output of fdisk -l /dev/sda, there are three logical drives that have been created. This can be determined by looking at the number of partitions listed under the "System" column. In this case, there are three partitions listed: /dev/sda1, /dev/sda2, and /dev/sda5. Each of these partitions represents a logical drive that has been created. Therefore, the correct answer is 3.

    Rate this question:

  • 49. 

    Identify the command used to activate a swap partition

    • Fdisk -l

    • Swapon

    • Mkfs

    • Mkswap

    • None of the above

    Correct Answer
    A. Swapon
    Explanation
    The command used to activate a swap partition is "swapon". This command is used to enable swapping on a specified swap device or file. By using the "swapon" command, the system will start using the swap space allocated in the swap partition, allowing for efficient memory management and improving overall system performance.

    Rate this question:

Quiz Review Timeline (Updated): Feb 6, 2024 +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Feb 06, 2024
    Quiz Edited by
    ProProfs Editorial Team
  • Apr 17, 2012
    Quiz Created by
    Golf_pro90
Back to Top Back to top
Advertisement
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.