LPI Part 2 Flashcards

1
Q

/etc/group

A

A text file which defines the groups to which users belong

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

GID

A

Group ID
Each user must be assigned a group ID. You can see this number in your /etc/passwd file

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

id

A

Used to find out user and group names and numeric ID’s (UID or group ID) of the current user or any other user in the server

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

id information

A

-User name and real user id.
-Find out the specific Users UID.
-Show the UID and all groups associated with a user.
-List out all the groups a user belongs to.
-Display security context of the current user.

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

last

A

Displays information about the last logged-in users.
Takes the system log file /var/log/wtmp as the data source to generate reports.

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

who

A

Displays information about currently logged-in users.
-Time of last system boot
-Current run level of the system
-List of logged-in users and more.

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

w

A

Displays important information about who is currently using the computer, how much the computer is being used, and what programs are running.
Syntax: w [options] user […]

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

/etc/skel

A

A directory that contains files and directories that are automatically copied over to a new user’s when it is created from useradd command.

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

useradd

A

Used to add user accounts to your system.
Syntax: useradd [options] [user_name]

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

useradd -u

A

Creates a new user with a custom UID

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

useradd -g

A

Creates a new user and assigns a specific group ID

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

useradd -M

A

Creates a new user without a home directory

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

groupadd

A

Used to create groups.
Syntax: groupadd [options] group_name

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

groupadd -f

A

Forces the command to abort silently if the group with the given name already assists

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

groupadd -g

A

This option assigns a specific numeric group id to the newly created group

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

groupadd -r

A

Creates a system group

17
Q

passwd

A

Modifies user passwords
Syntax: passwd [options] [username]

18
Q

passwd -d

A

Deletes the user password, making the account password-less.

19
Q

passwd -e

A

Immediately expires the account password, prompting the user to change it on the next login.

20
Q

passwd -i

A

Sets the number of days after password expiration before the account is deactivated.

21
Q

chmod

A

Used to change the access mode of a file.
Syntax: chmod [options] [mode] [File_name]

22
Q

chmod -R

A

Apply the permission change recursively to all the files and directories within the specified directory.

23
Q

chmod -v

A

It will display a message for each file that is processed. while indicating the permission change that was made.

24
Q

chmod Operators

A

+ Add permissions
- Remove Permissions
= Set the permissions to the specified values

25
Q

chmod Reference List

A

u = Owner
g = Group
o = Others
a = All

26
Q

chmod Example

A

chmod u+rw,go+r [file_name]

27
Q

chmod Octal Mode

A

First digit specify the permission for Owner.
Second digit specify the permission for Group.
Third digit specify the permission for Others.

28
Q

Octal Mode Digit Values

A

4 Read Permission
2 Write
1 Execute

29
Q

ln

A

Used to create hard links between files

30
Q

ln -s

A

Used to create soft links between files

31
Q

/tmp/

A

Used to store the data used by the system and user applications to store the data that are needed for a short period of time. Most Linux distributions are preconfigured to empty the tmp directory after each reboot.

32
Q

/var/tmp/

A

Used to store data by the system on physical storage, use this for longer term tmp files.

33
Q
A