RHCS4的問題-(急)!
各位高人,我用RHCS4 CMAN服務啟不來,如果採用GuLM方式,CMAN是可以正常啟來的,服務可以對外,當然我的Fence還是有點問題。具體的配置如下:
hosts表:
127.0.0.1 localhost.localdomain localhost Web_A
10.2.8.245 Web_A
10.2.8.244 Web_B
10.2.8.246 Web_VIP
cluster.conf內容如下:
<?xml version="1.0" ?>
<cluster config_version="4" name="alpha_cluster">
<fence_daemon clean_start="0" post_fail_delay="0" post_join_delay="3"/>
<clusternodes>
<clusternode name="Web_A" votes="1">
<fence>
<method name="1">
<device name="root" port="1"/>
</method>
</fence>
</clusternode>
<clusternode name="Web_B" votes="1">
<fence>
<method name="1">
<device name="root" port="1"/>
</method>
</fence>
</clusternode>
</clusternodes>
<cman expected_votes="1" two_node="1"/>
<fencedevices>
<fencedevice agent="fence_brocade" ipaddr="10.2.8.237" login="admin" name="root" passwd="password"/>
</fencedevices>
<rm>
<failoverdomains>
<failoverdomain name="web_failover" ordered="1" restricted="0">
<failoverdomainnode name="WebA" priority="1"/>
<failoverdomainnode name="WebB" priority="2"/>
</failoverdomain>
</failoverdomains>
<resources>
<ip address="10.2.8.246" monitor_link="1"/>
</resources>
<service autostart="1" domain="web_failover" name="WebSphere">
<ip ref="10.2.8.246"/>
</service>
</rm>
</cluster>
具體問題如下:
第一:我用fence_brocade -a 10.2.8.237 -l admin -p password -n 1 -o enable 測試Fence Device 返回值正常。但是服務fenced啟動不了。請問這用Brocade交換機做Fence Device還有其它方面的設置嗎?也正如版主說的,我把REDHAT的文檔都看了好多遍了,呵呵……還沒有通。
第二:請大家幫忙分析指導Cman服務啟動不了具體原因?
報錯信息:
Sep 28 11:39:43 localhost cman_tool: gethostby*.getanswer: asked for "Web_B IN AAAA", got type "A"
Sep 28 11:39:43 localhost cman: cman_tool: Can't find broadcast address for node Web_B failed
如果還有什麼沒有想到的地方,請指出!感激不盡!幫忙看一下?
[ 本帖最後由 dighdypea 於 2006-9-28 11:44 編輯 ]
《解決方案》
感謝關注,已經搞定
《解決方案》
share your experience here.
《解決方案》
我也在做一個相同的實驗,所不同的是使用了另外一台設備作為GFS的文件伺服器。
目前的問題也是卡在了fence這一塊兒了,設備在啟動fence時無法卡住了,無法正常啟動。
我現在的問題是,我沒有專用的fence交換機的話,如何去繼續完成這個實驗。
因為我查一些資料的過程中也是得知「fence是必須的,不配fence,你的集群可以跑起來,但是不算配好了,因為RHCS無法通過一個途徑來阻止一個failed node和healthy node來競爭shared resource,比如 shared lun從而破壞掉上面的數據」。
謝謝!
《解決方案》
我這個是生產環境用的,如果你要做實驗其實你可以腳本來完成,但我在配置FENCE DEVICE失敗時,曾經做過,但前後分析我的問題出錯不在FENCE,呵呵……,我回去測一下我寫的那個腳本可以不,如果可以在拿上來SHOW哈。出現我這個問題的原因網卡設置IP的時候要去掉MAC地址綁定。這個在多網卡綁定做網卡負載分攤時也要去掉。
《解決方案》
如何通過腳本實現?具體的方式fence的類型是什麼。盼
《解決方案》
測試中
[ 本帖最後由 dighdypea 於 2006-10-1 00:53 編輯 ]
《解決方案》
:em14:
LZ
你的web_a web_b為什麼都是「<device name="root" port="1"/>」
這好像不對吧。。。。。
《解決方案》
呵呵……因為我用的兩台BROCADE FC交換機,肯定沒有問題的。每一種FENCE設備都有測試命令,用fence_brocade -a 10.2.8.237 -l admin -p password -n 1 -o enable 測試Fence Device 返回值正常,我測過BROCADE FC交換機,原則上只能1,我測試過多個埠都不能得到正確的返回值。下面給出一最終的配置,以腳本服務的標準格式。
最終配置如下:
cat /etc/hosts:
# cat /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 localhost.localdomain localhost
10.2.8.245 Web_A.localdomain Web_A
10.2.8.244 Web_B.localdomain Web_B
10.2.8.246 Web_VIP.localdomain Web_VIP
cat /etc/cluster/cluster.conf
# cat /etc/cluster/cluster.conf
<?xml version="1.0"?>
<cluster config_version="13" name="websphere">
<fence_daemon clean_start="0" post_fail_delay="0" post_join_delay="3"/>
<clusternodes>
<clusternode name="Web_A" votes="1">
<fence>
<method name="1">
<device name="IBM-2005-B16_A" port="1"/>
</method>
<method name="2">
<device name="IBM-2005-B16-B" port="1"/>
</method>
</fence>
</clusternode>
<clusternode name="Web_B" votes="1">
<fence>
<method name="1">
<device name="IBM-2005-B16_A" port="1"/>
</method>
<method name="2">
<device name="IBM-2005-B16-B" port="1"/>
</method>
</fence>
</clusternode>
</clusternodes>
<cman expected_votes="1" two_node="1"/>
<fencedevices>
<fencedevice agent="fence_brocade" ipaddr="10.2.8.237" login="admin" name="IBM-2005-B16_A" passwd="password"/>
<fencedevice agent="fence_brocade" ipaddr="10.2.8.236" login="admin" name="IBM-2005-B16-B" passwd="password"/>
</fencedevices>
<rm>
<failoverdomains>
<failoverdomain name="web_failover" ordered="1" restricted="0">
<failoverdomainnode name="WebA" priority="1"/>
<failoverdomainnode name="WebB" priority="2"/>
</failoverdomain>
</failoverdomains>
<resources>
<ip address="10.2.8.246" monitor_link="1"/>
<script file="/data/WebSphere6Express/Websphere_Cluster" name="WebSphere"/>
<script file="/data/IBMHTTPSERVER/IBM_Httpd_Cluster" name="Http_Server"/>
</resources>
<service autostart="1" domain="web_failover" name="WebSphere">
<ip ref="10.2.8.246">
<script ref="WebSphere"/>
<script ref="Http_Server"/>
</ip>
</service>
</rm>
</cluster>
腳本服務:
#!/bin/sh
#
#
### BEGIN INIT INFO
# Provides: IBM WebSphere 6.0
# Required-Start: $local_fs $network $syslog
# Should-Start:
# Required-Stop:
# Default-Start: 2 3 4 5
# Default-Stop: 0 6
# Short-Description: IBM WebSphere 6.0
# Description: Starts and stops IBM WebSphere 6.0
### END INIT INFO
action=$1
WEBSPHERE=/data/WebSphere6Express
WEBSPHEREWNER=root
case "$action" in
'start')
#
# Check to make sure there isn't another agent running already.
# Kill and restart the agent.
echo "Starting IBM WebSphere 6.0..."
echo "RunOS:RedHat Linux Enterprise 4.2"
echo "Author:Xu qiquan"
echo "Date:2006-09-29"
su - $WEBSPHEREWNER -c "$WEBSPHERE/bin/startServer.sh server1"
echo "Start Done."
# Setup environment and start agent.
;;
'stop')
# Stop the agent.
su - $WEBSPHEREWNER -c "$WEBSPHERE/bin/stopServer.sh server1"
echo "Stop Done."
;;
"")
# Usage message.
echo "You must tell what you want me to do."
echo "Usage : ./oracle "
echo " start - Start IBM WebSphere 6.0"
echo " stop - Stop IBM WebSphere 6.0"
;;
esac
exit
以上所有均通過測試。