由chkconfig 引发的联想——怎么查看程序是否已经安装/成功安装
2012-08-26 13:46
543 查看
某天需要运行chkconfig,root登录依然找不到该命令。
[root@localhost ~]# chkconfig
bash: chkconfig: command not found
为什么,先看看chkconfig是不是安装过了?
[root@localhost ~]# rpm -q chkconfig
chkconfig-1.3.30.1-2
是安装过的,安装到哪里了?
[root@localhost ~]# whereis chkconfig
chkconfig: /sbin/chkconfig /usr/share/man/man8/chkconfig.8.gz
/sbin/chkconfig 在这里,那为什么不识别命令,看看环境变量
[root@localhost ~]# echo $PATH
/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/zhaoxueqian/bin
没有找到/sbin这个目录,加进去再说,网上一搜一堆
[root@localhost ~]# export PATH=$PATH:/sbin/
再次尝试chkconfig
[root@localhost ~]# chkconfig
chkconfig version 1.3.30.1 - Copyright (C) 1997-2000 Red Hat, Inc.
...
意思就是认识了。
[root@localhost ~]# chkconfig
bash: chkconfig: command not found
为什么,先看看chkconfig是不是安装过了?
[root@localhost ~]# rpm -q chkconfig
chkconfig-1.3.30.1-2
是安装过的,安装到哪里了?
[root@localhost ~]# whereis chkconfig
chkconfig: /sbin/chkconfig /usr/share/man/man8/chkconfig.8.gz
/sbin/chkconfig 在这里,那为什么不识别命令,看看环境变量
[root@localhost ~]# echo $PATH
/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/zhaoxueqian/bin
没有找到/sbin这个目录,加进去再说,网上一搜一堆
[root@localhost ~]# export PATH=$PATH:/sbin/
再次尝试chkconfig
[root@localhost ~]# chkconfig
chkconfig version 1.3.30.1 - Copyright (C) 1997-2000 Red Hat, Inc.
...
意思就是认识了。
相关文章推荐
- 由chkconfig 引发的联想——怎么查看程序是否已经安装/成功安装
- 如何查看ubuntu下显卡驱动是否已经成功安装
- 如何查看ubuntu下显卡驱动是否已经成功安装
- 如何查看ubuntu下显卡驱动是否已经成功安装
- 如何查看ubuntu下显卡驱动是否已经成功安装
- ubuntu下查看显卡驱动是否已经成功安装
- 教你怎么判断手机是否已安装某程序,然后调用该程序
- 关于查看Android ADT是否安装成功问题
- 程序安装时检查是否已经安装.NETFramework
- 【转】Linux下怎样检查、如何查看某软件包是否已经安装?
- 如何针对已经安装好的Apache/PHP/Mysql/Nginx程序查看他们的编译参数
- debian linux 中如何查看软件包是否已经安装和如何安装、卸载软件
- 如何查看我的sql server是否已经安装了sp3
- 急!请教高手,通过OTA下载安装程序完成后,怎样得到安装是否成功的标记?
- 查看jdk是否已经安装 和查看jdk的安装路径
- 在Inno Setup制作的安装包中利用Pascal脚本检查安装,卸载前检查程序是否已经启动 [转载]
- 如何针对已经安装好的Apache/PHP/Mysql/Nginx程序查看他们的编译参数
- Linux下怎样检查、如何查看某软件包是否已经安装?
- 用oralce连接.net客户端出现问题:“数据连接不成功,请检查该数据库是否已启动尝试加载oracle客户端时引发BadImageFormatException.如果在安装32位Oracle客户端组
- 查看本地Java安装是否成功和路径的方法