[rrd-users] Re: UTC - GMT convertion

Clifton Royston cliftonr at lava.net
Wed Nov 21 21:45:50 MET 2001

On Wed, Nov 21, 2001 at 02:19:31PM -0500, Tekin Gulsen wrote:
> Hello,
> A couple of quick questions;
> 1) I have a program that constantly updates the database. How can I retrieve
> the dates of the oldest and the newest data in an RRD database.
> 2) Is there a utility or command for unix systems that converts the GMT time
> to UTC and vice versa? Since the graphs will be generated by a program, the
> dates need to be converted in the program. I can use "date +%s" command to
> convert the current date and time to UTC but doing the convertion for a
> previous date is a problem.

  GMT == UTC, yes?  Did you mean converting local times to GMT/UTC, or
were you meaning UNIX epoch time when you wrote "UTC"?

  Either way, I recommend you try the too-little-known "convdate"
utility, which should be on most UNIX systems because it's a part of
the INN distribution.  convdate -n will take a string with a date/time
and output the corresponding UNIX time.  "man convdate" for more info
and some illuminating examples.

  -- Clifton

 Clifton Royston  --  LavaNet Systems Architect --  cliftonr at lava.net
   WWJD?   "JWRTFM!" - Scott Dorsey (kludge)   "JWG" - Eddie Aikau

Unsubscribe mailto:rrd-users-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:rrd-users-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/rrd-users
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi

More information about the rrd-users mailing list