Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MySQL no matching manifest for linux/arm/v7 in the manifest list entries for Raspberry Pi 3

I currently have a Raspberry Pi 3 which I am trying to host a webpage on locally. The page was originally hosted on a VM (Ubuntu) and the Pi loaded the webpage via the internet, however due to changes in the building the Pi can no longer connect to the internet. The site uses Nginx and Docker Compose linked to a MySQL database.

At this point I have moved all the related files to the Pi and in theory I should be able to run the docker-compose up -d command to pull the images, disconnect the Pi from Ethernet once pulled (working at my desk but needs to be in a room without Ethernet and hooked up to a screen, don't ask its a pain) but after its been pulled once it shouldn't need internet again as its hosted locally.

Now for the actual issue, during the pull most things went through fine however it gets stuck at MySQL with the error in the title (currently pulling mysql:latest but I've tried some other versions). I've looked into it and as I understand its because the Raspberry Pi 3 is 32-bit architecture whereas MySQL images are only x86_64, however this info was two years old. The reason for this question is to ask if anyone knows if any MySQL images came out that work on a Raspberry Pi 3 as I can't find any, or if anyone found a solution to this issue.

like image 208
Alisa Mayes Avatar asked Jan 21 '20 10:01

Alisa Mayes


2 Answers

TLDR;

  • 64 bit raspberry pi ubuntu image https://ubuntu.com/download/raspberry-pi
  • Docker pull mysql/mysql-server https://hub.docker.com/r/mysql/mysql-server/

Steps:

  1. Get raspberry pi 64 bit ubuntu image https://ubuntu.com/download/raspberry-pi
  2. Setup as usual to what you need (ssh, passwords, network, upgrades)
  3. Install docker, I used:
  4. curl -L https://get.docker.com -out installdocker.sh // skip if docker installed
  5. chmod +x installdocker.sh // skip if docker installed
  6. ./installdocker.sh // skip if docker installed
  7. usermod -aG docker pi // or whatever your username is.. skip if docker installed
  8. docker run -d -p 3306:3306 --name mysql mysql/mysql-server
  9. docker container logs mysql // find the root password in the logs here
  10. docker exec -it mysql mysql -uroot -p // enter root password when promoted

all done. if you need remote network access to the mysql, well i'm still figuring that one out.

like image 78
PathToLife Avatar answered Nov 09 '22 18:11

PathToLife


did you try specifying the architecture ? --platform=linux/arm64

docker run -d -p 3306:3306 --platform=linux/arm64 --name mysql mysql/mysql-server
like image 35
pacdev Avatar answered Nov 09 '22 17:11

pacdev