Menu

Graph axis incorrect (see picture)

2014-08-24
2014-12-06
  • Jerry van Kranenburg

    Hi!

    I have PHP Server Monitor installed on my QNAP server to monitor our hosted webserver.
    Everything works fine and I get a Pushover notification when a service stops. Great!!

    But, there is one problem with the graph:
    alternate text

    As you can see it's axis is at 1970.

    Ofcource I checked the database, but data is stored correctly:
    alternate text

    Is there anyone with the same problem? And maybe a solution?

    Thanks :-) :-) and keep up the good work!

    Reg, Jerry

     
  • Wesley

    Wesley - 2014-08-26

    Hi Jerry,

    I have the same issue - including the same date range. My DB seems to be collecting data, too.

    I posted earlier, see the NO GRAPHS posting. I followed the suggestions. I have received no errors and no further suggestions.

    Regards,

    Wesley

     
  • zdeno

    zdeno - 2014-11-19

    solution is very simple:

    in the file history.js change the call of parseInt to parseFloat. it is in this block:

    if($this.attr('data-endTime')) {
        var d = new Date(parseInt($this.attr('data-endTime')));
    } else {
        var d = new Date();
    }
    var time = d.getTime();
    

    just change it to

    if($this.attr('data-endTime')) {
        var d = new Date(parseFloat($this.attr('data-endTime')));
    } else {
        var d = new Date();
    }
    var time = d.getTime();
    
     
  • DanSch

    DanSch - 2014-12-06

    Hi all,
    had the same issue on my QNAP.
    I changed the history.js to the parseFloat value, but still there was no graph and the "last check" showed 7 hours ago!
    When I zoomed the graph I saw a draw.

    Database data are fine too.
    At the end, I checked the php.ini of the QNAP and there was the problem.

    [Date]
    date.timezone = "Asia/Taipei"

    After changed to the correct on, in my case "Europe/Berlin" I got the correct last check and also a correct graph.

    Maybe there will be something in the next version that checks the server timezone.

     

Log in to post a comment.