【发布时间】:2020-10-16 03:38:51
【问题描述】:
请帮忙! mariadb 在 raspberry4 上的 debian 10.4 上崩溃,刚刚从 10.2 升级到 10.4。但是我在升级后重新启动,重新启动后一切正常。崩溃发生在 1 小时后。
`/var/log/mysql/error.log
2020-06-25 15:36:25 0 [Note] InnoDB: 10.3.22 started; log sequence number 17201576; transaction id 150227
2020-06-25 15:36:25 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2020-06-25 15:36:25 0 [Note] Plugin 'FEEDBACK' is disabled.
2020-06-25 15:36:25 0 [Note] Recovering after a crash using tc.log
2020-06-25 15:36:25 0 [ERROR] Can't init tc log
2020-06-25 15:36:25 0 [ERROR] Aborting`
两小时前:
`2020-06-25 13:57:39 0 [Note] InnoDB: 10.3.22 started; log sequence number 17198243; transaction id 150195
2020-06-25 13:57:39 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2020-06-25 13:57:39 0 [Note] Plugin 'FEEDBACK' is disabled.
2020-06-25 13:57:39 0 [Note] Server socket created on IP: '127.0.0.1'.
2020-06-25 13:57:39 0 [Note] Reading of all Master_info entries succeeded
2020-06-25 13:57:39 0 [Note] Added new Master_info '' to hash table
2020-06-25 13:57:39 0 [Note] /usr/sbin/mysqld: ready for connections.`
我已经移动了 tc.log:
mv /var/lib/mysql/tc.log /var/lib/mysql/tc.log.bak
没用!!
root@archivpi:~# service mysql restart
Job for mariadb.service failed because a fatal signal was delivered to the control process.
See "systemctl status mariadb.service" and "journalctl -xe" for details.
这里是 systemctl 状态:我必须在这里写一些文本一些文本一些文本否则没有保存。我必须在这里写一些文本一些文本一些文本否则没有保存。我必须在这里写一些文本一些文本一些文本否则没有保存。
root@archivpi:~# systemctl status mariadb.service
● mariadb.service - MariaDB 10.3.22 database server
Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enabled)
Active: activating (start-pre) since Thu 2020-06-25 16:43:11 CEST; 198ms ago
Docs: man:mysqld(8)
https://mariadb.com/kb/en/library/systemd/
Process: 25326 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exited, status=0/SUCCESS)
Process: 25327 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Cntrl PID: 25329 (sh)
Tasks: 4 (limit: 1599)
Memory: 1.1M
CGroup: /system.slice/mariadb.service
├─25329 /bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= || VAR=`/usr/bin/galera_recovery`; [ $? -eq 0 ] && systemctl set-env
├─25330 /bin/sh /usr/bin/galera_recovery
├─25341 /bin/sh /usr/bin/galera_recovery
└─25343 sed -e s;--[^=]*=;;
Jun 25 16:43:11 archivpi systemd[1]: Starting MariaDB 10.3.22 database server...
我这里还有一个树莓派,也升级到了 10.4。 mariadb 在那里工作,类似的数据库。我可以在那里查看/比较...如果有帮助。
非常神秘的是:
root@archivpi:~# aptitude reinstall mariadb-server
Die folgenden Pakete werden ERNEUT INSTALLIERT:
mariadb-server
Die folgenden teilweise installierten Pakete werden konfiguriert:
hostapd
0 Pakete aktualisiert, 0 zusätzlich installiert, 1 erneut installiert, 0 werden entfernt und 0 nicht aktualisiert.
0 B/30,8 kB an Archiven müssen heruntergeladen werden. Nach dem Entpacken werden 0 B zusätzlich belegt sein.
(Lese Datenbank ... 129192 Dateien und Verzeichnisse sind derzeit installiert.)
Vorbereitung zum Entpacken von .../mariadb-server_1%3a10.3.22-0+deb10u1_all.deb ...
Entpacken von mariadb-server (1:10.3.22-0+deb10u1) über (1:10.3.22-0+deb10u1) ...
mariadb-server (1:10.3.22-0+deb10u1) wird eingerichtet ...
hostapd (2:2.7+git20190128+0c1e29f-6+deb10u2) wird eingerichtet ...
hostapd.service is a disabled or a static unit not running, not starting it.
/var/lib/dpkg/info/hostapd.postinst: 53: .: Can't open /etc/default/hostapd
dpkg: Fehler beim Bearbeiten des Paketes hostapd (--configure):
»installiertes hostapd-Skript des Paketes post-installation«-Unterprozess gab den Fehlerwert 127 zurück
Fehler traten auf beim Bearbeiten von:
hostapd
E: Sub-process /usr/bin/dpkg returned an error code (1)
hostapd (2:2.7+git20190128+0c1e29f-6+deb10u2) wird eingerichtet ...
hostapd.service is a disabled or a static unit not running, not starting it.
/var/lib/dpkg/info/hostapd.postinst: 53: .: Can't open /etc/default/hostapd
dpkg: Fehler beim Bearbeiten des Paketes hostapd (--configure):
»installiertes hostapd-Skript des Paketes post-installation«-Unterprozess gab den Fehlerwert 127 zurück
Fehler traten auf beim Bearbeiten von:
hostapd
hostapd 和 mariadb 有什么关系??我从其他机器复制了一个空的 /etc/default/hostapd 到那个树莓,现在 hostapd 是“满意的”。 (可能之前已经出错了,但是为什么重新安装 mariadb-server 时出现问题?
我有另一个运行 mariadb 的树莓派,也升级了,但正在运行。我可以比较文件/复制文件/ ...如果有用的话
我可以在不删除数据库的情况下重新安装数据库软件吗? - 我有一个重要数据库的副本。第二个数据库,没那么重要,我没有副本。
这就是 /var/log/mysql/mysql.log 的完整 start-until-crash 协议:
2020-06-25 15:51:16 0 [Note] InnoDB: Using Linux native AIO
2020-06-25 15:51:16 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2020-06-25 15:51:16 0 [Note] InnoDB: Uses event mutexes
2020-06-25 15:51:16 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
2020-06-25 15:51:16 0 [Note] InnoDB: Number of pools: 1
2020-06-25 15:51:16 0 [Note] InnoDB: Using generic crc32 instructions
2020-06-25 15:51:17 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2020-06-25 15:51:17 0 [Note] InnoDB: Completed initialization of buffer pool
2020-06-25 15:51:17 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page \
of setpriority().
2020-06-25 15:51:17 0 [Note] InnoDB: 128 out of 128 rollback segments are active.
2020-06-25 15:51:17 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2020-06-25 15:51:17 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2020-06-25 15:51:17 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2020-06-25 15:51:17 0 [Note] InnoDB: 10.3.22 started; log sequence number 17201594; transaction id 150227
2020-06-25 15:51:17 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2020-06-25 15:51:17 0 [Note] Plugin 'FEEDBACK' is disabled.
2020-06-25 15:51:17 0 [Note] Recovering after a crash using tc.log
2020-06-25 15:51:17 0 [ERROR] Can't init tc log
2020-06-25 15:51:17 0 [ERROR] Aborting
【问题讨论】:
-
嗨,这个问题会更好
-
使用问题下方的
edit链接