mysql crashes inside jail - maybe lack of memory or something like that?

Krautmaster

Explorer
Joined
Apr 10, 2017
Messages
81
My nextcloud instance ran fine with same db in Freenas 11.3 U5 but now with updated fresh jail and Truenas 12 the nextcloud is randomly down.

It seems to be an issue with that sql server. I can even run a check on my database and it looses the connection. Any ideas?
Thx
2020-10-28 19_27_09-Window.png


root@nextcloud:~ # mysqlcheck --version
mysqlcheck Ver 2.7.4-MariaDB Distrib 10.4.15-MariaDB, for FreeBSD12.1 (amd64)
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
What's inside the jail in /var/db/mysql/*.err? That should tell you why it is crashing.
 

Krautmaster

Explorer
Joined
Apr 10, 2017
Messages
81
hm i restored an elder snapshot of my DB to an new dataset and mounted that new dataset to that jail, and after the nextcloud update, it works fine. Even the database chekc now works without an issue. Weird.

I restored the problematic status from the auto snapshot from this night to check the *.err file. Last lines are


Code:
2020-09-26 12:03:47 34429034496 [Note] Reading of all Master_info entries succeeded
2020-09-26 12:03:47 34429034496 [Note] Added new Master_info '' to hash table
2020-09-26 12:03:47 34429034496 [Note] /usr/local/libexec/mysqld: ready for connections.
Version: '10.2.32-MariaDB'  socket: '/tmp/mysql.sock'  port: 3306  FreeBSD Ports
2020-09-26 12:03:50 34728667904 [Note] InnoDB: Buffer pool(s) load completed at 200926 12:03:50
2020-10-21  8:45:17 34429034496 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2020-10-21  8:45:17 34429034496 [Note] InnoDB: Uses event mutexes
2020-10-21  8:45:17 34429034496 [Note] InnoDB: Compressed tables use zlib 1.2.11
2020-10-21  8:45:17 34429034496 [Note] InnoDB: Number of pools: 1
2020-10-21  8:45:17 34429034496 [Note] InnoDB: Using SSE2 crc32 instructions
2020-10-21  8:45:17 34429034496 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2020-10-21  8:45:17 34429034496 [Note] InnoDB: Completed initialization of buffer pool
2020-10-21  8:45:17 34429034496 [Note] InnoDB: Highest supported file format is Barracuda.
2020-10-21  8:45:17 34429034496 [Note] InnoDB: Starting crash recovery from checkpoint LSN=15834734311
2020-10-21  8:45:18 34429034496 [Note] InnoDB: 128 out of 128 rollback segments are active.
2020-10-21  8:45:18 34429034496 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2020-10-21  8:45:18 34429034496 [Note] InnoDB: Creating shared tablespace for temporary tables
2020-10-21  8:45:18 34429034496 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2020-10-21  8:45:18 34429034496 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2020-10-21  8:45:18 34429034496 [Note] InnoDB: 5.7.30 started; log sequence number 15834734320
2020-10-21  8:45:18 34728667904 [Note] InnoDB: Loading buffer pool(s) from /var/db/mysql/ib_buffer_pool
2020-10-21  8:45:18 34429034496 [Note] Plugin 'FEEDBACK' is disabled.
2020-10-21  8:45:18 34429034496 [Note] Recovering after a crash using tc.log
2020-10-21  8:45:18 34429034496 [Note] Starting crash recovery...
2020-10-21  8:45:18 34429034496 [Note] Crash recovery finished.
2020-10-21  8:45:18 34429034496 [Note] Server socket created on IP: '0.0.0.0'.
2020-10-21  8:45:18 34429034496 [Note] Reading of all Master_info entries succeeded
2020-10-21  8:45:18 34429034496 [Note] Added new Master_info '' to hash table
2020-10-21  8:45:18 34429034496 [Note] /usr/local/libexec/mysqld: ready for connections.
Version: '10.2.32-MariaDB'  socket: '/tmp/mysql.sock'  port: 3306  FreeBSD Ports
2020-10-21  8:45:20 34728667904 [Note] InnoDB: Buffer pool(s) load completed at 201021  8:45:20
2020-10-22 14:53:02 34728652544 [Note] /usr/local/libexec/mysqld (initiated by: unknown): Normal shutdown
2020-10-22 14:53:02 34728652544 [Note] Event Scheduler: Purging the queue. 0 events
2020-10-22 14:53:02 34728661504 [Note] InnoDB: FTS optimize thread exiting.
2020-10-22 14:53:02 34728652544 [Note] InnoDB: Starting shutdown...
2020-10-22 14:53:02 34728667904 [Note] InnoDB: Dumping buffer pool(s) to /var/db/mysql/ib_buffer_pool
2020-10-22 14:53:02 34728667904 [Note] InnoDB: Instance 0, restricted to 2048 pages due to innodb_buf_pool_dump_pct=25
2020-10-22 14:53:02 34728667904 [Note] InnoDB: Buffer pool(s) dump completed at 201022 14:53:02
2020-10-22 14:53:03 34728652544 [Note] InnoDB: Shutdown completed; log sequence number 15877867710
2020-10-22 14:53:03 34728652544 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2020-10-22 14:53:03 34728652544 [Note] /usr/local/libexec/mysqld: Shutdown complete


nothing from the crashes i faced the last few days, so it seems that it crashed without even logging to that *.err file.

All entries are from the older maria db version 10.2.32.

This time once I restored the elder DB snapshot (from freenas 11.3 and NC19) I ran a
mysql_upgrade -u root -p
first, and that went fine. Then i opend the browser to do that NC update to 20 wich was already pending.

Whatever was wrong, Ill check if the DB runs fine the next days.
 
Last edited:
Top