Topic
  • 2 replies
  • Latest Post - ‏2012-11-19T12:51:37Z by SystemAdmin
PontiacGeronimo
PontiacGeronimo
2 Posts

Pinned topic nmon2rrd produces not complete graphs

‏2012-11-19T11:46:00Z |
nmon files are collected with options:

nmon -s 60 -c 1439 ... (started from crontab every midnight)

Excel nmon analyzer produces correct graphs (values begins from hour 00:00), but when I process the same nmon file with nmon2rrd (Version:12g), it produces graphs starting from ca. 07:00 (see example on attached picture). The same issue is observd for every day nmon file collected. Again, in nmonanalyzer there is no such problem observed.

Any idea how to fix this issue?

kind regards,.P./
Updated on 2012-11-19T12:51:37Z at 2012-11-19T12:51:37Z by SystemAdmin
  • PontiacGeronimo
    PontiacGeronimo
    2 Posts

    Re: nmon2rrd produces not complete graphs

    ‏2012-11-19T12:07:51Z  
    ok, probably I have fix it by myself.

    I did following changes in source file and compiled it again with new "limits".

    Anyone can confirm this solution is ok?
    
    $ sed s/1024/1536/g nmon2rrd.c >nmon2rrdX.c $ diff nmon2rrd.c nmon2rrdX.c 46c46 < 
    
    long tarray[10240]; --- > 
    
    long tarray[15360]; 48,49c48,49 < 
    
    char dirname[1024] = 
    "./"; < 
    
    char filename[1024]; --- > 
    
    char dirname[1536] = 
    "./"; > 
    
    char filename[1536]; 96c96 < #define NUMOFNAMES 1024 --- > #define NUMOFNAMES 1536 361c361 < 
    
    int lines=1024; --- > 
    
    int lines=1536; 367c367 < #define ARRAYMAX 1024 --- > #define ARRAYMAX 1536 372c372 < 
    
    char time_and_date[1024]; --- > 
    
    char time_and_date[1536]; 565,567c565,567 <                 
    
    if(debug)printf(
    "find malloc %d\n", sizeof( 
    
    char *) * 1024); <                 found = (
    
    char **)malloc(sizeof( 
    
    char *) * 1024); <                 founds = 1024; --- >                 
    
    if(debug)printf(
    "find malloc %d\n", sizeof( 
    
    char *) * 1536); >                 found = (
    
    char **)malloc(sizeof( 
    
    char *) * 1536); >                 founds = 1536; 649,650c649,650 < 
    
    char string1[1024]; < 
    
    char string2[1024]; --- > 
    
    char string1[1536]; > 
    
    char string2[1536]; 710c710 <         line = (
    
    char **)malloc(sizeof(
    
    char *)*1024); --- >         line = (
    
    char **)malloc(sizeof(
    
    char *)*1536); 747c747 <                         lines +=1024; --- >                         lines +=1536; 858,860c858,860 <         
    
    if(snapshots > 1024) 
    { <                 printf(
    "WARNING: truncating to 1024 snapshots (not the %d found in the nmon file)\n",snapshots); <                 snapshots=1024; --- >         
    
    if(snapshots > 1536) 
    { >                 printf(
    "WARNING: truncating to 1536 snapshots (not the %d found in the nmon file)\n",snapshots); > snapshots=1536;
    
  • SystemAdmin
    SystemAdmin
    2402 Posts

    Re: nmon2rrd produces not complete graphs

    ‏2012-11-19T12:51:37Z  
    ok, probably I have fix it by myself.

    I did following changes in source file and compiled it again with new "limits".

    Anyone can confirm this solution is ok?
    <pre class="jive-pre"> $ sed s/1024/1536/g nmon2rrd.c >nmon2rrdX.c $ diff nmon2rrd.c nmon2rrdX.c 46c46 < long tarray[10240]; --- > long tarray[15360]; 48,49c48,49 < char dirname[1024] = "./"; < char filename[1024]; --- > char dirname[1536] = "./"; > char filename[1536]; 96c96 < #define NUMOFNAMES 1024 --- > #define NUMOFNAMES 1536 361c361 < int lines=1024; --- > int lines=1536; 367c367 < #define ARRAYMAX 1024 --- > #define ARRAYMAX 1536 372c372 < char time_and_date[1024]; --- > char time_and_date[1536]; 565,567c565,567 < if(debug)printf( "find malloc %d\n", sizeof( char *) * 1024); < found = ( char **)malloc(sizeof( char *) * 1024); < founds = 1024; --- > if(debug)printf( "find malloc %d\n", sizeof( char *) * 1536); > found = ( char **)malloc(sizeof( char *) * 1536); > founds = 1536; 649,650c649,650 < char string1[1024]; < char string2[1024]; --- > char string1[1536]; > char string2[1536]; 710c710 < line = ( char **)malloc(sizeof( char *)*1024); --- > line = ( char **)malloc(sizeof( char *)*1536); 747c747 < lines +=1024; --- > lines +=1536; 858,860c858,860 < if(snapshots > 1024) { < printf( "WARNING: truncating to 1024 snapshots (not the %d found in the nmon file)\n",snapshots); < snapshots=1024; --- > if(snapshots > 1536) { > printf( "WARNING: truncating to 1536 snapshots (not the %d found in the nmon file)\n",snapshots); > snapshots=1536; </pre>
    Yes, its a good workaraound to give more space for snapshots.
    I guess your original problem might come from that your lpar data and lpar where nmon2rrd is used are on different timezones?

    Vesa