Jump to content
TNG Community

max_user_connections and 503 (server unresponsive) code


randalrh

Recommended Posts

This is to some extent a follow-on to a previous post, but the current context seems different enough to warrant a new one.  On https://rheinheimer.site, running TNG V15, I can display the home page and (now) log in as an admin, but clicking on any link that looks something up in the database spins and times out with a 503 error.  What I (and Claude) have done so far:  updated .htaccess to block most bots and created a script to check the max_user_connections to the database (20) and the current number of connections.  I'm not currently connected to the site, my "users" are a few members of my family, and the number of connections according to the script is 11.  Earlier today, I had 5 connections, clicked a getperson link, ran the script again, and immediately saw 15 connections.  I, Claudius is convinced TNG isn't cleaning up connections, but that is not my non-AI intuition, and 5, 11, and 15 are all less than 20, so I don't see why the database should time out and give me a 503 return code.  Has anyone seen something similar or have any theories about this behavior?

Thanks, Randal

Link to comment
Share on other sites

Rob Severijns

Randal,

There's a great mod that allows you to regulate which bots are allowed and which ones aren't.
Have a look at Bot Manager - TNG_Wiki by @Steve1200

Not sure why you want to set a max_user_connections for your site. Is there a specific reason?
Mayby the info on this site is helpfull: 
MySQL max_user_connections vs max_connections: Clarifying Their Relationship, Misconceptions & How They Impact Each Other — codegenes.net

Also have a look at Who is online - TNG_Wiki by @Michel KIRSCH to show you which users are logged in.

Link to comment
Share on other sites

max_user_connections is set by my hosting service, not by me.  I don't know if I can override it or not, but I don't really think it's the problem.

I will have a look at the resources you suggest, but I increasingly think all my issues come back to the file system of my hosting server.  I was able to get around the 503 return code by bypassing the log file locks in log.php and adminlog.php.  I know that's not ideal, but I'm very unlikely, given my level of traffic, to have log files being written by two sessions at the same time.  As for my admin status not persisting, I have a ticket in with ipage about why the location I'm supposed to be using for session IDs is not writable.  I'm using /tmp at the moment, but still getting weird behavior from admin_setup.php, which either redirects me to the login page, the home page, or sometimes the last getperson page I looked at.  It was not this hard to upgrade from TNG V13 to V14, but I'm increasingly convinced the problems are not with V15 but with my hosting service.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...