AAO25.com

Assist => Support => Topic started by: 82nd_DXO_COL=Shad on Monday, March 16, 2015, 21:19:52 PM

Title: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: 82nd_DXO_COL=Shad on Monday, March 16, 2015, 21:19:52 PM
aao25.com/vortex servers went down at 2100 EST as well as auth
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Spanky on Monday, March 16, 2015, 21:22:16 PM
The SMF error is due to Assist going down and causing a timeout on the PHP scripts for this site. It's the stats code that refreshes every 5 minutes when the next page is requested (by any user). Problem was, PHP's get_headers waits for a response or times out after the default 30 or 60 seconds. Once that happens, the SMF database connection gets refused and throws an error.

I've re-worked the function (again, thought I fixed it before) and it looks like it's working despite Assist being down.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: 82nd_DXO_COL=Shad on Monday, March 16, 2015, 21:37:39 PM
Always thought this was VBulletin.  fsocketopen routine with a $timeout might fail more gracefully
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Spanky on Monday, March 16, 2015, 21:48:48 PM
Nope, highly customized SMF :) We're too cheap to pay for VBulletin.

I've had a hard time in the past getting connections to fail gracefully. I think I have used fsocketopen but the stat code currently on this site was rewritten by Jared and despite it having a fail check, it wasn't graceful. There's still a delay here, I've got the timeout set at 2 seconds. Might change it to 1 but it seems to be working fine.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Nick on Tuesday, March 17, 2015, 00:06:34 AM
aao25.com/vortex servers went down at 2100 EST as well as auth

I can confirm that there was not maintenance or downtime on Vortex Servers end.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Spanky on Tuesday, March 17, 2015, 00:43:42 AM
Well the CURL code was bogus, switched over to a fsocketopen and looks like everything works... properly. Thanks for reminding me of that function Shad.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Petrol on Tuesday, March 17, 2015, 02:25:35 AM
60$ is bit to much for what you need to keep this game alive.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: teddy_grizzly_bear on Tuesday, March 17, 2015, 02:36:19 AM
And you know this because?

It's not a number just thought out of thin air.
Our month server costs end up being around $60.00 USD a month. Anything you donate will go straight to server cost and will help keep Assist moving forward.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Possessed on Tuesday, March 17, 2015, 03:20:43 AM
And its mostly for the auth hosting, the costs would be higher if we didnt had a partner :D
Not much time ago, Sergio paid all costs by him self.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Spanky on Tuesday, March 17, 2015, 13:29:24 PM
It's ONLY for the auth hosting. This website & the official game servers are sponsored by Vortex Servers. The work is volunteered.

I'm not sure what your point is, especially posting in this thread.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Petrol on Tuesday, March 17, 2015, 15:08:19 PM
60$ for auth is definitly to much.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Spanky on Tuesday, March 17, 2015, 15:28:28 PM
Instead of saying that, you could pretend to be helpful and ask how much bandwidth and disk space it uses, what kind of setup it is and recommend other hosts that might save us costs.
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Nick on Tuesday, March 17, 2015, 15:46:56 PM
Instead of saying that, you could pretend to be helpful and ask how much bandwidth and disk space it uses, what kind of setup it is and recommend other hosts that might save us costs.

My offer still stands whenever we are ready to move the auth :)
Title: Re: Connection Problems Sorry, SMF was unable to connect to the database.
Post by: Petrol on Wednesday, March 18, 2015, 08:44:41 AM
Nope...