Code Monkey home page Code Monkey logo

Comments (2)

lippertmarkus avatar lippertmarkus commented on May 22, 2024 2

The symlink setup is only needed for ctr to work, but isn't required for others like crictl or kubelet and that's why that isn't part of the runtime setup script. ctr paths have been changed in https://github.com/containerd/go-cni/pull/103/files#diff-df2b994645f533d6ced46ef610f95cfc41a3cecc099a873a9b47fadccb605b9b

from windows-container-networking.

kkbruce avatar kkbruce commented on May 22, 2024

Refer: containerd/nerdctl#559 (comment)
Refer: containerd/containerd#6304 (comment)

Create c:\etc\cni directory

PS C:\etc> tree
Folder PATH listing for volume Windows
Volume serial number is 94B1-2EBA
C:.
└───cni
    └───net.d

and create an SYMLINKD net.d [C:\Program Files\containerd\cni\conf]

C:\etc\cni>dir
 Volume in drive C is Windows
 Volume Serial Number is 94B1-2EBA

 Directory of C:\etc\cni

07/15/2022  02:05 AM    <DIR>          .
07/15/2022  02:05 AM    <DIR>          ..
07/15/2022  02:05 AM    <SYMLINKD>     net.d [C:\Program Files\containerd\cni\conf]

Same step create c:\opt\cni and symlinks bin [C:\Program Files\containerd\cni\bin], like:

C:\opt\cni>dir
 Volume in drive C is Windows
 Volume Serial Number is 94B1-2EBA

 Directory of C:\opt\cni

07/15/2022  02:05 AM    <DIR>          .
07/15/2022  02:05 AM    <DIR>          ..
07/15/2022  02:05 AM    <SYMLINKD>     bin [C:\Program Files\containerd\cni\bin]

run restart-service containerd and test --cni will work.

PS C:\> ctr run --cni --rm mcr.microsoft.com/windows/nanoserver:ltsc2022 test ipconfig

Windows IP Configuration


Ethernet adapter vEthernet (default-test_nat):

   Connection-specific DNS Suffix  . :
   Link-local IPv6 Address . . . . . : fe80::1c4a:2067:bd2e:b085%17
   IPv4 Address. . . . . . . . . . . : 172.20.86.46
   Subnet Mask . . . . . . . . . . . : 255.255.240.0
   Default Gateway . . . . . . . . . : 172.20.80.1

from windows-container-networking.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.