Operating System - HP-UX
1837202 Members
2928 Online
110115 Solutions
New Discussion

Re: Glance -j interval not precise

 
Thomas Lee_1
Advisor

Glance -j interval not precise

Hi,

I have scheduled glance to collect system data in daily basis, following are the metric:

/opt/perf/output/metric
print gbl_statdate, " ",
gbl_stattime, " ",
"TCPU", gbl_cpu_total_util|8|1, " ",
"PriQ", gbl_pri_queue|8|1, " ",
"RunQ", gbl_run_queue|8|1, " ",
"SMod", gbl_cpu_sys_mode_util|8|1, " ",
"INTR", gbl_cpu_interrupt_util|8|1, " ",
"SCal", gbl_cpu_syscall_util|8|1, " ",
"CSwh", gbl_cpu_cswitch_util|8|1, " ",
"Umod", gbl_cpu_user_mode_util|8|1, " ",
"DPek", gbl_disk_util_peak|8|1, " ",
"DSuQ", gbl_disk_subsystem_queue|4|1, " ",
"DWai", gbl_disk_wait_pct|8|1, " ",
"BRdH", gbl_mem_cache_hit_pct|8|1, " ",
"BWrH", gbl_mem_cache_write_hit_pct|8|1, " ",
"BUse", tbl_buffer_cache_used|8|1, " ",
"BMax", tbl_buffer_cache_max|8|1, " ",
"BMin", tbl_buffer_cache_min|8|1, " ",
"BHig", tbl_buffer_cache_high|8|1, " ",
"BAva", tbl_buffer_cache_avail|8|1, " ",
"Muse", gbl_mem_util|8|1, " ",
"Pout", gbl_mem_pageout_rate|8|1, " ",
"Sout", gbl_mem_swapout_rate|8|1, " ",
"MemQ", gbl_mem_queue|8|1, " ",
"SwpU", gbl_swap_space_util|8, " ",
"PAct", gbl_active_proc|8|1, " ",
"PAli", gbl_alive_proc|8|1

And then have a job collect data for whole day:
cat get_glance.sh
#/bin/sh

LOG=/opt/perf/output/glance_`hostname`_`date +%Y%m%d`.txt
/opt/perf/bin/glance -adviser_only -j 5 -iterations 17280 -syntax /opt/perf/output/metric > ${LOG}
/usr/contrib/bin/gzip ${LOG}

Finally schedule in crontab:
0 0 * * * /opt/perf/output/get_glance.sh >/dev/null 2>&1

NOW THE PROBLEM IS...
from the config above, you can see that I'm going to collect data for whole day ( 5 sec * 17280 = 86400 sec = 1440 mins = 24 hrs )

I have ran them in 2 boxes, glance C.04.50.00, HPUX 11.11...

Each day they really provide output files with 17280 lines, however, not every sampling is in 5 sec interval... so everyday they already reach 17280 lines at around 8~9pm.... thus missing few hours data everyday... do anybody here please kindly to help me solve this issue?
2 REPLIES 2
Peter Godron
Honored Contributor

Re: Glance -j interval not precise

Thomas,
I suspect the problem is down to the amount of time it takes to execute each iteration.
Thomas Lee_1
Advisor

Re: Glance -j interval not precise

But I do specify "-j 5", expect the shortest interval is 5 sec between each sampling, but I found many it just 1~2 sec between two sample.

Why glance not follow the order but just doing faster than expected?