Midterm (Short Answer) Flashcards

1
Q

What is the who command used for?

A

To determine information about who is logged in, use the who command

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Why is the who command important in a multiuser system?

A

In a multiuser system, knowing who is logged in to the system is important for the administrator, so the administrator can periodically verify authorized users and levels of use. Knowing who is logged in is also valuable for ordinary users,who can use that information to judge how busy the system is at a given time or who might want to contact another user.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is the man program?

A

For reference, UNIX/Linux include an online manual that contains all commands, including their options and arguments. The man program in UNIX/Linux displays this online manual, called the man pages, for command-line assistance.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What argument(s) does the man program accept?

A

The man program usually accepts only one argument—the name of the command about which you want more information. The online manual shows the valid command formats that your system accepts.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the cat command and how is it used?

A

The cat command gets its name from the word “concatenate”, which means “to link”. You can display multiple files by entering their file names after the cat command and separating them with spaces. UNIX/Linux then display the files’ contents in the order in which you entered them.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is output redirection (>)?

A

In UNIX/Linux, the greater-than sign (>) is called an output redirection operator. You can use this redirection operator to create a new file or overwrite an existing file by attaching it to a command that produces output. In effect, you redirect the output to a disk file instead of to the monitor.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How is output redirection performed in UNIX/Linux?

A

For example, if you type who > current_users and press Enter, this creates a file called current_users that contains the information from the who command.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

When is output redirection (>) useful?

A

Redirecting output is useful in many circumstances. For example, when you monitor a system, you might redirect output to a file that you can examine later. Or, you might have a program or report-generating utility that manipulates data so that you can redirect the results to a file instead of to the screen.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What command do you use to copy files in UNIX/Linux? How do you use this command?

A

The UNIX/Linux copy command is cp, which is used to copy files from one directory to another. The -i option provides valuable insurance because it warns you that the cp command overwrites the destination file, if a file of the same name already exists. You can also use the dot notation (current directory) as shorthand to specify the destination of a cp command.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Why would you want to set file permissions?

A

Early in computing, people didn’t worry much about security. Stolen files and intrusions were less of a concern, in part because networks were rare and there was no Internet. As you have probably learned through the media, friends, and school, times are different and you need to protect your files. Security is important on UNIX/Linux systems because they can house multiple users and are connected to networks and the Internet, all potential sources of intrusion.

Users can set permissions for files (including directories) they own so as to establish security. System administrators also set permissions to protect system and shared files. Permissions manage who can read, write, or execute files.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is the role of GIDs in UNIX/Linux systems?

A

The system administrator assigns group ids when he or she adds a new user account. A group id (GID) gives a group of users equal access to files that they all share. Others are all other users who are not associated with the owner’s group by a group id, but who have read and execute permissions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly