<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman, new york, times, serif;font-size:12pt"><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;">Hi Lon/Rajesh,<br><br>Thanks for the response. Earlier I thought RHEL release no. is directly mapped to cluster version and hence I was reading release from /etc/redhat-erlease file and get cluster specific commands to get cluster info. e.g.<br><br>RHEL 2.1    "/sbin/cluadmin -- cluster status"<br>RHEL 3.0    "/usr/sbin/clustat"<br><br>But I noticed that RHEL 3.0 could have cluster setup where  "/sbin/cluadmin -- cluster status" works. ( Where my code fails :-( ).<br>So now I need to find a way to detect cluster version and use corresponding cluster commands.<br><br>Rajesh has given a pointer to detect version For RHEL 2.1 and 3.0 run "rpm -qa |grep clumanager" and for rhel4.0 use ccs,cman,fence
 independent rpms to find the version. ( Rajesh which is the appropriate command to find version for RHEL4.0 ?)<br><br><br>m/c 1:<br><span style="font-family: courier,monaco,monospace,sans-serif;"># rpm -qa |grep clumanager</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;">clumanager-1.0.11-1</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;"># rpm -q redhat-release</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;">redhat-release-3AS-13.5.1</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;"># cat /etc/redhat-release</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;">Red Hat
 Enterprise Linux AS release 3 (Taroon Update 5)</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;"># ls -l /sbin/cluadmin</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;">-rwxr-xr-x    1 root     root       533296 Apr 17  2002 /sbin/cluadmin</span><br><br>m/c 2:<br><span style="font-family: courier,monaco,monospace,sans-serif;"># rpm -qa |grep clumanager</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;">clumanager-1.2.3-1</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;"># rpm -q redhat-release</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span
 style="font-family: courier,monaco,monospace,sans-serif;">redhat-release-3AS-1</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;"># cat /etc/redhat-release</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;">Red Hat Enterprise Linux AS release 3 (Taroon)</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;"># ls -l /sbin/cluadmin</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;">ls: /sbin/cluadmin: No such file or directory</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span style="font-family: courier,monaco,monospace,sans-serif;"># ls -l /usr/sbin/clustat</span><br style="font-family: courier,monaco,monospace,sans-serif;"><span
 style="font-family: courier,monaco,monospace,sans-serif;">-rwxr-xr-x    1 root     root        56128 Oct  6  2003 /usr/sbin/clustat</span><br><br>Do I need to consider second bit for cluster release? (e.g 2 in clumanager-1.2.3-1)<br>Thanks friends for your help.<br><br>Have a nice day !<br>- Krishna<br><br><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;">----- Original Message ----<br>From: Lon Hohberger <lhh@redhat.com><br>To: linux clustering <linux-cluster@redhat.com><br>Sent: Thursday, January 11, 2007 8:35:24 PM<br>Subject: Re: [Linux-cluster] cluster version identification:how?<br><br><div>On Thu, 2007-01-11 at 03:34 -0800, krishnamurthi G wrote:<br>>  Hi Frieds,<br>> <br>> Is there any ways to find cluster version (if it is !). <br>> Problem: The cluster specific commands/paths/command outputs have been<br>>
 changed/changing completely from RHEL 2.1 to 2.4 to 2.6.<br><br><br>> I am working on a project where I need support for all<br>> version/releases, some how I need to find cluster version if available<br>> so that I can parse accordingly.<br><br>> Temporary Work around: The cluster config file is unique for different<br>> RHEL releases.<br>> e.g RHEL 2.1 "/etc/cluster.xml" <br>> RHEL 2.4  "/etc/cluster.conf"<br>> RHEL 2.6 "/etc/cluster/cluster.conf"<br>> <br>> Check this config file and identify cluster type.<br><br>RHEL 2.1: /etc/cluster.conf<br>RHEL3:    /etc/cluster.xml<br>RHEL4:    /etc/cluster/cluster.conf<br>RHEL5:    /etc/cluster/cluster.conf<br><br>Why not just do 'rpm -q redhat-release'?  I'm curious; why does the<br>cluster version matter: are you manipulating cluster.[xml|conf]<br>directly?  If so, you'll need to do a few extra
 things.<br><br>-- Lon<br><br><br><br>--<br>Linux-cluster mailing list<br>Linux-cluster@redhat.com<br><a target="_blank" href="https://www.redhat.com/mailman/listinfo/linux-cluster">https://www.redhat.com/mailman/listinfo/linux-cluster</a><br></div></div><br></div></div><br>

<hr size=1>Check out <a href="http://us.rd.yahoo.com/evt=43257/*http://advision.webevents.yahoo.com/mailbeta">the all-new Yahoo! Mail beta</a> - Fire up a more powerful email and get things done faster.</body></html>