root@datapark2:~#python-V
Python3.4.3
#!/usr/bin/python
#-*-coding:utf-8-*-
importparamiko
importsys,os
home_dir=os.path.expanduser(‘~‘)
id_rsa_pub=‘%s/.ssh/id_rsa.pub‘%home_dir
ifnotid_rsa_pub:
print(‘id_rsa.puberror!‘)
sys.exit(0)
defupload_file(hostname..
分类:
其他好文 时间:
2016-07-11 10:44:08
阅读次数:
342