NDG Linux Essentials 2.21 | Navigating the Filesystem Module 7 | Chapter 07 Exam Answers Full 100% 2023 and 2024

These are questions of Cisco NDG Linux Essentials 2.21 Navigating the Filesystem Chapter 07 Exam Answers full 100% with the latest version and updated in 2023 and 2024. All answers are verified by experts with explanations.

  1. Hidden files are files that begin with what character?

    • A plus (+)
    • An asterisk (*)
    • A period (.)
    • A dash (-)
    • Answers Explanation & Hint:

      Hidden files are files that begin with a period (.) character.

      In Unix-like operating systems, any file or directory whose name starts with a period (.) is considered hidden. These files are hidden from normal directory listings, and they do not appear when you use commands like ls to list the contents of a directory unless you explicitly use options like ls -a to show hidden files. Hidden files are often used to store configuration files, settings, or other data that should not be displayed prominently in regular directory listings to avoid cluttering the output.

  2. What option for the ls command will display all files, including hidden files?

    • -a
    • -H
    • -w
    • -L
    • Answers Explanation & Hint:

      The option for the ls command that displays all files, including hidden files, is -a.

      To see hidden files when using ls, you can use the -a option as follows:

      ls -a
      This will show a listing of all files and directories, including those whose names start with a period (.), which indicates they are hidden files. The -a option stands for “all” in the context of ls and is commonly used to reveal hidden files in the output.
  3. The top-level directory on a Linux system is represented as:

    • /
    • /root
    • /home
    • C:
    • Answers Explanation & Hint:

      The top-level directory on a Linux system is represented as /.

      In the Linux file system hierarchy, the root directory is denoted by a single forward slash (/). It is the starting point of the file system, and all other directories and files are organized under it in a hierarchical manner. The root directory is the highest level in the file system, and it is the parent directory of all other directories on the system. It is equivalent to the root directory on Windows systems, which is represented as C:. However, on Linux, it is simply /.

  4. Is the following path absolute or relative?

    /etc/ppp

    • Absolute
    • Relative
    • Answers Explanation & Hint:

      The following path, /etc/ppp, is an absolute path.

      An absolute path is a complete path that starts from the root directory (/) and specifies the exact location of a file or directory in the file system hierarchy. In this case, the path /etc/ppp starts from the root directory and provides a specific and unambiguous location for the ppp directory. The leading forward slash indicates that the path is absolute.

      On the other hand, a relative path is a path that is specified relative to the current working directory. It does not start from the root directory. For example, if the current working directory is /home/user/, a relative path to ppp would simply be ppp, without the leading forward slash.

  5. Is the following path absolute or relative?

    sysadmin/Documents

    • Relative
    • Absolute
    • Answers Explanation & Hint:

      The following path, sysadmin/Documents, is a relative path.

      A relative path is a path that is specified relative to the current working directory. It does not start from the root directory (/). In this case, the path sysadmin/Documents does not have a leading forward slash, which means it is relative.

      If you are currently in the directory /home/user/, then sysadmin/Documents would refer to the Documents directory within the sysadmin directory, which is a subdirectory of the current working directory. The full absolute path would depend on the current working directory from where you are executing the path. For example, if you are in /home/user/, the full absolute path would be /home/user/sysadmin/Documents.

  6. Is the following path absolute or relative?

    ../../home/sysadmin

    • Relative
    • Absolute
    • Answers Explanation & Hint:

      The following path, ../../home/sysadmin, is a relative path.

      A relative path is a path that is specified relative to the current working directory. It does not start from the root directory (/). In this case, the path starts with .., which indicates moving up two directories from the current working directory.

      Let’s assume the current working directory is /home/user/documents/, then the path ../../home/sysadmin would refer to the sysadmin directory within the /home/ directory, which is two levels above the current working directory.

      The full absolute path would depend on the current working directory from where you are executing the path. For example, if you are in /home/user/documents/, the full absolute path would be /home/sysadmin/.

  7. The tilde (~) is used to represent:

    • The directory above the current working directory
    • Any two single characters
    • A user’s home directory
    • Nothing; it has no special meaning
  8. Which of the following commands can be used to access the home directory of the user “bob” while logged in as root? (choose two)

    • cd &&
    • cd ~bob
    • cd /home/bob
    • ~bob
  9. The double dot (..) can be used with the cd command to represent:

    • The directory above the current working directory
    • A user’s home directory.
    • Nothing; it has no special meaning.
    • Any two single characters
  10. The cd command by itself will take you to what directory?

    • The directory above the current working directory
    • The system root directory
    • Your home directory
    • None; it is not a valid command
  11. What command will allow you to change your current working directory?

    • ls
    • list
    • cd
    • chdir
  12. The double dot (..) can be used to represent the directory…

    • …above the current directory.
    • …with any two single numbers.
    • …below the current directory.
    • …above the current directory only when using the cd command.
  13. The ls command without options or arguments…

    • …generates an error as this command requires arguments.
    • …prompts for a directory to list.
    • …lists the contents of a user’s home directory.
    • …lists the contents of the current directory.
  14. The first character in a long listing (ls -l) indicates:

    • If something is a file, directory, or symbolic link
    • The owner
    • The size
    • The permissions
  15. Which option for the ls command, when used in conjunction with the -l option, will display human-readable file sizes?

    • -M
    • -h
    • -H
    • -S
  16. Which of the following commands will prevent any aliased options to the ls command?

    • /ls
    • %ls
    • `ls
    • \ls
  17. The ls command color codes results by default.

    True or False?

    • True
    • False
  18. The command ls -S will sort files:

    • By size, largest to smallest
    • By size, smallest to largest
    • By number of symlinks, largest to smallest
    • By modification date, newest to oldest
Subscribe
Notify of
guest
0 Comments
Newest
Oldest Most Voted
Inline Feedbacks
View all comments