JARVIS icon indicating copy to clipboard operation
JARVIS copied to clipboard

got errors when exec docker-compose. it seems to be related to nvidia-driver-470 installation

Open bladexxx opened this issue 2 years ago • 6 comments

WIN10 pro + Docker desktop.

=> ERROR [2/9] RUN apt-get update && apt-get install -y curl wget git && rm -rf /var/lib/apt/lists/* && curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | apt-key add - && distribution=$(. /etc/os-release 54.2s

[2/9] RUN apt-get update && apt-get install -y curl wget git && rm -rf /var/lib/apt/lists/* && curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | apt-key add - && distribution=$(. /etc/os-release;echo $ID$VERSION_ID) && curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | tee /etc/apt/sources.list.d/nvidia-docker.list && apt-get update && apt-get install -y nvidia-driver-470 && rm -rf /var/lib/apt/lists/*:

#0 50.71 Reading package lists... #0 52.51 Reading package lists... #0 53.92 Building dependency tree... #0 54.11 Reading state information... #0 54.14 E: Unable to locate package nvidia-driver-470

failed to solve: executor failed running [/bin/sh -c apt-get update && apt-get install -y curl wget git && rm -rf /var/lib/apt/lists/* && curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | apt-key add - && distribution=$(. /etc/os-release;echo $ID$VERSION_ID) && curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | tee /etc/apt/sources.list.d/nvidia-docker.list && apt-get update && apt-get install -y nvidia-driver-470 && rm -rf /var/lib/apt/lists/*]: exit code: 100

bladexxx avatar Apr 06 '23 17:04 bladexxx

+1

I've got the same error on Ubuntu 16.04:

...
Fetched 19.9 MB in 3s (6119 kB/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
E: Unable to locate package nvidia-driver-470
The command '/bin/sh -c apt-get update &&     apt-get install -y curl wget git &&     rm -rf /var/lib/apt/lists/* &&     curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | apt-key add - &&     distribution=$(. /etc/os-release;echo $ID$VERSION_ID) &&     curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | tee /etc/apt/sources.list.d/nvidia-docker.list &&     apt-get update &&     apt-get install -y nvidia-driver-470 &&     rm -rf /var/lib/apt/lists/*' returned a non-zero code: 100

Clarence-pan avatar Apr 07 '23 05:04 Clarence-pan

Same error for me as well

ERROR: failed to solve: process "/bin/sh -c apt-get update && apt-get install -y curl wget git && rm -rf /var/lib/apt/lists/* && curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | apt-key add - && distribution=$(. /etc/os-release;echo $ID$VERSION_ID) && curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | tee /etc/apt/sources.list.d/nvidia-docker.list && apt-get update && apt-get install -y nvidia-driver-470 && rm -rf /var/lib/apt/lists/*" did not complete successfully: exit code: 100

MacJedi42 avatar Apr 07 '23 06:04 MacJedi42

Sorry. The Docker files are provided by #34 and have not been rigorously reviewed. We hope that someone could contribute a stable and usable Docker build for Jarvis. Thaks.

tricktreat avatar Apr 07 '23 10:04 tricktreat

It looks like there are also some commands having some issues in addition to that:

# Create a working directory
WORKDIR /app

# Copy the requirements file and install Python dependencies
COPY server/requirements.txt .
RUN pip3 install -r requirements.txt

Trying to copy the requirements.txt into /app working directory just results in...

#10 [6/9] COPY server/requirements.txt . #10 sha256:03d49b7854c03c0c00734fb423d2dd017c9b0af15f74e769c886d7d6efd4a7fa #10 ERROR: "/server/requirements.txt" not found: not found

[6/9] COPY server/requirements.txt .:


failed to compute cache key: "/server/requirements.txt" not found: not found

Being unable to detect the file in question to copy over?

I even tried doing

RUN chmod +r /server/requirements.txt
RUN ls -l /server/requirements.txt

To at least make sure it has permissions to read the file but it still can't find it

SwiggitySwerve avatar Apr 07 '23 18:04 SwiggitySwerve

I assume if you are installing on WSL2, Ubuntu 16.04 may not be compatible with it. https://docs.nvidia.com/datacenter/tesla/tesla-installation-notes/index.html requires installing kernel headers but I get this error,

sudo apt-get install linux-headers-$(uname -r) Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package linux-headers-5.15.90.1-microsoft-standard-WSL2 E: Couldn't find any package by glob 'linux-headers-5.15.90.1-microsoft-standard-WSL2' E: Couldn't find any package by regex 'linux-headers-5.15.90.1-microsoft-standard-WSL2'

Edit: looks like I can build a kernel from a git source https://github.com/microsoft/WSL2-Linux-Kernel I will try and see how it goes.

Edit2: building a kernel does not work. I am changing the docker image to a preinstalled nvidia driver.

FROM nvcr.io/nvidia/driver:460.32.03-ubuntu16.04

Edit3: gpg key error & python3 not found. Retrying with nvcr.io/nvidia/driver:470.182.03-ubuntu18.04

Ok, still installing the container, but so far doing just fine. Here's my suggestion for the Dockerfile

  1. Change the Docker image source to nvcr.io/nvidia/driver:470.182.03-ubuntu18.04 (if you need to "docker login nvcr.io", create a nvidia ngc account then get your api key).

FROM nvcr.io/nvidia/driver:470.182.03-ubuntu18.04

  1. Comment out the RUN section that installs nvidia-driver-470.

Hope it works.

jubileekr avatar Apr 08 '23 08:04 jubileekr

If have a bug fix that

Aniketmaurya8 avatar Apr 08 '23 10:04 Aniketmaurya8