Welcome, Guest. Please login or register.

Author Topic: Mysql error with nebuntu.sh fresh install of ubuntu 17.10.1  (Read 3348 times)

johnm

  • Newbie
  • *
  • Posts: 1
    • View Profile
Mysql error with nebuntu.sh fresh install of ubuntu 17.10.1
« on: February 28, 2018, 07:33:04 pm »
nebuntu.sh completes fine except for the following error.  I'm executing script as normal user with sudo command sudo ./nebuntu.sh, also the admin page is not loading.

Initialize NeDi DB!!!
------------------------------------------------------------------------
DBI connect('dbname=mysql;host=localhost','root',...) failed: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) at /var/nedi/inc/libdb.pm line 37.
Enabling SNMP latency measurement
Enabling snapshots
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2 "No such file or directory")
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2 "No such file or directory")
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2 "No such file or directory")

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2903
    • View Profile
    • NeDi
Re: Mysql error with nebuntu.sh fresh install of ubuntu 17.10.1
« Reply #1 on: March 03, 2018, 02:58:15 pm »
Looks like mariadb (mysql) doesn't like the sudo part. I've written the script to be executed by root. Can you retry as root? You could configure this part manually , if not:

As dbadmin/root:
UPDATE mysql.user SET plugin='' WHERE user='root';
SET PASSWORD = PASSWORD('dbpa55');
FLUSH PRIVILEGES;

This mysql plugin is a recent change. While it might be a good thing for some users, I find it rather cumbersome since a regular user cannot do "mysql -u root -p" anymore :-(
« Last Edit: March 03, 2018, 03:00:17 pm by rickli »
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo