<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Performance and Capacity on Amit Agarwal Linux Blog</title>
    <link>/tags/performance-and-capacity/</link>
    <description>Recent content in Performance and Capacity on Amit Agarwal Linux Blog</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    <lastBuildDate>Mon, 04 Jun 2018 01:00:39 +0000</lastBuildDate>
    
	<atom:link href="/tags/performance-and-capacity/index.xml" rel="self" type="application/rss+xml" />
    
    
    <item>
      <title>glances – new way to look at contention</title>
      <link>/2018/06/04/glances-contention/</link>
      <pubDate>Mon, 04 Jun 2018 01:00:39 +0000</pubDate>
      
      <guid>/2018/06/04/glances-contention/</guid>
      <description>&lt;p&gt;glances is like top/htop but little different. It shows you sort based on contention (smartly and automatically) unless you change that and hence if you just want to check what is biggest bottleneck in system, then head over to glances quickly. Here is quick description from dnf info command&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;blockquote&gt;
&lt;dl&gt;
&lt;dt&gt;Name : glances&lt;/dt&gt;
&lt;dt&gt;Version : 2.11.1&lt;/dt&gt;
&lt;dt&gt;Release : 2.fc28&lt;/dt&gt;
&lt;dt&gt;Arch : noarch&lt;/dt&gt;
&lt;dt&gt;Size : 3.2 M&lt;/dt&gt;
&lt;dt&gt;Source : glances-2.11.1-2.fc28.src.rpm&lt;/dt&gt;
&lt;dt&gt;Repo : @System&lt;/dt&gt;
&lt;dt&gt;From repo : fedora&lt;/dt&gt;
&lt;dt&gt;Summary : CLI curses based monitoring tool&lt;/dt&gt;
&lt;dt&gt;URL : &lt;a href=&#34;https://github.com/nicolargo/glances&#34;&gt;https://github.com/nicolargo/glances&lt;/a&gt;&lt;/dt&gt;
&lt;dt&gt;License : GPLv3&lt;/dt&gt;
&lt;dt&gt;Description : Glances is a CLI curses based monitoring tool for both GNU/Linux and BSD.&lt;/dt&gt;
&lt;dd&gt;&lt;/dd&gt;
&lt;dd&gt;Glances uses the PsUtil library to get information from your system.&lt;/dd&gt;
&lt;dd&gt;&lt;/dd&gt;
&lt;dd&gt;It is developed in Python.&lt;/dd&gt;
&lt;/dl&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>power saving on laptop</title>
      <link>/2016/09/22/power-saving-laptop/</link>
      <pubDate>Thu, 22 Sep 2016 00:54:15 +0000</pubDate>
      
      <guid>/2016/09/22/power-saving-laptop/</guid>
      <description>&lt;p&gt;One of the easiest way to make sure that you can have a decent battery life is&lt;/p&gt;
&lt;pre class=&#34;brush:shell&#34;&gt;sudo yum install tlp smartmontools
sudo systemctl enable tlp
sudo systemctl start tlp&lt;/pre&gt;
&lt;p&gt;And after this you can check the status like this:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;sudo tlp stat&lt;/strong&gt;&lt;br&gt;
— TLP 0.9 ——————————————–&lt;/p&gt;
&lt;p&gt;+++ Configured Settings: /etc/default/tlp&lt;br&gt;
TLP_ENABLE=1&lt;br&gt;
TLP_DEFAULT_MODE=AC&lt;br&gt;
DISK_IDLE_SECS_ON_AC=0&lt;br&gt;
DISK_IDLE_SECS_ON_BAT=2&lt;br&gt;
MAX_LOST_WORK_SECS_ON_AC=15&lt;br&gt;
MAX_LOST_WORK_SECS_ON_BAT=60&lt;br&gt;
SCHED_POWERSAVE_ON_AC=0&lt;br&gt;
SCHED_POWERSAVE_ON_BAT=1&lt;br&gt;
NMI_WATCHDOG=0&lt;br&gt;
ENERGY_PERF_POLICY_ON_AC=performance&lt;br&gt;
ENERGY_PERF_POLICY_ON_BAT=powersave&lt;br&gt;
DISK_DEVICES=”sda sdb”&lt;br&gt;
DISK_APM_LEVEL_ON_AC=”254 254″&lt;br&gt;
DISK_APM_LEVEL_ON_BAT=”128 128″&lt;br&gt;
SATA_LINKPWR_ON_AC=max_performance&lt;br&gt;
SATA_LINKPWR_ON_BAT=min_power&lt;br&gt;
AHCI_RUNTIME_PM_TIMEOUT=15&lt;br&gt;
PCIE_ASPM_ON_AC=performance&lt;br&gt;
PCIE_ASPM_ON_BAT=powersave&lt;br&gt;
RADEON_POWER_PROFILE_ON_AC=high&lt;br&gt;
RADEON_POWER_PROFILE_ON_BAT=low&lt;br&gt;
RADEON_DPM_STATE_ON_AC=performance&lt;br&gt;
RADEON_DPM_STATE_ON_BAT=battery&lt;br&gt;
RADEON_DPM_PERF_LEVEL_ON_AC=auto&lt;br&gt;
RADEON_DPM_PERF_LEVEL_ON_BAT=auto&lt;br&gt;
WIFI_PWR_ON_AC=off&lt;br&gt;
WIFI_PWR_ON_BAT=on&lt;br&gt;
WOL_DISABLE=Y&lt;br&gt;
SOUND_POWER_SAVE_ON_AC=0&lt;br&gt;
SOUND_POWER_SAVE_ON_BAT=1&lt;br&gt;
SOUND_POWER_SAVE_CONTROLLER=Y&lt;br&gt;
BAY_POWEROFF_ON_BAT=0&lt;br&gt;
BAY_DEVICE=”sr0″&lt;br&gt;
RUNTIME_PM_ON_AC=on&lt;br&gt;
RUNTIME_PM_ON_BAT=auto&lt;br&gt;
RUNTIME_PM_ALL=1&lt;br&gt;
RUNTIME_PM_DRIVER_BLACKLIST=”radeon nouveau”&lt;br&gt;
USB_AUTOSUSPEND=1&lt;br&gt;
USB_BLACKLIST_WWAN=1&lt;br&gt;
RESTORE_DEVICE_STATE_ON_STARTUP=0&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Benchmarking the system/CPU performance</title>
      <link>/2012/01/15/benchmarking-system-cpu-performance/</link>
      <pubDate>Sun, 15 Jan 2012 07:56:44 +0000</pubDate>
      
      <guid>/2012/01/15/benchmarking-system-cpu-performance/</guid>
      <description>&lt;p&gt;Have you ever wanted to have a quick check on your CPU performance. I know that lot of people will say that this is not the right way to do this, but here is something that you can use to check the CPU speed.&lt;/p&gt;
&lt;pre class=&#34;brush: bash; gutter: true; first-line: 1&#34;&gt;#!/bin/bash -
#===============================================================================
#
#          FILE:  benchmark.sh
#
#         USAGE:  ./benchmark.sh
#
#   DESCRIPTION:  Benchmark the CPU
#
#       OPTIONS:  ---
#  REQUIREMENTS:  ---
#          BUGS:  ---
#         NOTES:  ---
#        AUTHOR: Amit Agarwal (aka), amit.agarwal@roamware.com
#       COMPANY: Roamware India Pvt Ltd
#       CREATED: 09/21/2011 11:46:03 AM IST
# Last modified: Wed Sep 21, 2011  12:22PM
#      REVISION:  ---
#===============================================================================

add ()
{
    COUNTER=0
    exec 2&amp;gt;&amp;1
    time=$(exec 2&amp;gt;&amp;1;(time while [[  $COUNTER -lt 100000 ]]; do ((COUNTER++)) \
        ; done))
    echo &#34;Time for 100000 additions is &#34;$time
}	# ----------  end of function add  ----------
mul ()
{
    COUNTER=0
    test=2
    exec 2&amp;gt;&amp;1
    time=$(exec 2&amp;gt;&amp;1;(time while [[  $COUNTER -lt 100000 ]]; do ((COUNTER++)) \
        ; ((test=test*2));done))
    echo &#34;Time for 100000 mul is &#34;$time
}	# ----------  end of function add  ----------
div ()
{
    COUNTER=0
    test=1000000000000
    exec 2&amp;gt;&amp;1
    time=$(exec 2&amp;gt;&amp;1;(time while [[  $COUNTER -lt 100000 ]]; do ((COUNTER++)) \
        ; (( test=test/2)); done)|tr -d &#39;\n&#39;)
    echo &#34;Time for 100000 divisions is &#34;${time}
}	# ----------  end of function add  ----------

time add
time mul
time div&lt;/pre&gt;
&lt;p&gt;And here is the output :&lt;/p&gt;</description>
    </item>
    
  </channel>
</rss>
