Cracking the Ocs Installation On Centos Secret

OCS inventory management application installation on Centos

In this Topic we are going to discuss about OCS inventory management application installation on Centos

Its a software which you can install in your office to  get inventory information like hardware details, software’s installed, IP address information etc.

It runs like a client server model where you can install a server to get and manage inventory information and client can be installed on all machines like Linux, Windows and MAC which provide information to the server. The inventory information is updated automatically by client from time to time.

You just need to install the client in all machines and you can easily manage hardware and software inventory in your software.

Main information which you get from this application are as follows :

Amount of RAM installed.
CPU and its speed
Total disk and percentage of utilization.
IP and gateway information
Various software’s installed
Type and version of OS
Remotely install a package

For the installation of this application on Centos operating system, you just need to have Apache, PHP & MySQL pre-installed.

You also need to have some Perl modules. So, let’s get started.

# yum install mysql-server mysql httpd
# service httpd start; chkconfig httpd on
# service mysqld start; chkconfig mysqld on
# yum install perl-XML-Simple perl-Compress-Zlib perl-DBI perl-DBD-MySQL perl-Apache-DBI perl-Net-IP perl-SOAP-Lite
# yum install php-pecl-zip php-mysql php-devel zlib-devel php-pear php-gd gcc

Add zip support to PHP once this is installed

# pecl install zip
# vim /etc/php.ini
;Add zip support
extension=zip.so

Restart Apache once done

# service httpd restart

Download OCS server package from here:

http://www.ocsinventory-ng.org/en/download/register-download-ocs-inventory-ng-server-for-unix.html
# tar -xzvf OCSNG_LINUX_SERVER_1.01.tar.gz
# cd OCSNG_LINUX_SERVER_1.01
# sh setup.sh

Install OCS in Apache web root /var/www/html

Configuration file : /etc/httpd/conf.d/ocsinventory.conf
Log                      : /var/log/ocsinventory-NG/

once done follow web setup, create a MySQL database and provide the information in the web page.

http://server-ip-address/ocsreports

Correct any errors if encountered here. Now you can now login to the web interface with username and password of both admin. You can change the default password at the top right-hand side of the browser window.
Server installation part is complete now, now install clients

Client – Linux

# yum install ocsinventory-agent

Follow on screen instructions

# vi /etc/ocsinventory/ocsinventory-agent.cfg

Here add your ocs server and tag name your client.

server = http://ocs.server/ocsinventory
tag = tag_name
Change the line local = /var/lib/ocsinventory-agent to basevardir = /var/lib/ocsinventory-agent. Save and close the file.

To run agent daily.

# mv /etc/cron.hourly/ocsinventory-agent /etc/cron.daily/

To forcefully send inventory

# /usr/sbin/ocsinventory-agent

Client – Windows

Download the windows client from here :

http://www.ocsinventory-ng.org/en/download/download-agent.html

and run the .exe, point client to your OCS server by client name or IP address and add tag name.

Client – MAC

Download the client from here :

http://www.ocsinventory-ng.org/en/download/download-agent.html

unzip the file and double click “Ocsinventory_Agent_MacOSX.pkg

Follow on screen instructions and point the client to OCS server, add tag name as well.

Schedule to run OCS agent every 6 hours that would be enough.

To access/manage OCS server

http://ocs-server-IP address/ocsreports

Here you can navigate and can get all required information.

Total
0
Shares
Leave a Reply

Your email address will not be published. Required fields are marked *

Related Posts