[rrd-users] Show day number and name

rrd-users at ficos.de rrd-users at ficos.de
Tue Dec 1 11:28:54 CET 2009


Dod schrieb:
> Hello,
> 
> Depending how many days I want to graph, rrdtool automatically adapt
> the horinzontal date format.
> 
> How do I force it showing day name instead of day number ?

Hi Dod,

see man rrdgraph and try the examples in there/below.
(see man strftime for the date fmt strings)

BUT: you will manually have to adapt your new X-Grid depending on the
time period you're showing - normally the autoscaler does all that ...


X-Grid
    [-x|--x-grid GTM:GST:MTM:MST:LTM:LST:LPR:LFM]

    [-x|--x-grid none]

    The x-axis label is quite complex to configure. If you don't have
    very special needs it is probably best to rely on the autoconfigu-
    ration to get this right. You can specify the string "none" to
    suppress the grid and labels altogether.

    The grid is defined by specifying a certain amount of time in the
    ?TM positions. You can choose from "SECOND", "MINUTE", "HOUR",
    "DAY", "WEEK", "MONTH" or "YEAR". Then you define how many of
    these should pass between each line or label.  This pair (?TM:?ST)
    needs to be specified for the base grid (G??), the major grid
    (M??) and the labels (L??). For the labels you also must define a
    precision in LPR and a strftime format string in LFM.  LPR defines
    where each label will be placed. If it is zero, the label will be
    placed right under the corresponding line (useful for hours, dates
    etcetera).  If you specify a number of seconds here the label is
    centered on this interval (useful for Monday, January etcetera).

     --x-grid MINUTE:10:HOUR:1:HOUR:4:0:%X

    This places grid lines every 10 minutes, major grid lines every
    hour, and labels every 4 hours. The labels are placed under the
    major grid lines as they specify exactly that time.

     --x-grid HOUR:8:DAY:1:DAY:1:86400:%A

    This places grid lines every 8 hours, major grid lines and labels
    each day. The labels are placed exactly between two major grid
    lines as they specify the complete day and not just midnight.



More information about the rrd-users mailing list