Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-6762

Init script is too silent in case of basic failures

    XMLWordPrintable

Details

    Description

      Currently a failed upgrade or incomplete installation, which ends up with mysqld_safe not being installed, becomes an investigation nightmare. The service attempts to start and after a timeout says that it failed:

      sudo /etc/init.d/mysql start
      [FAIL] Starting MariaDB database server: mysqld . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . failed!

      Syslog only contains unhelpful messages saying that something went wrong:

      Sep 21 03:09:10 wheezy-64 /etc/init.d/mysql[13619]: 0 processes alive and '/usr/bin/mysqladmin --defaults-file=/etc/mysql/debian.cnf ping' resulted in
      Sep 21 03:09:10 wheezy-64 /etc/init.d/mysql[13619]: #007/usr/bin/mysqladmin: connect to server at 'localhost' failed
      Sep 21 03:09:10 wheezy-64 /etc/init.d/mysql[13619]: error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
      Sep 21 03:09:10 wheezy-64 /etc/init.d/mysql[13619]: Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
      Sep 21 03:09:10 wheezy-64 /etc/init.d/mysql[13619]: 

      That's how we end up with users' complaints like "server just does not start, nothing in the error log", at which point we get stuck because there's nothing to work with.

      It is a realistic situation, for example that's exactly what happens when one tries to dist-upgrade from 5.5 to 10.0 on Wheezy.

      It happens because all output of mysqld_safe call in the init script is redirected to /dev/null.

      Attachments

        Issue Links

          Activity

            People

              serg Sergei Golubchik
              elenst Elena Stepanova
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.