Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I get the above error from time to time from my blog's database. It's annoying, but it's normally easily fixed by opening phpMyAdmin and running a "repair table" on all tables (I usually also do a "check" and an "optimize" just for good measure).
My question is more of a background question. Although I know a bit about MySQL and MariaDB and a lot about phpMyAdmin, I am by no means qualified to be an database admin.
Here's the question: what kinds of problems in the database may cause this error? Inquiring minds want to know.
Please note this is not an urgent cry for help. It's mild cry for knowledge.
Distribution: Ubuntu, OpenSUSE, Mythbuntu, Embedded Linux
Posts: 46
Rep:
Whilst I am not an expert to say the least.
Your error message reads to me like its the port connection that the DB is failing to use.
Usually on MySQL the port 3306 is used by default. I would check and see what port your Maria-DB & MySQL-DB uses in their configuration file(s). Also see what ports are uses by "netstat -a -p" preferably as root.
Maybe there is more than one service trying to use the assigned DB port, hence intermittent error(s) when a less active process tries to use the same port # or two services collide. Of course you would expect that all processes would open/use/close with port locking but maybe that is not happening for some unknown reason. However is it probably something much more simple (always is after you stumble on the fix IMHO).
My experience with systems that hang || halt at times usually because of older process mistakes leaving corrupted code hanging around unfortunately. So, dependent on the Linux Distro your currently using, run checks on the DB & php packages to ensure no code corruption or incomparability. I typically do "apt upgrade" as su.
Also after errors happening again go and investigate all associated logs eg:
sudo tail -n 100 /var/log/system | grep Database // See what happening to your DB process
"Hopefully the mental horizon traveled is a little further out of the darkness."
Cheers G.
Last edited by WildPossum; 09-15-2017 at 01:39 AM.
Your error message reads to me like its the port connection that the DB is failing to use.
That makes sense. Note that this on a VPS provided by my hosting provider.
I guess I'm asking what may be making it fail. Since doing routine database management tasks makes the error go away, I'm guessing that it's something errant in the tables, but my guess could be way off base.
Distribution: Ubuntu, OpenSUSE, Mythbuntu, Embedded Linux
Posts: 46
Rep:
Have you asked your Providers Support Team.
Hi again.
I would suggest -- if you haven't already done so -- is to ask your VPS providers' support people have they seen this problem before (they may have incorrectly configured your service so have them check this out!). Are they aware of any issues on their side where delayed DB management [scripts] maybe tardy in correcting issues i.e.: causing what your seeing.
And what if anything that your kicking off DB admin seems to correcting back on their severside.
Apart from this unfortunately I am not able to assist you much more.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.