Here is my test environment:
key |
value |
OS |
CentOS 7.2.1511 (Core) |
Kernel |
3.10.0-327.3.1.el7.x86_64 |
Docker |
1.13.0, build 49bf474 |
Storage Driver |
overlay |
I think the root cause may the storage driver, and I change the driver to devicemapper, these problems are gone. Maybe related to moby/moby#12327 , consider update kernel to resolve it.
Only these 4 images I tested, others are not tested.
Time is 2017-02-07
Image tag is latest, 55 MB, 17 days ago
REPOSITORY TAG IMAGE ID CREATED SIZE
zabbix/zabbix-web-apache-mysql latest 8b6a65b030b6 2 weeks ago 178 MB
zabbix/zabbix-web-nginx-mysql latest 863b950a6ade 2 weeks ago 176 MB
zabbix/zabbix-web-apache-mysql ubuntu-latest 12462fde1eec 2 weeks ago 336 MB
zabbix/zabbix-web-nginx-mysql ubuntu-latest 68ce36486a28 2 weeks ago 336 MB
- zabbix web alpine apache mysql could not create pid file to directory
/run/apache2/
because this is no directory in /run
.
docker run --name zabbix-web-apache-mysql --link zabbix-db-mysql --link zabbix-server -e DB_SERVER_HOST="zabbix-db-mysql" -e MYSQL_USER="zabbix" -e MYSQL_PASSWORD="zabbix" -e ZBX_SERVER_HOST="zabbix-server" -e TZ="Asia/Shanghai" -d zabbix/zabbix-web-apache-mysql:latest
docker logs zabbix-web-apache-mysql
[Tue Feb 07 07:32:49.252624 2017] [core:error] [pid 30] (2)No such file or directory: AH00099: could not create /run/apache2/httpd.pid
[Tue Feb 07 07:32:49.252653 2017] [core:error] [pid 30] AH00100: httpd: could not log pid to file /run/apache2/httpd.pid
2017-02-07 07:32:49,253 INFO exited: apache2 (exit status 1; not expected)
2017-02-07 07:32:49,253 INFO exited: apache2 (exit status 1; not expected)
2017-02-07 07:32:50,255 INFO spawned: 'apache2' with pid 31
2017-02-07 07:32:50,255 INFO spawned: 'apache2' with pid 31
AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using 172.17.0.5. Set the 'ServerName' directive globally to suppress this message
AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using 172.17.0.5. Set the 'ServerName' directive globally to suppress this message
[Tue Feb 07 07:32:50.283722 2017] [core:error] [pid 31] (2)No such file or directory: AH00099: could not create /run/apache2/httpd.pid
[Tue Feb 07 07:32:50.283746 2017] [core:error] [pid 31] AH00100: httpd: could not log pid to file /run/apache2/httpd.pid
2017-02-07 07:32:50,284 INFO exited: apache2 (exit status 1; not expected)
2017-02-07 07:32:50,284 INFO exited: apache2 (exit status 1; not expected)
# docker exec -it zabbix-web-apache-mysql bash
bash-4.3# ls /var/run/
supervisor.sock supervisord.pid
bash-4.3# ls /run
bash-4.3#
- zabbix web apache mysql ubuntu
Default shows "It works", and access via hostname does not work. I create a soft link in the container by using ln -s /usr/share/zabbix/ /var/www/zabbix
, so I can accress zabbix web by http://zabbix/zabbix
docker run -p 80:80 --name zabbix-web-apache-mysql-ubuntu --link zabbix-server --link zabbix-db-mysql -e DB_SERVER_HOST="zabbix-db-mysql" -e MYSQL_USER="zabbix" -e MYSQL_PASSWORD="zabbix" -e ZBX_SERVER_HOST="zabbix-server" -e TZ="Asia/Shanghai" -d zabbix/zabbix-web-apache-mysql:ubuntu-latest
-
zabbix web nginx mysql ubuntu can use out of box
-
zabbix web nginx mysql alpine
Something wrong with /etc/nginx/conf.d/default.conf
docker run -p 80:80 --name zabbix-web-apache-nginx-alpine --link zabbix-server --link zabbix-db-mysql -e DB_SERVER_HOST="zabbix-db-mysql" -e MYSQL_USER="zabbix" -e MYSQL_PASSWORD="zabbix" -e ZBX_SERVER_HOST="zabbix-server" -e TZ="Asia/Shanghai" -d zabbix/zabbix-web-nginx-mysql:latest
docker logs zabbix-web-nginx-mysql-alpine
2017/02/13 10:22:55 [emerg] 34#34: open() "/etc/nginx/conf.d/default.conf" failed (2: No such file or directory) in /etc/nginx/nginx.conf:62
nginx: [emerg] open() "/etc/nginx/conf.d/default.conf" failed (2: No such file or directory) in /etc/nginx/nginx.conf:62
2017-02-13 10:22:55,581 INFO exited: nginx (exit status 1; not expected)
2017-02-13 10:22:55,581 INFO exited: nginx (exit status 1; not expected)
2017-02-13 10:22:56,582 INFO gave up: nginx entered FATAL state, too many start retries too quickly
2017-02-13 10:22:56,582 INFO gave up: nginx entered FATAL state, too many start retries too quickly
docker exec -it zabbix-web-apache-nginx-alpine bash
bash-4.3# ls -al /etc/nginx/conf.d/
ls: /etc/nginx/conf.d/default.conf: No such file or directory
total 0
drwxr-xr-x 1 root root 42 Feb 13 10:22 .
drwxr-xr-x 1 root root 19 Feb 7 01:42 ..
lrwxrwxrwx 1 root root 22 Feb 13 10:22 nginx.conf -> /etc/zabbix/nginx.conf
bash-4.3# rm /etc/nginx/conf.d/default.conf
rm: can't remove '/etc/nginx/conf.d/default.conf': No such file or directory
These are my docker info
output
Containers: 6
Running: 5
Paused: 0
Stopped: 1
Images: 32
Server Version: 1.13.0
Storage Driver: overlay
Backing Filesystem: xfs
Supports d_type: false
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host macvlan null overlay
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 03e5862ec0d8d3b3f750e19fca3ee367e13c090e
runc version: 2f7393a47307a16f8cee44a37b262e8b81021e3e
init version: 949e6fa
Security Options:
seccomp
Profile: default
Kernel Version: 3.10.0-327.3.1.el7.x86_64
Operating System: CentOS Linux 7 (Core)
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 3.702 GiB
Name: docker
ID: xxx
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Registry: https://index.docker.io/v1/
WARNING: bridge-nf-call-iptables is disabled
WARNING: bridge-nf-call-ip6tables is disabled
Experimental: false
Insecure Registries:
127.0.0.0/8
Registry Mirrors:
http://xxx
Live Restore Enabled: false