Commit b50f33f0 by jajapi

fixed checkPM.py, cms_serverlist.txt, updateSH.py

parent 924baab2
......@@ -60,8 +60,9 @@ for svrhost in serverhost:
### 인자값 초기화
os.system('sed -i "s/1/0/" factor')
filepath = ('/home/orchard/factor')
localpath = ('/home/orchard/CSCS/Mgmt/CMSmgmt/factor')
localpath = ('/home/orchard/CSCS/MgmtPM/CMSmgmt/factor')
sftp.put(localpath,filepath)
fac =subprocess.check_output ('cat factor',shell=True)
### sftp 접속종료
sftp.close()
......
cms-p-pm01
cms-p-pm02
cms-p-pm03
cms-p-pm04
cms-p-pm05
cms-p-pm06
cms-p-spm01
cms-t-pm01
cms-t-pm02
cms-t-pm03
cms-t-spm01
web-p-pm01
web-p-pm02
......
......@@ -35,8 +35,17 @@ for svrhost in serverhost:
localpath = '/home/orchard/CSCS/GuestPM/Integration/factor'
sftp.put(localpath,filepath)
print("%s Successful updates" % host)
sftp.close()
transport.close()
ssh = paramiko.SSHClient()
ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
ssh.connect(host,username=username,password='%s' %(password))
ssh.exec_command('sudo chmod 700 /home/orchard/Seocho_uxen_check.sh')
ssh.close()
print("%s Successful updates" % host)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment