How to change node availability in docker swarm

0 votes

Hi Guys,

I have added one master node in the Docker swarm. I want to drain a manager node so that it only performs swarm management tasks and is unavailable for task assignment. How to do that?

Dec 28, 2020 in Docker by akhtar
• 38,260 points
3,523 views

1 answer to this question.

0 votes

Hi@akhtar,

You can change the node availability according to your need. You can perform the below operations.

  • drain a manager node so that only performs swarm management tasks and is unavailable for task assignment.

  • drain a node so you can take it down for maintenance.

  • pause a node so it can’t receive new tasks.

  • restore unavailable or paused nodes available status.

For example, to change a manager node to Drain availability.

$ docker node update --availability drain node-1
node-1
answered Dec 28, 2020 by MD
• 95,460 points

Related Questions In Docker

0 votes
1 answer

How to change hosts in Docker for Windows in daemon.json?

you cannot specify options both as a ...READ MORE

answered Oct 16, 2018 in Docker by Tyrion anex
• 8,700 points
4,598 views
0 votes
1 answer

How to add one worker node to the Docker swarm?

Hi@akhtar, You will get one token when you ...READ MORE

answered Dec 24, 2020 in Docker by MD
• 95,460 points
1,156 views
0 votes
1 answer

How to remove a worker node from the docker swarm cluster?

Hi@akhtar, To remove a worker node from the ...READ MORE

answered Dec 24, 2020 in Docker by MD
• 95,460 points
5,511 views
0 votes
1 answer

How to create a service in Docker swarm?

Hi@akhtar, To create a service in Docker swarm, ...READ MORE

answered Dec 24, 2020 in Docker by MD
• 95,460 points
544 views
+2 votes
1 answer
+5 votes
7 answers

Docker swarm vs kubernetes

Swarm is easy handling while kn8 is ...READ MORE

answered Aug 27, 2018 in Docker by Mahesh Ajmeria
3,793 views
0 votes
1 answer

How to get the hostname of the manager node in the Docker swarm?

Hi@akhtar, You can find the manager hostname using ...READ MORE

answered Dec 24, 2020 in Docker by MD
• 95,460 points
4,133 views
0 votes
1 answer

How to create a Docker swarm in Linux system?

Hi@akhtar, You need to initialize one node with ...READ MORE

answered Dec 24, 2020 in Docker by MD
• 95,460 points
593 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP