view release on metacpan or search on metacpan
examples/Meltdown.pl view on Meta::CPAN
# rxdebug commands.
#
use blib;
use AFS::Monitor;
sub Usage {
print STDERR "\n\n$progName: collect rxdebug stats on AFS process.\n";
print STDERR "usage: $progName [options]\n";
print STDERR "options:\n";
print STDERR " -s <server> (required parameter, no default).\n";
print STDERR " -p <port> (default: 7000).\n";
print STDERR " -t <interval> (default: 1200 seconds).\n";
print STDERR " -C \n";
print STDERR " -h (help: show this help message).\n\n";
print STDERR "Example: $progName -s point -p 7000\n";
print STDERR "Collect statistics on server point for port 7000\n";
print STDERR "Refresh interval will default to 20 minutes (1200 seconds)\n\n";
exit 0;
} # Usage
sub Check_data {
#
# If a value is going to overflow the field length,
# then bump the field length to match the value.
# It won't be pretty but we'll have valid data.
#
(length $wproc > $Ln[0]) ? ($Ln[0] = length $wproc) : "";
examples/Meltdown.pl view on Meta::CPAN
$progName = $0;
$tmpName= "";
GETPROG: while ($letr = chop($progName)) {
$_ = $letr;
/\// && last GETPROG;
$tmpName .= $letr;
}
$progName = reverse($tmpName);
#
# set the defaults for server, port, and delay interval
#
$server = "";
$port = 7000;
$delay = 1200;
$csvmove = 0;
#
# any parms?
#
while ($_ = shift(@ARGV)) {
examples/Meltdown.pl view on Meta::CPAN
$wpack = 0;
$fpack = 0;
$calls = 0;
$data = 0;
$resend = 0;
$nobuf = 0;
$idle = 0;
$oldcall = 0;
#
# set the default field format lengths for
# wproc,nobuf,wpack,fpack,calls,delta,data,resend,idle
#
@Ln = (5,8,6,8,9,6,9,8,4);
#
# force header display on first call
#
$firstrun = 1;
#
examples/rxdebug view on Meta::CPAN
my $onlyauth = 'auth'; # some of the tests will show only connections with this auth level
my @tests; # choose which tests to run
$tests[1] = 1; # prints version
$tests[2] = 0; # prints all peers and all non-dallying connections.
# (can be long)
$tests[3] = 0; # nonexistant host
$tests[4] = 0; # nonexistant port
$tests[5] = 0; # bad port; getstats fails. (can be slow)
$tests[6] = 0; # prints long version of all peers. (can be long)
$tests[7] = 0; # server $servers port $port. prints default info.
$tests[8] = 0; # prints rxstats, no connections.
$tests[9] = 0; # prints only auth $onlyauth
$tests[10] = 0; # shows all connections. (can be long)
$tests[11] = 0; # shows all server connections. (can be long)
$tests[12] = 0; # shows all client connections on port $port from host $onlyhost
$tests[13] = 0; # doesn't give port, tries default (7000).
$tests[14] = 0; # no arguments, runs on current machine with default port.
$tests[15] = 0; # port $port, runs on current machine.
$tests[16] = 0; # prints rxstats, all connections, long version of all peers.
# (can be very long)
my $all = 1; # show all tests
my $showdump = 0; # dump contents of hash to the screen for each test instead of printing rxdebug formatted output
# all available options:
# rxdebug(nodally => 1,
pod/afsmonitor.pod view on Meta::CPAN
);
=head1 DESCRIPTION
The B<afsmonitor> function gathers statistics about specified File Server
and Cache Manager operations. It allows the issuer to monitor, from a
single location, a wide range of File Server and Cache Manager
operations on any number of machines in both local and foreign cells.
There are 271 available File Server statistics and 571 available Cache
Manager statistics, listed in the L<afsmon_stats(1)> documentation. By default,
the command displays all of the relevant statistics for the file server
machines named by the B<fshosts> argument and the client machines named
by the B<cmhosts> argument. To limit the display to only the statistics
of interest, list them in the configuration file specified by the
B<config> argument. In addition, use the configuration file for the
following purposes:
=over
=item *
To set threshold values for any statistic. The statistics with values exceeding
their thresholds are indicated in the returned data structure. There are no
default threshold values.
=item *
To specify a program or script to associate with a statistic when it exceeds its
threshold. The script and all of it's arguments will be included in the returned
data structure in a format easy to invoke from within a Perl script. The AFS
distribution does not include any such scripts.
=item *
pod/afsmonitor.pod view on Meta::CPAN
Names the configuration file which lists the machines to probe,
statistics to display, and threshold values, if any. A partial
pathname is interpreted relative to the current working directory.
Provide this argument if not providing the B<fshosts> argument or
B<cmhosts> argument. For instructions on creating this file, see the
L<"configuration file"|/"THE CONFIGURATION FILE"> section below.
=item B<output>
Names the file to which the B<afsmonitor> function writes all of the
statistics that it collects. By default, no output file is created.
See the L<"writing to an output file"|/"WRITING TO AN OUTPUT FILE">
section below for more information on this file.
=item B<detailed>
Formats the information in the output file named by B<output> argument in a
maximally readable format. Provide the B<output> argument along with this one.
=item B<fshosts>
pod/afsmonitor.pod view on Meta::CPAN
an abbreviation depends on the state of the cell's name service
at the time the command is issued). This argument can be combined
with the B<fshosts> argument, but not with the B<config> argument.
=item B<fsshow>
Reference to an array with the names of individual statistics, groups of
statistics, or sections of statistics to include in the File Servers (fs)
data structure. Use this only if not using a configuration file. The
L<afsmon_stats(1)> documentation specifies the group and section to which
each statistic belongs. By default, all of the statistics will be included.
=item B<cmshow>
Reference to an array with the names of individual statistics, groups of
statistics, or sections of statistics to include in the Cache Managers (cm)
data structure. Use thi sonly if not using a configuration file. The
L<afsmon_stats(1)> documentation specifies the group and section to which
each statistic belongs. By default, all of the statistics will be included.
=item B<fsthresh>
Reference to an array of hash references containing thresholds to set. Each
hash should contain a key that is the name of an individual File Server
statistic, with it's value being the desired threshold value for that
statistic. If it is a host-specific threshold, then the key B<host> should
be included, with a value corresponding to one of the File Server hosts
specified in the B<fshosts> argument. If a handler function is to be
associated with the threshold, the key B<handler>'s value should be the name
pod/afsmonitor.pod view on Meta::CPAN
can specify the following in the configuration file:
=over
=item *
The File Servers, Cache Managers, or both, to gather statistics on.
=item *
The statistics to display. By default, the display includes 271
statistics for File Servers and 571 statistics for Cache Managers.
For information on the available statistics, see the L<afsmon_stats(1)>
documentation.
=item *
The threshold values to set for statistics and a script or program
to associate with the statistic if a threshold is exceeded. By
default, no threshold values are defined.
=back
The following list describes the instructions that can appear
in the configuration file:
=over
=item B<cm I<host_name>>
pod/rxdebug.pod view on Meta::CPAN
=back
=item B<nodally>
Produces output only for connections that are not in dally mode. Dally mode is
a state in which the connection is idle or waiting.
=item B<allconnections>
Produces output for all connections, even inactive ones. By default, the output
includes information only for connections that are active or in dally mode.
=item B<rxstats>
Produces detailed statistics about Rx history and performance (for example,
counts of the number of packets of various types the process has read and sent,
calculations of average and minimum roundtrip time, and so on).
=item B<onlyserver>
pod/udebug.pod view on Meta::CPAN
=item *
B<vlserver> or B<7003> for the Volume Location Server
=back
=item B<long>
Reports additional information about each peer of the machine
named by the B<server> argument. The information appears by
default if that machine is the synchronization site.
=back
=head1 OUTPUT
Returns a reference to a hash containing all of the collected data.
Below is a list of keys that the hash may contain:
=over
src/Makefile.PL view on Meta::CPAN
-laudit
)
)
],
'realclean' => {FILES => 'Makefile.bak lib'},
);
if ($Config{osname} =~ /aix/) {
$MakefileArgs{LIBS}->[0] .= ' -ldl';
} elsif ($Config{osname} =~ /irix/) {
# just the default LIBS
} elsif ($Config{osname} =~ /solaris/) {
$MakefileArgs{DEFINE} .= ' -Dint32=afs_int32 -Duint32=afs_uint32' if $alpha_sys eq 'sun4x_56'; # From Peter@PSDT.com
$MakefileArgs{LIBS}->[0] .= ' -lresolv -lsocket -lnsl -lintl -ldl';
$MakefileArgs{CC} = 'gcc';
#$MakefileArgs{LD} = 'gcc';
$MakefileArgs{CCCDLFLAGS} = '-fPIC';
$MakefileArgs{LIBS}->[0] .= " -R$AFSPath/lib";
} elsif ($Config{osname} =~ /linux/) {
$MakefileArgs{LIBS}->[0] .= ' -lresolv';
### $MakefileArgs{LDFLAGS} = "-Wl,-rpath -Wl,$AFSPath/lib";
} elsif ($Config{osname} =~ /darwin/) {
$MakefileArgs{LDDLFLAGS} = $Config{lddlflags} . ' -lresolv -multiply_defined suppress -read_only_relocs suppress';
}
# elsif ($Config{osname} =~ /dec_osf/) {
# # hier fehlt noch was !!!!!
# }
else {
warn("System type '$Config{osname}' not yet tested with this Makefile.PL...\n\n"
. "Using the default values, which may or may not work\n"
. "If it is working, please inform the maintainer of this package.\n"
. "Thank you.\n\n");
}
WriteMakefile(%MakefileArgs);
# change the library name of the AFS system library "util.a"
my $command = "\'s#-lutil#$AFSPath/lib/afs/util.a#\'";
system("perl -p -i.bak -e $command Makefile") unless -f "$AFSPath/lib/afs/libutil.a";
src/Monitor.xs view on Meta::CPAN
case 0: /* its a global threshold */
(*global_fsThreshCount)++;
break;
case 1: /* inc thresh count of last file server */
last_hostEntry->numThresh++;
break;
case 2:
sprintf(buffer,
"A threshold for a File Server cannot be placed after a Cache Manager host entry in the config file");
return (-1);
default:
sprintf(buffer, "Programming error 1");
return (-1);
}
}
else if ((strcasecmp(arg1, "cm")) == 0) {
switch (lastHostType) {
case 0: /* its a global threshold */
(*global_cmThreshCount)++;
break;
case 2: /* inc thresh count of last cache manager */
last_hostEntry->numThresh++;
break;
case 1:
sprintf(buffer,
"A threshold for a Cache Manager cannot be placed after a File Server host entry in the config file");
return (-1);
default:
sprintf(buffer, "Programming error 2");
return (-1);
}
}
else {
sprintf(buffer,
"Syntax error. Second argument should be \"fs\" or \"cm\"");
return (-1);
}
src/Monitor.xs view on Meta::CPAN
* Bump the current fsprobe connection to set up.
*/
curr_conn++;
} /*for curr_srv */
/*
* Create the AFS callback service (listener).
*/
if (scout_debugfd)
fprintf(scout_debugfd, "[%s] Creating AFS callback listener\n", rn);
rxsrv_afsserver = rx_NewService(0, /*Use default port */
1, /*Service ID */
"afs", /*Service name */
&CBsecobj, /*Ptr to security object(s) */
1, /*Number of security objects */
RXAFSCB_ExecuteRequest); /*Dispatcher */
if (rxsrv_afsserver == (struct rx_service *) NULL) {
/*Delete already-malloc'ed areas */
my_fsprobe_Cleanup(fsprobe_Results, *fsprobe_ConnInfo, a_numServers,
scout_debugfd, buff2);
sprintf(buffer, "[%s] Can't create callback Rx service/listener. %s",
src/Monitor.xs view on Meta::CPAN
case AFS_XSTATSCOLL_FULL_PERF_INFO:
my_fs_PrintFullPerfInfo(&xstat_fs_Results, HOSTINFO);
break;
#ifndef NOAFS_XSTATSCOLL_CBSTATS
case AFS_XSTATSCOLL_CBSTATS:
my_fs_PrintCbCounters(&xstat_fs_Results, HOSTINFO);
break;
#endif
default:
sprintf(buffer, "** Unknown collection: %d",
xstat_fs_Results.collectionNumber);
return (-1);
}
}
av_store(RETVAL, index, newRV_inc((SV *) HOSTINFO));
return (0);
}
src/Monitor.xs view on Meta::CPAN
case AFSCB_XSTATSCOLL_PERF_INFO:
/* we will do nothing here */
/* PrintPerfInfo(); */
my_cm_PrintPerfInfo(&xstat_cm_Results, HOSTINFO);
break;
case AFSCB_XSTATSCOLL_FULL_PERF_INFO:
my_cm_PrintFullPerfInfo(&xstat_cm_Results, HOSTINFO);
break;
default:
sprintf(buffer, "** Unknown collection: %d",
xstat_cm_Results.collectionNumber);
return (-1);
}
}
av_store(RETVAL, index, newRV_inc((SV *) HOSTINFO));
return (0);
}
src/Monitor.xs view on Meta::CPAN
if (SvROK(value))
host_array = (AV*) SvRV(value);
else {
host_array = av_make(1, &value);
sv_2mortal((SV *) host_array);
}
numFSs = av_len(host_array) + 1;
} else goto unrecognized;
break;
default:
unrecognized:
sprintf(buffer, "Unrecognized flag: %s", key);
BSETCODE(-1, buffer);
XSRETURN_UNDEF;
break;
} /* end switch */
} /* end while */
/* done parsing arguments */
if (host_array == 0) {
src/Monitor.xs view on Meta::CPAN
if (SvROK(value))
host_array = (AV*) SvRV(value);
else {
host_array = av_make(1, &value);
sv_2mortal((SV *) host_array);
}
numservers = av_len(host_array) + 1;
} else goto unrecognized;
break;
default:
unrecognized:
sprintf(buffer, "Unrecognized flag: %s", key);
BSETCODE(-1, buffer);
XSRETURN_UNDEF;
break;
} /* end switch */
} /* end while */
/* done parsing arguments */
if(numservers == 0) {
src/Monitor.xs view on Meta::CPAN
portName = (char *) SvPV(value, PL_na);
} else goto unrecognized;
break;
case 's':
if(strncmp(key, "server", keylen) == 0 && keylen <= 6) {
hostName = (char *) SvPV(value, PL_na);
} else goto unrecognized;
break;
default:
unrecognized:
sprintf(buffer, "Unrecognized flag: %s", key);
BSETCODE(-1, buffer);
XSRETURN_UNDEF;
break;
} /* end switch */
} /* end while */
/* done parsing arguments */
src/Monitor.xs view on Meta::CPAN
sprintf(buffer, "udebug: host %s not found in host table", hostName);
BSETCODE(1, buffer);
XSRETURN_UNDEF;
}
memcpy(&hostAddr, th->h_addr, sizeof(afs_int32));
}
else hostAddr = htonl(0x7f000001); /* IP localhost */
if (!portName)
port = htons(3000); /* default */
else {
port = udebug_PortNumber(portName);
if (port < 0)
port = udebug_PortName(portName);
if (port < 0) {
sprintf(buffer, "udebug: can't resolve port name %s", portName);
BSETCODE(1, buffer);
XSRETURN_UNDEF;
}
port = htons(port);
src/Monitor.xs view on Meta::CPAN
port = (int) SvIV(value);
} else goto unrecognized;
break;
case 's':
if(strncmp(key, "servers", keylen) == 0 && keylen <= 7) {
hostName = (char *) SvPV(value, PL_na);
} else goto unrecognized;
break;
default:
unrecognized:
sprintf(buffer, "Unrecognized flag: %s", key);
BSETCODE(-1, buffer);
XSRETURN_UNDEF;
break;
} /* end switch */
} /* end while */
/* done parsing arguments */
rx_Init(0);
src/Monitor.xs view on Meta::CPAN
}
}
} else goto unrecognized;
break;
case 't':
if(strncmp(key, "cmthresh", keylen) == 0 && keylen <= 8) {
/* fprintf(STDERR, "flag %s recognized as cmthresh\n", key); */
cmthresh_array = (AV*) SvRV(value);
} else goto unrecognized;
break;
default:
goto unrecognized;
}
break;
default:
goto unrecognized;
}
break;
case 'd':
if(strncmp(key, "detailed", keylen) == 0 && keylen <= 8) {
/* fprintf(STDERR, "flag %s recognized as detailed; value is %d\n",
key, (int) SvIV(value)); */
detailed = (int) SvIV(value);
} else goto unrecognized;
src/Monitor.xs view on Meta::CPAN
}
}
} else goto unrecognized;
break;
case 't':
if(strncmp(key, "fsthresh", keylen) == 0 && keylen <= 8) {
/* fprintf(STDERR, "flag %s recognized as fsthresh\n", key); */
fsthresh_array = (AV*) SvRV(value);
} else goto unrecognized;
break;
default:
goto unrecognized;
}
break;
case 'o':
if(strncmp(key, "output", keylen) == 0 && keylen <= 6) {
/* fprintf(STDERR, "flag %s recognized as output; value is %s\n",
key, (char *) SvPV(value, PL_na)); */
output_filename = (char *) SvPV(value, PL_na);
} else goto unrecognized;
break;
default:
unrecognized:
/* fprintf(STDERR,
"flag not recognized. (key: %s) (value: %s)\n",
key, (char *) SvPV(value, PL_na)); */
sprintf(buffer, "Unrecognized flag: %s", key);
BSETCODE(-1, buffer);
XSRETURN_UNDEF;
} /* end switch */
} /* end while */
/* done parsing arguments */
src/Monitor.xs view on Meta::CPAN
hostName = (char *) SvPV(value, PL_na);
}
break;
case 'v':
if (memcmp( flag, "version", 7) == 0 ) {
version_flag = (int) SvIV(value);
}
break;
default:
break;
} /* switch */
} /* while */
/* fprintf(STDERR, "Done parsing args\n\n"); */
/* lookup host */
if (hostName) {
th = hostutil_GetHostByName(hostName);
if (!th) {
sprintf(buffer, "rxdebug: host %s not found in host table", hostName);
VSETCODE(-1, buffer);
XSRETURN_UNDEF;
}
memcpy(&host, th->h_addr, sizeof(afs_int32));
}
else host = htonl(0x7f000001); /* IP localhost */
if (!portName)
port = htons(7000); /* default is fileserver */
else {
if ((port = rxdebug_PortNumber(portName)) == -1)
port = rxdebug_PortName(portName);
if (port == -1) {
sprintf(buffer, "rxdebug: can't resolve port name %s", portName);
VSETCODE(-1, buffer);
XSRETURN_UNDEF;
}
}
src/Monitor.xs view on Meta::CPAN
return;
}
break;
case '_':
if (strEQ(name,"AF_INET")) sv_setiv(ST(0),AF_INET);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'C':
switch (name[1]) {
case 'F':
switch (name[2]) {
case 'G':
if (strEQ(name,"CFG_STR_LEN"))
sv_setiv(ST(0),CFG_STR_LEN);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'M':
if (strEQ(name,"CM")) sv_setiv(ST(0),CM);
else {
switch (name[2]) {
case '_':
if (strEQ(name,"CM_NUM_DATA_CATEGORIES"))
sv_setiv(ST(0),CM_NUM_DATA_CATEGORIES);
else if (strEQ(name,"CM_STAT_STRING_LEN"))
sv_setiv(ST(0),CM_STAT_STRING_LEN);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'F':
switch (name[1]) {
case 'S':
if (strEQ(name,"FS")) sv_setiv(ST(0),FS);
else {
switch (name[2]) {
src/Monitor.xs view on Meta::CPAN
sv_setiv(ST(0),FS_STATS_NUM_RPC_OPS);
else if (strEQ(name,"FS_STATS_NUM_XFER_OPS"))
sv_setiv(ST(0),FS_STATS_NUM_XFER_OPS);
else if (strEQ(name,"FS_STAT_STRING_LEN"))
sv_setiv(ST(0),FS_STAT_STRING_LEN);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'H':
switch (name[1]) {
case 'O':
switch (name[2]) {
case 'S':
if (strEQ(name,"HOST_NAME_LEN"))
sv_setiv(ST(0),HOST_NAME_LEN);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'M':
switch (name[1]) {
case 'A':
switch (name[2]) {
case 'X':
if (strEQ(name,"MAXSKEW"))
sv_setiv(ST(0),MAXSKEW);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'N':
switch (name[1]) {
case 'U':
switch (name[2]) {
case 'M':
if (strEQ(name,"NUM_AFS_STATS_CMPERF_LONGS"))
src/Monitor.xs view on Meta::CPAN
sv_setiv(ST(0),NUM_CM_STAT_ENTRIES);
else if (strEQ(name,"NUM_FS_STAT_ENTRIES"))
sv_setiv(ST(0),NUM_FS_STAT_ENTRIES);
else if (strEQ(name,"NUM_XSTAT_FS_AFS_PERFSTATS_LONGS"))
sv_setiv(ST(0),NUM_XSTAT_FS_AFS_PERFSTATS_LONGS);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'P':
switch (name[1]) {
case 'A':
switch (name[2]) {
case 'R':
if (strEQ(name,"PARTVALID"))
sv_setiv(ST(0),PARTVALID);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'R':
switch (name[1]) {
case 'E':
switch (name[2]) {
case 'A':
if (strEQ(name,"READ_LOCK"))
sv_setiv(ST(0),READ_LOCK);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'X':
switch (name[2]) {
case 'G':
if (strEQ(name,"RXGEN_OPCODE"))
sv_setiv(ST(0),RXGEN_OPCODE);
else {
src/Monitor.xs view on Meta::CPAN
sv_setiv(ST(0),RX_STATE_HOLD);
else if (strEQ(name,"RX_STATE_NOTINIT"))
sv_setiv(ST(0),RX_STATE_NOTINIT);
else if (strEQ(name,"RX_STATE_PRECALL"))
sv_setiv(ST(0),RX_STATE_PRECALL);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'S':
switch (name[1]) {
case 'H':
switch (name[2]) {
case 'A':
if (strEQ(name,"SHARED_LOCK"))
sv_setiv(ST(0),SHARED_LOCK);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'O':
switch (name[2]) {
case 'C':
if (strEQ(name,"SOCK_DGRAM"))
sv_setiv(ST(0),SOCK_DGRAM);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'T':
switch (name[1]) {
case 'H':
switch (name[2]) {
case 'R':
if (strEQ(name,"THRESH_VAR_LEN"))
sv_setiv(ST(0),THRESH_VAR_LEN);
else if (strEQ(name,"THRESH_VAR_NAME_LEN"))
sv_setiv(ST(0),THRESH_VAR_NAME_LEN);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'U':
switch (name[1]) {
case 'B':
switch (name[2]) {
case 'I':
if (strEQ(name,"UBIK_MAX_INTERFACE_ADDR"))
sv_setiv(ST(0),UBIK_MAX_INTERFACE_ADDR);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'V':
switch (name[1]) {
case 'O':
switch (name[2]) {
case 'L':
if (strEQ(name,"VOLMAXPARTS"))
src/Monitor.xs view on Meta::CPAN
}
break;
case 'T':
if (strEQ(name,"VOTE_SERVICE_ID"))
sv_setiv(ST(0),VOTE_SERVICE_ID);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'W':
switch (name[1]) {
case 'R':
switch (name[2]) {
case 'I':
if (strEQ(name,"WRITE_LOCK"))
sv_setiv(ST(0),WRITE_LOCK);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
case 'X':
switch (name[1]) {
case 'S':
switch (name[2]) {
case 'T':
if (strEQ(name,"XSTAT_FS_CBPORT"))
sv_setiv(ST(0),XSTAT_FS_CBPORT);
else {
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
break;
default:
ST(0) = ST(1) = &PL_sv_undef;
return;
}
errno = 0;
XSRETURN(1);
return;
}