I was recently trying to backup one of my databases over PuTTY/SSH for a server move. Using the following:
mysqldump -hlocalhost -uUSERNAME -pPASSWORD DATABASE > filename.sql
I was getting the following error:
mysqldump: Got error: 1105: File ‘./Database-Names/table_comments.MYD’ not found (Errcode: 24) when using LOCK TABLES
I couldn’t find a work around at first and most search results kept coming back to a bug in MySQL, which advised to make changes to the memory allowance, in this case that wasn’t an option.
I then came across http://www.webhostingtalk.com where a user by the name of SROHost mentioned that using:
–lock-tables=false
should fix the problem, well it did and for that I’m really grateful. As usual I tend to blog this stuff on my site, it serves to keep a personal record for me and to potentially help someone else in need.
mysqldump –lock-tables=false -hlocalhost -uUSERNAME -pPASSWORDÂ DATABASE > filename.sql
Note: This happening with a WordPress database.
Being new to cPanel and whm I’ve had a little bit of a learning curve, I’ve never really had this much access to a production server before. Our servers used to be with 1&1 but they are absolute crap and don’t ever know what they are talking about, now we’re no longer with them I’m happy. Being with them gave very limited access on a managed server.
Anyway I was trying to set a crontab and cPanel has this cool feature to set them up, but it kept displaying:
/usr/bin/crontab permissions are wrong. Please set to 4755
If you tried to set up a crontab in ssh you’d get a permission denied message.
To fix this you need root access to your server, log in and enter the following:
chmod 4755 /usr/bin/crontab
This will change the permissions for you.
If you don’t have root access then you will need to contact your service providers and ask them