Beispiel #1
0
    def delete(self, backup=False):
        JBoxContainer.log_info("Deleting %s", self.debug_str())
        self.refresh()
        cname = self.get_name()
        if self.is_running() or self.is_restarting():
            self.kill()

        disk = VolMgr.get_disk_from_container(self.dockid)
        if disk is not None:
            disk.release(backup=backup)

        if cname is not None:
            JBoxContainer.PINGS.pop(cname, None)
        JBoxContainer.DCKR.remove_container(self.dockid)
        JBoxContainer.log_info("Deleted %s", self.debug_str())
Beispiel #2
0
    def delete(self, backup=False):
        JBoxContainer.log_info("Deleting %s", self.debug_str())
        self.refresh()
        cname = self.get_name()
        if self.is_running() or self.is_restarting():
            self.kill()

        disk = VolMgr.get_disk_from_container(self.dockid)
        if disk is not None:
            disk.release(backup=backup)

        if cname is not None:
            JBoxContainer.PINGS.pop(cname, None)
        JBoxContainer.DCKR.remove_container(self.dockid)
        JBoxContainer.log_info("Deleted %s", self.debug_str())
Beispiel #3
0
 def get_disk_allocated(self):
     disk = VolMgr.get_disk_from_container(self.dockid)
     if disk is not None:
         return disk.get_disk_allocated_size()
     return 0
Beispiel #4
0
 def get_disk_allocated(self):
     disk = VolMgr.get_disk_from_container(self.dockid)
     if disk is not None:
         return disk.get_disk_allocated_size()
     return 0