Top command
will give the list of process with nice level, CPU utilization, and memory
utilization.
First line contains the uptime, number of users logged in, load average (1min, 5 min, 15 min)

Calculate load on multiple CPU machine.
Step 1) get number of processors from the below file.
cat /proc/cpuinfo | grep “model name” | wc –l

Step 2) (average load) / (number of processors)
Lines of top command:

Line 1: uptime, number of users logged in, load average (1min, 5 min, 15 min)
Line 2: task information (total, running, sleeping and stopped)
Line 3: CPU information
Line 4: Memory information
Line 5: Swap information
Sort process by Memory usage/CPU
enter shift + m to sort by memory usage

enter shift + p to sort by CPU usage

Re-nice a particular process:
Step 1) Before renice the value of PID 12 is 10.

Step 2) enter r to renice. Then enter new pid (example: 12) when prompted.

Step 3) provide new nice value and hit enter

Step 4) The nice lave will be set.

First line contains the uptime, number of users logged in, load average (1min, 5 min, 15 min)

Calculate load on multiple CPU machine.
Step 1) get number of processors from the below file.
cat /proc/cpuinfo | grep “model name” | wc –l

Step 2) (average load) / (number of processors)
Lines of top command:

Line 1: uptime, number of users logged in, load average (1min, 5 min, 15 min)
Line 2: task information (total, running, sleeping and stopped)
Line 3: CPU information
Line 4: Memory information
Line 5: Swap information
Sort process by Memory usage/CPU
enter shift + m to sort by memory usage

enter shift + p to sort by CPU usage

Re-nice a particular process:
Step 1) Before renice the value of PID 12 is 10.

Step 2) enter r to renice. Then enter new pid (example: 12) when prompted.

Step 3) provide new nice value and hit enter

Step 4) The nice lave will be set.

Set delay time for refersh
step 1) type d and enter. It will prompt to give new delay time. Then type new value and hit enter.

Find the full path of command in top result.
Type c and hit enter

step 1) type d and enter. It will prompt to give new delay time. Then type new value and hit enter.

Find the full path of command in top result.
Type c and hit enter

No comments:
Post a Comment