Page 1 of 1

Error establishing a database connection

Posted: Tue Jan 09, 2018 12:58 am
by rasco
my 3 websites go down only the ones with Database the ones that don't have Database works.
Df -h
[root@localhost ~]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/cl-root 50G 50g 120k 100% /
devtmpfs 3.9G 0 3.9G 0% /dev
tmpfs 3.9G 0 3.9G 0% /dev/shm
tmpfs 3.9G 8.8M 3.9G 1% /run
tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup
/dev/sda1 1014M 186M 829M 19% /boot
/dev/mapper/cl-home 545G 141G 404G 26% /home
tmpfs 781M 0 781M 0% /run/user/0

#du -sch * --exclude=home
/tmp 75g

I detele all the tmp* files and now
everything is back to normal it says only 7% free.

but problem keeps coming back anyone knows why this is happening?

i check the /tmp folder and it like if it was making backups of all my domains

Re: Error establishing a database connection

Posted: Thu Jan 11, 2018 8:13 am
by wedge1001
well,
oyu root-partition is full.
The database normally writes to /var/
so... if you don't have any space left, the DB will crash.

What you can do: get more HDD for the root-system or move out the /var to it's own hdd (or lvs)
or just change the database-path to s.th. in /home: https://forums.cpanel.net/threads/how-t ... ost-709306
this will at least, prevent the database to crash.

as for the /tmp:
i'm not sure why there is 75g in your folder.
the tmp.* files should normally be removed asap the backup is done.
But since your hdd hasn't genough space on /backup I think that the files were never cleared.
also look here: viewtopic.php?t=15327