URL: https://www.opennet.me/cgi-bin/openforum/vsluhboard.cgi
Форум: vsluhforumID12
Нить номер: 5244
[ Назад ]

Исходное сообщение
"Synchronize squid time with hardware system time ?"

Отправлено eXtremer , 23-Ноя-07 12:30 
Synchronize squid time with hardware system time ?
Cose when the ERR_ message appears it show an incorect time.
For example, the system time now is :
Fri Nov 23 11:24:14 EET 2007

But the squid ERR_ shows:
Generated Fri, 23 NOV 2007 09:24:14 GMT

And I see that the Timez Zones are different EET and GMT.
I need squid to show the system time.

Wating for a reply, thanks in dvance.


Содержание

Сообщения в этом обсуждении
"Synchronize squid time with hardware system time ?"
Отправлено ipmanyak , 23-Ноя-07 14:02 
I want to use local time zone in error messages
Squid by defaults uses GMT as timestamp in all geenrated error messages. This to allow the cache to participate in a hierarchy of caches in different timezones without risking confusion about what the time is.
To change the timestamp in Squid generated error messages you must change the Squid signature. See faq or wikipedia - Customizable Error Messages. The signature by defaults uses %T as timestamp, but if you like then you can use %t instead for a timestamp using local time zone.

p.s

My method.
Find in directory src file errorpage.c , then find in this file string
"Generated %T by %h (%s)\n"
change it to
"Generated %t by %h (%s)\n"

Recompile squid. Good luck.



"Synchronize squid time with hardware system time ?"
Отправлено eXtremer , 23-Ноя-07 14:17 
>[оверквотинг удален]
>p.s
>
>My method.
>Find in directory src file errorpage.c , then find in this file
>string
> "Generated %T by %h (%s)\n"
>change it to
> "Generated %t by %h (%s)\n"
>
>Recompile squid. Good luck.

Ahams, thanks ipmanyak, I will check it out tommorow.


"Synchronize squid time with hardware system time ?"
Отправлено eXtremer , 26-Ноя-07 10:34 
>[оверквотинг удален]
>p.s
>
>My method.
>Find in directory src file errorpage.c , then find in this file
>string
> "Generated %T by %h (%s)\n"
>change it to
> "Generated %t by %h (%s)\n"
>
>Recompile squid. Good luck.

Sorry ipmanyak but I can't find the "src" directory and the errorpage.c,
I've read this: http://wiki.squid-cache.org/SquidFaq/MiscFeatures#head-fd8f5...
...and still cannot figure out where to put the %t.
In the ERR_messages there is nothing like %T..