• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

ERROR: PleskDBException: Unable to connect to database

1. /dev/md2 - this is a raid setup? May be YES, Because my server have the Raid system too. But i can not remember for i set up Raid or not as it've long time.

2. Now i've FTP to delete 4 Backup file, The size about 16 GB/File

3. And i run du -a / | sort -n -r | head -n 15 , but don't display anything.

4. And i still have the issue can not login to my Plesk Dashboard.
 
For more information, I was already Reboot the server after the step above and clear Browser cache. And still display as below:

ERROR: PleskDBException: Unable to connect to database: mysql_connect(): No such file or directory /var/run/mysqld/mysqld.sock (Error code: 2002). Please check that database server is started and accessible. (Abstract.php:69)
 
Hi cookkoo,

you got TWO big, red signs, which directly point to your issue:
From your code above the result as below:

mysql.service - LSB: Start and stop the mysql database server daemon
Loaded: loaded (/etc/init.d/mysql)
Active: failed (Result: exit-code) since Tue 2016-05-17 14:51:35 ICT; 6h ago

May 17 14:51:35 cookkoo.com mysql[1206]: /etc/init.d/mysql: ERROR: The partition with /var/lib/mysql is too full! ... failed!
May 17 14:51:35 cookkoo.com systemd[1]: mysql.service: control process exited, code=exited status=1
May 17 14:51:35 cookkoo.com systemd[1]: Failed to start LSB: Start and stop the mysql database server daemon.
May 17 14:51:35 cookkoo.com systemd[1]: Unit mysql.service entered failed state.
May 17 21:17:48 cookkoo.com systemd[1]: Stopped LSB: Start and stop the mysql database server daemon.

=> This error message states clear, that the partition "is too full". MySQL will not start without issues/failures/problems, if you don't solve that issue. You don't have to reboot, restart, or what ever else, because this problem will not be solved, if you don't either delete, or move stuff, or if you don't resize your partition, or as third solution, move the content from "/var/lib/mysql" to another partition and symlink your new location to "/var/lib/mysql".

The result as below:

# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/md2 2.0T 1.9T 0 100% /
udev 10M 0 10M 0% /dev
tmpfs 6.3G 82M 6.2G 2% /run
tmpfs 16G 0 16G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 16G 0 16G 0% /sys/fs/cgroup
/dev/md1 488M 36M 427M 8% /boot
/dev/md3 8.9T 41M 8.5T 1% /home
tmpfs 3.2G 0 3.2G 0% /run/user/0

You have a very strange partitioning here. The partition md2 got 2 TB, while md3 ( with 41 MB usage at "/home" ! ), got 8.9 TB. If you are not familiar with "resizing partitions" on a linux system, pls. consider to hire a professional linux administrator to do this task.
 
UFHH01 , Thank you again for your suggestion as you help a lot of people in this forum and me too. I wish to do and learn by myself as this forum have a lot of professional (as you). After check on the net. Now if i will "resizing partitions" by partman tool, Please comment.
 
I've already check and the server have RAID install. Then i've run

# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/md2 2.0T 1.9T 0 100% /
udev 10M 0 10M 0% /dev
tmpfs 6.3G 138M 6.2G 3% /run
tmpfs 16G 0 16G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 16G 0 16G 0% /sys/fs/cgroup
/dev/md1 488M 36M 427M 8% /boot
/dev/md3 8.9T 41M 8.5T 1% /home
tmpfs 3.2G 0 3.2G 0% /run/user/0
root@cookkoo ~ # fdisk -l

Disk /dev/sdb: 5.5 TiB, 6001175126016 bytes, 11721045168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 16A6E211-3029-4D90-AF1A-4BA84D798CCF

Device Start End Sectors Size Type
/dev/sdb1 4096 33558527 33554432 16G Linux RAID
/dev/sdb2 33558528 34607103 1048576 512M Linux RAID
/dev/sdb3 34607104 2146439167 2111832064 1007G Linux RAID
/dev/sdb4 2146439168 11721045134 9574605967 4.5T Linux RAID
/dev/sdb5 2048 4095 2048 1M BIOS boot

Partition table entries are not in disk order.
Disk /dev/sdd: 5.5 TiB, 6001175126016 bytes, 11721045168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 198EE917-5F1A-4EB7-BF0E-D5119EF9896F

Device Start End Sectors Size Type
/dev/sdd1 4096 33558527 33554432 16G Linux RAID
/dev/sdd2 33558528 34607103 1048576 512M Linux RAID
/dev/sdd3 34607104 2146439167 2111832064 1007G Linux RAID
/dev/sdd4 2146439168 11721045134 9574605967 4.5T Linux RAID
/dev/sdd5 2048 4095 2048 1M BIOS boot

Partition table entries are not in disk order.
Disk /dev/sdc: 5.5 TiB, 6001175126016 bytes, 11721045168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: B3A0BB85-A84C-4969-9F00-DDCEA4D4F23F

Device Start End Sectors Size Type
/dev/sdc1 4096 33558527 33554432 16G Linux RAID
/dev/sdc2 33558528 34607103 1048576 512M Linux RAID
/dev/sdc3 34607104 2146439167 2111832064 1007G Linux RAID
/dev/sdc4 2146439168 11721045134 9574605967 4.5T Linux RAID
/dev/sdc5 2048 4095 2048 1M BIOS boot

Partition table entries are not in disk order.
Disk /dev/sda: 5.5 TiB, 6001175126016 bytes, 11721045168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 1E8D7607-5D8D-44D7-BE49-A021467EC6A1

Device Start End Sectors Size Type
/dev/sda1 4096 33558527 33554432 16G Linux RAID
/dev/sda2 33558528 34607103 1048576 512M Linux RAID
/dev/sda3 34607104 2146439167 2111832064 1007G Linux RAID
/dev/sda4 2146439168 11721045134 9574605967 4.5T Linux RAID
/dev/sda5 2048 4095 2048 1M BIOS boot

Partition table entries are not in disk order.
Disk /dev/md0: 16 GiB, 17163091968 bytes, 33521664 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/md1: 511.4 MiB, 536281088 bytes, 1047424 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/md2: 2 TiB, 2162247598080 bytes, 4223139840 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 524288 bytes / 1048576 bytes
Disk /dev/md3: 8.9 TiB, 9804127928320 bytes, 19148687360 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 524288 bytes / 1048576 bytes

Then i've run

# resize2fs /dev/md2
resize2fs 1.42.12 (29-Aug-2014)
The filesystem is already 527892480 (4k) blocks long. Nothing to do!

And then

# resize2fs /dev/sda2
resize2fs 1.42.12 (29-Aug-2014)
resize2fs: Device or resource busy while trying to open /dev/sda2
Couldn't find valid filesystem superblock.

And resizing patitions unsuccesful. Please help to suggestion. Thank you
 
Hey @cookkoo, have you made any more progress?

Just to clarify:
For more information, I can not found folder /mysqld IN /var/run/
Sorry I believe it should be: /var/lib/mysql not mysqld for ubunutu LTS

What is the output of:
Code:
cat /var/log/mysql/error.log

can you confirm the BIND-ADDRESS? in /etc/mysql/my.cnf?

is MySQL reinstallation an option? incase you are missing any folders/files/dependencies?

Code:
sudo apt-get --reinstall install mysql-server
 
1. the output of: Code:
cat /var/log/mysql/error.log
The output is nothing to display.

2. the BIND-ADDRESS? in /etc/mysql/my.cnf
[mysqld]
bind-address = ::
skip_name_resolve
local-infile=0

3. is MySQL reinstallation an option? This is dangerous and have a risk to destroy my DATA or not ? Because my backup process to Backup Server was unsuccessful as it's display Backup server the space is FULL. If not dangerous, i will do.
 
Hi shoxicwaste,

you are digging at the wrong place...
Unable to connect to database: mysql_connect(): No such file or directory /var/run/mysqld/mysqld.sock (Error code: 2002)

root cause is:
mysql.service - LSB: Start and stop the mysql database server daemon
Loaded: loaded (/etc/init.d/mysql)
Active: failed (Result: exit-code) since Tue 2016-05-17 14:51:35 ICT; 6h ago

May 17 14:51:35 cookkoo.com mysql[1206]: /etc/init.d/mysql: ERROR: The partition with /var/lib/mysql is too full! ... failed!
May 17 14:51:35 cookkoo.com systemd[1]: mysql.service: control process exited, c ode=exited status=1
May 17 14:51:35 cookkoo.com systemd[1]: Failed to start LSB: Start and stop the mysql database server daemon.
May 17 14:51:35 cookkoo.com systemd[1]: Unit mysql.service entered failed state.
May 17 21:17:48 cookkoo.com systemd[1]: Stopped LSB: Start and stop the mysql da tabase server daemon.

The result as below:

# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/md2 2.0T 1.9T 0 100% /
udev 10M 0 10M 0% /dev
tmpfs 6.3G 82M 6.2G 2% /run
tmpfs 16G 0 16G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 16G 0 16G 0% /sys/fs/cgroup
/dev/md1 488M 36M 427M 8% /boot
/dev/md3 8.9T 41M 8.5T 1% /home
tmpfs 3.2G 0 3.2G 0% /run/user/0
 
If i've reinstall mysql, 1. Is it the good idea ? 2. To reinstall mysql this will destroy my old data or not ?
 
Hi cookkoo,

re-installing MySQL will not solve your "insufficient space problem" at md2. You already got my suggestion, how to solve the issue:

You have a very strange partitioning here. The partition md2 got 2 TB, while md3 ( with 41 MB usage at "/home" ! ), got 8.9 TB. If you are not familiar with "resizing partitions" on a linux system, pls. consider to hire a professional linux administrator to do this task.
 
Hello UFHH01

I've contact with Hosting administrator for help and their reply is,

the hardware check is completed now. No issues have been found:

-----------------%<-----------------
END: 03:35h
DISK: NAG2TUKX test_ok

DISK: NAG2SEMY test_ok

DISK: NAHPXKUX test_ok

DISK: NAG2XE4Y test_ok
-----------------%<-----------------

We have rebooted the server back into the installed system.

An then i run,

# fsck -nf /dev/md2
fsck from util-linux 2.25.2
e2fsck 1.42.12 (29-Aug-2014)
Warning! /dev/md2 is mounted.
Warning: skipping journal recovery because doing a read-only filesystem check.
Pass 1: Checking inodes, blocks, and sizes
Inodes that were part of a corrupted orphan linked list found. Fix? no

Inode 3538962 was part of the orphaned inode list. IGNORED.
Inode 3538968 was part of the orphaned inode list. IGNORED.
Deleted inode 3538969 has zero dtime. Fix? no

Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
Block bitmap differences: -(258621587--258621615) -(258627372--258627408) -268657981 -(402097404--402097422) -403212663 -(451314885--451314892) -(451579571--451579599) -451582594
Fix? no

Free blocks count wrong for group #7892 (5048, counted=4961).
Fix? no

Free blocks count wrong for group #8198 (6946, counted=6945).
Fix? no

Free blocks count wrong for group #12271 (778, counted=753).
Fix? no

Free blocks count wrong for group #12305 (6668, counted=6667).
Fix? no

Free blocks count wrong for group #13773 (5282, counted=5273).
Fix? no

Free blocks count wrong for group #13781 (5648, counted=5608).
Fix? no

Free blocks count wrong (18026359, counted=18248604).
Fix? no

Inode bitmap differences: -3538962 -(3538968--3538969)
Fix? no

Free inodes count wrong (99297235, counted=99298450).
Fix? no


/dev/md2: ********** WARNING: Filesystem still has errors **********

/dev/md2: 32675885/131973120 files (0.0% non-contiguous), 509866121/527892480 blocks

I run this more than 4-5 times, But still have the issue.
 
Hi cookkoo,

sorry, but you really have insufficient linux knowledge, why I suggested to hire an advanced system administrator, to solve the task of resizing your partitions. This is NO hardware issue and as you can see with your current issues/errors, you really should not try more things, as you already did - you might loose your data on your hard drive(s).

This forum is for "Plesk related subjects" and even that the forum users sometimes answer questions in behalf of non-related Plesk subjects, the basics should be respected.
 
Back
Top