[mythtv-users] Mythweb timezone question

Andrey Zhunev a-j at a-j.ru
Sat Nov 12 18:03:03 UTC 2011


Hello Michael,

Saturday, November 12, 2011, 9:14:00 PM, you wrote:

> On 11/12/2011 11:12 AM, Andrey Zhunev wrote:
>> After recent daylight saving time switch, I'm having an issue with
>> MythWeb time being one hour earlier than it should be.

> What do you mean by this?

Here's an example:

Current actual time is 21:28 (or 09:28PM).

In the upper right corner of MythWeb, I can see the time is 20:28.

The "TV listings" are off by 1 hour, too - according to MythWeb, the
next show is to start at 20:30 (in 2 minutes from now), while it
will actually start at 21:30 (which is the 2 minutes from now).

"Recorded Programs" are shifted by 1 hour as well. A show I recorded
today from 17:00 to 18:00 (actual time) is displayed in MythWeb as
recorded from 16:00 to 17:00.



>> date.timezone = Etc/GMT+4

> You almost certainly don't want this one--you want:

> date.timezone = Europe/Moscow

> although Etc/GMT+4 has the same time right this minute as as 
> Europe/Moscow, they have had different times over the years.  Using 
> Etc/GMT+4 (and such) is basically equivalent to just setting your clock
> to local time--which will break MythTV because MythTV needs to know the
> current time offset /and/ the offset for every point in the past (since
> you started using MythTV) and in the future (for as long as you continue
> to use MythTV).

Our lovely government recently decided that we (Russia) should not
switch to/from daylight saving time anymore. Instead, we are
permanently staying on summer time, which is GMT+4. So from now on, we
are fixed to GMT+4 (until they decide on something else).

While Linux timezone data is easily updated by means of tzdata file,
I couldn't find an easy way to update php with recent timezone
changes. I'm pretty sure my php version doesn't know what our
government decided - so I thought I would just tell it to stick to
"Etc/GMT+4". The only drawback that I see is that my old recordings'
start and end times could appear shifted in MythWeb. I can live with
that.


> That said, MythWeb requests the current time zone from the master
> backend system and then applies whatever time zone is set on the master
> backend (because the important thing is that all MythTV hosts agree on
> the rules for applying offsets, not just on the current offset).  
> Therefore, date.timezone isn't used (unless you're using a really old 
> MythTV).

I have mythbackend, apache http server and mythfrontend running on the
same machine. I'm accessing mythweb from another machine (I guess it
shouldn't matter, but this machine's timezone is also set to GMT+4).

The time is correct everywhere, except for Mythweb - as I explained
above...


> Mike

-- 
Best regards,
 Andrey             



More information about the mythtv-users mailing list