Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timezone support in the display layer #500

Open
LordFPL opened this Issue Feb 2, 2015 · 15 comments

Comments

Projects
None yet
@LordFPL
Copy link

LordFPL commented Feb 2, 2015

Hi all,

Is there a way configure a timezone ? I'm always in gmt time... i try to change with a new build with a dockerfile like this :

FROM prom/prometheus
RUN echo "Europe/Paris" > /etc/timezone && dpkg-reconfigure -f noninteractive tzdata

Not the good way ?

@juliusv

This comment has been minimized.

Copy link
Member

juliusv commented Feb 2, 2015

Hi, since servers usually run on GMT and that is the common time for correlating things from monitoring, logs, etc. with another, we do everything explicitly in GMT at the moment. I'm open for suggestions on how time zones could/should be configurable...

@beorn7

This comment has been minimized.

Copy link
Member

beorn7 commented Feb 2, 2015

I guess we should have an FAQ about the timezone issue.

@juliusv

This comment has been minimized.

Copy link
Member

juliusv commented Feb 2, 2015

@LordFPL To clarify, this is mainly a display issue, right? I.e. in the UI you want to be able to choose between GMT and local time?

@LordFPL

This comment has been minimized.

Copy link
Author

LordFPL commented Feb 2, 2015

@juliusv Yes, it's only a display issue. Choose between gmt/local will be a very good solution, or at least, take the host config. Thx in advance :)

@juliusv

This comment has been minimized.

Copy link
Member

juliusv commented Feb 2, 2015

@LordFPL Well, it's a valid feature request, but low priority for us at the moment. But we welcome contributions :) Or maybe I'll get bored one weekend and do it...

@LordFPL

This comment has been minimized.

Copy link
Author

LordFPL commented Feb 3, 2015

@juliusv This is just a minor feature yes.

My message initially trying to see if it was possible to do it now.

The end result is mainly cosmetic ;)

@beorn7 beorn7 changed the title Timezone support ? Timezone support in the display layer Feb 3, 2015

@jack230230

This comment has been minimized.

Copy link

jack230230 commented Dec 24, 2015

any follow up?

@fabxc

This comment has been minimized.

Copy link
Member

fabxc commented Dec 24, 2015

As before, we are open to review and help with contributions but currently do not have capacity to spend time on it ourselves.

@beorn7

This comment has been minimized.

Copy link
Member

beorn7 commented Dec 28, 2015

I'm tempted to file a bug against several governments on this planet and add it as a blocker to this feature request: "Your timezone has a fatal design error: The time inexplicably has a gap of 3600s once per year, and at another time once per year, it jumps back 3600s, breaking monotonicity. That renders your timezone unusable for most purposes of time measurement and display."

@LuboVarga

This comment has been minimized.

Copy link

LuboVarga commented Jan 17, 2017

Hi @beorn7 , there is same issue with GMT if I am not wrong. But that one is irregular and smaller scale. It is called leap second. How do you deal with that? I know that visualization of "time going backward" is an issue, but I would also like prometheus charts in local time (optionally) and I could live with some error message like "In selected period of time, time has stepped back and thus effectively making graph with non-monotonous X-axis unrendable. To visualize things, please switch back to GMT time visualization.".

PS: Use-case for local time is correlating things with people calling to support (they are referring always to local time) or to kibana/elasticsearch.

@beorn7

This comment has been minimized.

Copy link
Member

beorn7 commented Jan 17, 2017

The leap second issue is problematic on a much different level. As we concluded elsewhere, it's not even clear how the time package in the Go standard library is supposed to handle it. Unix time usually ignores it, and the de-facto standard is to "smear out" leap seconds over about a day. The same will effectively apply to Prometheus, as it is Unix-time basedp

@0cjs

This comment has been minimized.

Copy link

0cjs commented Jul 12, 2017

@LuboVarga: It's not an issue with GMT; GMT does not observe any kind of daylight savings time. Britain uses GMT only during the winter; during the summer it uses BST, which is one hour forward of GMT.

But in general, you ought not use the term GMT because the meaning attributed to it varies (some systems even consider it to be equivalent to BST during the summer, contrary to the actual definition of BST). Instead use UTC, which unambiguously does not observe any sort of daylight savings time.

@jackyliusohu

This comment has been minimized.

Copy link

jackyliusohu commented Dec 15, 2017

Docker in the time zone is still wrong to amend

@kevinniu666

This comment has been minimized.

Copy link

kevinniu666 commented Apr 15, 2019

Hope this can be resolved soon.

@NicholasLuo666

This comment has been minimized.

Copy link

NicholasLuo666 commented Apr 15, 2019

Hope this to be done soon,it's really unconvenient to just only use UTC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.