1

EDIT: Found out what I was doing wrong. I was using mariadb-dump to import instead of just mariadb.

I upgraded from MariaDB 10.x to 11.x. mariadb -V is showing the updated version.

I exported the database (which was retained during upgrade) via MySQL/MariaDB-dump and got the infamous sandbox error.

Using sed or piping commands, we can get it uploaded, but it's annoying.

We ran mariadb-upgrade and it still had the same error.

/*M!999999\- enable the sandbox mode */
-- MariaDB dump 10.19-11.5.2-MariaDB, for debian-linux-gnu (x86_64)
--
-- Host: localhost    Database:
-- ------------------------------------------------------
-- Server version       11.5.2-MariaDB-ubu2204

Logically, two things could be going on. One is that somehow the dump program is still the older version, possibly because it was never overwritten despite the rest being upgraded.

Second possibility is that the database itself is still the older version. Either because mariadb-upgrade was incorrect or maybe a new database has to be made under the current MariaDB.

I have not tried mariabackup yet, but that looks like a possible solution.

Question: How can I troubleshoot this, and any potential solutions?

EDIT: To clarify the import/export command I am using goes like this;

For export:

mariadb-dump -u username -p DBname > filename.sql

Import:

mariadb-dump -u username -p DBname < filename.sql

NOTE: I used both mariadb-dump and mysql dump (which just switched to maria).

EDIT 2:

So I think the database is exporting fine. The issue is that my database may be corrupted. /M!999999\ is different than /!999999\ sandbox bug. Looks like an M was inserted.

8
  • 1
    The database dump appears to be taken via the the new version because /*M!99999.... If mariadb -V is showing the latest version, are you using this client in some way? And per below the server version is 11.5.2. How are you using the SQL Dump in such a way as to trigger the sandbox protection? What sort of "upload" are you doing?
    – danblack
    Commented Aug 27 at 23:01
  • What I did was try to restore backups on a test server with the same environment. I updated this question with the commands I used. I see your point, it is inexplicable because both environments are running the same version of mariaDB and the sandbox iss only happens going to on older version of mariaDB, not a newer.
    – Tony
    Commented Aug 28 at 1:06
  • Ran this command to check the SQL file: customer@host:/var/www$ head -n 5 db.sql :::OUTPUT:::: /*M!999999\- enable the sandbox mode */ -- MariaDB dump 10.19-11.5.2-MariaDB, for debian-linux-gnu (x86_64)
    – Tony
    Commented Aug 28 at 4:16
  • So I think the database is exporting fine. The issue is that my database may be corrupted. /*M!999999\ is different than /*!999999\. Looks like an M was inserted.
    – Tony
    Commented Aug 28 at 5:03
  • 1
    @danblack found out what I was doing wrong. I was using mariadb-dump to import instead of just mariadb.
    – Tony
    Commented Sep 2 at 6:52

2 Answers 2

1

Found out what I was doing wrong. I was using mariadb-dump to import instead of just mariadb. I'm used to using mysql/mysqldump.

-1

I think you've updated the database instance, the server so to speak, so the database files are still in the older version.

Have you done a

SELECT VERSION();

in a selected database to check the version?

4
  • This is not an answer to the question but appears more like it should be a comment?
    – easleyfixed
    Commented Aug 27 at 19:35
  • Thanks. I did do SELECT VERSION(); but I did not have the database selected. This time I did and it is showing as updated: MariaDB [DBname] SELECT VERSION(); +------------------------+ | VERSION() | +------------------------+ | 11.5.2-MariaDB-ubu2204 | +------------------------+ 1 row in set (0.000 sec)
    – Tony
    Commented Aug 27 at 19:46
  • ok, so, just to be clear, you updated the database and tried to restore the backups after the update, or you updated the database then tried to make a backup?
    – Alec
    Commented Aug 27 at 20:36
  • What I did was try to restore backups on a test server with the same environment. I updated this question with the commands I used.
    – Tony
    Commented Aug 28 at 1:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.