|
|
Contention for CPU resources is inevitable unless you run only one job. The following are recommendations and procedures you can use to ease that contention.
Sometimes users do not realize the strain they are putting on system resources. Detecting problems in the workload and notifying users of alternatives can result in better system availability and response for everyone.
First, try to reduce the prime-time load.
Identify inefficient use of system resources by users or user-caused errors.
The
ps(1)
command provides
information about active processes and light-weight processes (LWPs).
(Note that many processes have only one LWP.)
It gives a snapshot of what is going on,
and you can use it to identify processes and LWPs
that are loading the system.
Examine the entries for TIME
(the minutes and seconds of
CPU time used by processes and LWPs) and STIME
(the time when the process or LWP first started).
When you identify a runaway process or LWP (one that uses progressively more system resources over a period of time), check with the owner. A runaway process can continue to eat up system resources until everything stops. It is possible that such a process or LWP should be terminated immediately using the kill(1) command.
When you identify processes or LWPs that execute for a long time, suggest that users use the cron(1M) or at(1) commands to execute the job during off-hours.
A PATH environment variable set in each user's
.profile file defines a list of directories to be
searched when a command is executed.
The system searches every directory in $PATH
before displaying a not found
error message.
These searches require both processor and disk time.
If there is a disk or processor slowdown,
changes to PATH might help performance.
You can inform system users that inefficient PATH variables use excessive system resources, provide a default PATH, and inform users of the best way to customize their PATH variable.
Include the system directories accessible by all users in the default system PATH in the /etc/profile file.
Check PATH variables for the following:
The timex(1) command is used to collect information about system consumption. The results can be used to identify heavily loaded resources so that you can tune the system for better throughput. See ``Reporting application turnaround with timex'' for more information about the timex command.