Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request]: Support for Apple Silicon Mac #253

Closed
1 task done
vega113 opened this issue Apr 8, 2024 · 9 comments
Closed
1 task done

[Feature Request]: Support for Apple Silicon Mac #253

vega113 opened this issue Apr 8, 2024 · 9 comments

Comments

@vega113
Copy link

vega113 commented Apr 8, 2024

Is there an existing issue for the same feature request?

  • I have checked the existing issues.

Is your feature request related to a problem?

Hi.
It looks like the docker image and instructions are for Linux. I tried to run the docker compose on my M2 Mac, but I do get errors related to MySQL.

! mysql The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
 runtime: failed to create new OS thread (have 2 already; errno=22)


### Describe the feature you'd like

Apple Silicone support and clear instructions how to install in Mac

### Describe implementation you've considered

I tried to add     `platform: linux/amd64` to MySQL image deofinition in docker compose, but this didn't help.

### Documentation, adoption, use case

_No response_

### Additional information

_No response_
@litetoooooom
Copy link

M

1 similar comment
@franztao
Copy link

franztao commented Apr 9, 2024

M

@hxf829
Copy link

hxf829 commented Apr 10, 2024

modify docker-compose-base.yml
image
mysql:
image: mysql/mysql-server:latest

@vega113
Copy link
Author

vega113 commented Apr 10, 2024

@hxf829 Thanks. That helped.
However I get now some issue with starting MySQL. Missing permission.

ragflow-mysql   | 2024-04-10T08:28:05.436873Z 0 [Warning] [MY-011068] [Server] The syntax '--skip-host-cache' is deprecated and will be removed in a future release. Please use SET GLOBAL host_cache_size=0 instead.
ragflow-mysql   | 2024-04-10T08:28:05.442115Z 0 [Warning] [MY-010918] [Server] 'default_authentication_plugin' is deprecated and will be removed in a future release. Please use authentication_policy instead.
ragflow-mysql   | 2024-04-10T08:28:05.442322Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.32) starting as process 1
ragflow-mysql   | mysqld: 
ragflow-mysql   | File './binlog.index' not found (OS errno 13 - Permission denied)
ragflow-mysql   | 
ragflow-mysql   | 
ragflow-mysql   | 2024-04-10T08:28:05.455909Z 0 [ERROR] [MY-010119] [Server] Aborting
ragflow-mysql   | 2024-04-10T08:28:05.457529Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.32)  MySQL Community Server - GPL.
ragflow-mysql exited with code 1
ragflow-mysql   | [Entrypoint] Starting MySQL 8.0.32-1.2.11-server
ragflow-mysql   | 2024-04-10T08:28:06.548380Z 0 [Warning] [MY-011068] [Server] The syntax '--skip-host-cache' is deprecated and will be removed in a future release. Please use SET GLOBAL host_cache_size=0 instead.
ragflow-mysql   | 2024-04-10T08:28:06.550551Z 0 [Warning] [MY-010918] [Server] 'default_authentication_plugin' is deprecated and will be removed in a future release. Please use authentication_policy instead.
ragflow-mysql   | 2024-04-10T08:28:06.550634Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.32) starting as process 1
ragflow-mysql   | mysqld: File './binlog.index' not found (OS errno 13 - Permission denied)
ragflow-mysql   | 2024-04-10T08:28:06.562618Z 0 [ERROR] [MY-010119] [Server] Aborting
ragflow-mysql   | 2024-04-10T08:28:06.567073Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.32)  MySQL Community Server - GPL.
ragflow-mysql exited with code 1
ragflow-mysql   | [Entrypoint] Starting MySQL 8.0.32-1.2.11-server
ragflow-es-01   | 
ragflow-es-01   | 
ragflow-es-01   | ERROR: Elasticsearch exited unexpectedly, with exit code 137
ragflow-mysql   | 2024-04-10T08:28:08.193320Z 0 [Warning] [MY-011068] [Server] The syntax '--skip-host-cache' is deprecated and will be removed in a future release. Please use SET GLOBAL host_cache_size=0 instead.
ragflow-mysql   | 2024-04-10T08:28:08.199096Z 0 [Warning] [MY-010918] [Server] 'default_authentication_plugin' is deprecated and will be removed in a future release. Please use authentication_policy instead.
ragflow-mysql   | 2024-04-10T08:28:08.199287Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.32) starting as process 1
ragflow-mysql   | mysqld: File './binlog.index' not found (OS errno 13 - Permission denied)
ragflow-mysql   | 2024-04-10T08:28:08.215373Z 0 [ERROR] [MY-010119] [Server] Aborting
ragflow-mysql   | 2024-04-10T08:28:08.216843Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.32)  MySQL Community Server - GPL.
dependency failed to start: container ragflow-es-01 is unhealthy```

I use Colima as docker container, maybe it is related

@KevinHuSh
Copy link
Collaborator

Have a look at #329

KevinHuSh pushed a commit that referenced this issue May 27, 2024
### What problem does this PR solve?

#253 

### Type of change

- [x] New Feature (non-breaking change which adds functionality)
@FellowTraveler
Copy link

Having trouble running ragflow on M3 Silicon Mac or even building the docker:
docker build --no-cache -t infiniflow/ragflow:dev -f Dockerfile.arm .

Output:

Dockerfile.arm:7
--------------------
   6 |     COPY requirements_arm.txt /ragflow/requirements.txt
   7 | >>> RUN pip install -i https://mirrors.aliyun.com/pypi/simple/ --default-timeout=1000 -r requirements.txt &&\
   8 | >>> python -c "import nltk;nltk.download('punkt');nltk.download('wordnet')"
   9 |     
--------------------
ERROR: failed to solve: process "/bin/sh -c pip install -i https://mirrors.aliyun.com/pypi/simple/ --default-timeout=1000 -r requirements.txt &&python -c \"import nltk;nltk.download('punkt');nltk.download('wordnet')\"" did not complete successfully: exit code: 1

View build details: docker-desktop://dashboard/build/desktop-linux/desktop-linux/fvay1k2wtt4fzbb2yijrj0r2t

@joeke80215
Copy link

joeke80215 commented Aug 28, 2024

Having trouble running ragflow on M3 Silicon Mac or even building the docker: docker build --no-cache -t infiniflow/ragflow:dev -f Dockerfile.arm .

Output:

Dockerfile.arm:7
--------------------
   6 |     COPY requirements_arm.txt /ragflow/requirements.txt
   7 | >>> RUN pip install -i https://mirrors.aliyun.com/pypi/simple/ --default-timeout=1000 -r requirements.txt &&\
   8 | >>> python -c "import nltk;nltk.download('punkt');nltk.download('wordnet')"
   9 |     
--------------------
ERROR: failed to solve: process "/bin/sh -c pip install -i https://mirrors.aliyun.com/pypi/simple/ --default-timeout=1000 -r requirements.txt &&python -c \"import nltk;nltk.download('punkt');nltk.download('wordnet')\"" did not complete successfully: exit code: 1

View build details: docker-desktop://dashboard/build/desktop-linux/desktop-linux/fvay1k2wtt4fzbb2yijrj0r2t

change install==1.3.5 to pip-install==1.3.5 and tabulate-0.9.0 to tabulate==0.9.0 on requirements_arm.txt

KevinHuSh pushed a commit that referenced this issue Aug 28, 2024
Fix building on ARM architecture.

### What problem does this PR solve?

Fix building on ARM architecture.

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)


### Related issues

- #2137
- #610
- #434
- #253
@houchenll
Copy link

modify docker-compose-base.yml image mysql: image: mysql/mysql-server:latest

works for me, Apple M2 Pro

@yuzhichang
Copy link
Member

Latest main has changed mysql from 5.7 to 8.0.
I've verify it work on linux/arm64.

Halfknow pushed a commit to Halfknow/ragflow that referenced this issue Nov 11, 2024
Fix building on ARM architecture.

### What problem does this PR solve?

Fix building on ARM architecture.

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)


### Related issues

- infiniflow#2137
- infiniflow#610
- infiniflow#434
- infiniflow#253
Halfknow pushed a commit to Halfknow/ragflow that referenced this issue Nov 13, 2024
### What problem does this PR solve?

infiniflow#253 

### Type of change

- [x] New Feature (non-breaking change which adds functionality)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants