[Support] Linuxserver.io - MariaDB


Recommended Posts

Hey guys 

it seems like my docker container got nuked with the latest update. The method of reverting to an older version and updating doesn’t work for me. My log gets spammed with the same message over and over 

Quote

211113 02:31:24 mysqld safe Starting mariadbd daemon with
databases from /config/databases
211113 02:31:25 mysqld safe Logging to '/config/databases/73bc06bd266c.err'

So I had a look into the file that’s named and there’s just this message that’s repeating a few times

Quote

211113 02:25:57 mysqld_safe Starting mariadbd daemon with databases from /config/databases 2021-11-13 2:25:57 0 [Note] /usr/bin/mariadbd (mysqld 10.5.12-MariaDB-log) starting as process 496 ... 2021-11-13 2:25:57 0 [Note] InnoDB: Uses event mutexes 2021-11-13 2:25:57 0 [Note] InnoDB: Compressed tables use zlib 1.2.11 2021-11-13 2:25:57 0 [Note] InnoDB: Number of pools: 1 2021-11-13 2:25:57 0 [Note] InnoDB: Using crc32 + pclmulqdq instructions 2021-11-13 2:25:57 0 [Note] mariadbd: O_TMPFILE is not supported on /var/tmp (disabling future attempts) 2021-11-13 2:25:57 0 [Note] InnoDB: Using Linux native AIO 2021-11-13 2:25:57 0 [Note] InnoDB: Initializing buffer pool, total size = 268435456, chunk size = 134217728 2021-11-13 2:25:57 0 [Note] InnoDB: Completed initialization of buffer pool 2021-11-13 2:25:57 0 [Note] InnoDB: 128 rollback segments are active. 2021-11-13 2:25:57 0 [Note] InnoDB: Creating shared tablespace for temporary tables 2021-11-13 2:25:57 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ... 2021-11-13 2:25:57 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB. 2021-11-13 2:25:57 0 [Note] InnoDB: 10.5.12 started; log sequence number 8367293001; transaction id 37076987 2021-11-13 2:25:57 0 [Note] InnoDB: Loading buffer pool(s) from /config/databases/ib_buffer_pool 2021-11-13 2:25:57 0 [Note] Plugin 'FEEDBACK' is disabled. 2021-11-13 2:25:57 0 [Note] InnoDB: Buffer pool(s) load completed at 211113 2:25:57 2021-11-13 2:25:57 0 [ERROR] mariadbd: File '/conf/config/log/mysql/mariadb-bin.005698' not found (Errcode: 2 "No such file or directory") 2021-11-13 2:25:57 0 [ERROR] Failed to open log (file '/conf/config/log/mysql/mariadb-bin.005698', errno 2) 2021-11-13 2:25:57 0 [ERROR] Could not open log file 2021-11-13 2:25:57 0 [ERROR] Can't init tc log 2021-11-13 2:25:57 0 [ERROR] Aborting

I tried a few things I read but it didn’t get me anywhere, I hope you can help me 

 

sadly I have no backup of my databases as I didn’t even realize that that’s something you should do

Edited by kralwal
Spelling
Link to comment

I'm experiencing a weird issue with kodi and a shared mariadb .  Right now my setup contains a windows laptop, android tablet, shieldtv, and chromebook that all share the same video and music database.  I think I've isolated the behavior to the following: if I open kodi on the windows laptop, I can no longer open kodi on the android devices.  If I reset the mariadb docker container, android starts working again.  I've been running a shared database for years without seeing this issue.  It seems to be similar to what's mentioned here but there's no solution.

 

I don't know if this has to do with the issues from that started popping up here around in August.  These seemed to be related with the update from ubuntu to alpine.  The fix was to downgrade mariadb then upgrade to latest.  If this is the issue referenced above, would someone summarize the steps required to fix it?  The steps are mentioned in this thread but it's kind of scattered and hard to follow.  

 

The relevant section of the chromebook's kodi log after the windows laptop launched kodi:

2021-11-15 19:07:18.664 T:5323     INFO <general>: MYSQL: Connected to version 10.5.13-MariaDB-log
2021-11-15 19:07:18.761 T:5323    ERROR <general>: SQL: [music-adults82] An unknown error occurred
                                                   Query: SELECT idVersion FROM version
                                                   
                                                   
2021-11-15 19:07:18.763 T:5323    ERROR <general>: Process error processing job 

 

I realize "An unknown error occurred" isn't very helpful and I'd be happy to post more relevant logs from kodi and mariadb once we confirm what the problem is.  Anybody else experience this?

Link to comment
  • 2 weeks later...

I had some cache pool upgrade issues and now am receiving this error in Nextcloud
"MySQL server has gone away in /config/www/nextcloud/lib/private/DB/Connection.php:87"

 

I tried poking around MariaDB's appdata to find an error log but was unsuccessful. I know nothing about MariaDB except follow SIO's videos.

 

Any ELI5 help is appreciated. I do have an appdata backup if it comes to that but figured there may be a more appropriate and better way to fix the issue.

 

TIA!

Link to comment
  • 2 weeks later...

I can't seem to get MariaDB to let me login. I'm a newb and following spaceinvaderone's guide.  I've tried both versions of MariaDB in docker. I tried the one he used but kept geting errors so then tried the OFFICIAL version and was following it's instructions to reset the password. I'm getting this response as I do it. Even though the script keeps running and asking me to select options when I get to the end I still can't login.

 

 

 

Quote

 /usr/bin/mysql_secure_installation
touch: cannot touch '.my.cnf.138': Permission denied
touch: cannot touch '.mysql.138': Permission denied
chmod: cannot access '.my.cnf.138': No such file or directory
chmod: cannot access '.mysql.138': No such file or directory

NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB
      SERVERS IN PRODUCTION USE!  PLEASE READ EACH STEP CAREFULLY!

In order to log into MariaDB to secure it, we'll need the current
password for the root user. If you've just installed MariaDB, and
haven't set the root password yet, you should just press enter here.

Enter current password for root (enter for none): 
/usr/bin/mysql_secure_installation: 249: cannot create .my.cnf.138: Permission denied
/usr/bin/mysql_secure_installation: 250: cannot create .my.cnf.138: Permission denied
/usr/bin/mysql_secure_installation: 251: cannot create .my.cnf.138: Permission denied
/usr/bin/mysql_secure_installation: 253: cannot create .my.cnf.138: Permission denied
/usr/bin/mysql_secure_installation: 218: cannot create .mysql.138: Permission denied
/usr/bin/mysql_secure_installation: 220: cannot open .mysql.138: No such file
grep: .my.output.138: No such file or directory
OK, successfully used password, moving on...

Setting the root password or using the unix_socket ensures that nobody
can log into the MariaDB root user without the proper authorisation.

You already have your root account protected, so you can safely answer 'n'.

Switch to unix_socket authentication [Y/n] n
 ... skipping.

You already have your root account protected, so you can safely answer 'n'.

Change the root password? [Y/n] n
 ... skipping.

 

Link to comment
On 8/26/2021 at 2:36 AM, goosetrousers said:
On 8/25/2021 at 7:30 PM, sonic6 said:

Repository: linuxserver/mariadb:110.4.21mariabionic-ls31

I did this, everything worked again. Then I updated to 

linuxserver/mariadb:latest

and everything continued to work, but with an Alpine base. Saved me from migrating, I guess I'll sit on my backups and see how this plays out.


Unfortunately, that didn't work for me.
 

I am now on latest branch, but my Nextcloud still gives error messages.

 

3C3EF22A-5FAC-466B-AADB-4956688A55CB.thumb.jpeg.7296b1adb6e8c8777a9373ab8324ee6a.jpeg

 

Here my MariaDB Log.

 

BCA5BF7F-E566-43FF-9DDC-23D65801EEA1.thumb.jpeg.562914b9b8b8b4b30e153fbb12a0ca0d.jpeg

Link to comment

How can I add another user and a new database?

 

Should I use the console and follow mariadb instructions or is it something I need to do in the docker settings on unraid? Or perhaps a whole new docker container should be setup?

 

Right now I am using it for nextcloud but would also like to use mariadb for my RPi base Home Assistant instance. 

 

If you have a link handy I would very grateful :)

 

Thank you!

Edited by kilonde
clarity
Link to comment

Is there a way to reset the credentials of the root user? The password I have set in the docker configuration isn't working, so I must have tried to change it at some point in the last 2 & a half years. The dockerhub page says once you install the container with a root password, changing it in the docker config will do nothing, and that you have to use mysqladmin. The problem is, I don't have a working password.

 

My Nextcloud container depends on the database I created. Would it be possible to reset the root password without wiping any data?

Link to comment
21 minutes ago, kilonde said:

Click on the mariadb icon in your docker page and then console. 

 

Oh right, I was misunderstanding something. I thought it had to be launched with specific commands.

 

2 hours ago, allanp81 said:

Yes, you'll need to terminal into the docker (you can access this from the docker page on your server):

 

https://www.digitalocean.com/community/tutorials/how-to-reset-your-mysql-or-mariadb-root-password

 

When I follow the DigitalOcean guide, I get an error when trying to flush privileges:

ERROR 1146 (42S02): Table 'mysql.db' doesn't exist

 

and when I try to run ALTER USER:

ERROR 1290 (HY000): The MariaDB server is running with the --skip-grant-tables option so it cannot execute this statement

 

Edited by Stubbs
Link to comment
  • 2 weeks later...
  • 2 weeks later...
On 12/28/2021 at 9:06 PM, thymon said:

 I have the same MariaDB log :( :(  What should I do ?

Hi, 

 

I also have received the same error for the last few weeks sometimes. I was able to solve it with this command after looking into the .err logfile

 

2022-01-05 23:39:32 0 [ERROR] mariadbd: Can't create/write to file '/var/tmp/ibXXXXXX' (Errcode: 13 "Permission denied")
2022-01-05 23:39:32 0 [ERROR] InnoDB: Unable to create temporary file; errno: 13

 

chmod 777 /var/tmp

 

 

Link to comment
  • 2 weeks later...

Hiya,

 

Is it possible to run MariaDB Docker across more than one VLAN? Or can i have two MariaDB instances, one for each VLAN?

 

I read that in theory i could have two MariaDBs as long as they had different:

- Socket

- Port

- Data location.

 

I'm quite new to Dockers, VLANs and Databases!

 

Use-case: I am looking at using MariaDB for both Shinobi CCTV (in a VLAN) and NextCloud in main LAN.

 

I'd prefer one docker across both, but can i do that? Cheers.

Edited by Derek_
Link to comment

Is this normal??


UMASK must be a 3-digit mode with an additional leading 0 to indicate octal.
The first digit will be corrected to 6, the others may be 0, 2, 4, or 6.
UMASK corrected from 022 to 0640 ...

220118 10:53:37 mysqld_safe Logging to '/config/databases/a33da0ec2e80.err'.
220118 10:53:37 mysqld_safe Starting mariadbd daemon with databases from /config/databases

 

Brought to you by linuxserver.io
-------------------------------------

To support LSIO projects visit:
https://www.linuxserver.io/donate/
-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 30-config: executing...
[cont-init.d] 30-config: exited 0.
[cont-init.d] 40-initialise-db: executing...
[cont-init.d] 40-initialise-db: exited 0.
[cont-init.d] 90-custom-folders: executing...
[cont-init.d] 90-custom-folders: exited 0.
[cont-init.d] 99-custom-files: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-files: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
UMASK must be a 3-digit mode with an additional leading 0 to indicate octal.
The first digit will be corrected to 6, the others may be 0, 2, 4, or 6.
UMASK corrected from 022 to 0640 ...
220118 10:53:37 mysqld_safe Logging to '/config/databases/a33da0ec2e80.err'.
220118 10:53:37 mysqld_safe Starting mariadbd daemon with databases from /config/databases

 

Edited by L0rdRaiden
Link to comment
On 1/18/2022 at 2:02 AM, L0rdRaiden said:

Is this normal??


UMASK must be a 3-digit mode with an additional leading 0 to indicate octal.
The first digit will be corrected to 6, the others may be 0, 2, 4, or 6.
UMASK corrected from 022 to 0640 ...

220118 10:53:37 mysqld_safe Logging to '/config/databases/a33da0ec2e80.err'.
220118 10:53:37 mysqld_safe Starting mariadbd daemon with databases from /config/databases

 

Brought to you by linuxserver.io
-------------------------------------

To support LSIO projects visit:
https://www.linuxserver.io/donate/
-------------------------------------
GID/UID
-------------------------------------

User uid: 99
User gid: 100
-------------------------------------

[cont-init.d] 10-adduser: exited 0.
[cont-init.d] 30-config: executing...
[cont-init.d] 30-config: exited 0.
[cont-init.d] 40-initialise-db: executing...
[cont-init.d] 40-initialise-db: exited 0.
[cont-init.d] 90-custom-folders: executing...
[cont-init.d] 90-custom-folders: exited 0.
[cont-init.d] 99-custom-files: executing...
[custom-init] no custom files found exiting...
[cont-init.d] 99-custom-files: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
UMASK must be a 3-digit mode with an additional leading 0 to indicate octal.
The first digit will be corrected to 6, the others may be 0, 2, 4, or 6.
UMASK corrected from 022 to 0640 ...
220118 10:53:37 mysqld_safe Logging to '/config/databases/a33da0ec2e80.err'.
220118 10:53:37 mysqld_safe Starting mariadbd daemon with databases from /config/databases

 

I am using MariaDB for nextcloud which was functioning well now all of a sudden its dead slow. Have this same UMASK in my logs.

Link to comment
  • 2 weeks later...
On 11/16/2021 at 4:48 AM, nukeman said:

I'm experiencing a weird issue with kodi and a shared mariadb .  Right now my setup contains a windows laptop, android tablet, shieldtv, and chromebook that all share the same video and music database.  I think I've isolated the behavior to the following: if I open kodi on the windows laptop, I can no longer open kodi on the android devices.  If I reset the mariadb docker container, android starts working again.  I've been running a shared database for years without seeing this issue.  It seems to be similar to what's mentioned here but there's no solution.

 

I don't know if this has to do with the issues from that started popping up here around in August.  These seemed to be related with the update from ubuntu to alpine.  The fix was to downgrade mariadb then upgrade to latest.  If this is the issue referenced above, would someone summarize the steps required to fix it?  The steps are mentioned in this thread but it's kind of scattered and hard to follow.  

 

The relevant section of the chromebook's kodi log after the windows laptop launched kodi:

2021-11-15 19:07:18.664 T:5323     INFO <general>: MYSQL: Connected to version 10.5.13-MariaDB-log
2021-11-15 19:07:18.761 T:5323    ERROR <general>: SQL: [music-adults82] An unknown error occurred
                                                   Query: SELECT idVersion FROM version
                                                   
                                                   
2021-11-15 19:07:18.763 T:5323    ERROR <general>: Process error processing job 

 

I realize "An unknown error occurred" isn't very helpful and I'd be happy to post more relevant logs from kodi and mariadb once we confirm what the problem is.  Anybody else experience this?

have you managed to solve the problem?

Link to comment
19 hours ago, nukeman said:

No, not with MariaDB.   I installed a MySQL docker and everything is back to working like it should.

 Could you please elaborate how you migrated to MySQL? I have thousands of records and I don't want to rebuild the DB from scrtach.

Edited by ds123
Link to comment
6 hours ago, ds123 said:

 Could you please elaborate how you migrated to MySQL? I have thousands of records and I don't want to rebuild the DB from scrtach.

First I exported my video library to separate files by following these instructions.  Then I setup MySQL like normal and imported the library from the exported nfo files.  Finally, once I validated the import was successful, I deleted all the nfo files.  Pay attention to the importwatchedstate and importresumepoint options when importing.

Link to comment

Hi! I upgraded my MariaDBs on Unraid, and now none of them will start. Apparently, just Clicking "Update" on the docker, does not gracefully shut-down Mariadb, but terminate it? So after the Update, the MariaDB now says "Upgrade after crash not supported" and then InnoDB wont start. This seems to be a quite common issue, but any way to firstly get this up and running?

 

Secondly, apparently just using the "Upgrade/Update" button on the MariaDB Docker in the Unraid WebGUI, isn't a good idea since it hard-kills the docker and then upgrades it, leaving perhaps un-applied redo-logs / unstartable docker? The mariadb will probably start if I just Delete the redo-logs, but I'd rather not? Hope one of you experts here can help me out. I'm no MariaDB expert, I usually stick to Oracle DB :)


Thanks :)

mariadb04_docker_log.txt

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.