Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Portainer agent on Windows Server 1803 #2463

Closed
ipetko96 opened this issue Nov 13, 2018 · 4 comments
Closed

Portainer agent on Windows Server 1803 #2463

ipetko96 opened this issue Nov 13, 2018 · 4 comments

Comments

@ipetko96
Copy link

Description

Hello, I am trying to install a portainer agent on windows server worker node, but after I execute this command:
docker run -d --name portainer_agent --restart always --network portainer_agent_network -e AGENT_CLUSTER_ADDR=tasks.agent --mount type=npipe,source=\\.\pipe\docker_engine,target=\\.\pipe\docker_engine portainer/agent:windows1803-amd64

I always get this error:

docker : invalid argument "type=npipe" for "--mount" flag: target is required

  • CategoryInfo : NotSpecified: (invalid argumen...get is required:String) [], RemoteException
  • FullyQualifiedErrorId : NativeCommandError

Steps to reproduce the issue:

  1. Install Docker EE 18.09 on Windows Server Datacenter 1803
  2. Run command above

Technical details:

  • Portainer version: 1.19.2
  • Manager nodes Docker version: 18.03.1-ce
  • Worker nodes Docker version: 18.09.0-ee
  • Platform: Windows Server Datacenter 1803
  • Command used to start Portainer: I deployed it as Stack via docker-compose

If you have any solution please help.

docker version

Client:
Version: 18.09.0
API version: 1.39
Go version: go1.10.3
Git commit: 33a45cd0a2
Built: unknown-buildtime
OS/Arch: windows/amd64
Experimental: false

Server:
Engine:
Version: 18.09.0
API version: 1.39 (minimum version 1.24)
Go version: go1.10.3
Git commit: 33a45cd0a2
Built: 11/07/2018 00:24:12
OS/Arch: windows/amd64
Experimental: false

docker info

Containers: 0
Running: 0
Paused: 0
Stopped: 0
Images: 0
Server Version: 18.09.0
Storage Driver: windowsfilter
Windows:
Logging Driver: json-file
Plugins:
Volume: local
Network: ics l2bridge l2tunnel nat null overlay transparent
Log: awslogs etwlogs fluentd gelf json-file local logentries splunk syslog
Swarm: inactive
Default Isolation: process
Kernel Version: 10.0 17134 (17134.1.amd64fre.rs4_release.180410-1804)
Operating System: Windows Server Datacenter Version 1803 (OS Build 17134.1)
OSType: windows
Architecture: x86_64
CPUs: 2
Total Memory: 3.999GiB
Name: srv-dockerw1
ID: QZ4J:RGFC:HJW5:PDIT:SMK4:NLVQ:CLJ2:VUWW:7IVC:Y7Z5:JHTA:RDV2
Docker Root Dir: E:\docker
Debug Mode (client): false
Debug Mode (server): false
Username:
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false

@ncresswell
Copy link
Member

ncresswell commented Nov 13, 2018 via email

@ipetko96
Copy link
Author

I have 3 manager nodes on Centos 7, portainer and portainer agents running just fine.
and 5 worker nodes on Windows Server 1803.
On worker nodes are running several applications, but I am unable to install a portainer agent on them.

The commands you provide does not work.
After the first command, the container cannot even run, always restarting.

@ncresswell
Copy link
Member

ncresswell commented Nov 13, 2018 via email

@deviantony
Copy link
Member

deviantony commented Nov 13, 2018

@uptlak I can see two problems in this issue:

  • The first one is associated to the --mount command, which is not related to Portainer but to Docker itself.
docker : invalid argument "type=npipe" for "--mount" flag: target is required

CategoryInfo : NotSpecified: (invalid argumen...get is required:String) [], RemoteException
FullyQualifiedErrorId : NativeCommandError

I'd say that this is related to your environment. Can you try to bind mount a named pipe in another container image?

  • For the second one, @ncresswell stated that there is no way run the agent on windows in a multi-node swarm which is not entirely true. Actually, there is no EASY way to run the agent on windows in a multi-node swarm mainly due to the fact that you cannot deploy it as a service or via a stack on Windows node (npipe bind mount not supported, more details: Support for Windows named pipes mounts moby/swarmkit#2691)

It can actually be deployed manually, but it's much more complicated, steps can be adapted from this tutorial: https://www.esentri.com/blog/2018/09/10/portainer-agent-deployment-on-docker-swarm-with-user-namespace-remap/

You can remove any userns related stuff.

Closing this issue for now, feel free to comment if you're missing anything.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants