cluster-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-07-06 16:23 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-07-06 16:23 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Changes by:	rohara at sourceware.org	2006-07-06 16:23:41

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Added extra output when verbose option is given.
	Fixed code to close stdin, stdout, stderr after open3 call.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&r1=1.1&r2=1.2

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/06/29 21:36:09	1.1
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/07/06 16:23:40	1.2
@@ -141,6 +141,10 @@
 	    push @volumes, $device;
 	}
     }
+
+    close($in);
+    close($out);
+    close($err);
 }
 
 sub check_sg_persist
@@ -153,6 +157,12 @@
 
     die "Unable to execute sg_persist.\n" if ($?>>8);
 
+    while (<$out>)
+    {
+	chomp;
+	print "OUT: $_\n" if $opt_v;
+    }
+
     close($in);
     close($out);
     close($err);



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-07-06 21:58 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-07-06 21:58 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Changes by:	rohara at sourceware.org	2006-07-06 21:58:30

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Fix stdin parameter parsing to handle 'name=value' correctly.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&r1=1.2&r2=1.3

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/07/06 16:23:40	1.2
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/07/06 21:58:30	1.3
@@ -93,7 +93,7 @@
 
 	next unless $opt;
 
-	($name, $val) = split /\s*=\s/, $opt;
+	($name, $val) = split /\s*=\s*/, $opt;
 
 	if ($name eq "")
 	{



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-07-10 18:53 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-07-10 18:53 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Changes by:	rohara at sourceware.org	2006-07-10 18:53:59

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Name of node to be fenced is passed via "nodename=" parameter.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&r1=1.3&r2=1.4

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/07/06 21:58:30	1.3
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/07/10 18:53:58	1.4
@@ -103,7 +103,7 @@
 	elsif ($name eq "agent")
 	{
 	}
-	elsif ($name eq "node")
+	elsif ($name eq "nodename")
 	{
 	    $opt_n = $val;
 	}
@@ -227,7 +227,7 @@
 
     get_options_stdin();
 
-    fail "failed: missing 'node'" unless defined $node;
+    fail "failed: missing 'node'" unless defined $opt_n;
 
 }
 



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-07-12 20:34 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-07-12 20:34 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Changes by:	rohara at sourceware.org	2006-07-12 20:34:18

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	fence_scsi agent should use "self" rather than try to determine node node.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&r1=1.4&r2=1.5

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/07/10 18:53:58	1.4
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/07/12 20:34:17	1.5
@@ -103,10 +103,14 @@
 	elsif ($name eq "agent")
 	{
 	}
-	elsif ($name eq "nodename")
+	elsif ($name eq "node")
 	{
 	    $opt_n = $val;
 	}
+	elsif ($name eq "self")
+	{
+	    $opt_s = $val;
+	}
 	elsif ($name eq "verbose")
 	{
 	    $opt_v = $val;
@@ -170,9 +174,9 @@
 
 sub fence_node
 {
-    my $name = (POSIX::uname())[1];
+    # my $name = (POSIX::uname())[1];
 
-    my $host_key = get_key($name);
+    my $host_key = get_key($opt_s);
     my $node_key = get_key($opt_n);
     
     my $cmd;
@@ -222,12 +226,14 @@
 
     fail_usage "Unkown parameter." if (@ARGV > 0);
     fail_usage "No '-n' flag specified." unless defined $opt_n;
+    fail_usage "No '-s' flag specified." unless defined $opt_s;
 
 } else {
 
     get_options_stdin();
 
     fail "failed: missing 'node'" unless defined $opt_n;
+    fail "failed: missing 'self'" unless defined $opt_s;
 
 }
 



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-11-29 20:14 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-11-29 20:14 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL4
Changes by:	rohara at sourceware.org	2006-11-29 20:14:43

Added files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Fence agent for SCSI persistent reservations.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=NONE&r2=1.5.6.1

/cvs/cluster/cluster/fence/agents/scsi/fence_scsi.pl,v  -->  standard output
revision 1.5.6.1
--- cluster/fence/agents/scsi/fence_scsi.pl
+++ -	2006-11-29 20:14:44.724242000 +0000
@@ -0,0 +1,280 @@
+#!/usr/bin/perl
+
+use Getopt::Std;
+use IPC::Open3;
+use POSIX;
+
+my @volumes;
+
+$_ = $0;
+s/.*\///;
+my $pname = $_;
+
+# WARNING!! Do not add code bewteen "#BEGIN_VERSION_GENERATION" and
+# "#END_VERSION_GENERATION"  It is generated by the Makefile
+
+#BEGIN_VERSION_GENERATION
+$FENCE_RELEASE_NAME="";
+$REDHAT_COPYRIGHT="";
+$BUILD_DATE="";
+#END_VERSION_GENERATION
+
+sub usage
+{
+    print "Usage\n";
+    print "\n";
+    print "$pname [options]\n";
+    print "\n";
+    print "Options\n";
+    print "  -n <node>        IP address or hostname of node to fence\n";
+    print "  -h               usage\n";
+    print "  -V               version\n";
+    print "  -v               verbose\n";
+
+    exit 0;
+}
+
+sub version
+{
+    print "$pname $FENCE_RELEASE_NAME $BUILD_DATE\n";
+    print "$REDHAT_COPYRIGHT\n" if ( $REDHAT_COPYRIGHT );
+
+    exit 0;
+}
+
+sub fail
+{
+    ($msg)=@_;
+
+    print $msg."\n" unless defined $opt_q;
+
+    exit 1;
+}
+
+sub fail_usage
+{
+    ($msg)=@_;
+
+    print STDERR $msg."\n" if $msg;
+    print STDERR "Please use '-h' for usage.\n";
+
+    exit 1;
+}
+
+sub get_key
+{
+    ($node)=@_;
+
+    my $addr = gethostbyname($node) or die "$!\n";
+
+    return unpack("H*", $addr);
+}
+
+sub get_node_name
+{
+    return $opt_n;
+}
+
+sub get_host_name
+{
+    my $host_name;
+
+    my ($in, $out, $err);
+    my $cmd = "cman_tool status";
+
+    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+    waitpid($pid, 0);
+
+    die "Unable to execute cman_tool.\n" if ($?>>8);
+
+    while (<$out>)
+    {
+	chomp;
+	print "OUT: $_\n" if $opt_v;
+
+	my ($name, $value) = split(/\s*:\s*/, $_, 2);
+
+	if ($name eq "Node name")
+	{
+	    $host_name = $value;
+	    last;
+	}
+    }
+
+    close($in);
+    close($out);
+    close($err);
+
+    return $host_name;
+}
+
+sub get_option_stdin
+{
+    my $opt;
+    mt $line = 0;
+
+    while (defined($in = <>))
+    {
+	$_ = $in;
+	chomp;
+
+	# strip leading and trailing whitespace
+	s/^\s*//;
+	s/\s*$//;
+
+	# skip comments
+	next if /^#/;
+
+	$line += 1;
+	$opt = $_;
+
+	next unless $opt;
+
+	($name, $val) = split /\s*=\s*/, $opt;
+
+	if ($name eq "")
+	{
+	    print STDERR "parse error: illegal name in option $line\n";
+	    exit 2;
+	}
+	elsif ($name eq "agent")
+	{
+	}
+	elsif ($name eq "node")
+	{
+	    $opt_n = $val;
+	}
+	elsif ($name eq "self")
+	{
+	    $opt_s = $val;
+	}
+	elsif ($name eq "verbose")
+	{
+	    $opt_v = $val;
+	}
+	else
+	{
+	    fail "parse error: unknown option \"$opt\"";
+	}
+    }
+}
+
+sub get_scsi_devices
+{
+    my ($in, $out, $err);
+    my $cmd = "lvs --noheadings --separator : -o vg_attr,devices";
+    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+    waitpid($pid, 0);
+
+    die "Unable to execute lvs.\n" if ($?>>8);
+
+    while (<$out>)
+    {
+	chomp;
+	print "OUT: $_\n" if $opt_v;
+
+	my ($vg_attrs, $device) = split /:/, $_, 2;
+
+	if ($vg_attrs =~ /.*c$/)
+	{
+	    $device =~ s/\(.*\)://;
+	    push @volumes, $device;
+	}
+    }
+
+    close($in);
+    close($out);
+    close($err);
+}
+
+sub check_sg_persist
+{
+    my ($in, $out, $err);
+    my $cmd = "sg_persist -V";
+    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+    waitpid($pid, 0);
+
+    die "Unable to execute sg_persist.\n" if ($?>>8);
+
+    while (<$out>)
+    {
+	chomp;
+	print "OUT: $_\n" if $opt_v;
+    }
+
+    close($in);
+    close($out);
+    close($err);
+}
+
+sub fence_node
+{
+    my $host_name = get_host_name();
+    my $node_name = get_node_name();
+
+    my $host_key = get_key($host_name);
+    my $node_key = get_key($node_name);
+
+    my $cmd;
+    my ($in, $out, $err);
+
+    foreach $dev (@volumes)
+    {
+	if ($host_key eq $node_key)
+	{
+	    $cmd = "sg_persist -d $dev -o -G -K $host_key -S 0";
+	}
+	else
+	{
+	    $cmd = "sg_persist -d $dev -o -A -K $host_key -S $node_key -T 5";
+	}
+
+	my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+	waitpid($pid, 0);
+
+	die "Unable to execute sg_persist.\n" if ($?>>8);
+
+	while (<$out>)
+	{
+	    chomp;
+	    print "OUT: $_\n" if $opt_v;
+	}
+
+	close($in);
+	close($out);
+	close($err);
+    }
+}
+
+### MAIN #######################################################
+
+if (@ARGV > 0) {
+
+    getopts("n:s:hqvV") || fail_usage;
+
+    usage if defined $opt_h;
+    version if defined $opt_V;
+
+    fail_usage "Unkown parameter." if (@ARGV > 0);
+    fail_usage "No '-n' flag specified." unless defined $opt_n;
+    fail_usage "No '-s' flag specified." unless defined $opt_s;
+
+} else {
+
+    get_options_stdin();
+
+    fail "failed: missing 'node'" unless defined $opt_n;
+    fail "failed: missing 'self'" unless defined $opt_s;
+
+}
+
+check_sg_persist;
+
+get_scsi_devices;
+
+fence_node;
+



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-11-29 23:19 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-11-29 23:19 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL4
Changes by:	rohara at sourceware.org	2006-11-29 23:19:04

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Remove LIMIT param from calls to split. Seems that different versions of
	Perl behave differently when split uses this param, so removing this
	optional parameter makes things behanve consistently.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=1.5.6.1&r2=1.5.6.2

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/11/29 20:14:42	1.5.6.1
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/11/29 23:19:04	1.5.6.2
@@ -93,7 +93,7 @@
 	chomp;
 	print "OUT: $_\n" if $opt_v;
 
-	my ($name, $value) = split(/\s*:\s*/, $_, 2);
+	my ($name, $value) = split(/\s*:\s*/, $_);
 
 	if ($name eq "Node name")
 	{
@@ -131,7 +131,7 @@
 
 	next unless $opt;
 
-	($name, $val) = split /\s*=\s*/, $opt;
+	($name, $val) = split(/\s*=\s*/, $opt);
 
 	if ($name eq "")
 	{
@@ -175,7 +175,7 @@
 	chomp;
 	print "OUT: $_\n" if $opt_v;
 
-	my ($vg_attrs, $device) = split /:/, $_, 2;
+	my ($vg_attrs, $device) = split(/:/, $_);
 
 	if ($vg_attrs =~ /.*c$/)
 	{



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-01 17:53 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-01 17:53 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL4
Changes by:	rohara at sourceware.org	2006-12-01 17:53:07

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Remove "self" parameter. This was used to specify the name of the node
	performing the fence operation, and was passed to the agent. This is
	no longer used. Instead, we get the name of the local node in the agent
	by parsing the output from 'cman_tool status'.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=1.5.6.2&r2=1.5.6.3

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/11/29 23:19:04	1.5.6.2
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/01 17:53:07	1.5.6.3
@@ -145,10 +145,6 @@
 	{
 	    $opt_n = $val;
 	}
-	elsif ($name eq "self")
-	{
-	    $opt_s = $val;
-	}
 	elsif ($name eq "verbose")
 	{
 	    $opt_v = $val;
@@ -254,21 +250,20 @@
 
 if (@ARGV > 0) {
 
-    getopts("n:s:hqvV") || fail_usage;
+    getopts("n:hqvV") || fail_usage;
 
     usage if defined $opt_h;
     version if defined $opt_V;
 
     fail_usage "Unkown parameter." if (@ARGV > 0);
+
     fail_usage "No '-n' flag specified." unless defined $opt_n;
-    fail_usage "No '-s' flag specified." unless defined $opt_s;
 
 } else {
 
     get_options_stdin();
 
     fail "failed: missing 'node'" unless defined $opt_n;
-    fail "failed: missing 'self'" unless defined $opt_s;
 
 }
 



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-01 17:53 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-01 17:53 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL5
Changes by:	rohara at sourceware.org	2006-12-01 17:53:22

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Remove "self" parameter. This was used to specify the name of the node
	performing the fence operation, and was passed to the agent. This is
	no longer used. Instead, we get the name of the local node in the agent
	by parsing the output from 'cman_tool status'.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.5&r2=1.5.2.1

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/07/12 20:34:17	1.5
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/01 17:53:22	1.5.2.1
@@ -4,7 +4,6 @@
 use IPC::Open3;
 use POSIX;
 
-my $verbose = 0;
 my @volumes;
 
 $_ = $0;
@@ -71,6 +70,45 @@
     return unpack("H*", $addr);
 }
 
+sub get_node_name
+{
+    return $opt_n;
+}
+
+sub get_host_name
+{
+    my $host_name;
+
+    my ($in, $out, $err);
+    my $cmd = "cman_tool status";
+
+    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+    waitpid($pid, 0);
+
+    die "Unable to execute cman_tool.\n" if ($?>>8);
+
+    while (<$out>)
+    {
+	chomp;
+	print "OUT: $_\n" if $opt_v;
+
+	my ($name, $value) = split(/\s*:\s*/, $_);
+
+	if ($name eq "Node name")
+	{
+	    $host_name = $value;
+	    last;
+	}
+    }
+
+    close($in);
+    close($out);
+    close($err);
+
+    return $host_name;
+}
+
 sub get_options_stdin
 {
     my $opt;
@@ -107,10 +145,6 @@
 	{
 	    $opt_n = $val;
 	}
-	elsif ($name eq "self")
-	{
-	    $opt_s = $val;
-	}
 	elsif ($name eq "verbose")
 	{
 	    $opt_v = $val;
@@ -174,10 +208,11 @@
 
 sub fence_node
 {
-    # my $name = (POSIX::uname())[1];
+    my $host_name = get_host_name();
+    my $node_name = get_node_name();
 
-    my $host_key = get_key($opt_s);
-    my $node_key = get_key($opt_n);
+    my $host_key = get_key($host_name);
+    my $node_key = get_key($node_name);
     
     my $cmd;
     my ($in, $out, $err);
@@ -197,18 +232,14 @@
 
 	waitpid($pid, 0);
 
-	if ($opt_v)
+	die "Unable to execute sg_persist.\n" if ($?>>8);
+
+	while (<$out>)
 	{
-	    print "$cmd\n";
-	    while (<$out>)
-	    {
-		chomp;
-		print "OUT: $_\n";
-	    }
+	    chomp;
+	    print "OUT: $_\n" if $opt_v;
 	}
 
-	die "Unable to execute sg_persist.\n" if ($?>>8);
-
 	close($in);
 	close($out);
 	close($err);
@@ -225,15 +256,14 @@
     version if defined $opt_V;
 
     fail_usage "Unkown parameter." if (@ARGV > 0);
+
     fail_usage "No '-n' flag specified." unless defined $opt_n;
-    fail_usage "No '-s' flag specified." unless defined $opt_s;
 
 } else {
 
     get_options_stdin();
 
     fail "failed: missing 'node'" unless defined $opt_n;
-    fail "failed: missing 'self'" unless defined $opt_s;
 
 }
 
@@ -242,3 +272,4 @@
 get_scsi_devices;
 
 fence_node;
+



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-01 20:24 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-01 20:24 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL50
Changes by:	rohara at sourceware.org	2006-12-01 20:24:18

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Remove "self" parameter. This was used to specify the name of the node
	performing the fence operation, and was passed to the agent. This is
	no longer used. Instead, we get the name of the local node in the agent
	by parsing the output from 'cman_tool status'.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL50&r1=1.5&r2=1.5.4.1

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/07/12 20:34:17	1.5
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/01 20:24:18	1.5.4.1
@@ -4,7 +4,6 @@
 use IPC::Open3;
 use POSIX;
 
-my $verbose = 0;
 my @volumes;
 
 $_ = $0;
@@ -13,8 +12,8 @@
 
 # WARNING!! Do not add code bewteen "#BEGIN_VERSION_GENERATION" and
 # "#END_VERSION_GENERATION"  It is generated by the Makefile
-                                                                                
 #BEGIN_VERSION_GENERATION
+
 $FENCE_RELEASE_NAME="";
 $REDHAT_COPYRIGHT="";
 $BUILD_DATE="";
@@ -71,6 +70,45 @@
     return unpack("H*", $addr);
 }
 
+sub get_node_name
+{
+    return $opt_n;
+}
+
+sub get_host_name
+{
+    my $host_name;
+
+    my ($in, $out, $err);
+    my $cmd = "cman_tool status";
+
+    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+    waitpid($pid, 0);
+
+    die "Unable to execute cman_tool.\n" if ($?>>8);
+
+    while (<$out>)
+    {
+	chomp;
+	print "OUT: $_\n" if $opt_v;
+
+	my ($name, $value) = split(/\s*:\s*/, $_);
+
+	if ($name eq "Node name")
+	{
+	    $host_name = $value;
+	    last;
+	}
+    }
+
+    close($in);
+    close($out);
+    close($err);
+
+    return $host_name;
+}
+
 sub get_options_stdin
 {
     my $opt;
@@ -107,10 +145,6 @@
 	{
 	    $opt_n = $val;
 	}
-	elsif ($name eq "self")
-	{
-	    $opt_s = $val;
-	}
 	elsif ($name eq "verbose")
 	{
 	    $opt_v = $val;
@@ -174,10 +208,11 @@
 
 sub fence_node
 {
-    # my $name = (POSIX::uname())[1];
+    my $host_name = get_host_name();
+    my $node_name = get_node_name();
 
-    my $host_key = get_key($opt_s);
-    my $node_key = get_key($opt_n);
+    my $host_key = get_key($host_name);
+    my $node_key = get_key($node_name);
     
     my $cmd;
     my ($in, $out, $err);
@@ -197,18 +232,14 @@
 
 	waitpid($pid, 0);
 
-	if ($opt_v)
+	die "Unable to execute sg_persist.\n" if ($?>>8);
+
+	while (<$out>)
 	{
-	    print "$cmd\n";
-	    while (<$out>)
-	    {
-		chomp;
-		print "OUT: $_\n";
-	    }
+	    chomp;
+	    print "OUT: $_\n" if $opt_v;
 	}
 
-	die "Unable to execute sg_persist.\n" if ($?>>8);
-
 	close($in);
 	close($out);
 	close($err);
@@ -225,15 +256,14 @@
     version if defined $opt_V;
 
     fail_usage "Unkown parameter." if (@ARGV > 0);
+
     fail_usage "No '-n' flag specified." unless defined $opt_n;
-    fail_usage "No '-s' flag specified." unless defined $opt_s;
 
 } else {
 
     get_options_stdin();
 
     fail "failed: missing 'node'" unless defined $opt_n;
-    fail "failed: missing 'self'" unless defined $opt_s;
 
 }
 
@@ -242,3 +272,4 @@
 get_scsi_devices;
 
 fence_node;
+



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-07 19:40 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-07 19:40 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL4
Changes by:	rohara at sourceware.org	2006-12-07 19:40:43

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Fix get_options_stdin routine, which was incorrectly named get_option_stdin.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=1.5.6.3&r2=1.5.6.4

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/12/01 17:53:07	1.5.6.3
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/07 19:40:43	1.5.6.4
@@ -109,7 +109,7 @@
     return $host_name;
 }
 
-sub get_option_stdin
+sub get_options_stdin
 {
     my $opt;
     mt $line = 0;



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-07 19:43 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-07 19:43 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL4
Changes by:	rohara at sourceware.org	2006-12-07 19:43:04

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Fix variable declaration.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=1.5.6.4&r2=1.5.6.5

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/12/07 19:40:43	1.5.6.4
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/07 19:43:04	1.5.6.5
@@ -112,7 +112,7 @@
 sub get_options_stdin
 {
     my $opt;
-    mt $line = 0;
+    my $line = 0;
 
     while (defined($in = <>))
     {



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-07 20:04 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-07 20:04 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL4
Changes by:	rohara at sourceware.org	2006-12-07 20:04:17

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Fix problem when parsing the output from lvs command.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=1.5.6.5&r2=1.5.6.6

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/12/07 19:43:04	1.5.6.5
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/07 20:04:17	1.5.6.6
@@ -175,7 +175,7 @@
 
 	if ($vg_attrs =~ /.*c$/)
 	{
-	    $device =~ s/\(.*\)://;
+	    $device =~ s/\(.*\)//;
 	    push @volumes, $device;
 	}
     }



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-08 21:23 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-08 21:23 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL5
Changes by:	rohara at sourceware.org	2006-12-08 21:23:00

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Fix split calls to be consistent. Remove the optional LIMIT parameter.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.5.2.1&r2=1.5.2.2

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/12/01 17:53:22	1.5.2.1
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/08 21:23:00	1.5.2.2
@@ -12,7 +12,7 @@
 
 # WARNING!! Do not add code bewteen "#BEGIN_VERSION_GENERATION" and
 # "#END_VERSION_GENERATION"  It is generated by the Makefile
-                                                                                
+
 #BEGIN_VERSION_GENERATION
 $FENCE_RELEASE_NAME="";
 $REDHAT_COPYRIGHT="";
@@ -131,7 +131,7 @@
 
 	next unless $opt;
 
-	($name, $val) = split /\s*=\s*/, $opt;
+	($name, $val) = split(/\s*=\s*/, $opt);
 
 	if ($name eq "")
 	{
@@ -171,7 +171,7 @@
 	chomp;
 	print "OUT: $_\n" if $opt_v;
 
-	my ($vg_attrs, $device) = split /:/, $_, 3;
+	my ($vg_attrs, $device) = split(/:/, $_);
 
 	if ($vg_attrs =~ /.*c$/)
 	{



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-12 22:22 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-12 22:22 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL4
Changes by:	rohara at sourceware.org	2006-12-12 22:22:30

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Rewrite of get_scsi_devices function.
	It is no longer possible to use lvs to get a list of cluster volumes (and
	underlying devices) at fence time. For this reason we must "keep state"
	by recording which devices we register with at startup. The init script
	(scsi_reserve) will record each device it successfully registered with to
	a file (/var/run/scsi_reserve). Then, and fence time, the fence_scsi agent
	will unregister each device listed in the state file.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=1.5.6.6&r2=1.5.6.7

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/12/07 20:04:17	1.5.6.6
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/12 22:22:30	1.5.6.7
@@ -156,33 +156,46 @@
     }
 }
 
+#sub get_scsi_devices
+#{
+#    my ($in, $out, $err);
+#    my $cmd = "lvs --noheadings --separator : -o vg_attr,devices";
+#    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+#
+#    waitpid($pid, 0);
+#
+#    die "Unable to execute lvs.\n" if ($?>>8);
+#
+#    while (<$out>)
+#    {
+#	chomp;
+#	print "OUT: $_\n" if $opt_v;
+#
+#	my ($vg_attrs, $device) = split(/:/, $_);
+#
+#	if ($vg_attrs =~ /.*c$/)
+#	{
+#	    $device =~ s/\(.*\)//;
+#	    push(@volumes, $device);
+#	}
+#    }
+#
+#    close($in);
+#    close($out);
+#    close($err);
+#}
+
 sub get_scsi_devices
 {
-    my ($in, $out, $err);
-    my $cmd = "lvs --noheadings --separator : -o vg_attr,devices";
-    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
-
-    waitpid($pid, 0);
-
-    die "Unable to execute lvs.\n" if ($?>>8);
+    open(FILE, "/var/run/scsi_reserve") or die "$!\n";
 
-    while (<$out>)
+    while (<FILE>)
     {
 	chomp;
-	print "OUT: $_\n" if $opt_v;
-
-	my ($vg_attrs, $device) = split(/:/, $_);
-
-	if ($vg_attrs =~ /.*c$/)
-	{
-	    $device =~ s/\(.*\)//;
-	    push @volumes, $device;
-	}
+	push(@volumes, $_);
     }
 
-    close($in);
-    close($out);
-    close($err);
+    close FILE;
 }
 
 sub check_sg_persist



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-12 22:22 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-12 22:22 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL5
Changes by:	rohara at sourceware.org	2006-12-12 22:22:51

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Rewrite of get_scsi_devices function.
	It is no longer possible to use lvs to get a list of cluster volumes (and
	underlying devices) at fence time. For this reason we must "keep state"
	by recording which devices we register with at startup. The init script
	(scsi_reserve) will record each device it successfully registered with to
	a file (/var/run/scsi_reserve). Then, and fence time, the fence_scsi agent
	will unregister each device listed in the state file.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.5.2.2&r2=1.5.2.3

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/12/08 21:23:00	1.5.2.2
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/12 22:22:51	1.5.2.3
@@ -156,33 +156,46 @@
     }
 }
 
+#sub get_scsi_devices
+#{
+#    my ($in, $out, $err);
+#    my $cmd = "lvs --noheadings --separator : -o vg_attr,devices";
+#    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+#
+#    waitpid($pid, 0);
+#
+#    die "Unable to execute lvs.\n" if ($?>>8);
+#
+#    while (<$out>)
+#    {
+#	chomp;
+#	print "OUT: $_\n" if $opt_v;
+#
+#	my ($vg_attrs, $device) = split(/:/, $_);
+#
+#	if ($vg_attrs =~ /.*c$/)
+#	{
+#	    $device =~ s/\(.*\)//;
+#	    push @volumes, $device;
+#	}
+#    }
+#
+#    close($in);
+#    close($out);
+#    close($err);
+#}
+
 sub get_scsi_devices
 {
-    my ($in, $out, $err);
-    my $cmd = "lvs --noheadings --separator : -o vg_attr,devices";
-    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
-
-    waitpid($pid, 0);
-
-    die "Unable to execute lvs.\n" if ($?>>8);
+    open(FILE, "/var/run/scsi_reserve") or die "$!\n";
 
-    while (<$out>)
+    while (<FILE>)
     {
 	chomp;
-	print "OUT: $_\n" if $opt_v;
-
-	my ($vg_attrs, $device) = split(/:/, $_);
-
-	if ($vg_attrs =~ /.*c$/)
-	{
-	    $device =~ s/\(.*\)//;
-	    push @volumes, $device;
-	}
+	push(@volumes, $_);
     }
 
-    close($in);
-    close($out);
-    close($err);
+    close FILE;
 }
 
 sub check_sg_persist



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-14 21:16 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-14 21:16 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL4
Changes by:	rohara at sourceware.org	2006-12-14 21:16:36

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Attempt to register the node in the case where it must perform fence_scsi
	fencing but is not registered with the device(s) that must be fence. With
	SCSI persistent reservations, in order to do a "preempt and abort" (which
	we are using to fence a node), the node doing this operation must be
	registered with the device. This fix will check to see the the node that
	is performing the fencing is registered with the device(s). If it is not,
	then it attempts to register with the device(s) so that it can then
	continue with the fence operation normally. Note that this situation should
	never happen, especially if things are configured properly.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL4&r1=1.5.6.7&r2=1.5.6.8

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/12/12 22:22:30	1.5.6.7
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/14 21:16:36	1.5.6.8
@@ -156,6 +156,38 @@
     }
 }
 
+sub get_key_list
+{
+    ($dev) = @_;
+
+    my ($in, $out, $err);
+    my $cmd = "sg_persist -d $dev -i -k";
+    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+    waitpid($pid, 0);
+
+    die "Unable to execute sg_persist.\n" if ($?>>8);
+
+    while (<$out>)
+    {
+	chomp;
+	if ($_ =~ /^\s*0x/)
+	{
+	    s/^\s+0x//;
+	    s/\s+$//;
+
+	    my $key = sprintf("%8.8x", hex($_));
+	    $key_list{$key} = 1;
+	}
+    }
+
+    close($in);
+    close($out);
+    close($err);
+
+    return %key_list;
+}
+
 #sub get_scsi_devices
 #{
 #    my ($in, $out, $err);
@@ -219,6 +251,29 @@
     close($err);
 }
 
+sub do_register
+{
+    ($dev, $key) = @_;
+
+    my ($in, $out, $err);
+    my $cmd = "sg_persist -d $dev -o -G -S $key";
+    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+    waitpid($pid, 0);
+
+    die "Unable to execute sg_persist.\n" if ($?>>8);
+
+    while (<$out>)
+    {
+	chomp;
+	print "OUT: $_\n" if $opt_v;
+    }
+
+    close($in);
+    close($out);
+    close($err);
+}
+
 sub fence_node
 {
     my $host_name = get_host_name();
@@ -227,11 +282,17 @@
     my $host_key = get_key($host_name);
     my $node_key = get_key($node_name);
 
-    my $cmd;
     my ($in, $out, $err);
 
     foreach $dev (@volumes)
     {
+	my %key_list = get_key_list($dev);
+
+	if (!$key_list{$host_key})
+	{
+	    do_register($dev, $host_key);
+	}
+
 	if ($host_key eq $node_key)
 	{
 	    $cmd = "sg_persist -d $dev -o -G -K $host_key -S 0";



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2006-12-14 21:18 rohara
  0 siblings, 0 replies; 19+ messages in thread
From: rohara @ 2006-12-14 21:18 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL5
Changes by:	rohara at sourceware.org	2006-12-14 21:18:09

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	Attempt to register the node in the case where it must perform fence_scsi
	fencing but is not registered with the device(s) that must be fence. With
	SCSI persistent reservations, in order to do a "preempt and abort" (which
	we are using to fence a node), the node doing this operation must be
	registered with the device. This fix will check to see the the node that
	is performing the fencing is registered with the device(s). If it is not,
	then it attempts to register with the device(s) so that it can then
	continue with the fence operation normally. Note that this situation should
	never happen, especially if things are configured properly.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.5.2.3&r2=1.5.2.4

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/12/12 22:22:51	1.5.2.3
+++ cluster/fence/agents/scsi/fence_scsi.pl	2006/12/14 21:18:09	1.5.2.4
@@ -156,6 +156,38 @@
     }
 }
 
+sub get_key_list
+{
+    ($dev) = @_;
+
+    my ($in, $out, $err);
+    my $cmd = "sg_persist -d $dev -i -k";
+    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+    waitpid($pid, 0);
+
+    die "Unable to execute sg_persist.\n" if ($?>>8);
+
+    while (<$out>)
+    {
+	chomp;
+	if ($_ =~ /^\s*0x/)
+	{
+	    s/^\s+0x//;
+	    s/\s+$//;
+
+	    my $key = sprintf("%8.8x", hex($_));
+	    $key_list{$key} = 1;
+	}
+    }
+
+    close($in);
+    close($out);
+    close($err);
+
+    return %key_list;
+}
+
 #sub get_scsi_devices
 #{
 #    my ($in, $out, $err);
@@ -176,7 +208,7 @@
 #	if ($vg_attrs =~ /.*c$/)
 #	{
 #	    $device =~ s/\(.*\)//;
-#	    push @volumes, $device;
+#	    push(@volumes, $device);
 #	}
 #    }
 #
@@ -219,6 +251,29 @@
     close($err);
 }
 
+sub do_register
+{
+    ($dev, $key) = @_;
+
+    my ($in, $out, $err);
+    my $cmd = "sg_persist -d $dev -o -G -S $key";
+    my $pid = open3($in, $out, $err, $cmd) or die "$!\n";
+
+    waitpid($pid, 0);
+
+    die "Unable to execute sg_persist.\n" if ($?>>8);
+
+    while (<$out>)
+    {
+	chomp;
+	print "OUT: $_\n" if $opt_v;
+    }
+
+    close($in);
+    close($out);
+    close($err);
+}
+
 sub fence_node
 {
     my $host_name = get_host_name();
@@ -226,12 +281,18 @@
 
     my $host_key = get_key($host_name);
     my $node_key = get_key($node_name);
-    
-    my $cmd;
+
     my ($in, $out, $err);
 
     foreach $dev (@volumes)
     {
+	my %key_list = get_key_list($dev);
+
+	if (!$key_list{$host_key})
+	{
+	    do_register($dev, $host_key);
+	}
+
 	if ($host_key eq $node_key)
 	{
 	    $cmd = "sg_persist -d $dev -o -G -K $host_key -S 0";



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2007-09-21  3:08 rmccabe
  0 siblings, 0 replies; 19+ messages in thread
From: rmccabe @ 2007-09-21  3:08 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Changes by:	rmccabe at sourceware.org	2007-09-21 03:08:06

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	fix bz277781 by accepting "nodename" as a synonym for "node"

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&r1=1.6&r2=1.7

--- cluster/fence/agents/scsi/fence_scsi.pl	2007/08/22 08:58:40	1.6
+++ cluster/fence/agents/scsi/fence_scsi.pl	2007/09/21 03:08:06	1.7
@@ -107,6 +107,10 @@
 	{
 	    $opt_n = $val;
 	}
+	elsif ($name eq "nodename")
+	{
+	    $opt_n = $val;
+	}
 	elsif ($name eq "self")
 	{
 	    $opt_s = $val;



^ permalink raw reply	[flat|nested] 19+ messages in thread

* [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl
@ 2007-09-21  3:09 rmccabe
  0 siblings, 0 replies; 19+ messages in thread
From: rmccabe @ 2007-09-21  3:09 UTC (permalink / raw)
  To: cluster-devel.redhat.com

CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	RHEL5
Changes by:	rmccabe at sourceware.org	2007-09-21 03:09:04

Modified files:
	fence/agents/scsi: fence_scsi.pl 

Log message:
	fix bz277781 by accepting "nodename" as a synonym for "node"

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/fence/agents/scsi/fence_scsi.pl.diff?cvsroot=cluster&only_with_tag=RHEL5&r1=1.5.2.4&r2=1.5.2.5

--- cluster/fence/agents/scsi/fence_scsi.pl	2006/12/14 21:18:09	1.5.2.4
+++ cluster/fence/agents/scsi/fence_scsi.pl	2007/09/21 03:09:04	1.5.2.5
@@ -145,6 +145,10 @@
 	{
 	    $opt_n = $val;
 	}
+	elsif ($name eq "nodename")
+	{
+	    $opt_n = $val;
+	}
 	elsif ($name eq "verbose")
 	{
 	    $opt_v = $val;



^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2007-09-21  3:09 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-29 20:14 [Cluster-devel] cluster/fence/agents/scsi fence_scsi.pl rohara
  -- strict thread matches above, loose matches on Subject: below --
2007-09-21  3:09 rmccabe
2007-09-21  3:08 rmccabe
2006-12-14 21:18 rohara
2006-12-14 21:16 rohara
2006-12-12 22:22 rohara
2006-12-12 22:22 rohara
2006-12-08 21:23 rohara
2006-12-07 20:04 rohara
2006-12-07 19:43 rohara
2006-12-07 19:40 rohara
2006-12-01 20:24 rohara
2006-12-01 17:53 rohara
2006-12-01 17:53 rohara
2006-11-29 23:19 rohara
2006-07-12 20:34 rohara
2006-07-10 18:53 rohara
2006-07-06 21:58 rohara
2006-07-06 16:23 rohara

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).