Test Linux System Performance using Command Line Tools Part-1

 Uptime

Uptime Command display results include server has been running for how long, how many users log on the server performance and overall assessment load average. Load average values were recorded in the last 1 minute, 5 minutes and 15 minutes intervals of the load, load average is not a percentage, but in the queue waiting for the process of implementation of the number. If the process requires that the CPU time is blocked (meaning the CPU did not have time to deal with it), load average value will increase. On the other hand, if each process can get immediate access to CPU time, this value will decrease.

UP kernel load average under the optimal value is 1, indicating that each process can be CPU processing immediately, of course, lower is not a problem, only shows part of a waste of resources. However, this value between different systems are different, for example, a single-CPU workstation, load average of 1 or 2 are acceptable, but in a multi-CPU systems this value should be divided by the number of physical CPU, Suppose the number is 4 CPU, while the load average of 8 or 10, then the result is in more than two points.

You can judge a performance problem using uptime is in the server or network. For example, if a network application running performance is not satisfactory, run uptime check the system load is relatively high, if not the problem more likely in your network.


Top

Top command shows the actual CPU usage, by default, it shows the CPU-server task information and refresh every 5 seconds. You can categories them through a variety of ways, including PID, time and memory usage.


The following is the description of output values:


PID: process ID


USER: process owner user name


PRI: the priority of the process


NI: nice level


SIZE: the number of the memory process (code + data + stack)


RSS: amount of physical memory used by the process


SHARE: the process and other processes, the number of shared memory


STAT: state of the process: S = sleep state, R = running, T = stopped state, D = interrupt sleep state, Z = zombie state


% CPU: CPU to use the shared


% MEM; shared physical memory


TIME: process CPU-time


COMMAND: command line to start the task (including parameters)



Process priority and Nice levels

Process priority is the implementation of a decision process is CPU priority parameter, the kernel will be adjusted this value. Nice value is a limit to priority. Process priority value can not be less than the nice value. (Nice value, the lower the higher the priority).
Process priority is not to manually change, and only indirectly by changing the nice value to the adjustment process priority. If a process is running too slow, you can specify a lower nice value to allocate more CPU to its resources. Of course, this means that some other process will be assigned fewer CPU resources to run more slowly. Linux supports nice range of values is 19 (low priority) to -20 (high priority), the default value is 0. If you need to change a process nice value is negative (high priority), must use the su command to root user login.

Comments

Popular posts from this blog

How to create Oracle stored Procedures using TOAD for Oracle

Create Tables in Oracle Database using TOAD

How to Create Packages in Oracle Database using TOAD for Oracle