Skip to content

fix: Create mount points before rbind mount#472

Merged
kvinwang merged 1 commit into
masterfrom
fix/create-mount-points
Jan 27, 2026
Merged

fix: Create mount points before rbind mount#472
kvinwang merged 1 commit into
masterfrom
fix/create-mount-points

Conversation

@kvinwang

@kvinwang kvinwang commented Jan 27, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Create /var/lib/docker and /var/lib/containerd directories before rbind mount

Problem

When containerd.service is configured with a drop-in to start after dstack-prepare.service, the /var/lib/containerd directory may not exist yet since containerd hasn't started to create it. This causes the rbind mount to fail with:

mount: /var/lib/containerd: mount point does not exist.

Solution

Create the mount point directories explicitly in dstack-prepare.sh before attempting the rbind mount.

Test plan

  • Boot a CVM with containerd.service configured to start after dstack-prepare.service
  • Verify dstack-prepare.service completes successfully
  • Verify containerd and docker start normally

When containerd.service is configured to start after dstack-prepare.service,
the /var/lib/containerd directory may not exist yet since containerd hasn't
started to create it. This causes the rbind mount to fail.

Create the mount point directories explicitly before mounting.
@kvinwang
kvinwang merged commit 9e7acde into master Jan 27, 2026
11 checks passed
@kvinwang
kvinwang deleted the fix/create-mount-points branch July 20, 2026 14:04
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

Successfully merging this pull request may close these issues.

1 participant