duplicato il load sql
This commit is contained in:
@@ -106,6 +106,25 @@ while ( my $line = $tail->GetLine() ) {
|
||||
);
|
||||
exit(0);
|
||||
}
|
||||
if ( $truser ne 'asega' ) {
|
||||
print getTimeStamp("log")
|
||||
. " >> Sender user $truser: duplicate as asega user -> load data into DB.\n";
|
||||
$truser = 'asega';
|
||||
my ( $login, $pass, $uid, $gid ) = getpwnam($truser)
|
||||
or warn getTimeStamp("log")
|
||||
. " >> $truser not in passwd file.\n";
|
||||
unless ( fork() ) {
|
||||
setgid($gid);
|
||||
setuid($uid);
|
||||
$ENV{"HOME"} = 'home/' . $truser;
|
||||
exec( $scriptpath
|
||||
. "LoadCSVData.pl -f \"$dest\" -s \"$outpath/SQL/$filename"
|
||||
. "_"
|
||||
. "$timestamp.sql\" -d $truser >> /home/$truser/log/loadcsvdata.log 2>&1"
|
||||
);
|
||||
exit(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user