#184: Additional information for galera
Removing dependency to Env module #192
This commit is contained in:
parent
a8babd7e69
commit
5b55c92ac5
1 changed files with 7 additions and 7 deletions
|
@ -51,7 +51,7 @@ use Data::Dumper;
|
||||||
$Data::Dumper::Pair = " : ";
|
$Data::Dumper::Pair = " : ";
|
||||||
|
|
||||||
# for which()
|
# for which()
|
||||||
use Env;
|
#use Env;
|
||||||
|
|
||||||
# Set up a few variables for use in the script
|
# Set up a few variables for use in the script
|
||||||
my $tunerversion = "1.6.10";
|
my $tunerversion = "1.6.10";
|
||||||
|
@ -445,13 +445,13 @@ sub os_setup {
|
||||||
}
|
}
|
||||||
|
|
||||||
sub get_http_cli {
|
sub get_http_cli {
|
||||||
my $httpcli = which("curl", $PATH);
|
my $httpcli = which("curl", $ENV{'PATH'});
|
||||||
chomp($httpcli);
|
chomp($httpcli);
|
||||||
if ($httpcli) {
|
if ($httpcli) {
|
||||||
return $httpcli;
|
return $httpcli;
|
||||||
}
|
}
|
||||||
|
|
||||||
$httpcli = which("wget", $PATH);
|
$httpcli = which("wget", $ENV{'PATH'});
|
||||||
chomp($httpcli);
|
chomp($httpcli);
|
||||||
if ($httpcli) {
|
if ($httpcli) {
|
||||||
return $httpcli;
|
return $httpcli;
|
||||||
|
@ -608,7 +608,7 @@ sub mysql_setup {
|
||||||
$mysqladmincmd = $opt{mysqladmin};
|
$mysqladmincmd = $opt{mysqladmin};
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$mysqladmincmd = which("mysqladmin", $PATH);
|
$mysqladmincmd = which("mysqladmin", $ENV{'PATH'});
|
||||||
}
|
}
|
||||||
chomp($mysqladmincmd);
|
chomp($mysqladmincmd);
|
||||||
if ( !-e $mysqladmincmd && $opt{mysqladmin} ) {
|
if ( !-e $mysqladmincmd && $opt{mysqladmin} ) {
|
||||||
|
@ -624,7 +624,7 @@ sub mysql_setup {
|
||||||
$mysqlcmd = $opt{mysqlcmd};
|
$mysqlcmd = $opt{mysqlcmd};
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$mysqlcmd = which("mysql", $PATH);
|
$mysqlcmd = which("mysql", $ENV{'PATH'});
|
||||||
}
|
}
|
||||||
chomp($mysqlcmd);
|
chomp($mysqlcmd);
|
||||||
if ( !-e $mysqlcmd && $opt{mysqlcmd} ) {
|
if ( !-e $mysqlcmd && $opt{mysqlcmd} ) {
|
||||||
|
@ -701,7 +701,7 @@ sub mysql_setup {
|
||||||
exit 1;
|
exit 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
my $svcprop = which("svcprop", $PATH);
|
my $svcprop = which("svcprop", $ENV{'PATH'});
|
||||||
if ( substr( $svcprop, 0, 1 ) =~ "/" ) {
|
if ( substr( $svcprop, 0, 1 ) =~ "/" ) {
|
||||||
|
|
||||||
# We are on solaris
|
# We are on solaris
|
||||||
|
@ -3908,7 +3908,7 @@ sub dump_result {
|
||||||
sub which {
|
sub which {
|
||||||
my $prog_name = shift;
|
my $prog_name = shift;
|
||||||
my $path_string = shift;
|
my $path_string = shift;
|
||||||
my @path_array = split /:/, $PATH;
|
my @path_array = split /:/, $ENV{'PATH'};
|
||||||
|
|
||||||
for my $path ( @path_array) {
|
for my $path ( @path_array) {
|
||||||
if ( -x "$path/$prog_name" ) {
|
if ( -x "$path/$prog_name" ) {
|
||||||
|
|
Loading…
Reference in a new issue