Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: Performance Monitoring  (Read 4188 times)

0 Members and 1 Guest are viewing this topic.

Godwin

  • Guest
Performance Monitoring
« on: November 28, 2014, 08:21:04 pm »
Server > Specifications >Determining

a] Server:

Server : running instance of an application (software).
Capable of accepting requests from the client and giving responses.
Types of servers > Shared, VPS, Dedicated
Advantage of Dedicated server > Security
Theoretically, any computerized process that shares a resource to one or more client processes is a 'server'.
The mechanism used for file sharing is called 'Server'
In the hardware sense, Server => computer models intended for hosting software applications.
In this client–server configuration, a computer appliance share information with each other with one acting as a host for the other.
Personal computer > capable of acting as a network server.
A dedicated server > Contain more features


b] Features:

Faster CPU
Increased high-performance RAM
Increased storage capacity
Reliability, Availability and Serviceability (RAS)
Fault tolerance features, such as redundancy in power supplies, storage (as in RAID), and network connections. ( Backups )
Larger computer fans or water cooling to help remove heat.







c] Determining:

Check the /proc/ folder
/proc/cpuinfo   (about processor info)
/proc/meminfo (about RAM memory)
/proc/partitions (a full list about all disk partitions)

 cat /proc/cpuinfo
 cat  /proc/meminfo
 cat /proc/partitions

lshw
Information on the hardware configuration of the machine.

pacman -S lshw
 Full list of hardware info in details

lshw
    short list about hardware

lshw -short
lshw -class processor

hwinfo
      Hardware info

   hwinfo
      Info about a particular class of hardware such as memory, processor or       bios
   hwinfo - -bios

dmidecode

 Displays table contents of a computer's DMI. ( Desktop Management Interface)


Parameters to check for server health

CPU usage, Memory usage, Swap Memory, Cache Size, Buffer Size.
Virtual memory, kernerl threads, disks, system processes, I/O blocks, interrupts.
List of open files.
Packet filtering
Network packets
Real time Disk I/O
IP traffic
User activity
Network bandwidth
Cooling Fans and Heatsinks


Tools for Health checkup of a server

Command-Line Tools
lsof – List Open Files
Lists of all the open files and the processes.
Open files include disk files, network sockets, pipes, devices and processes.

htop – Linux Process Monitoring
Similar to Linux top command but it has some rich features like user friendly interface to manage process, shortcut keys, vertical and horizontal view of the processes.

tcpdump – Network Packet Analyzer
Used to capture or filter TCP/IP packets that received or transferred on a specific interface over a network.

System Tools
top – Linux Process Monitoring
 It displays CPU usage, Memory usage, Swap Memory, Cache Size, Buffer Size, Process PID, User, Commands.



vmstat – Virtual Memory Statistics
Displays statistics of virtual memory, kernerl threads, disks, system processes, I/O blocks, interrupts, CPU activity.
Need to install a package called sysstat.

w - Find Out Who Is Logged on And What They Are Doing
uptime - Tell How Long The System Has Been Running
free - Memory Usage
pmap - Process Memory Usage

netstat – Network Statistics
Tool for monitoring incoming and outgoing network packets statistics as well as interface statistics.

iotop – Monitor Linux Disk I/O
Monitors and display real time Disk I/O and processes.

iostat – Input/Output Statistics
Shows system input and output storage device statistics.
Used to trace storage device performance issues including devices, local disks, remote disks such as NFS.

Example : Sysstat

sar collects and displays ALL system activities statistics.
sar -u      CPU Usage of ALL CPUs
sar -P      CPU Usage of Individual CPU or Core
sar -r      Memory Free and Used
sar -S      Swap Space Used
sar -b      Overall I/O Activities
sar -d      Individual Block Device I/O Activities
sar -w   Display context switch per second
sar -q      Reports run queue and load average
sar -n      Report network statistics
sar -s      Report Sar Data Using Start Time




Example : ps

ps gives a snapshot of the current processes.
-A   select all processes
   -N   negate selection
   -a   select all with a tty except session leaders
   -d   select all, but omit session leaders
   -e   select all processes
   

   T   select all processes on this terminal
   a    select all processes on a terminal, including those of other users
   g    really all, even group leaders (does nothing w/o SunOS settings)
   r   restrict output to running processes
   x   select processes without controlling ttys
   -C   select by command name
   -G   select by RGID (supports names)
   -U   select by RUID (supports names)
   -g   select by session leader OR by group name
   -p   select by PID
   -s   select processes belonging to the sessions given
   -t   select by tty
   -u   select by effective user ID (supports names)
   U   select processes for specified users
   p   select by process ID
   t   select by tty