Topic2: Linux Installation and Package management Flashcards

1
Q

Woodhaven Road

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q
  1. Woodhaven Attic Shelves

cmd used to update the list of available packages when using dpkg based package management

A

apt-get update

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

Top level system directory is used for files and data that change regularly while the system is running and are to be kept between reboots

A

/var/

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

3: Attic Middle Window

command updates the linker cache of shared libraries

A

ldconfig

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

4: Attic Shell Window

function key is used to start Safe Mode in WIndows NT

A

Windows NT does not support Safe Mode

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

5: Attic Middle Window

diff between –remove and –purge action with dpkg cmd

A

–remove removes the program –purge also removes the config files

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

6: Attic Organ

command will disable swapping on a device

A

swapoff

/sbin/swapoff

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

7: Attic Organ Bench

option to the yum command will update the entire system

A

update, upgrade

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

8: Attic Ledge behind Organ

What can Logical Volume Manager (LVM) be used for

A

dynamically change the size of logical volumes

create snapshots

dynamically create or delete logical volumes

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

9: Attic Ledge facing futon

When speaking about mount points

A

every existing directory can be used as a mount point.

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

10: Attic Futon

in which directory must definition files be placed to add additional repositories to yum

A

/etc/yum.repos.d/

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

11: Attic Side Window

Which of the following commands can be used to download RPM package kernel without installing it

A

yumdownloader kernel

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

12: Attic Hole in wall

command lists all currently installed packages when using RPM package management

A

rpm –query –all

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

13: Attic choo choo train

admin issued following cmd

grub-install –root-directory=/custom-grub /dev/sda

in which directory will new config files be found

A

/custom-grub/boot/grub

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

14: Attic Bathroom Sink

world-writeable directory should be placed on a separate partition in order to prevent users from being able to fill up / filesystem

A

/tmp

/var/tmp

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

15: Attic Bathroom Cabinet

what apt-get command will install the newest versions of all currently installed packages without removing any packages or installing new packages that are not already installed.

A

upgrade

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

16: Attic Bathroom Toilet

when removing a package when dpkg option will completely remove the files including configuration files

A

–purge

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

17: Attic Bathroom Shower

what command lists the dependencies of a given dpkg package

A

apt-cache depends package

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

18: Attic Ledge Facing Bathroom

main config file for GNU GRUB

A

menu.lst

grub.conf

grub.cfg

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

19: Attic Stairs

what file should be edited to select the network location from which Debian installation package files are loaded

A

/etc/apt/sources.list

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

20: Attic Door to Second Floor

Debian package management tool asks the config questions for a specific already installed package just as if the package were being installed for the first time.

A

dpkg-reconfigure

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

21: Second Floor Landing

cmd overwrites the bootloader located on /dev/sda without overwriting the partition table or any data following it

A

dd if=/dev/zero of=/dev/sda bs=440 count=1

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

22: Conor’s Closet

dpkg-_____ cmd will ask config questions for a specified package just as if the package were being installed for the first time

A

dpkg-reconfigure

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

23: Conor’s Bed

you want to preview where package file, apacke-xml.i386.rpm will install before installing it - what command do you issue

A

rpm -qpl apache-xml.i386.rpm

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

24: Conor’s Window

cmd can be used to perform a full text search on all available packages on a Debian system

A

apt-cache

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

25: Conor’s Mirrors

after modifying GNU GRUB’s config file which cmd must be run for changes to take effect

A

no action required.

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

26: Conor’s Dresser

option used in GRUB Legacy config file to define the amount of time that GRUB menu will be shown to the user

A

timeout

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

27: Conor’s Shelves

what environment variable will you assign or append a value if you need to tell the dynamic linker to look in a build directory for some of a program’s shared libraries

A

LD_LIBRARY_PATH

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

28: Conor’s Door

what RPM command will output the name of the package that supplied the file /etc/exports

A

rpm -qf /etc/exports

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

29: Landing Outside Conor’s Room

Which of the following environment variables overrides or extends the list of directories holding shared libraries

A

LD_LIBRARY_PATH

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

30: Mick’s Dresser

when using rpm –verify to check files created during the installation of RPM packages what is taken into consideration

A

Timestamps

MD5 checksums

File sizes

32
Q

32: Michael’s Closet

effect of the egrep command when using the -v option

A

it only outputs non-matching lines

33
Q

33: Michael’s Bed

in compliance with the FHS, in which directories are man pages found

A

/usr/share/man

34
Q

34: Michael R Window

file in user home directory used to store Bash history

A

.bash_history

35
Q

35: Michael Center Window

Bash env var defines in which file the user history is stored when the user history is stored when exiting a Bash process

A

HISTFILE

36
Q

36: Michaels Toy Chest

user accidentally created subdirectory \dir in his home directory. Which of the following commands will remove the directory?

A

rmdir ~/\dir

37
Q

37: Michael’s L Window

signal sent to a process when the key combination CTRL+C is pressed on the keyboard

A

SIGINT

38
Q

38: Michael’s Beanbag #1

vi editor how can commands such as moving the cursor or copying lines into the buffer be issued multiple times or applied to multiple rows

A

by specifying the number right in front of a command such as 4l or 2yj.

39
Q

39: Michael’s Beanbag #2

Which grep command will print only the lines that do not ed with a / in the file foo.

A

grep -v ‘/$’ foo

40
Q

40: Michael’s Door

commands that can be used to determine how long the system has been running

A

uptime

top

41
Q

41: landing outside Michael’s door

which characters can be combined with a separator string in order to read from the current input source until the separator string, that is on a separate line and without and trailing spaces is reached

A

«

42
Q

42: Master Bedroom Chest of Drawers

cmd will NOT update the modify timestamp on the file /tmp/myfile.txt

A

file /tmp/myfile.txt

43
Q

42: Master Bedroom Mirrors

which commands replace each occurrence of ‘bob’ in the file letter with ‘Bob’ and writes the result to the file newsletter

A

sed ‘s/bob/Bob/g’ letter > newsletter

44
Q

43: Master Bedroom Ikea Dresser # 1

What does the + symbol mean in the following grep regular expression

grep ‘^d[aei]+d$’ /usr/share/dict/words

A

Match the preceeding character set ([aei]) one or more times

45
Q

44: Master Bedroom Ikea Dresser # 2

vi editor which cmd will copy the current line into the vi buffer

A

yy

46
Q

45: Master Bedroom Ikea Dresser # 3

In Bash, inserting 1>&2 after a cmd redirects

A

standard output to standard error

47
Q

46: Master Bedroom L Window

what command can be used to create a USB storaage media from a disk image

A

dd

48
Q

47: Master Bedroom L nightstand

which of the following commands prints all files and directories within the /tmp directory or its subdirectories that are also owned by the user root

A

find /tmp -user root -print

find /tmp -user root

49
Q

48: Master Bedroom L Lamp

Command that determines the type of file by using a definition database file that contains information about all common file types

A

file

50
Q

49: Master Bedroom Bed

default nice level when a process is started using the nice command

A

10

51
Q
  1. Master bedroom r side table

editing in vi and file changed due to another process. without exiting vi how can the file be reopened for editing with the new content

A

:e

52
Q
  1. R master master bedroom window

regarding nice -5 /usr/bin/prog what is the current nice level

A

5

53
Q
  1. Master bedroom linen closet

cmd searches down a particular number of subdirectories

A

-maxdepth

54
Q
  1. Master bathroom bathtub

max niceness level a regular user can assign to a process with the nice command when executing a new process

A

19

55
Q
  1. Master bath skylight

vi editor save opened document and exits the editor

A

esc ZZ

esc :wq!

56
Q

54, Master bath shower

what is true about cmd foo 1> bar

A

stdout from cmd foo overwrites file bar

57
Q
  1. Master bath toilet

character added to end of a cmd runs that cmd in background as a child process of current shell

A

&

58
Q
  1. Master bath sink # 1

valid reason to run a command in the background of your shell

A

cmd has to be run immediately but the user needs to log out

59
Q
  1. Master bath Mirror # 1

purpose of bash built in export cmd

A

sets up env vars for apps

60
Q
  1. Master bath Sink #2

cmd will print last 10 lines of a text file to standard output

A

tail -n 10 filename

61
Q
  1. Master bath Mirror #2

commands is used to change options and positional parameters

A

set

62
Q
  1. Master Closet Shelves

diff between i and a cmds in vi

A

i (insert) inserts text BEFORE the current cursor position

a (append) inserts text AFTER the cursor

63
Q
  1. Master Closet Back Wall

cmd moves and resumes in background that last stopped shell job

A

bg

64
Q
  1. Master Closet Clothing Rack

for sed -e “s/a/b” /tmp/file > /tmp/file why is the /tmp/file empty afterwards

A

When the shell establishes the redirection it OVERWRITES the target file before the redirected cmd starts and opens it for reading

65
Q
  1. Master Bedroom Dresser

when starting a program with nice cmd without any additional params which nice level is set for the resulting process

A

10

66
Q
  1. Master Bedroom Mirror

cmd prints a list of username (first column) and their primary group (fourth column) from the /etc/passwd file

A

cut -d : -f 1,4 /etc/passwd

67
Q
  1. Master Bedroom Door
A
68
Q
  1. Landing outside Master Bedroom
A
69
Q
  1. 2nd Floor Bathroom sink
A
70
Q
  1. 2nd Floor Bathroom Toilet
A
71
Q
  1. 2nd Floor Bathroom Bath
A
72
Q
  1. 2nd Floor Shower
A
73
Q
  1. 2nd Floor Bathroom Door
A
74
Q
  1. Landing Outside 2nd Floor Bathroom
A
75
Q

74.

A