如何在Ubuntu 14上解决“而不是调用init脚本…”
我正在使用Ubuntu 14的Docker容器。
$ cat /etc/lsb-release # this is in the container DISTRIB_ID=Ubuntu DISTRIB_RELEASE=14.04 DISTRIB_CODENAME=trusty DISTRIB_DESCRIPTION="Ubuntu 14.04.5 LTS"
当我在容器中键入service cron start
时,出现以下错误。 我认为下面的错误并不会因为我使用/etc/init.d/cron start
时显示错误而导致错误。
$ service cron start Rather than invoking init scripts through /etc/init.d, use the service(8) utility, eg service cron start Since the script you are attempting to invoke has been converted to an Upstart job, you may also use the start(8) utility, eg start cron
当我在容器中input/etc/init.d/cron start
时。 service cron start
显示同样的错误
你能告诉我如何解决这个错误,以及如何在Docker容器中启动cron
吗?
要运行cron守护进程,你可以简单地调用'cron':
root@89bdd8666c95:# cron root@89bdd8666c95:# ps -ef UID PID PPID C STIME TTY TIME CMD root 1 0 0 14:56 ? 00:00:00 bash root 88 1 0 15:02 ? 00:00:00 cron root 89 1 0 15:02 ? 00:00:00 ps -ef
- configurationstream浪机:Dockerfile(Dockerfile)必须位于构build上下文中
- 预创build检查错误:“找不到VBoxManage。 确保安装了VirtualBox并且VBoxManage在path“
- docker工人无头镀铬与python。 Chrome无法启动:崩溃
- Docker用户定义的networking网关超时
- Docker守护进程无法在Debian 7上使用AUFS运行
- 由于docker-machine使用的vboxnet,Hazelcast多播不起作用
- docker的postgres映像找不到initdb。 我错过了什么?
- 集成Docker与jenkins进行持续集成
- HEALTHCHECK启动容器过程导致无效环境USERNAME