Skip to content

install script throws ETXTBSY  ETXTBSY: text file is busy, copyfile '/tmp/tmp.rPcedmGtun/pnpm' -> '/home/capaj/.local/share/pnpm/pnpm' #8173

@capaj

Description

@capaj

I am having this issue for almost a year now: https://github.com/orgs/pnpm/discussions/6989
so let's open a proper issue for it.

Verify latest release

  • I verified that the issue exists in the latest pnpm release

pnpm version

v8-v9

Which area(s) of pnpm are affected? (leave empty if unsure)

CLI

Link to the code that reproduces this issue or a replay of the bug

No response

Reproduction steps

run curl -fsSL https://get.pnpm.io/install.sh | sh -

Describe the Bug

error is thrown:

==> Downloading pnpm binaries 9.1.4
 WARN  using --force I sure hope you know what you are doing
Copying pnpm CLI from /tmp/tmp.rPcedmGtun/pnpm to /home/capaj/.local/share/pnpm/pnpm
 ETXTBSY  ETXTBSY: text file is busy, copyfile '/tmp/tmp.rPcedmGtun/pnpm' -> '/home/capaj/.local/share/pnpm/pnpm'

pnpm: ETXTBSY: text file is busy, copyfile '/tmp/tmp.rPcedmGtun/pnpm' -> '/home/capaj/.local/share/pnpm/pnpm'
    at Object.copyFileSync (node:fs:2866:3)
    at Object.copyFileSync (pkg/prelude/bootstrap.js:1166:16)
    at copyCli (/snapshot/dist/pnpm.cjs)
    at Object.handler [as setup] (/snapshot/dist/pnpm.cjs)
    at /snapshot/dist/pnpm.cjs
    at async main (/snapshot/dist/pnpm.cjs)
    at async runPnpm (/snapshot/dist/pnpm.cjs)
    at async /snapshot/dist/pnpm.cjs
Install Error!

I can get around it by restarting my computer and running the command right after login, but it's annoying to do every time I need to upgrade pnpm.

Expected Behavior

pnpm installs ok

Which Node.js version are you using?

20, 21, 22

Which operating systems have you used?

  • macOS
  • Windows
  • Linux

If your OS is a Linux based, which one it is? (Include the version if relevant)

Ubuntu 22 and 24

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions