查看完整版本: Opennms 1.61安裝

danny 2009-5-21 16:49

Opennms 1.61安裝

[font=新細明體]系統環境:[/font]Centos 5.2

  [font=新細明體]1.安裝[/font]yum-fastestmirror
  .[root@localhost ~]# yum install yum-fastestmirror
  
Setting up Install Process
  ...  
Running Transaction  
Installing: yum-fastestmirror
######################### [1/1]   
Installed: yum-fastestmirror.noarch 0:1.1.9-2.fc8  
Complete!
   
  2.[font=新細明體]安裝[/font]Repository RPMs
  [root@localhost ~]# rpm -Uvh [url=http://yum.opennms.org/repofiles/opennms-repo-stable-rhel5.noarch.rpm]http://yum.opennms.org/repofiles/opennms-repo-stable-rhel5.noarch.rpm[/url]
   
  [font=新細明體]查詢可安裝的套件[/font]
  [root@localhost ~]# yum list opennms
  …….
  Available Packages
  opennms.noarch  1.6.1-1  opennms-stable-c
   
3.[font=新細明體]安裝[/font]postgresql-server
  [root@localhost ~]# yum -y install postgresql-server
  ……
  Transaction Test Succeeded
  Running Transaction
  
Installing: postgresql
######################### [1/2]  
Installing: postgresql-server
######################### [2/2]   
  Installed: postgresql-server.i386 0:8.1.11-1.el5_1.1
  Dependency Installed: postgresql.i386 0:8.1.11-1.el5_1.1
  Complete!
   
4.[font=新細明體]啟動[/font]postgresql[font=新細明體]並設定開機時啟動。[/font]
  [root@localhost ~]# service postgresql start
  Initializing database:[OK]
  Starting postgresql service:[OK]
  [root@localhost ~]# chkconfig postgresql on  

5. Install OpenNMS
  =============================================================================  
Package
Arch
Version
Repository
Size
  =============================================================================
  Installing:  
opennms  noarch  1.6.1-1
opennms-stable-common 4.9 k
  Installing for dependencies:  
jdk i586 2000:1.5.0_15-fcs
opennms-stable-common 46 M
jicmp i386 1.0.7-1
opennms-stable-rhel5 46 k
opennms-core noarch 1.6.1-1
opennms-stable-common 49 M
opennms-webapp-jetty noarch 1.6.1-1
opennms-stable-common 30 M

  Transaction Summary
  =============================================================================
  Install
5 Package(s)
  Update
0 Package(s)
  Remove
0 Package(s)
   
  Total download size: 126 M
  Is this ok [y/N]: y
  Downloading Packages:
  (1/5): opennms-core-1.6.1 100% |=========================| 49 MB 03:30
  (2/5): opennms-webapp-jet 100% |=========================| 30 MB 01:36
  (3/5): jdk-1_5_0_15-linux 100% |=========================| 46 MB 03:02
  (4/5): opennms-1.6.1-1.no 100% |=========================| 4.9 kB 00:00
  (5/5): jicmp-1.0.7-1.i386 100% |=========================| 46 kB 00:00
  warning: rpmts_HdrFromFdno: Header V3 DSA signature: NOKEY, key ID 4c4cbbd9
  Importing GPG key 0x4C4CBBD9 "OpenNMS Project (A Key for Signing OpenNMS RPMs) " from [url=http://yum.opennms.org/OPENNMS-GPG-KEY]http://yum.opennms.org/OPENNMS-GPG-KEY[/url]   
  [font="]

6.[/font]將[font="]/etc/yum.repos.d/opennms*.repo[/font]檔案加入以下的參數[font="][/font][font="]enabled=0[/font]   

7. Configure OpenNMS
  [root@localhost ~]# [font="]export OPENNMS_HOME=/opt/opennms[/font]   
  
8. Configure Database
  pg_hba.conf [font=新細明體]與[/font] postgresql.conf [font=新細明體]在[/font] /var/lib/pgsql/data[font=新細明體]下[/font]   
  [root@localhost ~]# vi /var/lib/pgsql/data/ pg_hba.conf
  [font=新細明體]原有的參數設定[/font]
  local all all                             ident sameuser
  host all all 127.0.0.1/32      ident sameuser
  host all all ::1/128                ident sameuser   
  [font=新細明體]改成[/font]  
local all all                             trust  
host all all  127.0.0.1/32      trust
host all all ::1/128                 trust
     
  [root@localhost ~]# vi /var/lib/pgsql/data/ postgresql.conf
  # [font=新細明體]去除[/font] "*" [font=新細明體]如下[/font]  
listen_addresses = 'localhost'  

9.[font=新細明體]重新啟動[/font]services[font=新細明體]並建立[/font]Database
  [root@localhost ~]# service postgresql restart
  [root@localhost ~]# sudo -u postgres createdb -U postgres -E UNICODE opennms
     
10.[font=新細明體]安裝[/font]iplike
  [root@localhost ~]# yum install iplike
  [root@localhost ~]# install_iplike.sh
  CREATE FUNCTION
   
11.[font=新細明體]設定[/font]OpenNMS [font=新細明體]連結到[/font] Java
  [root@localhost ~]# $OPENNMS_HOME/bin/runjava –s
   
12.[font=新細明體]加入[/font]JAVA_HOME [font=新細明體]到[/font] /etc/default/opennms
  [root@localhost ~]# vi /etc/default/opennms
  JAVA_HOME=/usr
   
13. [font=新細明體]初始化[/font]OpenNMS [font=新細明體]與[/font] Database(請注意您的系統是32bit或64bit之作業系統)
  # i386 example
  $OPENNMS_HOME/bin/install -dis -l /usr/lib/jni:/usr/lib
  # x86_64 example
  $OPENNMS_HOME/bin/install -dis -l /usr/lib64/jni:/usr/lib64
  …………..
  Installer completed successfully!
  [font=新細明體]表示成功了。[/font]
   
14.[font=新細明體]編輯[/font]$OPENNMS_HOME/etc/discovery-configuration.xml[font=新細明體],設定所要監看的[/font]IP[font=新細明體]區間[/font]
  
  [url=http://1.bp.blogspot.com/_PCm72EWcFWY/SSpajbvXw2I/AAAAAAAABiI/LuzR5DU-p38/s1600-h/op3.jpg][img]http://1.bp.blogspot.com/_PCm72EWcFWY/SSpajbvXw2I/AAAAAAAABiI/LuzR5DU-p38/s320/op3.jpg[/img][/url]

15.[font=新細明體]啟動[/font]opennms[font=新細明體]的[/font]service[font=新細明體],並設定開機時啟動[/font]
  [root@localhost ~]# service opennms start
  [root@localhost ~]# chkconifg opennms on
   
16.[font=新細明體]由瀏覽器連線到[/font]SERVER[font=新細明體]看結果[/font]
  [url=http://serverip:8980/opennms/]http://ServerIP:8980/opennms/[/url]
  [font=新細明體]初始帳號密碼:[/font]admin/admin
  [url=http://3.bp.blogspot.com/_PCm72EWcFWY/SSpWiDpupAI/AAAAAAAABh4/lS-EKWj6gZI/s1600-h/op1.jpg][img=181,68]http://3.bp.blogspot.com/_PCm72EWcFWY/SSpWiDpupAI/AAAAAAAABh4/lS-EKWj6gZI/s320/op1.jpg[/img][/url]

  17.[font=新細明體]在[/font]opennms[font=新細明體]運行一段時間後,就可以看到下列的訊息。[/font]
  [url=http://4.bp.blogspot.com/_PCm72EWcFWY/SSpWwW1mEUI/AAAAAAAABiA/jHrxq-VdKTc/s1600-h/op2.jpg][img]http://4.bp.blogspot.com/_PCm72EWcFWY/SSpWwW1mEUI/AAAAAAAABiA/jHrxq-VdKTc/s320/op2.jpg[/img][/url]
頁: [1]
查看完整版本: Opennms 1.61安裝