Skip to content

Commit

Permalink
added additional logic to create /dev/char directory
Browse files Browse the repository at this point in the history
(cherry picked from commit a8f55f3)
  • Loading branch information
ibrokethecloud authored and bk201 committed Jun 17, 2024
1 parent 5fcd62f commit 40108f6
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions nvidia-driver-toolkit/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,18 @@ then
rm /tmp/ready
fi

# fix from: https://gitlab.com/nvidia/container-images/driver/-/commit/94324dc6dbaff191b72a734b7734710110d82198
# Create /dev/char directory if it doesn't exist inside the container.
# Without this directory, nvidia-vgpu-mgr will fail to create symlinks
# under /dev/char for new devices nodes.
create_dev_char_directory() {
if [ ! -d "/dev/char" ]; then
echo "Creating '/dev/char' directory"
mkdir -p /dev/char
fi
}


if [ -n "${DRIVER_LOCATION}" ]
then
echo "Installing nvidia driver from ${DRIVER_LOCATION}"
Expand All @@ -18,6 +30,7 @@ else
fi

echo "running nvidia vgpud"
create_dev_char_directory
/usr/bin/nvidia-vgpud
/usr/bin/nvidia-vgpu-mgr

Expand Down

0 comments on commit 40108f6

Please sign in to comment.