-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
incorrect X-axis value plotted #9
Comments
What timezone are you in? If the server on which the TSD is running isn't currently set to use your local time, you need to tell the TSD which time zone to use in order to render timestamps. You do so by running this command once in the root directory of OpenTSDB: |
My timezone is GMT+8 (China,Shanhai), so I've done this:
And I've verified my timezone by using zdump command:
But still the graph seems 10 hours earlier than my local time although I've restarted both opentsdb and hbase. |
If you look at the logs of the TSD, do the timestamps appear in your local timezone, or are they also incorrect? I suspect that they will be incorrect too, which means that the TSD didn't pick up the If the timestamps in the log are correct, but the graphs are still off, then there's another problem somewhere else. |
The timestamps in TSD are correct: which starts from Mon Feb 07 2011 12:00:00 GMT+0800 (China Standard Time), end at Mon Feb 07 2011 15:05:31 GMT+0800 (China Standard Time). Since only the graph is incorrect, is this related to Gnuplot? |
Sorry, I wasn't clear enough. I was asking you whether the time on each log line in the TSD's log was correct. Note: the UNIX timestamps (such as |
Okay, the TSD's log is correct.
Thanks for note :) |
OK, this is really weird then. When you make a query, if you look in the cache directory of the TSD, you should see a bunch of Also I'd like to know what's the output of |
Sorry, my gnuplot is a very old one: The time stamp in the
Now I'll try to upgrade gnuplot to 4.4 patchleve 2. |
Problem solved. It's actually a gnuplot issue. On the website it reads:
So It's my fault to neglect warnings, I just proved that 4.0 is incompatible with TSD, lol. Thanks for you time. |
I think the timestamp in the file is correct, because 1297093200 is Mon Feb 7 15:40:00 2011 in CST (your time zone). Let me explain what's going on under the hood: timestamps are always in UTC, so whenever the TSD receives and stores a timestamp, it doesn't change it, because no adjustment is needed if your data source is providing a correct UNIX timestamp. When you make a query, the TSD retrieves the data points and passes them on to Gnuplot. The problem is that you can't tell Gnuplot what timezone to render the timestamps in, it always renders them in UTC. So the TSD has to adjust the timestamps so that they're rendered correctly for your time zone. This happens in So, let's recap:
|
So, just to be clear, did you upgrade Gnuplot and the problem went away? Maybe Gnuplot changed the way they were handling timestamps? Please confirm whether upgrading Gnuplot fixed the issue for you. |
Confirm. After upgrading from 4.0 patchlevel 0 to 4.4 patchlevel 2, the issue is fixed.
Correct.
Correct.
No, 1297093200 is
Actually, the generated graph is very strange, I've uploaded an incorrect one here: http://op.sdo.com/download/gnuplot-graph.png. If it is an timezone issue, then the wrong graph should be 8 hours earlier than the given input value. However, the different is 10 hours which is peculiar. |
OK, I know what this problem is. You're using a buggy version of Gnuplot. I've had this problem in the past. The version you have is clipping the first character off the label of the X axis. I'm trying to find the reference to the bug report. Please upgrade your version of Gnuplot to one that doesn't have this bug. |
Test hbase store
In my case, the start time is set to 2011/02/06-12:00:00 and the To is "now".
However, in the result graph, the X-axis is plotted like 2:00, 3:00, 4:00 instead of 12:00, 13:00 and 14:00.
The text was updated successfully, but these errors were encountered: