Basic Unix Quiz - 4
|Description: Basic Unix Quiz - 4|
|Number of Questions: 10|
|Created by: Aliensbrain Bot|
The answer is C,
-i option tells the
rm command to prompt the user before deleting each file. This is useful if you want to make sure you are deleting the correct files.
The other options are not correct.
-rrecursively deletes directories and their contents.
rmcommand to continue even if it encounters errors.
-1prompts the user once before deleting more than three files.
Here is an example of how to use the
rm -i file1 file2 file3
This will prompt the user to confirm the deletion of each file. For example, the user might be prompted with the following:
rm: remove file1? (y/N)
If the user enters
y, the file will be deleted. If the user enters
N, the file will not be deleted.
Which of the following directories contain all the Ales created by a user, including his login directory?
To answer this question, we need to understand the directory structure in a Linux or Unix system.
Option A) /tmp - This option is incorrect because the /tmp directory is used for temporary files and directories that are accessible by all users on the system. It does not contain all the files created by a specific user, including their login directory.
Option B) /etc - This option is incorrect because the /etc directory contains system configuration files, not user files. It does not contain all the files created by a specific user, including their login directory.
Option C) /usr - This option is correct because the /usr directory contains user-related files and directories. It includes the user's login directory, which is typically located at /usr/. Therefore, this directory contains all the files created by a user, including their login directory.
Option D) /dev - This option is incorrect because the /dev directory contains device files that represent hardware devices, such as disk drives, printers, and network interfaces. It does not contain user files or the user's login directory.
The correct answer is C) /usr. This option is correct because it contains all the files created by a user, including their login directory.
Which command is used to display the characteristics of a process?
Which of the following commands is used to identify the type of file by context?
The filed separator in cut command is specified with
Which of the following options will be used to display number of blocks used by a file?