1.下載rpm包地址http://rpm.pbone.net
下載ocsinventory-agent-2.0.4-1.el6.remi.noarch.rpm
下載 monitor-edid-2.1-1.el6.rf.i686.rpm
2.安裝OCS客戶端軟件
[root@zh888 ~]# rpm -ivh ocsinventory-agent-2.0.4-1.el6.remi.noarch.rpm
warning: ocsinventory-agent-2.0.4-1.el6.remi.noarch.rpm: Header V3 DSA/SHA1 Signature, key ID 00f97f56: NOKEY
error: Failed dependencies:
monitor-edid is needed by ocsinventory-agent-2.0.4-1.el6.remi.noarch
perl(Proc::Daemon) is needed by ocsinventory-agent-2.0.4-1.el6.remi.noarch
[root@zh888 ~]# rpm -ivh monitor-edid-2.1-1.el6.rf.i686.rpm //安裝依賴包
warning: monitor-edid-2.1-1.el6.rf.i686.rpm: Header V3 DSA/SHA1 Signature, key ID 6b8d79e6: NOKEY
Preparing... ########################################### [100%]
1:monitor-edid ########################################### [100%]
[root@zh888 ~]# rpm -ivh ocsinventory-agent-2.0.4-1.el6.remi.noarch.rpm //但是還是有依賴直接忽略
warning: ocsinventory-agent-2.0.4-1.el6.remi.noarch.rpm: Header V3 DSA/SHA1 Signature, key ID 00f97f56: NOKEY
error: Failed dependencies:
perl(Proc::Daemon) is needed by ocsinventory-agent-2.0.4-1.el6.remi.noarch
[root@zh888 ~]# rpm -ivh ocsinventory-agent-2.0.4-1.el6.remi.noarch.rpm --nodeps//忽略掉直接安裝
warning: ocsinventory-agent-2.0.4-1.el6.remi.noarch.rpm: Header V3 DSA/SHA1 Signature, key ID 00f97f56: NOKEY
Preparing... ########################################### [100%]
1:ocsinventory-agent ########################################### [100%]
3.修改配置文件
[root@zh888 ~]# cat /etc/ocsinventory/ocsinventory-agent.cfg
#
# OCS Inventory "Unix Unified Agent" Configuration File
#
# options used by cron job overides this (see /etc/sysconfig/ocsinventory-agent)
#
# Server URL, unconmment if needed
server = 192.168.1.2 //在這裡就填寫server端的ip地址,不是本地的哦。
#local = /var/lib/ocsinventory-agent//把這個#掉
# Administrative TAG (optional, must be filed before first inventory)
# tag = your_tag
# How to log, can be File,Stderr,Syslog
#logger = Stderr//把這個#掉
#logfile = /var/log/ocsinventory-agent/ocsinventory-agent.log//把這個#掉
4.測試
[root@zh888 ~]# ocsinventory-agent --debug
本文出自 “有志者事竟成!” 博客,請務必保留此出處http://zh888.blog.51cto.com/1684752/832133