Chessnut / NutScript

A free role-play framework for Garry's Mod.
http://nutscript.rocks
MIT License
94 stars 77 forks source link

MySQL error #466

Closed Aberidius closed 9 years ago

Aberidius commented 9 years ago

There's a problem with the mysql. The database is completely fine although, people get stuck on loadingscreen and it just shows errors in console

Query Error: UPDATE characters SET inv = '', chardata = '~\"attrib_acrv\":n4.315;\"clip1v\":n-1;\"idv\":n1112362532;\"attrib_spdv\":n5.1;\"attrib_endv\":n6.2;\"ammov\":{}\"flagsv\":\"petcnrv\"\"attrib_strv\":n5;', charname = 'Albin Stroström', faction = 4, money = 0, model = 'models/half-dead/civilians/male_04.mdl', gender = 'male', description = '6\'4|Bald|Light Skin|Scottish Dialect|Thick Jacket|Ring Finger Cut Off|Bandage Over Wound|' WHERE steamid = 76561198019375670 AND id = 1 AND rpschema = 'finalhourrp'

MySQL server has gone away

Chessnut commented 9 years ago

Try using tmysql instead

Aberidius commented 9 years ago

I just did, same issue.

Aberidius commented 9 years ago

Example of the error i get in console:

Query Error: UPDATE players SET plydata = '', whitelists = 'military,' WHERE steamid = 76561198019375670 AND rpschema = 'finalhourrp'

Chessnut commented 9 years ago

Did you import the SQL tables?

Aberidius commented 9 years ago

Yes i did

3 maj 2015 kl. 19:59 skrev Brian notifications@github.com:

Did you import the SQL tables?

— Reply to this email directly or view it on GitHub.

Chessnut commented 9 years ago

tmysql should not give the server has gone away error unless it's a problem with your MySQL server. Also I'd advise updating to 1.1 if you can.

franzhoog commented 9 years ago

The same thing is happening to me on 1.0. How would we go about fixing this? I'd ask you on Steam, but you deleted me as you tend to do periodically.

Chessnut commented 9 years ago

The database handler for 1.1 and 1.0 are pretty much identical so I don't know.

On Thu, May 7, 2015 at 3:36 PM, franzhoog notifications@github.com wrote:

The same thing is happening to me on 1.0. How would we go about fixing this? I'd ask you on Steam, but you deleted me as you tend to do periodically.

— Reply to this email directly or view it on GitHub https://github.com/Chessnut/NutScript/issues/466#issuecomment-100039304.

franzhoog commented 9 years ago

Why would both of our databases break simultaneously? Is this related to a recent game update, or what?

Chessnut commented 9 years ago

There hasn't been a recent game update anyways and the server has gone away usually happens when you use mysqloo and the DB has been idle because nothing has happened (like having no players online) so it disconnects.

On Thu, May 7, 2015 at 3:37 PM, franzhoog notifications@github.com wrote:

Why would both of our databases break simultaneously? Is this related to a recent game update, or what?

— Reply to this email directly or view it on GitHub https://github.com/Chessnut/NutScript/issues/466#issuecomment-100039537.

franzhoog commented 9 years ago

How would I go about wiping my database, then? I'll try that and see if that fixes it.

Chessnut commented 9 years ago

nut_recreatedb I think, or you can just use phpMyAdmin if you have that, or use the mysql command line directly.

On Thu, May 7, 2015 at 3:40 PM, franzhoog notifications@github.com wrote:

How would I go about wiping my database, then? I'll try that and see if that fixes it.

— Reply to this email directly or view it on GitHub https://github.com/Chessnut/NutScript/issues/466#issuecomment-100040079.

zack-w commented 9 years ago

You don't need to wipe your database. Just have a timer to poll the database once every few minutes with a basic query like...

SELECT 1+1

Or alternatively overwrite the database connection timeout limit (although this requires SUPER) privileges. Wiping the database will do literally nothing.

Chessnut commented 9 years ago

By the way Hoog, 1.1 does this if you don't mind upgrading ;)

On Thu, May 7, 2015 at 3:42 PM, zack-w notifications@github.com wrote:

You don't need to wipe your database. Just have a timer to poll the database once every few minutes with a basic query like "SELECT 1+1;" or alternatively overwrite the database connection timeout limit (although this requires SUPER) privileges.

— Reply to this email directly or view it on GitHub https://github.com/Chessnut/NutScript/issues/466#issuecomment-100040301.

franzhoog commented 9 years ago

I'm told by a friend that this is pretty easy to fix.

1.1 is a mess as it stands right now - I don't want to deal with that - and I'd lose a ton of functionality if I even attempted to upgrade.

Chessnut commented 9 years ago

1.1 has more functionality and stability than 1.0 if anything

On Thu, May 7, 2015 at 3:45 PM, franzhoog notifications@github.com wrote:

I'm told by a friend that this is pretty easy to fix.

1.1 is a mess as it stands right now - I don't want to deal with that - and I'd lose a ton of functionality if I even attempted to upgrade.

— Reply to this email directly or view it on GitHub https://github.com/Chessnut/NutScript/issues/466#issuecomment-100040740.

zack-w commented 9 years ago

@Chessnut the migration can be a pain due to major functional changes between the two versions

franzhoog commented 9 years ago

Sure, but the schema I'm working on is a year's worth of work. I'm not going to lose all that just for greater stability.

@Chessnut

also, thanks zack for the attempts to help, but that's gibberish to me - i'll have my guy help me out

Chessnut commented 9 years ago

Check if this update fixes it.

franzhoog commented 9 years ago

I was able to fix the issue by wiping my database. Seems that it breaks down periodically.

On Jun 11, 2015, at 5:08 PM, Brian notifications@github.com wrote:

Check if this update fixes it.

— Reply to this email directly or view it on GitHub.

Chessnut commented 9 years ago

The issue has nothing to do with your database tables.