[root@localhost core]# systemctl daemon-reload
[root@localhost core]# systemctl start core-daemon.service
---------------------------------------------------------------------------
[root@localhost core]# core-gui
----------------------
/root/.core/configs/m-MPE-manet.imn
----------------------
Under the Session Menu, the Options... dialog has an option to set a control network prefix.
This can be set to a network prefix such as 172.16.0.0/24. A bridge will be created on the host machine having the last address in the prefix range (e.g. 172.16.0.254), and each node will have an extra ctrl0 control interface configured with an address corresponding to its node number (e.g. 172.16.0.3 for n3.)
----------------------
[root@localhost doc]# ifconfig
enp13s0: flags=4163 mtu 1500
inet 192.168.0.100 netmask 255.255.255.0 broadcast 192.168.0.255
inet6 fe80::3e97:eff:fef0:b5bb prefixlen 64 scopeid 0x20
ether 3c:97:0e:f0:b5:bb txqueuelen 1000 (Ethernet)
RX packets 424786 bytes 474479916 (452.4 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 402854 bytes 46953257 (44.7 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
^^^^^^宿主机测试
docker images
docker search centos
docker pull centos
docker images
docker tag 2933d50b9f77 docker.io/centos:core
docker run centos echo "hello world!" ^^^^^^至此,宿主机 OK
docker run --rm -it centos /bin/bash
docker run --rm -it -d centos /bin/bash
docker run --rm centos echo "hello world!"
docker run centos echo "hello world!"
docker run --cap-add=NET_ADMIN --cap-add=SYS_ADMIN centos echo "hello world!"
docker run --privileged -ti -v /sys/fs/cgroup:/sys/fs/cgroup centos echo "hello world!"
docker run --privileged -ti -e "container=docker" -v /sys/fs/cgroup:/sys/fs/cgroup centos /usr/sbin/init
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^problem & resolve
[root@localhost ~]# systemctl start docker.service
Job for docker.service failed because the control process exited with error code. See "systemctl status docker.service" and "journalctl -xe" for details.
---------------------------------------------------------------------------
Created the overlay network as:
docker network create -d overlay --subnet="192.168.252.0/16" --gateway="192.168.252.1" hcf
---------------------------------------------------------------------------
Ran the container as:
docker run -d --restart=always --net=hcf -p=8000:80 --name=testhttp -t nginx
---------------------------------------------------------------------------
一直用CentOS 6 习惯了,一下没适应过来。防火墙配置后执行service iptables save 出现"Failed to restart iptables.service: Unit iptables.service failed to load: No such file or directory."错误,在CentOS 7或RHEL 7或Fedora中防火墙由firewalld来管理,当然你可以还原传统的管理方式。或则使用新的命令进行管理。
假如采用传统请执行一下命令:
systemctl stop firewalld
systemctl mask firewalld
并且安装iptables-services:
yum install iptables-services
设置开机启动:
systemctl enable iptables
systemctl [stop|start|restart] iptables
#or
service iptables [stop|start|restart]
service iptables save
#or
/usr/libexec/iptables/iptables.init save
---------------------------------------------------------------------------
systemctl stop firewalld
systemctl start firewalld
systemctl restart firewalld
[root@localhost core]#
ip link add gt0 type gretap remote 192.168.0.100 local 192.168.0.111 key 1
ip addr add 10.0.0.2/24 dev gt0
ip link set dev gt0 up
ip link set dev gt0 down
route add default dev eth0
route add default gw 192.168.1.1
route del default gw 10.108.160.1
brctl show
ifconfig b.2.ac down
brctl delbr b.2.ac
//Docker daemon supports for several different image layer storage drivers: aufs, devicemapper, btrfs, zfs and overlay
// OK OK OK
[root@n6 n6.conf]# docker daemon -D -s overlay &
--------------------------------
problem:
[root@localhost ~]# systemctl restart docker
Job for docker.service failed because the control process exited with error code. See "systemctl status docker.service" and "journalctl -xe" for details.
[root@localhost ~]# docker daemon
WARN[0000] Usage of loopback devices is strongly discouraged for production use. Please use `--storage-opt dm.thinpooldev` or use `man docker` to refer to dm.thinpooldev section.
FATA[0000] Error starting daemon: error initializing graphdriver: "/var/lib/docker" contains other graphdrivers: overlay; Please cleanup or explicitly choose storage driver (-s )
resolve:
# rm /var/lib/docker/overlay/ -rf
--------------------------------
Docker not starting “ could not delete the default bridge network: network bridge has active endpoints”"
Run
sudo mv /var/lib/docker/network/files/ /tmp/dn-bak
to reset your networks. Then restart docker (sudo systemctl restart docker or sudo service docker restart depending on your OS). If everything works again you can delete the dn-bak directory.
On arch linux I needed
ip link set down docker0 instead of ifconfig docker0 down and
systemctl restart docker instead of service docker start.
To delete all images, I did
docker rmi $(docker images -q)
++++++++++++++++
docker tag c8a648134623 docker.io/centos:core
/etc/sysconfig/docker-storage这个配置文件
DOCKER_STORAGE_OPTIONS="--storage-opt dm.no_warn_on_loop_devices=true"
or
DOCKER_STORAGE_OPTIONS="-s overlay"