https://blog.csdn.net/king_gun/article/details/78423115

【问题】

从docker hub上拉取到则镜像centos:6.7在执行ping命令是报错:


  1. [root@dcd9947346b3 /]# ping
  2. bash: ping: command not found

百度上搜索,查到linux下安装ping命令的方法为:

apt-get install inetutils-ping

但是docker镜像中不存在apt-get指令,使用yum install inetutils-ping找不到对应的包 【解决】

yum 安装ping命令如下:

yum install -y iputils

docker下centos安装ping命令的更多相关文章

  1. centos安装tree命令

    centos安装tree命令 sudo yum -y install tree windows安装tree命令 我的另一篇

  2. CentOS 安装tab命令补全

    CentOS 安装tab命令补全 1. 安装epel 源 yum -y install epel-release 2. 加快yum速度 yum -y install yum-plugin-fastes ...

  3. CentOS 安装 semanage 命令

    CentOS 安装 semanage 命令 在服务器上运行: [root@ca1 ~]# yum install policycoreutils-python vim /etc/selinux/con ...

  4. linux下安装 ping 命令

    使用docker仓库下载的ubuntu 14.04 镜像.里面精简的连 ping 命令都没有.google 百度都搜索不到ping 命令在哪个包里. 努力找了半天,在一篇文章的字里行间发现了 ping ...

  5. Docker Ubuntu中安装ping ifconfig命令

    Ubuntu 容器环境安装ping ifconfig 进入容器执行:ifconfig ping 没有该命令 apt-get update ###命令 ifconfig apt-get install ...

  6. CentOS执行ping命令报错 name or service not know

    在虚拟机上安装的CentOS,但是当执行ping命令的时候,提示name or service not known 解决方法如下: 1. 添加DNS服务器 vi /etc/resolv.conf 1 ...

  7. Docker Compose的安装及命令补全

    安装Compose Compose的安装有多种方式,例如通过shell安装.通过pip安装.以及将compose作为容器安装等等.本文讲解通过shell安装的方式.其他安装方式如有兴趣,可以查看Doc ...

  8. Docker Ubuntu容器安装ping(zz)

    更新apt-get的软件包信息,然后再安装 sudo docker run ubuntu apt-get update sudo docker run ubuntu apt-get install i ...

  9. docker的基本安装和命令详解

    docker的安装 yum install docker-io docker的启动 /bin/systemctl start docker.service docker查找镜像 docker sear ...

随机推荐

  1. MyBatis-Plus使用教程

    单机版 安装环境 上传压缩包到/usr/local/software/下 解压安装包,进入解压目录的bin目录下,启动命令: ./solr start -force 默认端口是8983,请求虚拟机, ...

  2. 深入浅出Node.js---Connect模块解析 。转载

    文章地址:https://blog.csdn.net/zhangyuan19880606/article/details/51509205 1 Connect模块背景 Node.js的愿望是成为一个能 ...

  3. C# to IL 2 IL Basics(IL基础)

    This chapter and the next couple of them will focus on and elicit a simple belief of ours,that if yo ...

  4. Kubernetes 知识点

    自己总结的 Kubernetes 的各模块(待补充) 各模块包含关系: namespace => node => pod => container table th:first-of ...

  5. nginx 镜像使用说明

    nginx 镜像说明 目录 说明 /etc/nginx nginx安装目录 /usr/share/nginx/html nginx网站资源存放的目录 运行nginx容器,相关命令: 命令 说明 doc ...

  6. django使用session报错:no such table: django_session

    Django版本:1.11.15 使用session的代码:request.session['key'] = value 运行后报错:no such table: django_session 解决办 ...

  7. log4j.properties配置说明学习网址

    https://blog.csdn.net/wangzhaotongalex/article/details/51308802

  8. BeanShell用法(摘抄至网络)

    说明:本文部分资料摘抄至 来源: http://www.cnblogs.com/puresoul/p/4915350.html 来源: http://www.cnblogs.com/puresoul/ ...

  9. golang 如何查看channel通道中未读数据的长度

    可以通过内建函数len查看channel中元素的个数. 内建函数len的定义如下: func len(v Type) int The len built-in function returns the ...

  10. ML: 聚类算法-概论

    聚类分析是一种重要的人类行为,早在孩提时代,一个人就通过不断改进下意识中的聚类模式来学会如何区分猫狗.动物植物.目前在许多领域都得到了广泛的研究和成功的应用,如用于模式识别.数据分析.图像处理.市场研 ...