more LL setup
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@7753 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
parent
48f3a6f452
commit
d8312a32ef
@ -1319,6 +1319,28 @@ sub setupODBC
|
||||
$message = "$db2clifile already configured, will not change.";
|
||||
xCAT::MsgUtils->message("I", "$message");
|
||||
}
|
||||
} else { # file does not exist
|
||||
my $entry = "[$instance]\nuid=$instance\npasswd=$passwd";
|
||||
$cmd = "echo \"$entry\" > $db2clifile";
|
||||
xCAT::Utils->runcmd($cmd, 0);
|
||||
if ($::RUNCMD_RC != 0)
|
||||
{
|
||||
$message = "$cmd failed. Could not setup $db2clifile.";
|
||||
xCAT::MsgUtils->message("E", "$message");
|
||||
|
||||
}
|
||||
$cmd = "chown xcatdb $db2clifile";
|
||||
xCAT::Utils->runcmd($cmd, 0);
|
||||
if ($::RUNCMD_RC != 0)
|
||||
{
|
||||
xCAT::MsgUtils->message("E", " $cmd failed.");
|
||||
}
|
||||
$cmd = "chmod 0600 $db2clifile";
|
||||
xCAT::Utils->runcmd($cmd, 0);
|
||||
if ($::RUNCMD_RC != 0)
|
||||
{
|
||||
xCAT::MsgUtils->message("E", " $cmd failed.");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user