Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-29260

Server crashes when running migration queries inside Docker on Windows

    XMLWordPrintable

Details

    Description

      I have a Laravel application inside Docker container, which crashes when trying to run migrations.
      docker-compose.yml:

      mysql:
          container_name: web__mysql
          build:
            context: .
            dockerfile: ./.docker/services/mysql/Dockerfile
          restart: unless-stopped
          tty: true
          ports:
            - "3306:3306"
          volumes:
            - ./.docker/services/mysql/data:/var/lib/mysql
          environment:
            MARIADB_DATABASE: db
            MARIADB_USER: web
            MARIADB_PASSWORD: password
            MARIADB_ROOT_PASSWORD: root
            SERVICE_TAGS: dev
            SERVICE_NAME: mysql
            TZ: Europe/Riga
          networks:
            - app
      

      Dockerfile:

      FROM mariadb:latest
      ENV TZ=Europe/Riga
      RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
      

      No matter which version I pick, everytime i run migrations, the database server crashes with this error:

      InnoDB: preallocating 147456 bytes for file ./db/events_places.ibd failed with error 2
      

      This always happens on this query:

      alter table `events_places` add unique `events_places_place_id_event_id_unique`(`place_id`, `event_id`))
      

      If you need all queries that were run before that, I can provide. In attachment there is log from Docker terminal.

      Attachments

        Issue Links

          Activity

            People

              danblack Daniel Black
              deniss.kozlovs Deniss Kozlovs
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.