Created
May 29, 2012 03:18
-
-
Save AhnSeongHyun/2822335 to your computer and use it in GitHub Desktop.
[PYTHON] use code
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server_name = socket.gethostname(); | |
if pstack_count == 1: | |
for file in pstack_list: | |
mail("sh84.ahn@gmail.com",server_name + "::pstack log", file, "./"+file); | |
print "["+file+"]"+" send to sh84.ahn@gmail.com \n"; | |
os.remove("./"+file); | |
elif pstack_count > 1: | |
zip_file_name = "pstack_logs.zip"; | |
toZip(pstack_list, zip_file_name); | |
#for file in pstack_list: | |
#os.remove("./"+file); | |
mail("sh84.ahn@gmail.com",server_name + "::pstack log", zip_file_name, "./"+zip_file_name); | |
print "["+zip_file_name+"]"+" send to sh84.ahn@gmail.com \n"; | |
os.remove("./"+zip_file_name); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment