[rt-users] Timestamps when logging to a file
Mike Friedman
mikef at ack.Berkeley.EDU
Tue Dec 13 19:26:26 EST 2005
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I believe I've figured out what my problem was. It's really quite simple,
now that I know what it is (!)
In order for my own scripts to pick up modules (i.e., RT.pm) from
local/lib, I need to include that library explicitly in my perl code.
Presumably, RT itself already does this, so it knows to honor overrides in
local/lib.
So, I changed
use lib qw (/usr/local/rt3/lib);
to
use lib qw (/usr/local/rt3/local/lib /usr/local/rt3/lib);
And now my perl scripts are using my modified RT.pm (in which I had
changed 'gmtime' to 'localtime'), so logging from my scripts also uses
local time.
(Fortunately, there's only one occurrence of the above 'use' statement
that I need to change for all my scripts. The statement appears only in
my own perl module where I keep all my functions that use the RT API).
Mike
================================================================================
On Tue, 13 Dec 2005 at 09:35 (-0800), Mike Friedman wrote:
> I think I've found a correlation for transactions that get logged with
> GMT, as opposed to local time. I have several perl scripts that use the
> RT API. It seems that transactions resulting from those scripts get
> logged with GMT, whereas transactions initiated from within RT (usually,
> but not necessarily, triggered by email) get logged in local time.
>
> I still don't understand why this is, or how I can get all transactions
> to be logged in local time. Maybe someone else has some ideas.
_____________________________________________________________________
Mike Friedman System and Network Security
mikef at ack.Berkeley.EDU 2484 Shattuck Avenue
1-510-642-1410 University of California at Berkeley
http://ack.Berkeley.EDU/~mikef http://security.berkeley.edu
_____________________________________________________________________
-----BEGIN PGP SIGNATURE-----
Version: PGP 6.5.8
iQA/AwUBQ59mtq0bf1iNr4mCEQKV1wCgrpNQjiikR2zRIncG3X4NyVCCu5cAoLXt
IJp03mgZGhmZRBJ9Gxg9hDj8
=yFcN
-----END PGP SIGNATURE-----
More information about the rt-users
mailing list