Skip to content
This repository was archived by the owner on Feb 1, 2021. It is now read-only.

set MemorySwappiness default value #1425

Conversation

jimmyxian
Copy link
Contributor

Fix this issue: #1411
Signed-off-by: Xian Chaobo [email protected]

@jimmyxian
Copy link
Contributor Author

ping @fsfshijm @AzenYao
Can you try this and see if it works. Thanks

@jimmyxian jimmyxian force-pushed the set-memory-wappiness-default-value branch 2 times, most recently from 584cba3 to 56b7e28 Compare November 17, 2015 11:12
@fsfshijm
Copy link

@jimmyxian, Seems it works well!

-sh-4.2$ ps -ef | grep swarm
jmshi     9427     1  0 03:36 ?        00:00:00 swarm join --addr=192.168.0.233:2375 etcd://192.168.0.141:4001
jmshi     9439     1  0 03:36 ?        00:00:00 swarm join --addr=192.168.0.17:2375 etcd://192.168.0.141:4001
jmshi     9450     1  0 03:36 ?        00:00:02 swarm manage -H 0.0.0.0:2380 etcd://192.168.0.141:4001
jmshi    10466  9473  0 04:23 pts/0    00:00:00 grep --color=auto swarm
-sh-4.2$ export | grep DOCKER_HOST
export DOCKER_HOST="tcp://0.0.0.0:2380"
-sh-4.2$ swarm -v
swarm version 1.0.0 (HEAD)
-sh-4.2$ docker-compose up -d
Creating web
Creating mongo
-sh-4.2$ docker ps
CONTAINER ID        IMAGE                         COMMAND                  CREATED             STATUS              PORTS                          NAMES
678b77255062        mongo                         "/entrypoint.sh mongo"   3 seconds ago       Up 3 seconds        27017/tcp                      EP003/mongo
88d14f3e4264        bfirsh/compose-mongodb-demo   "/bin/sh -c 'python a"   6 seconds ago       Up 3 seconds        192.168.0.233:1234->5000/tcp   PEKdev233.dev.fwmrm.net/web
-sh-4.2$

Thanks very much!

@jimmyxian
Copy link
Contributor Author

ping @docker/swarm-maintainers

@abronan
Copy link
Contributor

abronan commented Nov 18, 2015

LGTM

@abronan
Copy link
Contributor

abronan commented Nov 20, 2015

ping @vieux

@vieux
Copy link
Contributor

vieux commented Nov 24, 2015

@jimmyxian shouldn't this be fixed in compose ?

@jimmyxian
Copy link
Contributor Author

@vieux I think should fix in both compose \ docker \ swarm.
If send create json request without MemorySwappiness to docker / swarm, we should set this -1 in docker / swarm.
In compose, maybe also need to set this -1.

@johnjelinek
Copy link

when will this get merged?

@jimmyxian jimmyxian force-pushed the set-memory-wappiness-default-value branch from 56b7e28 to 4523d6c Compare December 3, 2015 06:27
@jimmyxian
Copy link
Contributor Author

@johnjelinek Can you try this and see if it work. Thanks.

@jimmyxian jimmyxian force-pushed the set-memory-wappiness-default-value branch 2 times, most recently from de714dc to 47ceeb4 Compare December 3, 2015 09:05
@jimmyxian jimmyxian added this to the 1.0.1 milestone Dec 3, 2015
@johnjelinek
Copy link

@jimmyxian: I don't think I can test this until there's a container for it. I'm not set up to build golang apps yet in my cluster.

@johnjelinek
Copy link

I must've done something wrong. I did a $GOPATH/bin/godep go install . to build a new swarm bin (this is after I checked out this branch). Then I stopped all my swarm-agent containers and manually ran swarm in all my cluster servers. When I do docker version, it says swarm is pointing to this commit hash: jimmyxian@087e245. I still get the same error message about swappiness. Any ideas how I can build just your branch right?

@johnjelinek
Copy link

@jimmyxian: I also tried merging your branch into master in my local repo of swarm:master. Same problem. What should I do to ensure that it's tracking an updated commit hash?

@abronan
Copy link
Contributor

abronan commented Dec 3, 2015

@johnjelinek Did you restart your Swarm Manager too with the new Image/binary including the commit? From your comment I read that you tried only with Swarm Agents. You mostly need to restart the Swarm Manager. So restarting it (hopefully) should do the trick :)

@johnjelinek
Copy link

Hrmm ... I'll give that a shot. I have the swarm manager running in HA mode with consul. Not sure if that makes a difference.


Sent from Mailbox

On Thu, Dec 3, 2015 at 5:25 PM, Alexandre Beslic [email protected]
wrote:

@johnjelinek Did you restart your Swarm Manager too with the new Image/binary including the commit? From your comment I read that you tried only with Swarm Agents. You mostly need to restart the Swarm Manager. So restarting it (hopefully) should do the trick :)

Reply to this email directly or view it on GitHub:
#1425 (comment)

@johnjelinek
Copy link

@abronan: that was it :) all fixed now. :shipit:

@abronan
Copy link
Contributor

abronan commented Dec 3, 2015

@johnjelinek Woop! Thanks a lot for testing and confirming :)

Let's include the fix asap. PTAL @docker/swarm-maintainers

@jimmyxian
Copy link
Contributor Author

@johnjelinek Thanks for testing. :)

@jimmyxian jimmyxian force-pushed the set-memory-wappiness-default-value branch from 47ceeb4 to 63498b1 Compare December 4, 2015 01:26
@johnjelinek
Copy link

@jimmyxian / @abronan: do you have an ETA on when this might get merged/published? I feel nervous running all these processes outside of docker containers.

@aluzzardi
Copy link
Contributor

LGTM

aluzzardi added a commit that referenced this pull request Dec 4, 2015
…value

set MemorySwappiness default value
@aluzzardi aluzzardi merged commit 9386efd into docker-archive:master Dec 4, 2015
@aluzzardi
Copy link
Contributor

@johnjelinek Hey, you can run the master swarm image by doing a docker run of dockerswarm/swarm:master instead of swarm.

This will be published in 1.0.1 sometime next week.

@jimmyxian jimmyxian deleted the set-memory-wappiness-default-value branch December 4, 2015 03:39
@johnjelinek
Copy link

@aluzzardi: sweet, thanks!

@thaJeztah
Copy link
Member

If I understand correctly, this fixes moby/moby#17879 ?

@johnjelinek
Copy link

Yes, that's correct.

On Sun, Dec 6, 2015 at 4:39 AM, Sebastiaan van Stijn <
[email protected]> wrote:

If I understand correctly, this fixes moby/moby#17879
moby/moby#17879 ?


Reply to this email directly or view it on GitHub
#1425 (comment).

ChristianKniep pushed a commit to ChristianKniep/swarm that referenced this pull request Jul 27, 2017
…iness-default-value

set MemorySwappiness default value
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants