Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Default containerd version installed by install-containerd-runtime.ps1 causes container system PATH errors. #619

Closed
Labels
bugSomething isn't working triageNew and needs attention

Description

Describe the bug

Following the official documentation, the script installs containerd v1.6.6 when using default parameters.

Unfortunately (追記) this version contains a serious bug (追記ここまで) that was fixed only in v1.6.26 (and v1.7.11).

The bug causes the container system PATH to be set as Linux folders (!?), causing havoc to the most basic of applications.

Even powershell image fails (due to not finding pwsh.exe in system PATH):

PS C:\> & 'C:\Program Files\nerdctl\nerdctl.exe' run --rm -it mcr.microsoft.com/powershell:lts-nanoserver-ltsc2022
time="2025年10月31日T00:25:00-07:00" level=fatal msg="hcs::System::CreateProcess 110f1e446ebb96c96f76a7626c439279f633212fb069ed0c8b0e33cf1c488216: The system cannot find the file specified.: unknown"
PS C:\> & 'C:\Program Files\nerdctl\nerdctl.exe' run --rm -it mcr.microsoft.com/powershell:lts-nanoserver-ltsc2022 pwsh
time="2025年10月31日T00:25:02-07:00" level=fatal msg="hcs::System::CreateProcess c2a5c8c369c02944e79bffde84555f9570275568eaa24a997b72a00abe6d6262: The system cannot find the file specified.: unknown"
PS C:\> & 'C:\Program Files\nerdctl\nerdctl.exe' run --rm -it mcr.microsoft.com/powershell:lts-nanoserver-ltsc2022 "C:\Program Files\PowerShell\pwsh.exe"
PowerShell 7.2.19
Copyright (c) Microsoft Corporation.
https://aka.ms/powershell
Type 'help' to get help.
PS C:\Windows\System32> $env:PATH
Error reading or writing history file 'Microsoft\Windows\PowerShell\PSReadLine\ConsoleHost_history.txt': Access to the path 'C:\Windows\system32\Microsoft\Windows\PowerShell\PSReadLine' is denied.
ưmC:\Program Files\PowerShell;/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

To Reproduce

Steps to reproduce the behavior:

  • On a Hyper-V VM, with a clean Windows Server 2022 install
  • Run the installer script with no additional command line parameters:
    Invoke-WebRequest -UseBasicParsing "https://raw.githubusercontent.com/microsoft/Windows-Containers/Main/helpful_tools/Install-ContainerdRuntime/install-containerd-runtime.ps1" -o install-containerd-runtime.ps1
    .\install-containerd-runtime.ps1
  • Start any Windows container image
    & 'C:\Program Files\nerdctl\nerdctl.exe' run --rm -it mcr.microsoft.com/windows/nanoserver:ltsc2022
    # or
    & 'C:\Program Files\nerdctl\nerdctl.exe' run --rm -it mcr.microsoft.com/windows/servercore:ltsc2022
  • Check the container system PATH:
    Microsoft Windows [Version 10.0.20348.4297]
    (c) Microsoft Corporation. All rights reserved.
    C:\Windows\system32>echo %PATH%
    /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
    

Expected behavior

Containers system PATH set as expected for a Windows environment.

Configuration:

  • Edition: Windows Server 2022
  • Base Image being used: Windows Server Core / Windows Nano Core
  • Container engine: containerd
  • Container Engine version: 1.6.6
PS C:\> Get-ComputerInfo -Property OSName, OSVersion, WindowsProductName, WindowsVersion
OsName OsVersion WindowsProductName WindowsVersion
------ --------- ------------------ --------------
Microsoft Windows Server 2022 Standard 10.0.20348 Windows Server 2022 Standard 2009
PS C:\> & 'C:\Program Files\containerd\bin\ctr.exe' version
Client:
 Version: v1.6.6
 Revision: 10c12954828e7c7c9b6e0ea9b0c02b01407d3ae1
 Go version: go1.17.11
Server:
 Version: v1.6.6
 Revision: 10c12954828e7c7c9b6e0ea9b0c02b01407d3ae1
 UUID: 4195684b-ac60-4d65-bf98-bf8b57fb62d0
PS C:\> & 'C:\Program Files\nerdctl\nerdctl.exe' version
Client:
 Version: v0.21.0
 OS/Arch: windows/amd64
 Git commit: 9ddf5226eabcbb7b4b43987f3b0f8d53d86d3bca
Server:
 containerd:
 Version: v1.6.6
 GitCommit: 10c12954828e7c7c9b6e0ea9b0c02b01407d3ae1

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working triageNew and needs attention

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /