Linux commands Flashcards

1
Q

What command is used to number lines in terminal output?

A

nl (number lines)

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

What command lets you rename files?

A

mv (move)

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

What command lets you delete files?

A

rm (remove)

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

What command lets you view file/directory permissions?

A

ls -l or ll

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

What character lets you run multiple commands on one line?

A

; semicolon

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

How do you feed the output of one command as the input of another?

A

use the pipe | symbol.

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

What command is used to search through directories?

A

find

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

How to search through all directories recursively?

A

find / -name. This starts at root.

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

what command lets you change passwords?

A

passwd {user}

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

What command lets you organize the terminal output?

A

sort

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

What characters let you funnel a commands output into a recording file?

A

> ,&raquo_space;, 2>, 2», &>, &»

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

What is the command for finding regular expressions?

A

grep

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

What are some useful options for grep and what do they do?

A

-i : ignores case
-v : outputs lines without the regex.
-n : numbers the lines
-l
-o : print only the matching part of a line
-r : searches directories recursively.

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

top

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

ps

A

Lists all processes currently running.

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

What are some of the options for ps and what do they do?

A

c:
A:
l:

17
Q

What are some of the network utilities in Linux?

A

ifconfig
route
ping
traceroute
dig
netstat
ssh

18
Q

dig

A

displays results from DNS serversn

19
Q

netstat

A

display network statistics …

20
Q

ssh

A

allows a user to login to a remote machine.

21
Q

traceroute

A

Displays the routed network path between a client and its destination

22
Q

ifconfig

A

Display interface config information

23
Q

ping

A
24
Q

change

A

Used to change password aging settings for a user

25
Q

date

A

displays current date and time

26
Q

cal/ncal

A

displays the current calendar with numerous options.w

27
Q

who

A

Gives information about users. Related commands are whoami and who am I.

28
Q

what are the permissions symbols?

A

r: read
w: write
x: execute

29
Q

What methods can be used to change permissions?

A

The command to change permissions is chmod. You can change it using permissions symbols by using the desired viewer’s symbol (u, g, o, a), an operator, then the permissions symbols you want to add or remove (ex. go+rw). It can also be done numerically with numbers 1-7. Think of rwx as binary, with x in the 1 space, w in 2, and r in 4.

30
Q
A