close

REF: http://top12345tw.blogspot.com/2008/05/openser.html (better)

 

REF: http://www.hk-pub.com/forum/archiver/tid-1064603.html

website: http://www.openser.org/

download: http://ftp.upjs.sk/pub/users/sal/Fedora/7/

Files to donwload:
openser-1.2.2-10.fc7.i386.rpm
openser-mysql-1.2.2-10.fc7.i386.rpm

設定檔:
/etc/openser/openser.cfg
/etc/openser/openserctlrc

# vi /etc/openser/openser.cfg
找到以下各行文字, 並移除前頭的井字符號
# loadmodule 「mysql.so」
#loadmodule 「auth.so」
#loadmodule 「auth_db.so」
#modparam(」usrloc」, 「db_mode」, 2)
#modparam(」auth_db」, 「calculate_ha1〞, yes)
#modparam(」auth_db」, 「password_column」, 「password」)

#if (!www_authorize(」openser.org」, 「subscriber」)) {
#       www_challenge(」openser.org」, 「0〞);
#       exit;
#};
(以上四行裡的 operser.org 改成你主機的 FDQN)

建立資料庫表單在 MySQL 裡
# vi /usr/sbin/openser_mysql.sh (可以先編輯這個檔案, 裡面包含了可能會使的資訊)
# /usr/sbin/openser_mysql.sh (編輯後就執行它)
可用的參數有:
usage: openser_mysql.sh create
openser_mysql.sh drop   (!!entirely deletes tables)
openser_mysql.sh reinit (!!entirely deletes and than re-creates tables
openser_mysql.sh backup (dumps current database to stdout)
openser_mysql.sh restore <file> (restores tables from a file)
openser_mysql.sh copy <new_db> (creates a new db from an existing one)
openser_mysql.sh migrate <old_db> <new_db> (migrates DB from 1.1 to 1.2)
openser_mysql.sh presence (adds the presence related tables)
openser_mysql.sh extra (adds the extra tables - imc,cpl,siptrace,domainpolicy)
openser_mysql.sh serweb (adds the SERWEB specific tables)

建立環境:
export SIP_DOMAIN=your-ip.address (也可以把這行寫到 /etc/profile 裡)

建立一個資料庫給 OpenSER
# /usr/sbin/openser_mysql.sh create (然後會需要你的資料庫管理員的密碼, ex: root 的密碼)
MySQL password for root: xxxxxxxx

設定開機啟動:
chkconfig openser on

手動啟用:
service openser start

紀錄檔管理:
REF: http://www.openser.org/dokuwiki/doku.php/utils:basic-syslog-configuration
# vi openser.cfg

touch /var/log/openser
(選用)安裝管理程式 OpenSER Admin:
REF: http://www.read8.org/20080918/35617/
yum install ruby ruby-libs rubygems
http://sourceforge.net/projects/openseradmin
wget http://nchc.dl.sourceforge.net/sourceforge/openseradmin/openseradmin-0.3.tar.bz2
tar jxvf openseradmin-0.3.tar.bz2

http://lightyror.thegiive.net/2007/06/fedora-7-ruby-on-rails.html
gem i rails -y
gem install rails –include-dependencies

在 /etc/rc.local 裡加入
/var/www/oseradm/script/server -p 3000 -d
(-p 是指定 port , -d 表示以 daemon 執行)

arrow
arrow
    全站熱搜

    安德森 發表在 痞客邦 留言(0) 人氣()