5 Answers
- Newest
- Most votes
- Most comments
1
I have added
innodb_force_recovery = 1
in
/opt/bitnami/mariadb/conf/my.cnf
under [mysqld] and executed the following:
root@ip:/opt/bitnami# mysqld --skip-grant-tables --user=mysql --skip-external-locking --port=3306 --sock=/opt/bitnami/mariadb/tmp/mysql.sock
Then I was able to connect to MySQL console issuing
mysql -u root -p
answered 10 months ago
0
Try connecting via the IP instead of the socket
mysql -h 127.0.0.1 -P 3306 -u root -p <database>
Also see if its running telnet 127.0.0.1 3306
0
What results are returned with netstat -an |grep 3306
?
Is NC installed? netcat to 127.0.0.1 3306
0
root@ip:/opt/bitnami# ./ctlscript.sh status
apache already running
mariadb already running
php-fpm not running
root@ip:/opt/bitnami# netstat -an | grep 3306
root@ip:/opt/bitnami# netcat to 127.0.0.1
3306
netcat: port number invalid: 127.0.0.1
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1443/sshd: /usr/sb
i
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 696/sendmail: MTA:
tcp 0 0 127.0.0.1:587 0.0.0.0:* LISTEN 696/sendmail: MTA:
tcp6 0 0 :::22 :::* LISTEN 1443/sshd: /usr/sb
i
tcp6 0 0 :::443 :::* LISTEN 839/httpd
tcp6 0 0 :::80 :::* LISTEN 839/httpd
answered 10 months ago
0
root@ip:/opt/bitnami# ./ctlscript.sh status
apache already running
mariadb not running
php-fpm already running
root@ip:/opt/bitnami# ./ctlscript.sh start mariadb
Started mariadb
root@ip:/opt/bitnami# mysql -h 127.0.0.1 -P 3306 -u root -p my_database
Enter password:
ERROR 2002 (HY000): Can't connect to server on '127.0.0.1' (115)
Telnet is disabled.
answered 10 months ago
Relevant content
- asked 2 years ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 8 months ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 years ago