Augeas是一个配置编辑工具并提供了配置读写的API接口。它解析一些常见的配置文件例如/etc/hosts,/etc/grub.conf等并生成一个更直观的树状结构。
一直用pip升级python-augeas,如下: pip install --upgrade python-augeas 升级失败,提示如下: ERROR: Cannot uninstall 'python-augeas'. It is a distutils installed project and thus we cannot accurately determine which file
#模块安装 yum install -y augeas python-augeas #测试使用: >>> import augeas >>> a = augeas.Augeas() >>> a.get("/files/etc/sysctl.conf/net.ipv4.ip_forward") #查看/etc/sysctl.conf配置文件的net.ipv4.ip_forward参数值 u'