When I browse my site Internal Server Error show!
sudo service mysql status
Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enabled)
Active: active (running) since Tue 2021-12-14 21:36:19 UTC; 1min 56s ago
Docs: man:mysqld(8)
systemd - MariaDB Knowledge Base
Process: 1564 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exited, status=0/SUCCESS)
Process: 1573 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Process: 1577 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= || VAR=cd /usr/bin/..; /usr/bin/galera_recovery
; [ $? -eq 0 ] && systemctl set-environment _WSREP_START_POSITION=$VAR ||>
Process: 1665 ExecStartPost=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Process: 1667 ExecStartPost=/etc/mysql/debian-start (code=exited, status=0/SUCCESS)
Main PID: 1633 (mysqld)
Status: “Taking your SQL requests now…”
Tasks: 32 (limit: 1136)
Memory: 113.0M
CGroup: /system.slice/mariadb.service
└─1633 /usr/sbin/mysqldDec 14 21:36:18 Andyyy mysqld[1633]: 2021-12-14 21:36:18 0 [Note] /usr/sbin/mysqld (mysqld 10.3.32-MariaDB-0ubuntu0.20.04.1) starting as process 1633 …
Dec 14 21:36:19 Andyyy systemd[1]: Started MariaDB 10.3.32 database server.
Dec 14 21:36:19 Andyyy /etc/mysql/debian-start[1669]: Upgrading MySQL tables if necessary.
Dec 14 21:36:19 Andyyy /etc/mysql/debian-start[1672]: Looking for ‘mysql’ as: /usr/bin/mysql
Dec 14 21:36:19 Andyyy /etc/mysql/debian-start[1672]: Looking for ‘mysqlcheck’ as: /usr/bin/mysqlcheck
Dec 14 21:36:19 Andyyy /etc/mysql/debian-start[1672]: Version check failed. Got the following error when calling the ‘mysql’ command line client
Dec 14 21:36:19 Andyyy /etc/mysql/debian-start[1672]: ERROR 1045 (28000): Access denied for user ‘root’@‘localhost’ (using password: NO)
Dec 14 21:36:19 Andyyy /etc/mysql/debian-start[1672]: FATAL ERROR: Upgrade failed
Dec 14 21:36:19 Andyyy /etc/mysql/debian-start[1682]: Checking for insecure root accounts.
Dec 14 21:36:19 Andyyy debian-start[1685]: ERROR 1045 (28000): Access denied for user ‘root’@‘localhost’ (using password: NO)
it was working fine i don’t know what happened! also i can access mysql root …
i tried alot of thing also
but didn’t work.
most common line at logs file
pymysql.err.OperationalError: (2003, “Can’t connect to MySQL server on ‘127.0.0.1’ ([Errno 111] Connection refused)”)
I’m using Ubuntu 20 1 vCPU 1GB Ram
df -h
Filesystem Size Used Avail Use% Mounted on
udev 474M 0 474M 0% /dev
tmpfs 99M 1.2M 97M 2% /run
/dev/vda1 25G 6.2G 18G 26% /
tmpfs 491M 0 491M 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 491M 0 491M 0% /sys/fs/cgroup
/dev/loop0 62M 62M 0 100% /snap/core20/1270
/dev/loop2 68M 68M 0 100% /snap/lxd/21835
/dev/loop1 62M 62M 0 100% /snap/core20/1081
/dev/loop3 68M 68M 0 100% /snap/lxd/21545
/dev/loop4 33M 33M 0 100% /snap/snapd/13170
/dev/loop5 44M 44M 0 100% /snap/snapd/14295
/dev/vda15 105M 5.2M 100M 5% /boot/efi
tmpfs 99M 20K 99M 1% /run/user/123
tmpfs 99M 0 99M 0% /run/user/0
free
total used free shared buff/cache available
Mem: 1004844 791052 61356 4392 152436 59968
Swap: 0 0 0
please guide me