Check the below URL :
http://admin.webhostingdevelopment.com/viewtopic.php?f=108&t=115&p=130#p130
Check the below URL :
http://admin.webhostingdevelopment.com/viewtopic.php?f=108&t=115&p=130#p130
Getting the error “ERROR 2002 (HY000): Can’t connect to local MySQL server through socket ‘/var/lib/mysql/mysql.sock’ (2)” while I try to connect to mysql via a jailed shell enabled user.
[email protected] [~]# mysql
ERROR 2002 (HY000): Can’t connect to local MySQL server through socket ‘/var/lib/mysql/mysql.sock’ (2)
[email protected] [~]#
Solution :
http://admin.webhostingdevelopment.com/viewtopic.php?f=84&t=74
You need to specify the hostname so you can connect.
mysql -h=127.0.0.1 -u user_name -p
or
mysql -h=localhost -u user_name -p
This mainly happens if you terminated a cpanel account and somehow the MySQL user was not deleted properly.
Solution : Try deleting the mentioned user.
Delete the user :
mysql
mysql > use mysql;
mysql > drop user testusr7@localhost;
OR
mysql> delete from mysql.user where user=’testusr7′;
You can aslo check this using :
select User, Host from user where User like ‘%testusr7%’;
Now try restoring/recreating whatever you were trying to do and see if you still receive the error.
If yes do
grep testusr7 /var/cpanel/databases/users.db
grep testusr7 /etc/dbowners
If the user exist in the above files, delete that and try again.
OR
create a cpanel user with name “testusr7777″.
Modify account and rename that to “testusr7″
Terminate the account from WHM
It fixed for me!!!
Login to mysql.
mysql -u root -p
In mysql prompt use
mysql> use mysql;
Now change the password for user “arun” to “secret123″ as below :
[ mysql> update user set password=PASSWORD("secret123") where User='arun'; ]
Download and install the phpmyadmin as :
cd /usr/local/apache/htdocs
wget http://iweb.dl.sourceforge.net/project/phpmyadmin/phpMyAdmin/3.4.4/phpMyAdmin-3.4.4-english.tar.gz
tar -xzvf phpMyAdmin-3.4.4-english.tar.gz
chown nobody:nobody phpMyAdmin-3.4.4-english -R
cd phpMyAdmin-3.4.4-english
In browser open Ip/phpMyAdmin-3.4.4-english/setup
Give the required fields in the first page. Save and quit.
/etc/init.d/mysqld stop
[ mysqld_safe --skip-grant-tables & ]
mysql -u root
use mysql;
update user set password=PASSWORD(“YOUR_ROOT_PW”) where User=’root’;
Above command can be used to reset plesk admin password as well.
flush privileges;
quit
/etc/init.d/mysqld stop
/etc/init.d/mysqld start
mysql -u root -p
Solution that worked for me :
UPDATED perl
/scripts/checkperlmodules –force
UPCP to stable version…(Didnt fix)
Ran upcp in release version. (FIXED here)
Changed to stable and ran upcp and everything worked fine for me.
Also check the /var/lib/mysql to make sure all dbs have correct naming e.g. there is no folder there like someuser_somedb.bak
cd /usr/local/src/
wget mysqltuner.pl
perl mysqltuner.pl
Getting the following error on mysql sites and also when trying to access mysql from server
============
Can’t connect to local MySQL server through socket ‘/var/lib/mysql/mysql.sock’ (2) [2002]
============
Solution :
vi /etc/my.cnf
skip-innodb
Try to restart mysql and if it dont start then use killall -9 mysqld
After that restart mysql
When you are blocked by brute force try the below command to clear the database.
SSH to server
mysql -u user -p
mysql> connect cphulkd;
mysql> select IP, BRUTETIME from brutes order by BRUTETIME;
mysql> delete from brutes;
To increase the phpmyadmin upload limitation in cpanel servers you can edit the php.ini file mentioned below :
vi /usr/local/cpanel/3rdparty/etc/phpmyadmin/php.ini.
upload_max_filesize = 100M
post_max_size = 100M
Even if you edit the main php.ini file it wont work in this case.
Cpanel >> phpmyadmin may not reflect the change, if so go to
WHM >> tweak settings >> cPanel PHP max POST size >> and increase the limit.
or
Increase WHM >> Tweak Settings >> cPanel PHP max upload size
Getting error “The MySQL® server is currently offline.” while trying to add database.
Solution :
WHM >> Reset Local MySQL Root Password