Module 9 Flashcards
When will the following entry in the user crontab be executed?
1 2 3 4 * /bin/go_catch_Pokemon
- 1:02 am on March 4
- January 2nd at 3:04 am
- Monday, February 3rd at 4:00 am
- 1 minute after 2 am on the 3rd of April
- 1 minute after 2 am on the 3rd of April
How do you bring the “sleep 500” process to the foreground?
[user1@okuda 145]$ jobs
[1] Running sleep 400 &
[2]- Running sleep 500 &
[3]+ Running sleep 600 &
- $ %
- $ fg %2
- Type CTRL+z followed by fg and press the enter key.
- $ fg sleep 500
- $ fg %2
Which one is NOT a Linux scheduling tool?
- anat
- at
- anacron
- cron
- anat
How do you place a command that’s running in the foreground into the background?
- Type CTRL+b followed by bg and press the enter key.
- Type CTRL+c followed by bg and press the enter key.
- Type CTRL+d followed by bg and press the enter key.
- Type CTRL+z followed by bg and press the enter key.
- Type CTRL+z followed by bg and press the enter key.
When the same program is executed twice it will have the same PID.
- True
- False
- False
What value will be displayed at (1) and (2)?
$ ls file1 (file1 exists) $ echo "$?" (1) $ ls file2 (file2 does not exist) $ echo "$?" 2 $ echo "$?" (2)
- (1) 0, (2) 0
- (1) 0, (2) 2
- (1) 1, (2) 2
- (1) $1, (2) $2
- (1) 0, (2) 0
A process may have multiple parent processes.
- True
- False
- False
How do you start a sleep command to run in the background?
- $ bg | sleep
- $ sleep | bg
- $ sleep %
- $ sleep &
- $ sleep &
How do you display the background processes running in the current shell?
- $ lsbg
- $ jobs
- $ ps -bg
- $ bg -l
- $ jobs
Find the match.
SIGHUP
SIGINT
SIGKILL
SIGTERM
SIGHUP 1
SIGINT 2
SIGKILL 9
SIGTERM 15
Every process has a process ID and a_______.
- fork process
- daemon
- child process
- parent process ID
- parent process ID
A process spawning or initiating another process is referred to as _____.
- a child process
- forking
- branching
- parenting
- forking
What command is used to view and modify user jobs scheduled to run with cron?
- crontab
- cron
- ps
- sched
- crontab
What is the name given to a process not associated with a terminal?
- child process
- parent process
- user process
- daemon process
- daemon process
The pkill command terminates _________.
- all instances of a process with the same PPID
- all instances of a process with the same PID
- all instances of a process with the same priority
- all instances of a process with the same name matched by a regular expression
- all instances of a process with the same name matched by a regular expression
Which of the following statements is true? (Choose all that apply.)
- If /etc/at.allow exists, only users listed in it can use the at command.
- If /etc/cron.allow exists, only users listed in it can use the cron command.
- If /etc/cron.deny exists and /etc/cron.allow does not exist, any user not listed in /etc/cron.deny can use the cron command.
- If /etc/cron.allow and /etc/cron.deny exist, only users listed in the former can use the cron command and any listed in the latter are denied access to the cron command.
- If a user is listed in both /etc/cron.allow and /etc/cron.deny, then /etc/cron.deny takes precedence and the user cannot access the crontab command.
- If /etc/at.allow exists, only users listed in it can use the at command.
- If /etc/cron.allow exists, only users listed in it can use the cron command.
- If /etc/cron.deny exists and /etc/cron.allow does not exist, any user not listed in /etc/cron.deny can use the cron command.
A runaway process that is faulty and consuming mass amounts of system resources ________.
- is a zombie process
- is an orphaned process
- has a PPID of Z
- is a rogue process
- is a rogue process
Which process has a PID of 1 and a PPID of 0?
- the kernel itself
- ps
- init/systemd
- top
- init/systemd
What kill level signal cannot be trapped?
- 1
- 9
- 3
- 15
- 9
The at command is used to _______________.
- schedule processes to run periodically in the background
- schedule processes to run periodically on a recurring basis in the future
- schedule processes to run at a single instance in the future
- schedule processes to run in the foreground
- schedule processes to run at a single instance in the future