Basic process and print management
Management process
Run the process with low priority
Nice (c) instructions are used to execute commands at a lower scheduling priority, and each process has a NICE value for calculating it.
of
priority. The NICE value is in the range of 0 to 39. The high value gets low priority, and the default is the NICE value without giving the argument.
20.
Super users can specify a negative value to increase priority.
Process continues to execute after logging out
The process started in the background, by default, no longer exists after the logout is logged out, however, you can use the NOHUP (C) instruction, let
Enter
The process is not affected by hang and cancellation, which can continue to operate, for example:
$ Nohup Sort Bigfile> Sortfile &
4567
$ EXIT
When the user logs out, the user has not used the output to re-use, and the output will be sent to the nohup.out file in the current directory, if the current
Objective
If you are not written, the output is changed to $ home / nohup.out.
Restart the security level elf process
According to the C2 security level requirements, some elf processes run with Luid (Login User Identifier), so
can
Restart them with the SD (ADM) utility. If Luid is restricted (high security level), you can only use SD (
ADM),
For example, CRON (C) such a wizard, to restart it on the high security level.
Process termination utility
When you need to terminate the utility, you can send the information to the process, make it commit to suicide, usually used in termination of some hanging or
Yes
Run process. The syntax is as follows:
$ Kill [-signal]
E.g
$ Kill 4411
4411: Terminated
In this way, only the process of running the priority greater than 25, less than 25 priority processes can only be in the reboot system
withdraw
Note it. Scheduling a single job
The AT (c) command enables a set of commands at a specified time, mainly for the predetermined time in the case where the system is less.
Time
Limits (for example, in the middle of the middle or daily fixed time) running instructions. To re-direction, you can use standard input, or document
Piece
Enter; after entering the complete AT instruction, the job number and time will be run. The syntax is as follows:
$ at Time [Date] [increment] <[filename]
Any user can run an AT job, but must be authorized.
Specify a single job scheduling time
The time format is HR: min or min, HR, specified in the morning or in the afternoon with A.M or P.M, the effective time includes No ON,
MidNight and Now, specify the date with "Month [Year]" format, such as Feb14. A week can also be used one day
Monday, Mon, Today or Tomorrow.
.at instructions From standard input, read the commands intended in a certain moment:
$ at 14:00 jan
Sort / u / user1 / file
/ u / user1 / sort
Ctrl> d
Job 61202778.a at tu jan 4 14:00:00 1996
When you use it, you must specify a file with a full path name. The instruction output is sent to the user in an email, or it can output it to the text.
Piece
Or terminal.
List individual scheduling homework
Use command
$ AT -1
Job 612027780.a at WED JAN 24 08:43:00 19900.a at Wed Jan 24 08:43:00 1996
If you specify JOD_ID, the general user gets a table of all their homework, and the root user can obtain a table of all jobs.
Cancel single dispatch job
Use the following instruction to undo your job:
$ AT -R
You can use a match to undo multiple jobs. AT homework in USR / Spool / Cron / Atjobs
Scheduling jobs on the general database
Use crontab (c) instructions to copy or edit into a user's crontab file from the specified file or standard.
It is set to run some instructions at the specified date and time schedule. The CRONTAB instruction provides the CRON system wizard to be executed.
Make
Industry, cleanup / TMP, withdrawn on a general data diary file or unwanted file, as well as check space, mailing warning
use
Household, etc. The /usr/lib/cron/cron.allow file lists users who can use cron, / usr / lib / cron / cron.
Deny
The file lists users who refuse to access CRON, only when the cron.allow file does not exist, the cron.deny file will only start
effect.
Specify job and its scheduling time
The job may be a single instruction or a shell script containing multiple instructions, and the instruction output is mailed to the user, or it can be changed to
Text
Parts or terminals. In the file to enter the job and run time to run this job. The file can take any name, but not allow
Xu
Including the first and blank lines, and it is best to take .cronfile, this name reflects its function, easy to understand.
The .cronfile file can be created with text editing or VI. Each user only provides a .cronfile file, each execution
When the crontab directive, the new file will override the original file. Edit the existing .cronfile file, increase or modify one
Make
Industry, then re-submit it with crontab .cronfile. And each user's registration item will be stored in / usr / spool / cro
NTABS /.
List or modify cron jobs
To list the current CRON job, you can be entered:
$ crontab -1
Modify the cron item, use the instruction:
$ crontab -1> .cronfile
$ v .cronfile
$ crontab .cronfile
If you want to revoke the cron job, you can enter:
$ crontab -r
But in the same way, please pay attention, the root user does not .cronfile file.
Print management
Print Spooler Programs Automatically launched when system boots, responsible for the installation, configuration, and management of print services,
Refer
On the printer, the user print request is queued and the print can be paused without losing the queued print request.
Printer queue
The printer is grouped, and each group will access a queue (Class). And print request can be sent to a class, too
Can send
Go to the specified printer. In a Class, you can remove or add printers at any time, use sysadmsh menu or SCOAD
MIN
Print Manager, you can add printers to existing classes, or add a new Class.
Printer filter
Using the printer filter, you can convert user files or data streams, and print out on a given printer;
Two
Side printing, sketch or high quality text printing, etc. If the print failed, the print service will be notified, then tell the user to use it.
The problem. The printer filter is also known as the printer defined interface script, stored in / usr / spool / lp / bin.
Install and configure printers
To pick up the printer parallel PORT, SCO UNIX SYSTEM V supports two physical parallel equipment
(/ DEV / LP [0-2]). When using the master, use LP0 or LP1, the interrupt vector is 7. Second parallel, / DE
V / LP2,
The interrupt vector is 7. To take the printer on the serial port, it is best to connect the smart card, the printer
can
Contact the serial name with any valid serial. If hardware flow control is required, you can use a non-modulated demodulator to control the name. Another party
surface,
Local printing can be made from the terminal auxiliary port, and the instruction Lprint (c) can be printed from the user from the printer attached to the terminal.
Install the printer
To install the printer, first find a unused serial line to connect the printer, connect the wire, open the printer switch, check hard
Piece
connection. Then, call the sysadmsh menu or Print Manager, add the printer, fill in the right information
formula,
Specify the printer's class, if you do not exist, create a new Class, including the interface script path name. a lot of
hit
The printer can use the STANDARD interface script.
Printer management
When modifying the printer configuration, you can increase or revoke the destination; change the printer interface script, equipment, etc.; and change the default
hit
Printer destination. Several options need to pay attention to managing printer scheduling:
-Stop: To implement some printer maintenance, it is necessary to convert a fake printer into OFF.
-Begin: Spool conversion into ON.
-Accept: Allows the print request to the printer or class.
-Reject: Block requests from printing offline.
-ENABLE: Allows print from printers or classes.
-Disable: Prevent printing, but allows spooling to appear.
Each print request will give a priority, decide when to print, the priority data range is 0 (highest) to 39
(lowest). The default priority value is also 20. All print requests or individual print requests are movable to different queues or play
On the printer, if the printer's queue blocks or printers cannot be used, you should remove the print request; the printer should maintain, but also move
Go to print request.
If all requests have been removed, this printer will no longer accept new requests until the printer is enabled. To clean up print
Applicable
See, first point out the printer or request ID. If the printer is specified, the job currently being printed is also cleared, but
Do not use wildcard to match the cleaning print request.