init web ems all
This commit is contained in:
26
wxc2_omc/configuration/mscSync/putFile
Executable file
26
wxc2_omc/configuration/mscSync/putFile
Executable file
@@ -0,0 +1,26 @@
|
||||
#!/bin/bash
|
||||
|
||||
ip=$1
|
||||
fileName=$2
|
||||
|
||||
ftpUserNameStr=`/usr/bin/mysql -prootaa <<_EOF_
|
||||
SELECT pubVarValue FROM OMC_PUB.omcPubVarConf WHERE pubVarName='globalFTPUserName';
|
||||
_EOF_`
|
||||
|
||||
ftpPasswordStr=`/usr/bin/mysql -prootaa <<_EOF_
|
||||
SELECT pubVarValue FROM OMC_PUB.omcPubVarConf WHERE pubVarName='globalFTPPassword';
|
||||
_EOF_`
|
||||
|
||||
ftpUserName=`echo $ftpUserNameStr | awk '{print $2}'`
|
||||
ftpPassword=`echo $ftpPasswordStr | awk '{print $2}'`
|
||||
|
||||
|
||||
ftp -n >>result.txt <<__CTL_END
|
||||
open $ip
|
||||
user $ftpUserName $ftpPassword
|
||||
bin
|
||||
cd /usr/local/wxc2/bin/conf/
|
||||
put $fileName
|
||||
bye
|
||||
__CTL_END
|
||||
|
||||
Reference in New Issue
Block a user