Login

Username:


Password:


Remember me



Forgot Password?




 Merchandise




Problems with dates on topics/posts

Please post help requests in the Helpdesk forum. This forum is to be used for discussing the site, and events/projects.

Problems with dates on topics/posts

Postby Spack » Tue Apr 22, 2014 5:46 pm

For some weird reason the date on the server jumped forward by 1 day on Sunday 20th April, and reverted back early this afternoon on the 22nd April. This has happened a few times now, and isn't a problem with the site itself - something on the hosting server gets changed and affects all of the hosted servers including AoS. I've fixed times on posts and topics, and the last post time on user accounts (as this was blocking users from making new posts if they had posted since 1pm yesterday). If other issues crop up I will fix them as they make themselves known.

If anyone notices anything odd please let me know and I'll look into it.
User avatar
Spack
I R Ginger
Field Marshall
 
Posts: 6815
Joined: Sat Feb 12, 2005 12:00 am
Location: Birmingham, UK
Medals: 2
Bronze (1) Painting Entrant (1)
Blog: View Blog (29)

Re: Problems with dates on topics/posts

Postby KInG » Tue Apr 22, 2014 7:02 pm

Explains why DL face booked me about not getting to post.
www.GamingFigures.com & http://www.AgeofStrife.com 15% off GW models 10% off FoW & GF9 - extra 1% off orders £100+ & 2% off orders £250+ with FREE UK SHIPPING now added
AoS_GF moderator
Image
User avatar
KInG
Archon
Archon
 
Posts: 5209
Joined: Sun Mar 13, 2005 12:00 am
Medals: 2
Painting Entrant (2)

Re: Problems with dates on topics/posts

Postby KInG » Tue Apr 22, 2014 7:25 pm

View new posts seems to not be working either dan.
www.GamingFigures.com & http://www.AgeofStrife.com 15% off GW models 10% off FoW & GF9 - extra 1% off orders £100+ & 2% off orders £250+ with FREE UK SHIPPING now added
AoS_GF moderator
Image
User avatar
KInG
Archon
Archon
 
Posts: 5209
Joined: Sun Mar 13, 2005 12:00 am
Medals: 2
Painting Entrant (2)

Re: Problems with dates on topics/posts

Postby Spack » Tue Apr 22, 2014 9:50 pm

Doh, it uses "user_lastvisit" to determine when the previous user session started to find "new" posts, and because that was also set forward 23 hours it's not finding anything. I've adjusted this value for the users affected, hopefully it will work.

EDIT: didn't work. By the time I figure out how to fix it the problem will have sorted itself out anyway, but I'll make a note in case it happens again in the future.
User avatar
Spack
I R Ginger
Field Marshall
 
Posts: 6815
Joined: Sat Feb 12, 2005 12:00 am
Location: Birmingham, UK
Medals: 2
Bronze (1) Painting Entrant (1)
Blog: View Blog (29)

Re: Problems with dates on topics/posts

Postby KInG » Wed Apr 23, 2014 12:05 am

No problem mate. I'm sure we'll manage for 24 hours. :)
www.GamingFigures.com & http://www.AgeofStrife.com 15% off GW models 10% off FoW & GF9 - extra 1% off orders £100+ & 2% off orders £250+ with FREE UK SHIPPING now added
AoS_GF moderator
Image
User avatar
KInG
Archon
Archon
 
Posts: 5209
Joined: Sun Mar 13, 2005 12:00 am
Medals: 2
Painting Entrant (2)

Re: Problems with dates on topics/posts

Postby Darklighter » Wed Apr 23, 2014 12:36 am

Lol I was just about post about new topics not showing up....
What, no image sigs!
Darklighter
Shas'el
Shas'el
 
Posts: 1018
Joined: Sat Jul 31, 2010 3:47 pm
Location: Redcar
Medals: 19
Gold (3) Silver (2) Bronze (1) Painting Entrant (13)

Re: Problems with dates on topics/posts

Postby Spack » Wed Apr 23, 2014 8:47 am

Got a response back from the hosting company, apparently there was an issue with the NTP configuration on the host server that caused the time to jump forward by 1 day on reboot, and it was rebooted on Sunday. They've assured me that the problem has been fixed and it won't happen again, but I'll be adding a time check process to email me if it slips again. I can't automate correcting the time because my VPS time is sync'd to the host server, and only the hosting company can change the time on the host OS.
User avatar
Spack
I R Ginger
Field Marshall
 
Posts: 6815
Joined: Sat Feb 12, 2005 12:00 am
Location: Birmingham, UK
Medals: 2
Bronze (1) Painting Entrant (1)
Blog: View Blog (29)

Re: Problems with dates on topics/posts

Postby Angelwing » Wed Apr 23, 2014 8:49 am

is this a poor mans Y2K bug? ;)
User avatar
Angelwing
Zoanthrope
Zoanthrope
 
Posts: 2311
Joined: Thu Sep 20, 2007 12:00 am
Location: Bridgwater, Somerset
Medals: 17
Gold (5) Silver (1) Painting Entrant (11)

Re: Problems with dates on topics/posts

Postby Spack » Wed Apr 23, 2014 9:24 am

At least with Y2K you could predict when it was going to happen :P

I've now set up a script that runs every hour, grabbing an RFC date/time from a remote source and comparing it to the local date/time. If it's off by more than 1 hour it will send me an email, and throw an error to syslog. This will then allow me to get the hosting company to look into it as soon as it happens, if it does it again.
User avatar
Spack
I R Ginger
Field Marshall
 
Posts: 6815
Joined: Sat Feb 12, 2005 12:00 am
Location: Birmingham, UK
Medals: 2
Bronze (1) Painting Entrant (1)
Blog: View Blog (29)

Re: Problems with dates on topics/posts

Postby KInG » Wed Apr 23, 2014 11:51 am

wow, your skills are unlimited :) awesome work
www.GamingFigures.com & http://www.AgeofStrife.com 15% off GW models 10% off FoW & GF9 - extra 1% off orders £100+ & 2% off orders £250+ with FREE UK SHIPPING now added
AoS_GF moderator
Image
User avatar
KInG
Archon
Archon
 
Posts: 5209
Joined: Sun Mar 13, 2005 12:00 am
Medals: 2
Painting Entrant (2)

Re: Problems with dates on topics/posts

Postby timewizard » Wed Apr 23, 2014 1:16 pm

That explains why I wasn't seeing all the new posts!

Thanks Dan.
"I have found again and again that in encounter actions, the day goes to the side that is the first to plaster its opponent with fire." - Erwin Rommel
User avatar
timewizard
Master of Chronomancy
Field Commander
 
Posts: 5896
Joined: Fri Sep 21, 2007 12:00 am
Location: (TWAT Colonial Outpost) in the eastern USA
Medals: 11
Gold Wreath (1) Gold (1) Silver Wreath (1) Bronze (2) Painting Entrant (6)
Blog: View Blog (2)

Re: Problems with dates on topics/posts

Postby Spack » Fri Apr 25, 2014 1:57 pm

After a bit more digging around and posting messages back and forth with my hosting provider it looks like the NTP daemon wasn't updating the hardware clock, so each time the server was rebooted the clock was wrong by 24 hours as it had been initially set to the wrong day. ntpd wasn't starting on boot up, so the host OS clock was wrong, and therefore all guest VPS clocks were wrong too. Each time it was reported the clock appears to have been updated manually, or ntpd started at that point, so it would then be fine until the next reboot - at which point it would kick back to being 1 day out due to the hardware clock (the one set by the BIOS) still being wrong. They've now confirmed that the ntpd service is correctly configured to start up on reboot, and that it has been configured to update the hardware clock too, so the next reboot shouldn't cause the time to change.

I've still got my little script checking every hour with a remote source, and ready to email me if there's a problem. I can't use ntpd as it's unable to update the guest VPS clock due to the way in which the virtualisation software works - all guest VPS clocks are linked to the host server clock, and there's no way for a guest VPS to set it's own clock or affect the host server clock.
User avatar
Spack
I R Ginger
Field Marshall
 
Posts: 6815
Joined: Sat Feb 12, 2005 12:00 am
Location: Birmingham, UK
Medals: 2
Bronze (1) Painting Entrant (1)
Blog: View Blog (29)

Re: Problems with dates on topics/posts

Postby timewizard » Fri Apr 25, 2014 2:43 pm

I had noticed that sometimes I had to "backtrack" to see all the new posts. Now I know why.

Thanks again for the explanation and for working on it!
"I have found again and again that in encounter actions, the day goes to the side that is the first to plaster its opponent with fire." - Erwin Rommel
User avatar
timewizard
Master of Chronomancy
Field Commander
 
Posts: 5896
Joined: Fri Sep 21, 2007 12:00 am
Location: (TWAT Colonial Outpost) in the eastern USA
Medals: 11
Gold Wreath (1) Gold (1) Silver Wreath (1) Bronze (2) Painting Entrant (6)
Blog: View Blog (2)

Re: Problems with dates on topics/posts

Postby Spack » Fri Apr 25, 2014 2:44 pm

TW, should have only affected things from Sunday morning to Wednesday afternoon. If you've still got issues let me know and I'll look into it.
User avatar
Spack
I R Ginger
Field Marshall
 
Posts: 6815
Joined: Sat Feb 12, 2005 12:00 am
Location: Birmingham, UK
Medals: 2
Bronze (1) Painting Entrant (1)
Blog: View Blog (29)




Return to The Site




 Social Links