import configparsermachine = configparser.ConfigParser()machine.read('new.ini',encoding = 'utf-8')# 将文件加载入内存