Docker Error - Unknown or Invalid Runtime Name: Nvidia

Let’s take a look at the Visual SLAM package above in the Isaac Sim environment. This package works in ROS2 environment.

  1. Edit /etc/docker/daemon.json:
    I edited /etc/docker/daemon.json as follows:

    "runtimes": {
        "nvidia": {
            "path": "nvidia-container-runtime",
            "runtimeArgs": []
    "default-runtime": "nvidia"

    I added the 7th line (and the comma at the end of line 6) as it was not included in the original configuration.

  2. Apply the Changes:
    I applied the above changes with the following commands:

    $ sudo systemctl daemon-reload
    $ sudo systemctl restart docker
  3. Obtain Docker Scripts from Git:
    I performed the following steps to obtain Docker scripts. Here, I created a directory named docker in the home directory:

    $ cd ~
    $ mkdir docker
    $ cd docker
    $ git clone
  4. Prepare a Directory for Docker Container:
    I created the following directory for the Docker container (this is not mandatory):

    $ mkdir -p ~/workspaces/isaac_ros-dev
  5. Start the Docker Container:
    To start the Docker container, I moved to ~/docker/isaac_ros_common/ and entered the following command:

    $ scripts/ ~/workspaces/isaac_ros-dev/

I am encountering a runtime error with Docker when trying to use the Nvidia runtime. This issue arises despite having a successful output with an initial Docker command and making subsequent edits to the Docker configuration.

Steps to Reproduce

  1. Run the following Docker command which executes successfully:

    sudo docker run --rm --runtime=nvidia --gpus all ubuntu nvidia-smi
  2. Edit /etc/docker/daemon.json as follows:

        "runtimes": {
            "nvidia": {
                "path": "nvidia-container-runtime",
                "runtimeArgs": []
        "default-runtime": "nvidia"
  3. After making these changes, attempt to execute a script with the command:

    scripts/ ~/workspaces/isaac_ros-dev/

    This results in the following error:

    docker: Error response from daemon: unknown or invalid runtime name: nvidia.

Expected Behavior

The Docker container should recognize the Nvidia runtime without errors, especially since the initial command runs without issues.

Actual Behavior

The system throws an error stating “unknown or invalid runtime name: nvidia” when trying to run a script that utilizes Docker with the Nvidia runtime.


  • Docker version: Docker version 24.0.7, build afdd53b
  • Operating System:ubuntu22.04
  • Any other relevant environmental details

Attempts to Resolve

  • Verified that the initial Docker command runs successfully.
  • Checked the syntax and paths in the daemon.json file.
  • Searched for similar issues in forums and GitHub Issues.

Request for Help

Could anyone provide insights or suggest potential solutions to resolve this runtime error? Any advice or guidance would be greatly appreciated.

1 Like