Want to subscribe to topics you're interested in?
Become a Member

MariaDB Problems and can't sign in to

Discussion in 'Nginx, PHP-FPM & MariaDB MySQL' started by R0rke, Sep 25, 2017.

  1. R0rke

    R0rke Member

    83
    16
    8
    Jun 2, 2016
    Iran
    Ratings:
    +24
    Local Time:
    2:30 AM
    1.11.1
    10.1
    Please fill in any relevant information that applies to you:
    • CentOS Version: 7.4(Core)
    • Centmin Mod Version Installed: 123.09beta01
    • Nginx Version Installed: I don't check it
    • PHP Version Installed: after install, i just update my curl to latest version and I upgrade my PHP to 7.1.9
    • MariaDB MySQL Version Installed: 10.1.26
    • When was last time updated Centmin Mod codebase? : recently its just a fresh install for my friend and latest version
    • Persistent Config:
    Code:
    cat: /etc/centminmod/custom_config.inc: No such file or directory
    when I trying to connect :
    Code:
    ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
    sometimes: I have an error with not found : /var/lib/mysql/mysql.sock
    also, i try with the mysql_secure install but connections refusing.
     
  2. eva2000

    eva2000 Administrator Staff Member

    30,196
    6,789
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,144
    Local Time:
    7:30 PM
    Nginx 1.13.x
    MariaDB 5.5
    • how did you update to latest version of curl ?
    • is that SSH command line based connection attempt to mysql ? what was exact command you are using to connect ?
    • was mysql login ever working since initial install ? was the login issue only just a recent issue ?
    • did you successfully run mysql_secure and change mysql root password ? if you did you need to update /root/.my.cnf with updated password too as per FAQ item 35 to be able to run SSH command line connections to mysql without needing to enter mysql username and password
     
  3. R0rke

    R0rke Member

    83
    16
    8
    Jun 2, 2016
    Iran
    Ratings:
    +24
    Local Time:
    2:30 AM
    1.11.1
    10.1
    • for updating Curl :
      Code:
      Wget https://curl.haxx.se/download/curl-7.55.1.tar.gz
      cd /curlfolder
      ./configure
      make
      make install
    • im trying to connect via ssh as root :
      Code:
      mysql -u root -pThePassword
    • Actually, I don't know because after a fresh install I just simply update the curl and just then try to connect to MySQL but boom. at the end no any success connection to MYSQL
    • I Use mysql_secure but its refusing connection at all .
    Recently I just reloaded my Server os I try to install centminmod Again.
    I did it before I don't have any problems like this dunno just what happened
     
  4. eva2000

    eva2000 Administrator Staff Member

    30,196
    6,789
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,144
    Local Time:
    7:30 PM
    Nginx 1.13.x
    MariaDB 5.5
    Then most likely curl upgrade that way has broken something in the system as that isn't proper way to update curl. You should of probably done it via addons/customcurl.sh https://community.centminmod.com/threads/centmin-mod-curl-7-48-custom-rpms.3703/

    Try just fresh centmin mod install and NOT doing any curl updates and NOT doing mysql_secure run and see if you can connect - the mysql root password is same one listed in /root/.my.cnf for out of box installs
     
    • Like Like x 1
  5. R0rke

    R0rke Member

    83
    16
    8
    Jun 2, 2016
    Iran
    Ratings:
    +24
    Local Time:
    2:30 AM
    1.11.1
    10.1
    well I got this errors now when I installing new centminmod on fresh os
     

    Attached Files:

  6. R0rke

    R0rke Member

    83
    16
    8
    Jun 2, 2016
    Iran
    Ratings:
    +24
    Local Time:
    2:30 AM
    1.11.1
    10.1
    also problem with running MYSQL MariaDB :|

    Code:
     service mysqld restart
    Redirecting to /bin/systemctl restart mysqld.service
    Job for mariadb.service failed because the control process exited with error code. See "systemctl status mariadb.service" and "journalctl -xe" for details.
    [01:58][root@localhost.net ~]# systemctl status mariadb.service
    ● mariadb.service - MariaDB database server
       Loaded: loaded (/usr/lib/systemd/system/mariadb.service; enabled; vendor preset: disabled)
      Drop-In: /etc/systemd/system/mariadb.service.d
               └─migrated-from-my.cnf-settings.conf, openfileslimit.conf, protecthome.conf
       Active: failed (Result: exit-code) since Tue 2017-09-26 01:58:26 +0330; 2min 32s ago
      Process: 12961 ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS $_WSREP_NEW_CLUSTER $_WSREP_START_POSITION (code=exited, status=1/FAILURE)
      Process: 12724 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= ||   VAR=`/usr/bin/galera_recovery`; [ $? -eq 0 ]   && systemctl set-environment _WSREP_START_POSITION=$VAR || exit 1 (code=exited, status=0/SUCCESS)
      Process: 12722 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
     Main PID: 12961 (code=exited, status=1/FAILURE)
       Status: "MariaDB server is down"
    
    Sep 26 01:58:26 localhost.net mysqld[12961]: 2017-09-26 01:58:26 7f8f1b544900  InnoDB: Error: ... 13
    Sep 26 01:58:26 localhost.net mysqld[12961]: 2017-09-26  1:58:26 140252615559424 [ERROR] Plugi...or.
    Sep 26 01:58:26 localhost.net mysqld[12961]: 2017-09-26  1:58:26 140252615559424 [ERROR] Plugi...ed.
    Sep 26 01:58:26 localhost.net mysqld[12961]: 2017-09-26  1:58:26 140252615559424 [Note] Plugin...ed.
    Sep 26 01:58:26 localhost.net mysqld[12961]: 2017-09-26  1:58:26 140252615559424 [ERROR] Unkno...oDB
    Sep 26 01:58:26 localhost.net mysqld[12961]: 2017-09-26  1:58:26 140252615559424 [ERROR] Aborting
    Sep 26 01:58:26 localhost.net systemd[1]: mariadb.service: main process exited, code=exited, s...URE
    Sep 26 01:58:26 localhost.net systemd[1]: Failed to start MariaDB database server.
    Sep 26 01:58:26 localhost.net systemd[1]: Unit mariadb.service entered failed state.
    Sep 26 01:58:26 localhost.net systemd[1]: mariadb.service failed.
    Hint: Some lines were ellipsized, use -l to show in full.
    AND
    Code:
    atus mariadb.service" and "journalctl -xe" for details.
    [root@85 centminmod]# journalctl -xe"
    Sep 26 01:52:04 localhost.net polkitd[625]: Registered Authentication Agent for unix-process:12050:4616622 (system bus name :1.124 [/usr/bin/pkttyage
    Sep 26 01:52:04 localhost.net systemd[1]: Starting MariaDB database server...
    -- Subject: Unit mariadb.service has begun start-up
    -- Defined-By: systemd
    -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
    --
    -- Unit mariadb.service has begun starting up.
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] /usr/sbin/mysqld (mysqld 10.1.27-MariaDB) starting as process
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] InnoDB: Using mutexes to ref count buffer pool pages
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] InnoDB: The InnoDB memory heap is disabled
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memor
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] InnoDB: Compressed tables use zlib 1.2.7
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] InnoDB: Using Linux native AIO
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] InnoDB: Using SSE crc32 instructions
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] mysqld: Can't create/write to file '/home/mysqltmp/ib43Vp8Q'
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26 01:52:05 7f9b29039900  InnoDB: Error: unable to create temporary file; errno: 13
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] Plugin 'InnoDB' init function returned error.
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] Plugin 'FEEDBACK' is disabled.
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] Unknown/unsupported storage engine: InnoDB
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] Aborting
    Sep 26 01:52:05 localhost.net systemd[1]: mariadb.service: main process exited, code=exited, status=1/FAILURE
    Sep 26 01:52:05 localhost.net systemd[1]: Failed to start MariaDB database server.
    -- Subject: Unit mariadb.service has failed
    -- Defined-By: systemd
    -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
    --
    -- Unit mariadb.service has failed.
    --
    -- The result is failed.
    Sep 26 01:52:05 localhost.net systemd[1]: Unit mariadb.service entered failed state.
    Sep 26 01:52:05 localhost.net systemd[1]: mariadb.service failed.
    Sep 26 01:52:05 localhost.net polkitd[625]: Unregistered Authentication Agent for unix-process:12050:4616622 (system bus name :1.124, object path /or
    ~
    ~
     
    Last edited: Sep 26, 2017
  7. eva2000

    eva2000 Administrator Staff Member

    30,196
    6,789
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,144
    Local Time:
    7:30 PM
    Nginx 1.13.x
    MariaDB 5.5
    Might need your install log and info to troubleshoot.

    You'll need to post on the forums with the following info
    • Server or VPS details ? XEN, KVM, OpenVZ, VMWare or dedicated server ? OS ? CentOS 6.7 or 7.2 ? 32bit or 64bit ?
    • What version of Centmin Mod ? .07 stable or 08 stable or .09 beta01 or another branch version ?
    • Was it fresh install or upgrade ?
    • Method of install ? Via centmin.sh menu option 1, Git install or curl one liner install as outlined at centminmod.com/download.html ?
    • How long ago did you install Centmin Mod ?
    • There's numerous code changes, bug fixes over time, so ensure you have latest Centmin Mod code installed by upgrading your Centmin Mod code as instructed below.

    Troubleshooting Initial Install



    To troubleshoot initial installation, you need to check the initial install log at /root/centminlogs and instructions under Sharing logs and errors heading for using Pastebin.com or Gists to share a sanitised version of the contents of the initial install log. You can see full details at How to troubleshoot Centmin Mod initial install issues

    Example list /root/centminlogs files in date ascending order and grep for install.log
    Code (Text):
    ls -lahrt /root/centminlogs | grep install.log
    

    example output returns install log at /root/centminlogs/centminmod_1.2.3-eva2000.09.001_111016-112321_install.log
    Code (Text):
    ls -lahrt /root/centminlogs | grep install.log
    -rw-r--r--  1 root root 2.2M Oct 11 01:40 centminmod_1.2.3-eva2000.09.001_111016-112321_install.log
    

    in SSH use cat to ouput contents of /root/centminlogs/centminmod_1.2.3-eva2000.09.001_111016-112321_install.log. Clear your SSH client window/buffer so only output is the contents of the file
    Code (Text):
    cat /root/centminlogs/centminmod_1.2.3-eva2000.09.001_111016-112321_install.log
    

    Then copy and paste into Pastebin.com or Gists entry. If your SSH window scroll buffer isn't that large to get the whole contents of the install log, you can download file manually and copy and paste contents. But makes sure it's sanitised version of the contents of the initial install log as outlined at How to troubleshoot Centmin Mod initial install issues
     
    • Informative Informative x 1
  8. R0rke

    R0rke Member

    83
    16
    8
    Jun 2, 2016
    Iran
    Ratings:
    +24
    Local Time:
    2:30 AM
    1.11.1
    10.1
    you can check the first post about the version of os or ...
    I'm using VMware
    its fresh install
    method : ./centmin.sh install
    -
    Unfortunately, I can't post logs on pastebin because its size

    I just post here u can check it by nodepad++
     

    Attached Files:

  9. eva2000

    eva2000 Administrator Staff Member

    30,196
    6,789
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,144
    Local Time:
    7:30 PM
    Nginx 1.13.x
    MariaDB 5.5
    Centmin Mod 123.09beta01 official way to install as per install page https://centminmod.com/install.html is via installers curl command so wonder if that is the problem.
    Code (Text):
    yum -y update; curl -O https://centminmod.com/betainstaller.sh && chmod 0700 betainstaller.sh && bash betainstaller.sh
    

    I just tested fresh 123.09beta01 install and MariaDB 10.1.27 works fine and can no log via mysql root user.
     
  10. eva2000

    eva2000 Administrator Staff Member

    30,196
    6,789
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,144
    Local Time:
    7:30 PM
    Nginx 1.13.x
    MariaDB 5.5
    from your log seems mysql failed to restart after updating max open files limit so installed fine just couldn't restart so latter mysql root password setup would probably of failed to run
    Code (Text):
    Update MariaDB 10 setting for ProtectHome=false
    setup /var/log/mysqld.log
    -rw-------. 1 mysql mysql 0 Sep 26 01:32 /var/log/mysqld.log
    
    Initial Install: Update MariaDB 10 setting for LimitNOFILE=262144
    systemctl restart mysql.service
    Job for mariadb.service failed because the control process exited with error code. See "systemctl status mariadb.service" and "journalctl -xe" for details.
                 __  __               _         ____   ____    _   ___  
    

    so a mysql server restart and then check the logs for clues
    Code (Text):
    mysqlrestart
    

    or
    Code (Text):
    systemctl restart mysql
    

    then check logs
    Code (Text):
    journalctl -u mariadb --no-pager
    
     
    • Useful Useful x 1
  11. R0rke

    R0rke Member

    83
    16
    8
    Jun 2, 2016
    Iran
    Ratings:
    +24
    Local Time:
    2:30 AM
    1.11.1
    10.1
  12. eva2000

    eva2000 Administrator Staff Member

    30,196
    6,789
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,144
    Local Time:
    7:30 PM
    Nginx 1.13.x
    MariaDB 5.5
    that shouldn't happen
    Code (Text):
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] InnoDB: Using SSE crc32 instructions
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] mysqld: Can't create/write to file '/home/mysqltmp/ib43Vp8Q' (Errcode: 13 "Permission denied")
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26 01:52:05 7f9b29039900  InnoDB: Error: unable to create temporary file; errno: 13
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] Plugin 'InnoDB' init function returned error.
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [Note] Plugin 'FEEDBACK' is disabled.
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] Unknown/unsupported storage engine: InnoDB
    Sep 26 01:52:05 localhost.net mysqld[12305]: 2017-09-26  1:52:05 140304384760064 [ERROR] Aborting
    Sep 26 01:52:05 localhost.net systemd[1]: mariadb.service: main process exited, code=exited, status=1/FAILURE
    Sep 26 01:52:05 localhost.net systemd[1]: Failed to start MariaDB database server.
    Sep 26 01:52:05 localhost.net systemd[1]: Unit mariadb.service entered failed state.
    Sep 26 01:52:05 localhost.net systemd[1]: mariadb.service failed.
    

    as centmin mod creates a /etc/systemd/system/mariadb.service.d/protecthome.conf with contents to disable that protection and allow /home/mysqltmp
    Code (Text):
    [Service]
    ProtectSystem=false
    ProtectHome=false
    

    what does contents of your /etc/systemd/system/mariadb.service.d/protecthome.conf contain ?
    Code (Text):
    cat /etc/systemd/system/mariadb.service.d/protecthome.conf
    
     
    • Like Like x 1
  13. R0rke

    R0rke Member

    83
    16
    8
    Jun 2, 2016
    Iran
    Ratings:
    +24
    Local Time:
    2:30 AM
    1.11.1
    10.1
    Code:
    [Service]
    ProtectSystem=false
    ProtectHome=false
     
  14. eva2000

    eva2000 Administrator Staff Member

    30,196
    6,789
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,144
    Local Time:
    7:30 PM
    Nginx 1.13.x
    MariaDB 5.5
    That looks right so shouldn't cause the error you are experiencing hmmm
     
    • Like Like x 1
  15. eva2000

    eva2000 Administrator Staff Member

    30,196
    6,789
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,144
    Local Time:
    7:30 PM
    Nginx 1.13.x
    MariaDB 5.5
    For now for temp workaround you can comment out tmpdir option in /etc/my.cnf and restart MariaDB MySQL and set the mysql root password.