$opt[1] = "--title \"Performance indicators for ". str_replace("_","/",$servicedesc) ." on $hostname\" "; $ds_name[1] = "Port " . str_replace("_","/",$servicedesc) ." on $hostname"; $def[1] = "DEF:bytes_tx=$RRDFILE[1]:$DS[1]:AVERAGE "; $def[1] .= "DEF:bytes_rx=$RRDFILE[1]:$DS[2]:AVERAGE "; $def[1] .= "CDEF:bytes_all=bytes_tx,bytes_rx,+ "; $def[1] .= "DEF:err_enc_in=$RRDFILE[1]:$DS[5]:AVERAGE "; $def[1] .= "DEF:err_enc_out=$RRDFILE[1]:$DS[10]:AVERAGE "; $def[1] .= "DEF:err_crc=$RRDFILE[1]:$DS[6]:AVERAGE "; $def[1] .= "DEF:err_trunc=$RRDFILE[1]:$DS[7]:AVERAGE "; $def[1] .= "DEF:err_toolong=$RRDFILE[1]:$DS[8]:AVERAGE "; $def[1] .= "DEF:err_bad_eof=$RRDFILE[1]:$DS[9]:AVERAGE "; $def[1] .= "DEF:err_c3_timeout=$RRDFILE[1]:$DS[11]:AVERAGE "; $def[1] .= "AREA:bytes_all#FF6600:\"Throughput \" " ; $def[1] .= "GPRINT:bytes_all:LAST:\"%3.0lf%sB last \" " ; $def[1] .= "GPRINT:bytes_all:AVERAGE:\"%3.0lf%sB avg \" " ; $def[1] .= "GPRINT:bytes_all:MAX:\"%3.0lf%sB max\\l\" "; $def[1] .= "AREA:bytes_rx#7EE600:\"Throughput\: RX \" " ; $def[1] .= "GPRINT:bytes_rx:LAST:\"%3.0lf%sB last \" " ; $def[1] .= "GPRINT:bytes_rx:AVERAGE:\"%3.0lf%sB avg \" " ; $def[1] .= "GPRINT:bytes_rx:MAX:\"%3.0lf%sB max\\n\" "; $def[1] .= "AREA:bytes_tx#6DC8FE:\"Throughput\: TX \" " ; $def[1] .= "GPRINT:bytes_tx:LAST:\"%3.0lf%sB last \" " ; $def[1] .= "GPRINT:bytes_tx:AVERAGE:\"%3.0lf%sB avg \" " ; $def[1] .= "GPRINT:bytes_tx:MAX:\"%3.0lf%sB max\\n\" "; $def[1] .= "AREA:err_enc_in#EACC00:\"Errors\: Encoded In \" " ; $def[1] .= "GPRINT:err_enc_in:LAST:\"%3.0lf%s last \" " ; $def[1] .= "GPRINT:err_enc_in:AVERAGE:\"%3.0lf%s avg \" " ; $def[1] .= "GPRINT:err_enc_in:MAX:\"%3.0lf%s max\\n\" "; $def[1] .= "AREA:err_enc_out#EA8F00:\"Errors\: Encoded Out \" " ; $def[1] .= "GPRINT:err_enc_out:LAST:\"%3.0lf%s last \" " ; $def[1] .= "GPRINT:err_enc_out:AVERAGE:\"%3.0lf%s avg \" " ; $def[1] .= "GPRINT:err_enc_out:MAX:\"%3.0lf%s max\\n\" " ; $def[1] .= "AREA:err_trunc#CAF100:\"Errors\: Truncated \" " ; $def[1] .= "GPRINT:err_trunc:LAST:\"%3.0lf%s last \" " ; $def[1] .= "GPRINT:err_trunc:AVERAGE:\"%3.0lf%s avg \" " ; $def[1] .= "GPRINT:err_trunc:MAX:\"%3.0lf%s max\\n\" "; $def[1] .= "AREA:err_crc#FF0000:\"Errors\: CRC \" " ; $def[1] .= "GPRINT:err_crc:LAST:\"%3.0lf%s last \" " ; $def[1] .= "GPRINT:err_crc:AVERAGE:\"%3.0lf%s avg \" " ; $def[1] .= "GPRINT:err_crc:MAX:\"%3.0lf%s max\\n\" "; $def[1] .= "AREA:err_toolong#008A6D:\"Errors\: TooLong \" " ; $def[1] .= "GPRINT:err_toolong:LAST:\"%3.0lf%s last \" " ; $def[1] .= "GPRINT:err_toolong:AVERAGE:\"%3.0lf%s avg \" " ; $def[1] .= "GPRINT:err_toolong:MAX:\"%3.0lf%s max\\n\" "; $def[1] .= "AREA:err_bad_eof#942D0C:\"Errors\: Bad EOF \" " ; $def[1] .= "GPRINT:err_bad_eof:LAST:\"%3.0lf%s last \" " ; $def[1] .= "GPRINT:err_bad_eof:AVERAGE:\"%3.0lf%s avg \" " ; $def[1] .= "GPRINT:err_bad_eof:MAX:\"%3.0lf%s max\\n\" "; $def[1] .= "AREA:err_c3_timeout#FFFF66:\"Errors\: C3 Timeout \" " ; $def[1] .= "GPRINT:err_c3_timeout:LAST:\"%3.0lf%s last \" " ; $def[1] .= "GPRINT:err_c3_timeout:AVERAGE:\"%3.0lf%s avg \" " ; $def[1] .= "GPRINT:err_c3_timeout:MAX:\"%3.0lf%s max\\n\" " ; ?>