请教一下,docker info提示WARNING: No swap limit support,的意思?

请教一下各位,我在虚拟机(ubuntu15.04,64bit,内核4.0)装完docker后,用docker info ,显示:WARNING: No swap limit support,这句话有什么特别的意思吗?如果是我的虚拟机配置问题,那又需要作哪些改动呢。
root@localhost:~# docker info
Containers: 0
Images: 0
Storage Driver: devicemapper
Pool Name: docker-252:0-657575-pool
Pool Blocksize: 65.54 kB
Backing Filesystem: extfs
Data file: /dev/loop0
Metadata file: /dev/loop1
Data Space Used: 305.7 MB
Data Space Total: 107.4 GB
Data Space Available: 14.27 GB
Metadata Space Used: 729.1 kB
Metadata Space Total: 2.147 GB
Metadata Space Available: 2.147 GB
Udev Sync Supported: false
Data loop file: /var/lib/docker/devicemapper/devicemapper/data
Metadata loop file: /var/lib/docker/devicemapper/devicemapper/metadata
Library Version: 1.02.82-git (2013-10-04)
Execution Driver: native-0.2
Kernel Version: 4.0.0-040000-generic
Operating System: Ubuntu 15.04
CPUs: 4
Total Memory: 1.937 GiB
Name: localhost
ID: VNWE:SZ46:IZGD:FX26:NRKQ:CU72:GE2E:OVYD:52D7:UA5P:LQ46:WFBB
WARNING: No swap limit support

5回答

feitatfeitat  系统工程师 , ss
回复 2# dl528888     谢谢您的回复显示全部
回复 2# dl528888


    谢谢您的回复收起
 2015-05-12
浏览13475
feitatfeitat  系统工程师 , ss
回复 4# 胶东牛国磊 谢谢您的回复,很受启发显示全部
回复 4# 胶东牛国磊

谢谢您的回复,很受启发收起
 2015-05-12
浏览13437
胶东牛国磊胶东牛国磊  系统架构师 , 百度游戏
feitat赞同了此回答
回复 3# feitat     根据你的错误提示,只是cgroups中的swap account没有开启。这个功能应该是用在 `docker run -m=1524288 -it ubuntu /bin/bash` 类似的命令,用来限制一个docker容器的内存使用上限,所以这里只是WARNING,不影响使用。...显示全部
回复 3# feitat


    根据你的错误提示,只是cgroups中的swap account没有开启。这个功能应该是用在 `docker run -m=1524288 -it ubuntu /bin/bash` 类似的命令,用来限制一个docker容器的内存使用上限,所以这里只是WARNING,不影响使用。收起
 2015-05-12
浏览14436
feitatfeitat  系统工程师 , ss
dockerone的Lemon_Tree网友给出了答案,在docker官网上:https://docs.docker.com/installa ... and-swap-accounting说是需要开启memory and swap accounting ,不知道这两个特性的意义在哪里。请高手指点另外命令里有cgroup_enable这一项,这难道是说内核虽然支持cgroup,但默认...显示全部
dockerone的Lemon_Tree网友给出了答案,在docker官网上:
https://docs.docker.com/installa ... and-swap-accounting
说是需要开启memory and swap accounting ,不知道这两个特性的意义在哪里。请高手指点
另外命令里有cgroup_enable这一项,这难道是说内核虽然支持cgroup,但默认没有开启吗?收起
 2015-05-12
浏览13498
邓磊邓磊  系统运维工程师 , 游戏公司
feitat赞同了此回答
这个默认官方给予解决方法了,地址是https://docs.docker.com/installation/ubuntulinux/When users run Docker, they may see these messages when working with an image: WARNING: Your kernel does not support cgroup swap limit. WARNING: Your kernel does not suppo...显示全部
这个默认官方给予解决方法了,地址是https://docs.docker.com/installation/ubuntulinux/
When users run Docker, they may see these messages when working with an image:

WARNING: Your kernel does not support cgroup swap limit. WARNING: Your
kernel does not support swap limit capabilities. Limitation discarded.
To prevent these messages, enable memory and swap accounting on your system. To enable these on system using GNU GRUB (GNU GRand Unified Bootloader), do the following.

Log into Ubuntu as a user with sudo privileges.

Edit the /etc/default/grub file.

Set the GRUB_CMDLINE_LINUX value as follows:

GRUB_CMDLINE_LINUX="cgroup_enable=memory swapaccount=1"
Save and close the file.

Update GRUB.

$ sudo update-grub
Reboot your system.
收起
 2015-05-12
浏览13558

提问者

feitat系统工程师, ss

问题状态

  • 发布时间:2015-05-12
  • 关注会员:1 人
  • 问题浏览:19353
  • 最近回答:2015-05-12
  • 关于TWT  使用指南  社区专家合作  厂商入驻社区  企业招聘  投诉建议  版权与免责声明  联系我们
    © 2019  talkwithtrend — talk with trend,talk with technologist 京ICP备09031017号-30