Self Test


The following questions will help you measure your understanding of the material presented in this chapter. Read all the choices carefully because there might be more than one correct answer. Choose all correct answers for each question.

1. 

Which of the following commands can you use to display the process information that will be updated periodically?

  1. pgrep

  2. ps

  3. plist

  4. prstat

image from book

2. 

In the output of the ps command the S field for a running process will display which of the following values?

  1. O

  2. R

  3. S

  4. A

  5. Running

image from book

3. 

Which of the following commands will display all the processes that go in the process argument string?

  1. ps -ef grep go

  2. pgrep -l -f go

  3. ps -a go

  4. prstat go

image from book

4. 

Which of the following commands will kill a process with process ID 24387 and process name pass 2?

  1. kill 24387

  2. kill pass2

  3. pkill 24387

  4. pkill pass2

image from book

5. 

Which of the following commands or actions will kill the process with process ID 24387 and let it clean up after itself?

  1. Kill -9 24387

  2. Kill -15 24387

  3. sigterm 24387

  4. Press CTRL-D

image from book

6. 

Which of the following commands can you use to schedule a command to be executed repeatedly?

  1. crontab

  2. at

  3. cron

  4. run

image from book

7. 

Which of the following entries in a crontab file instructs the system to execute the diskchecker script at 9:10 A.M. each Sunday and Tuesday?

  1. 0 2 * * * 9:10 /etc/cron.d/diskchecker

  2. 10 9 * * * 0,2 /etc/cron.d/diskchecker

  3. 10 9 * * * 1,3 /etc/cron.d/diskchecker

  4. 9 10 * * * 0,2 /etc/cron.d/diskchecker

image from book

8. 

When you installed the SunOS software, you deleted the cron.deny file that the system created, and you did not create a cron.allow file. Which of the following is true?

  1. All users have access to the crontab command to manage all the crontab files.

  2. No user except the superuser has access to the crontab command.

  3. All users have the permission to use the crontab command only to manage their own crontab files.

  4. Users can edit their crontab files but cannot remove them.

image from book

9. 

Which of the following is a correct statement? (Choose all that apply.)

  1. If neither the cron.allow, nor the cron.deny file exists, no user without superuser privilege can have access to the crontab command.

  2. If neither the users.allow, nor users.deny file exists, no user except the superuser has access to a printer on the system.

  3. When you install the Solaris OS software, a cron.deny file is created automatically,

  4. When you install the Solaris OS software, a cron.allow file is created automatically.

image from book

10. 

How do you configure the print service on Solaris? (Choose all that apply.)

  1. Edit the configuration files underneath the directory /etc/lp/printers.

  2. Use the lpadmin command.

  3. Use the lpsched command.

  4. Use the printerconfig command.

image from book

11. 

The CEO of your company complains that she cannot print a web page. You suspect a problem with the print server and want to ensure that the listener service for the web print requests is running. What is the name of this service?

  1. http-listener

  2. ipp-listener

  3. ippd

  4. http-listen

image from book

12. 

You discover that the print scheduler, lpsched, has stopped on your system. Which SMF command would you issue to restart the scheduler?

  1. svcs enable svc:/application/print/server

  2. svcadm start svc:/application/print/server

  3. svcadm enable svc:/application/print/lpsched

  4. svcadm enable svc:/application/print/server

image from book

Answers

1. 

þ D. The prstat command refreshes the output at a specified interval.

ý A and B are incorrect because the pgrep and ps commands take a snapshot of the system and do not update the output. C is incorrect because plist is not a command.

2. 

þ A. The state O indicates that the process is running.

ý B is incorrect because R means the process is runnable —that is, in the queue for running. C is incorrect because S means the process is sleeping. D and E are incorrect because there are no state values A and running.

3. 

þ A and B. The ps command with -f option generates the full listing of the processes, and the grep command selects the process from the output whose argument string contains the string go. The pgrep command accomplishes the same thing.

ý B is incorrect because R means the process is runnable—that is, in the queue for running. C and D are incorrect because the ps and prstat commands are being used with the wrong syntax.

4. 

þ A and D. You use the process ID in the kill command and the process name in the pkill command.

ý B and C are incorrect because you use the process ID in the kill command and the process name in the pkill command.

5. 

þ B. Signal 15 kills the process and gives it a chance to clean up after itself.

ý A is incorrect because signal 9 kills the process without giving it a chance to clean up after itself. C is incorrect because it is the wrong command syntax. D is incorrect because pressing CTRL-C will interrupt the process but will not kill it.

6. 

þ A. The crontab command is used to edit a crontab file in which you can enter a command that you want to execute repeatedly.

ý B is incorrect because the at command is used to schedule a command to be executed at a future time only once. C and D are incorrect because there are no such commands as cron or run to schedule a process.

7. 

þ B. This is the correct use of the command. This first field is minute, the second field is hour, and the last field represents days: 0 for Sunday and 2 for Tuesday.

ý A is; incorrect because the first two fields have the wrong values for the minute and the hour, and the last field has the value in the wrong format. C is incorrect because it will schedule the job for Monday and Wednesday. D is incorrect because it will schedule the job at 10:09 A.M., not 9:10 A.M.

8. 

þ B. When neither the cron.allow nor the cron.deny file exists, only the superuser has access to the crontab command.

ý A is incorrect because no user except the superuser ever has access to all the crontab files. You need to be a superuser to access other users' crontab files. C and D are incorrect because when neither cron.allow nor cron.deny exists, no user except the superuser has access to any crontab file.

9. 

þ A and C. When neither the cron.allow nor the cron.deny file exists, only the superuser has access to the crontab command, and the cron.deny file is created during installation.

ý B is incorrect because each user has access to printers on the system if neither the users.allow nor the users.deny file exists. D is incorrect because only the cron.deny file, not the cron.allow file, is created during the Solaris OS software installation.

10. 

þ B. You use the lpadmin command to configure the LP print service.

ý A is incorrect because you should not edit the configuration files directly. C is incorrect because the lpsched is the scheduler that manages the print requests. D is incorrect because there is no such command as printerconfig to configure the LP print service.

11. 

þ B. The name of the service that listens to the print related HTTP requests is svc:/application/print/ipp-listener.

ý A, C, and D are all incorrect because there are no such services as http-listener, ippd, and http-listen.

12. 

þ D. The SMF service manages the print scheduler under the FMRI svc:/application /print/server. Therefore the svcadm enable svc:/application/print/server command will start the print scheduler.

ý A is incorrect because svcs is the SMF command to determine the status of a service. B is incorrect because the correct argument in the command is enable, not start. C is incorrect because the FMRI contains the word server, not lpsched.




Sun Certified System Administrator for Solaris 10 Study Guide Exams 310-XXX & 310-XXX
Sun Certified System Administrator for Solaris 10 Study Guide Exams 310-XXX & 310-XXX
ISBN: N/A
EAN: N/A
Year: 2005
Pages: 168

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net