← Back to team overview

maria-discuss team mailing list archive

Re: Maria-db refuses to start

 

Op 06-12-2022 om 16:43 schreef Jogchum Reitsma:
Op 16-11-2022 om 01:49 schreef Daniel Black:
<...>
Read Marko's email again.

10.8+ won't start without a ib_logfile0. This is what not starting looks like.

Start it with at 10.7 version which will recreate ib_logfile0, and if
you're lucky, you maybe won't have corrupted data because of this.
Then try 10.8+.

I just correctedhttps://wiki.archlinux.org/title/MariaDB.

If you see other sites saying delete ib_logfile0, please share your
experience with them

_______________________________________________
Mailing list:https://launchpad.net/~maria-discuss
Post to     :maria-discuss@xxxxxxxxxxxxxxxxxxx
Unsubscribe :https://launchpad.net/~maria-discuss
More help   :https://help.launchpad.net/ListHelp

Hi,

So I downloaded and installed 10.7.7.

Bu now I get

/usr/local/mariadb-10.7.7-linux-systemd-x86_64/bin/mysql
ERROR 2002 (HY000): Can't connect to local server through socket '/var/run/mysql/mysql.sock'

For now I have chmod /var/run/mysql to 777, so is writable by me when I try to start 10.7.7. But indeed the directory is empty.

In both /etc/my.cnf as ~/.my.cnf the socket is set to /var/run/mysql/mysql.sock

Hope you have some ideas to solve this one...

regards, Jogchum

Sorry, my bad: of course I should have started mysqld, not mysql.....

Starting 10.7.7 works, and indeed recreates ib_logfile0. All my databases are there, no corruption AFAICS.

Shut it down with kill -15, and the logfile reports a normal shutdown:

#####################################

cat mysqld.log
2022-12-07  9:29:20 0 [Note] InnoDB: Compressed tables use zlib 1.2.12
2022-12-07  9:29:20 0 [Note] InnoDB: Number of transaction pools: 1
2022-12-07  9:29:20 0 [Note] InnoDB: Using crc32 + pclmulqdq instructions
2022-12-07  9:29:20 0 [Note] InnoDB: Using Linux native AIO
2022-12-07  9:29:20 0 [Note] InnoDB: Initializing buffer pool, total size = 134217728, chunk size = 134217728 2022-12-07  9:29:20 0 [Note] InnoDB: Completed initialization of buffer pool
2022-12-07  9:29:21 0 [Note] InnoDB: 128 rollback segments are active.
2022-12-07  9:29:21 0 [Note] InnoDB: Creating shared tablespace for temporary tables 2022-12-07  9:29:21 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2022-12-07  9:29:21 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2022-12-07  9:29:21 0 [Note] InnoDB: 10.7.7 started; log sequence number 578191915; transaction id 2935782 2022-12-07  9:29:21 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2022-12-07  9:29:21 0 [Note] Plugin 'FEEDBACK' is disabled.
2022-12-07  9:29:21 0 [Warning] 'innodb-file-format' was removed. It does nothing now and exists only for compatibility with old my.cnf files.
2022-12-07  9:29:22 0 [Note] Server socket created on IP: '0.0.0.0'.
2022-12-07  9:29:22 0 [Note] /usr/local/mariadb-10.7.7-linux-systemd-x86_64/bin/mysqld: ready for connections. Version: '10.7.7-MariaDB-log'  socket: '/var/run/mysql/mysql.sock'  port: 3306  MariaDB Server 2022-12-07  9:29:23 0 [Note] InnoDB: Buffer pool(s) load completed at 221207  9:29:23 2022-12-07  9:39:23 0 [Note] /usr/local/mariadb-10.7.7-linux-systemd-x86_64/bin/mysqld (initiated by: unknown): Normal shutdown
2022-12-07  9:39:23 0 [Note] InnoDB: FTS optimize thread exiting.
2022-12-07  9:39:24 0 [Note] InnoDB: Starting shutdown...
2022-12-07  9:39:24 0 [Note] InnoDB: Dumping buffer pool(s) to /var/lib/mysql/ib_buffer_pool 2022-12-07  9:39:24 0 [Note] InnoDB: Restricted to 2028 pages due to innodb_buf_pool_dump_pct=25 2022-12-07  9:39:24 0 [Note] InnoDB: Buffer pool(s) dump completed at 221207  9:39:24 2022-12-07  9:39:24 0 [Note] InnoDB: Removed temporary tablespace data file: "./ibtmp1" 2022-12-07  9:39:24 0 [Note] InnoDB: Shutdown completed; log sequence number 578191927; transaction id 2935784 2022-12-07  9:39:24 0 [Note] /usr/local/mariadb-10.7.7-linux-systemd-x86_64/bin/mysqld: Shutdown complete

#######################################

So far so good.

But after that, still no luck in starting the server the regular way, i.e. with systemctl start mariadb.

######################################

systemctl start mariadb

Job for mariadb.service failed because the control process exited with error code. See "systemctl status mariadb.service" and "journalctl -xeu mariadb.service" for details

###########################################

systemctl status mariadb.service
×mariadb.service - MariaDB database server
    Loaded: loaded (/usr/lib/systemd/system/mariadb.service; disabled; preset: disabled)
   Drop-In: /etc/systemd/system/mariadb.service.d
            └─override.conf
    Active: failed(Result: exit-code) since Wed 2022-12-07 09:52:46 CET; 1min 51s ago
      Docs: man:mysqld(8)
https://mariadb.com/kb/en/library/systemd/
   Process: 93046 ExecStartPre=/usr/libexec/mysql/mysql-systemd-helper install (code=exited, status=0/SUCCESS)    Process: 93059 ExecStartPre=/usr/libexec/mysql/mysql-systemd-helper upgrade (code=exited, status=1/FAILURE)
       CPU: 438ms

dec 07 09:51:45 linux-mkay mysql-systemd-helper[93059]: Checking MySQL configuration for obsolete options... dec 07 09:51:45 linux-mkay mysql-systemd-helper[93059]: Trying to run upgrade of MySQL databases... dec 07 09:51:45 linux-mkay mysql-systemd-helper[93059]: Running protected MySQL... dec 07 09:51:45 linux-mkay mysql-systemd-helper[93059]: Waiting for MySQL to start dec 07 09:51:45 linux-mkay mysql-systemd-helper[93082]: 2022-12-07  9:51:45 0 [Note] /usr/sbin/mysqld (server 10.10.2-MariaDB) starting as process 93082 ...
dec 07 09:52:46 linux-mkay mysql-systemd-helper[93059]: MySQL is still dead
dec 07 09:52:46 linux-mkay mysql-systemd-helper[93059]: MySQL didn't start, can't continue dec 07 09:52:46 linux-mkay systemd[1]: mariadb.service: Control process exited, code=exited, status=1/FAILURE dec 07 09:52:46 linux-mkay systemd[1]: mariadb.service: Failed with result 'exit-code'. dec 07 09:52:46 linux-mkay systemd[1]: Failed to start MariaDB database server.

#################################################

journalctl -xeu mariadb.service

dec 07 09:51:45 linux-mkay systemd[1]: Starting MariaDB database server...
░░ Subject: A start job for unit mariadb.service has begun execution
░░Defined-By: systemd
░░Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
░░
░░A start job for unit mariadb.service has begun execution.
░░
░░The job identifier is 611401.
dec 07 09:51:45 linux-mkay mysql-systemd-helper[93059]: Checking MySQL configuration for obsolete options... dec 07 09:51:45 linux-mkay mysql-systemd-helper[93059]: Trying to run upgrade of MySQL databases... dec 07 09:51:45 linux-mkay mysql-systemd-helper[93059]: Running protected MySQL... dec 07 09:51:45 linux-mkay mysql-systemd-helper[93059]: Waiting for MySQL to start dec 07 09:51:45 linux-mkay mysql-systemd-helper[93082]: 2022-12-07  9:51:45 0 [Note] /usr/sbin/mysqld (server 10.10.2-MariaDB) starting as process 93082 ...
dec 07 09:52:46 linux-mkay mysql-systemd-helper[93059]: MySQL is still dead
dec 07 09:52:46 linux-mkay mysql-systemd-helper[93059]: MySQL didn't start, can't continue dec 07 09:52:46 linux-mkay systemd[1]: mariadb.service: Control process exited, code=exited, status=1/FAILURE
░░ Subject: Unit process exited
░░Defined-By: systemd
░░Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
░░
░░An ExecStartPre= process belonging to unit mariadb.service has exited.
░░
░░The process' exit code is 'exited' and its exit status is 1.
dec 07 09:52:46 linux-mkay systemd[1]: mariadb.service: Failed with result 'exit-code'.
░░ Subject: Unit failed
░░Defined-By: systemd
░░Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
░░
░░The unit mariadb.service has entered the 'failed' state with result 'exit-code'. dec 07 09:52:46 linux-mkay systemd[1]: Failed to start MariaDB database server.
░░ Subject: A start job for unit mariadb.service has failed
░░Defined-By: systemd
░░Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel
░░
░░A start job for unit mariadb.service has finished with a failure.
░░
░░The job identifier is 611401 and the job result is failed.

#########################################################################

The logfile is still the one created by 10.7.7, unaltered.

I don't see a clue to WHY MySQL didn't start in these reports.

Anyone any ideas here?

Of course, starting mysqld by hand, at least in the 10.7.7 version, gives me access to may data, but I would prefer starting the newest version in the standard systemd way...

Thanks in advance, again

regards, Jogchum



_______________________________________________
Mailing list:https://launchpad.net/~maria-discuss
Post to     :maria-discuss@xxxxxxxxxxxxxxxxxxx
Unsubscribe :https://launchpad.net/~maria-discuss
More help   :https://help.launchpad.net/ListHelp


Follow ups

References