<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Performance issue or something else? in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/performance-issue-or-something-else/m-p/4696184#M659065</link>
    <description>Hi All,&lt;BR /&gt;&lt;BR /&gt;I have the following script which I use in Nagios to check the health of the applications, the problem with it is that the curl part ($TOTAL) does not return anything after running for 2-3 hrs.&lt;BR /&gt;&lt;BR /&gt;There are 17 invocations of this script in a second. Wonder if its due to the system not able to handle multiple curls at the same time. Though the load and usage on the system seems to be fine.&lt;BR /&gt;&lt;BR /&gt;Can someone try to help and see if we can improve on this script's performance or is it something else.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Allan.&lt;BR /&gt;&lt;BR /&gt;#!/bin/bash&lt;BR /&gt;&lt;BR /&gt;read URL &amp;lt; "$1"&lt;BR /&gt;&lt;BR /&gt;TOTAL=`curl -w  '\ntotal_time=%{time_total}s' -s  -m 3 --connect-timeout 3 $URL |perl -n0e '$s=/"alive"/?"OK":"ERROR";($t)=/(total_time.+)/;print "$s $t;0;0;0\n"'`&lt;BR /&gt;&lt;BR /&gt;echo `date`: $TOTAL : $URL &amp;gt;&amp;gt; /tmp/curl.log&lt;BR /&gt;&lt;BR /&gt;STATUS=`echo $TOTAL|awk '{print $1}'`&lt;BR /&gt;PERF=`echo $TOTAL|awk '{print $2}'`&lt;BR /&gt;&lt;BR /&gt;case $STATUS in&lt;BR /&gt;OK)&lt;BR /&gt;   echo "$STATUS|$PERF"&lt;BR /&gt;   echo "curl $URL"&lt;BR /&gt;   exit 0&lt;BR /&gt;   ;;&lt;BR /&gt;WARN)&lt;BR /&gt;  echo "$STATUS|$PERF"&lt;BR /&gt;  echo "curl $URL"&lt;BR /&gt;  exit 1&lt;BR /&gt;  ;;&lt;BR /&gt;ERROR)&lt;BR /&gt; echo "$STATUS|$PERF"&lt;BR /&gt; echo "curl $URL"&lt;BR /&gt; exit 2&lt;BR /&gt;  ;;&lt;BR /&gt;FATAL)&lt;BR /&gt;  echo "$STATUS|$PERF"&lt;BR /&gt;  echo "curl $URL"&lt;BR /&gt; exit 2&lt;BR /&gt;  ;;&lt;BR /&gt;*)&lt;BR /&gt;  echo "$STATUS|$PERF"&lt;BR /&gt;  echo "curl $URL"&lt;BR /&gt;  exit 2&lt;BR /&gt;  ;;&lt;BR /&gt;esac&lt;BR /&gt;&lt;BR /&gt;Here is the curl.log output from when it was returning data and then does not return anything - &lt;BR /&gt;&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.015s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.021s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.016s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.017s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.024s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.017s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:42 PDT 2010: : http://URL&lt;BR /&gt;Wed Oct 6 15:11:42 PDT 2010: : http://URL&lt;BR /&gt;Wed Oct 6 15:11:42 PDT 2010: : http://URL&lt;BR /&gt;Wed Oct 6 15:11:42 PDT 2010: : http://URL</description>
    <pubDate>Wed, 06 Oct 2010 22:05:02 GMT</pubDate>
    <dc:creator>Allanm</dc:creator>
    <dc:date>2010-10-06T22:05:02Z</dc:date>
    <item>
      <title>Performance issue or something else?</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/performance-issue-or-something-else/m-p/4696184#M659065</link>
      <description>Hi All,&lt;BR /&gt;&lt;BR /&gt;I have the following script which I use in Nagios to check the health of the applications, the problem with it is that the curl part ($TOTAL) does not return anything after running for 2-3 hrs.&lt;BR /&gt;&lt;BR /&gt;There are 17 invocations of this script in a second. Wonder if its due to the system not able to handle multiple curls at the same time. Though the load and usage on the system seems to be fine.&lt;BR /&gt;&lt;BR /&gt;Can someone try to help and see if we can improve on this script's performance or is it something else.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Allan.&lt;BR /&gt;&lt;BR /&gt;#!/bin/bash&lt;BR /&gt;&lt;BR /&gt;read URL &amp;lt; "$1"&lt;BR /&gt;&lt;BR /&gt;TOTAL=`curl -w  '\ntotal_time=%{time_total}s' -s  -m 3 --connect-timeout 3 $URL |perl -n0e '$s=/"alive"/?"OK":"ERROR";($t)=/(total_time.+)/;print "$s $t;0;0;0\n"'`&lt;BR /&gt;&lt;BR /&gt;echo `date`: $TOTAL : $URL &amp;gt;&amp;gt; /tmp/curl.log&lt;BR /&gt;&lt;BR /&gt;STATUS=`echo $TOTAL|awk '{print $1}'`&lt;BR /&gt;PERF=`echo $TOTAL|awk '{print $2}'`&lt;BR /&gt;&lt;BR /&gt;case $STATUS in&lt;BR /&gt;OK)&lt;BR /&gt;   echo "$STATUS|$PERF"&lt;BR /&gt;   echo "curl $URL"&lt;BR /&gt;   exit 0&lt;BR /&gt;   ;;&lt;BR /&gt;WARN)&lt;BR /&gt;  echo "$STATUS|$PERF"&lt;BR /&gt;  echo "curl $URL"&lt;BR /&gt;  exit 1&lt;BR /&gt;  ;;&lt;BR /&gt;ERROR)&lt;BR /&gt; echo "$STATUS|$PERF"&lt;BR /&gt; echo "curl $URL"&lt;BR /&gt; exit 2&lt;BR /&gt;  ;;&lt;BR /&gt;FATAL)&lt;BR /&gt;  echo "$STATUS|$PERF"&lt;BR /&gt;  echo "curl $URL"&lt;BR /&gt; exit 2&lt;BR /&gt;  ;;&lt;BR /&gt;*)&lt;BR /&gt;  echo "$STATUS|$PERF"&lt;BR /&gt;  echo "curl $URL"&lt;BR /&gt;  exit 2&lt;BR /&gt;  ;;&lt;BR /&gt;esac&lt;BR /&gt;&lt;BR /&gt;Here is the curl.log output from when it was returning data and then does not return anything - &lt;BR /&gt;&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.015s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.021s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.016s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.017s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.024s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:41 PDT 2010: OK total_time=0.017s;0;0;0 : http://URL&lt;BR /&gt;Wed Oct 6 15:11:42 PDT 2010: : http://URL&lt;BR /&gt;Wed Oct 6 15:11:42 PDT 2010: : http://URL&lt;BR /&gt;Wed Oct 6 15:11:42 PDT 2010: : http://URL&lt;BR /&gt;Wed Oct 6 15:11:42 PDT 2010: : http://URL</description>
      <pubDate>Wed, 06 Oct 2010 22:05:02 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/performance-issue-or-something-else/m-p/4696184#M659065</guid>
      <dc:creator>Allanm</dc:creator>
      <dc:date>2010-10-06T22:05:02Z</dc:date>
    </item>
  </channel>
</rss>

