"install -D" race condition
| Affects | Status | Importance | Assigned to | Milestone | |
|---|---|---|---|---|---|
| rust-coreutils |
New
|
Unknown
|
|||
| coreutils-from (Ubuntu) |
Won't Fix
|
Undecided
|
Unassigned | ||
| rust-coreutils (Ubuntu) |
Triaged
|
High
|
Unassigned | ||
Bug Description
When "install -D dir" is invoked from a parallel make session, there is a race condition where one thread successfully creates "dir"; when the remaining threads get mkdir("
This race does not exist in GNU coreutils, where EEXIST does not trigger an error.
One example where this is a problem is during kernel builds:
$ make -j12 bindeb-pkg
...
install: cannot create directory 'debian/
make[6]: *** [scripts/
make[6]: *** Waiting for unfinished jobs....
make[5]: *** [Makefile:1617: dtbs_install] Error 2
make[4]: *** [Makefile:2272: run-command] Error 2
make[3]: *** [debian/rules:67: binary-image] Error 2
ProblemType: Bug
DistroRelease: Ubuntu 26.04
Package: coreutils-
Uname: Linux 7.1.0-rc3+ aarch64
ApportVersion: 2.34.0-0ubuntu2
Architecture: arm64
CasperMD5CheckR
CurrentDesktop: ubuntu:GNOME
Date: Wed May 13 18:15:07 2026
InstallationDate: Installed on 2026-04-24 (19 days ago)
InstallationMedia: Ubuntu 26.04 "Resolute Raccoon" - Release arm64 (20260423.1)
PackageArchitec
ProcEnviron:
LANG=en_US.UTF-8
PATH=(custom, no user)
SHELL=
TERM=xterm-ghostty
XDG_RUNTIME_
SourcePackage: coreutils-from
UpgradeStatus: No upgrade log present (probably fresh install)
| Changed in coreutils-from (Ubuntu): | |
| status: | Confirmed → Triaged |
| importance: | Undecided → High |
| status: | Triaged → Won't Fix |
| Changed in rust-coreutils (Ubuntu): | |
| status: | New → Triaged |
| importance: | Undecided → High |
| Changed in coreutils-from (Ubuntu): | |
| importance: | High → Undecided |
| Changed in rust-coreutils: | |
| status: | Unknown → New |
```console
$ install -D dir
install: missing destination file operand after 'dir'
Try 'install --help' for more information.
```
Your command is incomplete. Please minimize the Makefile into a Bash script so that other people can test this.