# -*- coding: cp936 -*-
import time
rserver = open("d:/name.txt","r")
vservice = open("d:/vservice.txt","r")
vserver = open("d:/vserver.txt","r")
readr = rserver.readlines()
readvs = vservice.readlines()
readvsr = vserver.readlines()
''' print service name'''
for rsn in readr:
rsn = rsn.strip('\n')
print 'rsn-name: ',rsn
for vs in readvs:
vs = vs.strip('\n')
if rsn in vs:
#print hang
print vs
vs = vs.split('"')[1]
print "====== service name ======"
print 'vs-name: ',vs
time.sleep(1)
print "=======service name ======="
''' print vserver name '''
for vsn in readvsr:
vsn = vsn.strip('\n')
if vs in vsn:
print vsn
print '----------------vserver name ------------'
vsn = vsn.split('"')[1]
print "vsn-name: ",vsn
time.sleep(1)
print '----------------vserver name -------------'
rserver.close()
vservice.close()
vserver.close()
阅读(3550) | 评论(0) | 转发(0) |