nova 根据conf动态加载虚拟化驱动
来源:互联网 发布:北京城市规划 知乎 编辑:程序博客网 时间:2024/06/05 18:35
在nova/virt/driver.py 中的ComputeDriver 类中定义了load_compute_driver来加载用于虚拟化的driver。def load_compute_driver(virtapi, compute_driver=None): """Load a compute driver module. Load the compute driver module specified by the compute_driver configuration option or, if supplied, the driver name supplied as an argument. Compute drivers constructors take a VirtAPI object as their first object and this must be supplied. :param virtapi: a VirtAPI instance :param compute_driver: a compute driver name to override the config opt :returns: a ComputeDriver instance """ if not compute_driver: compute_driver = CONF.compute_driver if not compute_driver: LOG.error(_LE("Compute driver option required, but not specified")) sys.exit(1) LOG.info(_LI("Loading compute driver '%s'"), compute_driver) try: driver = importutils.import_object( 'nova.virt.%s' % compute_driver, virtapi) return utils.check_isinstance(driver, ComputeDriver) except ImportError: LOG.exception(_LE("Unable to load the virtualization driver")) sys.exit(1)可以compute_driver 是在CONF.compute_driver得到的,本例中compute_driver=libvirt.LibvirtDriver因此最终会通过import_object 导入nova.virt.libvirt.LibvirtDriver
阅读全文
0 0
- nova 根据conf动态加载虚拟化驱动
- nova.conf
- OpenStack基于Libvirt的虚拟化平台调度实现----Nova虚拟机动态迁移源码分析
- OpenStack基于Libvirt的虚拟化平台调度实现----Nova虚拟机动态迁移源码分析
- OpenStack基于Libvirt的虚拟化平台调度实现----Nova虚拟机动态迁移源码分析
- nova.conf 参数说明
- nova.conf配置文件说明
- 模块化驱动动态加载
- ZwSetSystemInformation 动态加载驱动
- 动态加载驱动-2
- 驱动动态加载
- 动态加载流驱动
- 动态加载驱动 DDK
- 模块化驱动动态加载
- nova.conf及其他配置
- 【openstack】Nova(Folsom)虚拟化层Driver分析
- 关于动态加载/卸载驱动
- windows API 动态加载驱动
- 前端接口自动化测试工具-DOClever(免费开源的接口管理平台)使用介绍
- 备份
- 怎么使用echarts
- WinAPI: GetTextFace
- 印象笔记与有道云笔记
- nova 根据conf动态加载虚拟化驱动
- WinAPI: TextOut
- “JTAG Warning: T-bit of XPSR is 0 but should be 1. Changed to 1.” 解决方案
- 光盘
- PHP关于文件下载方面知识的总结(包括图片,文件等)
- Oracle用户登录密码过期的修改
- WinAPI: SetTextColor
- 网络
- 沉浸式