question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Where to modify the apt sources in building such container?

See original GitHub issue

Description A clear and concise description of what the bug is. In the process of compiling the triton server with docker, we find that we can not install some apt packages. And we want to modify the sources in /etc/apt/sources.list. But we can not find the corresponding dockerfile. Can you tell me where the corresponding dockerfile is or where we can add the new sources into sources.list. Thanks! We want to add these commands to the corresponding dockerfile. RUN sed -i 's/archive.ubuntu.com/mirrors.ustc.edu.cn/g' /etc/apt/sources.list && \ sed -i 's/security.ubuntu.com/mirrors.ustc.edu.cn/g' /etc/apt/sources.list Triton Information What version of Triton are you using? Main. Are you using the Triton container or did you build it yourself? Yes. To Reproduce Steps to reproduce the behavior. We will show the logs below. We can find that this errors are in the step 19/43 when executing some command in container. ... Step 1/43 : ARG BASE_IMAGE=nvcr.io/nvidia/tritonserver:21.12-py3-min Step 2/43 : ARG ONNXRUNTIME_VERSION=1.10.0 Step 3/43 : ARG ONNXRUNTIME_REPO=https://github.com/microsoft/onnxruntime Step 4/43 : ARG ONNXRUNTIME_BUILD_CONFIG=Release Step 5/43 : ARG ONNXRUNTIME_OPENVINO_VERSION=2021.2.200 Step 6/43 : FROM ${BASE_IMAGE} Step 7/43 : WORKDIR /workspace Step 8/43 : ENV DEBIAN_FRONTEND=noninteractive Step 9/43 : RUN apt-get update && apt-get install -y --no-install-recommends software-properties-common wget zip ca-certificates build-essential curl libcurl4-openssl-dev libssl-dev patchelf python3-dev python3-pip git gnupg gnupg1 Step 10/43 : RUN wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null && apt-add-repository 'deb https://apt.kitware.com/ubuntu/ focal main' && apt-get update && apt-get install -y --no-install-recommends cmake-data=3.21.1-0kitware1ubuntu20.04.1 cmake=3.21.1-0kitware1ubuntu20.04.1 && cmake --version ... Step 19/43 : RUN wget https://apt.repos.intel.com/openvino/2021/GPG-PUB-KEY-INTEL-OPENVINO-2021 && apt-key add GPG-PUB-KEY-INTEL-OPENVINO-2021 && rm GPG-PUB-KEY-INTEL-OPENVINO-2021 && cd /etc/apt/sources.list.d && echo "deb https://apt.repos.intel.com/openvino/2021 all main">intel-openvino-2021.list && apt update && apt install -y intel-openvino-dev-ubuntu20-${ONNXRUNTIME_OPENVINO_VERSION} && cd ${INTEL_OPENVINO_DIR}/install_dependencies && ./install_openvino_dependencies.sh ... 91mE: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/universe/f/flite/libflite1_2.1-release-3_amd64.deb Connection failed [IP: 91.189.88.152 80] E: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/main/g/gstreamer1.0/gir1.2-gstreamer-1.0_1.16.2-2_amd64.deb Connection failed [IP: 91.189.88.142 80] E: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/universe/f/faad2/libfaad2_2.9.1-1_amd64.deb Connection failed [IP: 91.189.88.142 80] E: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/universe/f/fluidsynth/libfluidsynth2_2.1.1-2_amd64.deb Connection failed [IP: 91.189.88.142 80] E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing? The command '/bin/sh -c wget https://apt.repos.intel.com/openvino/2021/GPG-PUB-KEY-INTEL-OPENVINO-2021 && apt-key add GPG-PUB-KEY-INTEL-OPENVINO-2021 && rm GPG-PUB-KEY-INTEL-OPENVINO-2021 && cd /etc/apt/sources.list.d && echo "deb https://apt.repos.intel.com/openvino/2021 all main">intel-openvino-2021.list && apt update && apt install -y intel-openvino-dev-ubuntu20-${ONNXRUNTIME_OPENVINO_VERSION} && cd ${INTEL_OPENVINO_DIR}/install_dependencies && ./install_openvino_dependencies.sh' returned a non-zero code: 100 make[2]: Leaving directory '/tmp/tritonbuild/onnxruntime/build' make[2]: *** [CMakeFiles/ort_target.dir/build.make:74: onnxruntime/lib/libonnxruntime.so] Error 100 make[1]: *** [CMakeFiles/Makefile2:143: CMakeFiles/ort_target.dir/all] Error 2 make[1]: Leaving directory '/tmp/tritonbuild/onnxruntime/build' make: *** [Makefile:136: all] Error 2 platform linux machine x86_64 version 2.19.0dev default repo-tag: main backend "ensemble" at tag/branch "main" backend "identity" at tag/branch "main" backend "repeat" at tag/branch "main" backend "square" at tag/branch "main" backend "onnxruntime" at tag/branch "main" backend "pytorch" at tag/branch "main" repoagent "checksum" at tag/branch "main" Building Triton Inference Server component "common" at tag/branch "main" component "core" at tag/branch "main" component "backend" at tag/branch "main" component "thirdparty" at tag/branch "main" error: make install failed platform linux machine x86_64 version 2.19.0dev default repo-tag: main container version 22.02dev upstream container version 21.12 backend "ensemble" at tag/branch "main" backend "identity" at tag/branch "main" backend "repeat" at tag/branch "main" backend "square" at tag/branch "main" backend "onnxruntime" at tag/branch "main" backend "pytorch" at tag/branch "main" repoagent "checksum" at tag/branch "main" error: docker run tritonserver_builder failed

We also check the docker. And we find that there exists such a container which has the same command with the step 19/43. 4043a261c598f42d0f6739c1a6e0a4468cf0d44f7cbf285f68f1e8706c446e75 sha256:67b54dfca3e2753ec28caaf633f4acee8ffdde03f81a4000ae67564f3b29f7f5 "/bin/sh -c 'wget https://apt.repos.intel.com/openvino/2021/GPG-PUB-KEY-INTEL-OPENVINO-2021 && apt-key add GPG-PUB-KEY-INTEL-OPENVINO-2021 && rm GPG-PUB-KEY-INTEL-OPENVINO-2021 && cd /etc/apt/sources.list.d && echo \"deb https://apt.repos.intel.com/openvino/2021 all main\">intel-openvino-2021.list && apt update && apt install -y intel-openvino-dev-ubuntu20-${ONNXRUNTIME_OPENVINO_VERSION} && cd ${INTEL_OPENVINO_DIR}/install_dependencies && ./install_openvino_dependencies.sh'" Describe the models (framework, inputs, outputs), ideally include the model configuration file (if using an ensemble include the model configuration file for that as well). ./build.py --build-dir=/tmp/citritonbuild --enable-logging --enable-stats --enable-tracing --enable-metrics --enable-gpu-metrics --enable-gpu --filesystem=gcs --filesystem=azure_storage --filesystem=s3 --endpoint=http --endpoint=grpc --repo-tag=common:main --repo-tag=core:main --repo-tag=backend:main --repo-tag=thirdparty:main --backend=ensemble --backend=identity:main --backend=repeat:main --backend=square:main --backend=onnxruntime:main --backend=pytorch:main --repoagent=checksum:main Expected behavior A clear and concise description of what you expected to happen. We can apt-get install all the packages.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
SimonLliucommented, Feb 16, 2022

That container is being built as a part of individual backend cmake build: https://github.com/triton-inference-server/onnxruntime_backend/blob/main/CMakeLists.txt#L360 The script to build the docker file is here: https://github.com/triton-inference-server/onnxruntime_backend/blob/main/tools/gen_ort_dockerfile.py

Same build structure is found in other backends.

Thanks very much! This problem is solved.

0reactions
tanmayv25commented, Feb 14, 2022

That container is being built as a part of individual backend cmake build: https://github.com/triton-inference-server/onnxruntime_backend/blob/main/CMakeLists.txt#L360 The script to build the docker file is here: https://github.com/triton-inference-server/onnxruntime_backend/blob/main/tools/gen_ort_dockerfile.py

Same build structure is found in other backends.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Docker ubunbu container , can't edit the source.list, no editor ...
Just installed a docker Ubuntu container. All the repositories in the sources list are commented (#) and so I neither can update nor...
Read more >
Best practices for writing Dockerfiles - Docker Documentation
Best practices for writing Dockerfiles. This document covers recommended best practices and methods for building efficient images.
Read more >
How do I remove a malformed line from my sources.list?
To do this, run this command (press Ctrl + Alt + T to open a Terminal): sudo -H gedit /etc/apt/sources.list · Save the...
Read more >
apt-add-repository: command not found error in Dockerfile
Now when I try to build the Dockerfile, like so: docker build -t gautam/pgrouted:v1 . The Dockerfile runs and then I get the...
Read more >
SourcesList - Debian Wiki
The main Apt sources configuration file is at /etc/apt/sources.list. You can edit this files (as root) using your favorite text editor.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found