static void daemonInitialize(void)
{
    /*
     * Note that the order is important: the first ones have a higher
     * priority when calling virStateInitialize. We must register
     * the network, storage and nodedev drivers before any domain
     * drivers, since their resources must be auto-started before
     * any domains can be auto-started.
     */
#ifdef WITH_DRIVER_MODULES
    /* We don't care if any of these fail, because the whole point
     * is to allow users to only install modules they want to use.
     * If they try to open a connection for a module that
     * is not loaded they'll get a suitable error at that point
     */
    virDriverLoadModule("network");
    virDriverLoadModule("storage");
    virDriverLoadModule("nodedev");
    virDriverLoadModule("secret");
    virDriverLoadModule("qemu");
    virDriverLoadModule("lxc");
    virDriverLoadModule("uml");
    virDriverLoadModule("nwfilter");
#else
# ifdef WITH_NETWORK
    networkRegister();
# endif
# ifdef WITH_NETCF
    interfaceRegister();
# endif
# ifdef WITH_STORAGE_DIR
    storageRegister();
# endif
# if defined(WITH_NODE_DEVICES)
    nodedevRegister();
# endif
# ifdef WITH_SECRETS
    secretRegister();
# endif
# ifdef WITH_NWFILTER
    nwfilterRegister();
# endif
# ifdef WITH_LIBXL
    libxlRegister();
# endif
# ifdef WITH_QEMU
    qemuRegister();
# endif
# ifdef WITH_LXC
    lxcRegister();
# endif
# ifdef WITH_UML
    umlRegister();
# endif
#endif
}
Exemple #2
0
static void daemonInitialize(void)
{
    /*
     * Note that the order is important: the first ones have a higher
     * priority when calling virStateInitialize. We must register the
     * network, storage and nodedev drivers before any stateful domain
     * driver, since their resources must be auto-started before any
     * domains can be auto-started.
     */
#ifdef WITH_DRIVER_MODULES
    /* We don't care if any of these fail, because the whole point
     * is to allow users to only install modules they want to use.
     * If they try to open a connection for a module that
     * is not loaded they'll get a suitable error at that point
     */
# ifdef WITH_NETWORK
    virDriverLoadModule("network");
# endif
# ifdef WITH_INTERFACE
    virDriverLoadModule("interface");
# endif
# ifdef WITH_STORAGE
    virDriverLoadModule("storage");
# endif
# ifdef WITH_NODE_DEVICES
    virDriverLoadModule("nodedev");
# endif
# ifdef WITH_SECRETS
    virDriverLoadModule("secret");
# endif
# ifdef WITH_NWFILTER
    virDriverLoadModule("nwfilter");
# endif
# ifdef WITH_XEN
    virDriverLoadModule("xen");
# endif
# ifdef WITH_LIBXL
    virDriverLoadModule("libxl");
# endif
# ifdef WITH_QEMU
    virDriverLoadModule("qemu");
# endif
# ifdef WITH_LXC
    virDriverLoadModule("lxc");
# endif
# ifdef WITH_UML
    virDriverLoadModule("uml");
# endif
# ifdef WITH_VBOX
    virDriverLoadModule("vbox");
# endif
# ifdef WITH_BHYVE
    virDriverLoadModule("bhyve");
# endif
# ifdef WITH_VZ
    virDriverLoadModule("vz");
# endif
#else
# ifdef WITH_NETWORK
    networkRegister();
# endif
# ifdef WITH_INTERFACE
    interfaceRegister();
# endif
# ifdef WITH_STORAGE
    storageRegister();
# endif
# ifdef WITH_NODE_DEVICES
    nodedevRegister();
# endif
# ifdef WITH_SECRETS
    secretRegister();
# endif
# ifdef WITH_NWFILTER
    nwfilterRegister();
# endif
# ifdef WITH_XEN
    xenRegister();
# endif
# ifdef WITH_LIBXL
    libxlRegister();
# endif
# ifdef WITH_QEMU
    qemuRegister();
# endif
# ifdef WITH_LXC
    lxcRegister();
# endif
# ifdef WITH_UML
    umlRegister();
# endif
# ifdef WITH_VBOX
    vboxRegister();
# endif
# ifdef WITH_BHYVE
    bhyveRegister();
# endif
# ifdef WITH_VZ
    vzRegister();
# endif
#endif
}