Ch2

Ace your homework & exams now with Quizwiz!

*Lab 2.2.4 Get Help 1* According to the command help, which of the following options can be added to the killall command to kill a process group instead of just a process? Type killall -h or killall --help at the prompt to answer this question.

-g

A user has requested that each time she presents credentials to log in, a particular entry be written to a log file. This action will only apply to her, and she is using the bash shell. Which of the following configuration files is the BEST to modify to enable this action?

.profile

*Lab 2.8.8 Find a Hidden Directory* Type ls -a /hr at the prompt to answer the question. What is the name of the hidden directory in /hr?

.sanford

Which of the following paths represents the root directory?

/

*Lab 2.9.7 View a List of Available Shells* The /etc/shells file contains a list of shells that are available on the current system. Type cat /etc/shells at the prompt to answer the following questions. Which of the shells listed below is not available on the system?

/bin/ksh

Under the Filesystem Hierarchy Standard (FHS), what is the full path to the directory that contains the device files for a Linux system?

/dev

*Lab 2.10.5 Create a Symbolic Link*

1. At the prompt, type ln -s /root/imitator /home/mbrown/imitator_link. 2. Press Enter to create the symbolic link.

*Lab 2.10.4 Create a Hard Link*

1. At the prompt, type ln /home/wadams/contacts.db /home/bcassini/contacts_link and press Enter. 2. Type ln /home/wadams/contacts.db /home/vedwards/contacts_link and press Enter.

*Lab 2.3.5 Create a New File*

1. At the prompt, type vi /etc/pref_shell and press Enter to open the file. 2. Press a to edit the file. 3. Move the cursor to the line SHELL=/bin/csh and insert a t to make the line read SHELL=/bin/tcsh. 4. Press the Esc key. 5. Type :wq and press Enter to save the changes and exit.

which of the following is the standard shell for MOST Linux computers?

Bourne-again shell (bash)

*Lab 2.5.4 View Environment Variables* Which values are set for the following environment variables? Type echo $variable at the prompt to answer the question. The variables are case sensitive.

HOME: /root LANG: en_US.UTF-8 SHELL: /bin/bash TERM: linux

Which of the following statement describes file globbing?

Using wildcards to match specific files.

Which of the following commands creates a shortcut that can be used to run the tail -f tail -f var/log/messages command?

alias sysmesg="tail -f /var/log/messages"

which of the following commands sorts the combined contents of the wordlist1 and wordlist2 files and sends the results to both the screen and a file named sortedwordlist?

cat /usr/wordlist1 /usr/wordlist2 | sort | tee sortedwordlist

Which of the following commands merges two files on a line-by-line basis and separate each line with a tab?

paste


Related study sets

ch 12 ( nursing care of patients having surgery)

View Set

Grey's Anatomy - Practice Questions

View Set

Pediatrics Capstone Pre-Assessment Quiz

View Set