Install Linux & Basic Commands - Ch1 Flashcards

1
Q

List popular Linux distributions

A

Enterprise Linux:

  • Red Hat Enterprise Linux (RHEL)
  • Oracle Linux
  • CentOS - Community Enterprise Oper Sys
  • Scientific Linux
  • Fedora
  • Debian Linux: Comm pwrd, supports mult vendor hdwr
  • Ubuntu Linux: Debian spinoff
  • SUSE Linux: Commericial
  • OpenSUSE Linux: Comm driven
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

The Linux command prompt consists of what?

A

username
Linux system name
Current directory
Dollar sign $: default shell sign indicating a regular user
Centos command prompt is slightly different and enclosed within square brackets

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

What is the basic syntax of the Linux command?

A

command;
option (switch);
argument (files & other data)

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

A Linux command option is often preceded by what?

A

A hyphen

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

ls

A

Lists files and directories

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

pwd

A

Print working directory : Displays curr location in dir tree

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

cd

A

Change dir

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

cd /

A

Switch to the root dir

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

cd -

A

Cmd switch to previous dir

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

cd ..

A

Move up to parent dir

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

tty

A

Cmd display terminal name you are currently running commands in

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

uptime

A

Show sys curr time, how log it has been up, no of users logged in, avg no of processes over last 1, 5, and 15 min

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

whoami

A

View user login name

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

logname

A

Login name; shows name of real user originally logged in to sys

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

id

A
Displays:
user id (UID);
user name;
group id (GID);
secondary group ids
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

groups

A

Lists all groups a user is a member of

17
Q

uname

A

Displays OS name.

18
Q

uname -a

A

Display OS name with details

19
Q

hostname

A

Display system hostname;

Ex… centos73

20
Q

clear

A

Clears terminal screen

21
Q

gzip

A

Creates a compressed file of each specified files;
Adds .gz extension to each file;
Faster with compression ratio, but not as good as bzip2

22
Q

gzip options;

  • r
  • l
A

-r
Compresses entire directory tree

-l
Instructs the command to display uncompressed filename

23
Q

gunzip

A

Used to decompress .gz files;

Can also use gzip -d to decompress;

24
Q

bzip2

A

Creates compressed file of each specified file;

Adds bz2 extension

25
Q

bzunzip2

A

Decompresses bzip2 compressed files

26
Q

xz

A

Compress files with better compression ratio, but slower than gzip or bzip2;
Adds .xz extension to compressed files

27
Q

unxz

A

Uncompress files compressed with xz;

Can also use xz -d to uncompress

28
Q

tar

A

Tape archive;

Create, append, update, list and extract files or dir tree to form a single tar file

29
Q

man

A

View manual pages

30
Q

man -k

A

Search man pages for keyword following -k

31
Q

–help

A

Display man pages of command following “–help “

32
Q

whatis

A

Display short description of a command or file in man database

33
Q

cpio

A

Copy in/out;

Copy, list and extract files to and from a single archive file