Exemplo n.º 1
0
    def _persistentNetworkBackup(cls, network):
        """ Persistently backup libvirt networks """
        content = libvirt.getNetworkDef(network)
        if not content:
            # For non-exists networks use predefined header
            content = cls.DELETED_HEADER + '\n'
        logging.debug("backing up network %s: %s", network, content)

        cls.writeBackupFile(NET_LOGICALNET_CONF_BACK_DIR, network, content)
Exemplo n.º 2
0
Arquivo: ifcfg.py Projeto: nirs/vdsm
    def _persistentNetworkBackup(cls, network):
        """ Persistently backup libvirt networks """
        content = libvirt.getNetworkDef(network)
        if not content:
            # For non-exists networks use predefined header
            content = cls.DELETED_HEADER + "\n"
        logging.debug("backing up network %s: %s", network, content)

        cls.writeBackupFile(NET_LOGICALNET_CONF_BACK_DIR, network, content)
Exemplo n.º 3
0
 def _atomicNetworkBackup(self, network):
     """ In-memory backup libvirt networks """
     if network not in self._networksBackups:
         self._networksBackups[network] = libvirt.getNetworkDef(network)
         logging.debug("Backed up %s", network)
Exemplo n.º 4
0
Arquivo: ifcfg.py Projeto: nirs/vdsm
 def _atomicNetworkBackup(self, network):
     """ In-memory backup libvirt networks """
     if network not in self._networksBackups:
         self._networksBackups[network] = libvirt.getNetworkDef(network)
         logging.debug("Backed up %s", network)