Storage-Unterschiede beim Abkoppeln benennen statt pauschal zu melden
Die Abhaengigkeit vom Quell-Snapshot ist eine Ceph-Eigenheit. Bisher meldete flatten alles andere pauschal als "kein Ceph-Datentraeger" - das klingt nach Einschraenkung, ist bei LVM-thin aber das Gegenteil. Nachgemessen auf local-lvm: ein Thin-Snapshot teilt sich die Bloecke im Pool (256 MB Nutzdaten liegen dort nur einmal), ist aber trotzdem eigenstaendig - Quell-Snapshot und Original liessen sich loeschen, waehrend der Klon existiert, und seine Pruefsumme blieb unveraendert. Dort gibt es also weder geschuetzte Snapshots noch etwas zu flatten. lvmthin nicht noetig, Klon ist von sich aus unabhaengig zfspool nicht moeglich, ginge nur ueber zfs send | zfs recv rbd noetig fuer den Dauerbetrieb lvm dick PVE kann dort gar keine Snapshots Der Hinweis in der Zusammenfassung richtet sich jetzt ebenfalls nach dem Storage-Typ, statt immer zum Flatten zu raten. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
09dcd4c572
commit
2c85011a08
@@ -27,7 +27,8 @@ from .curses_util import (C_DIM, C_FOOTER, C_HEADER, C_MARK, C_OK, C_SEL, C_WARN
|
||||
keybar, message, prompt, put, read_key)
|
||||
from .proxmox import Proxmox, ProxmoxError, pvesh_available
|
||||
from .recovery import (EXCHANGE_GUEST_PATH, MKFS, RecoveryError, Spec, create,
|
||||
destroy, find_orphans, flatten, flatten_cost, human_bytes,
|
||||
destroy, find_orphans, flatten, flatten_cost, flatten_hint,
|
||||
human_bytes,
|
||||
linked_volumes, list_instances, plan, pull, release,
|
||||
remove_orphans, start)
|
||||
from .snapfs import list_snapshots
|
||||
@@ -565,7 +566,8 @@ def _flatten(stdscr, proxmox, instance, linked):
|
||||
+ _plain(progress.lines), "Fehlgeschlagen")
|
||||
return
|
||||
lines = ["%d Datentraeger geloest." % len(done), ""]
|
||||
lines += ["nicht behandelt (kein Ceph): %s" % volid for volid in other]
|
||||
for volid in other:
|
||||
lines += _wrap("%s: %s" % (volid, flatten_hint(proxmox, volid)), 74)
|
||||
if not linked_volumes(proxmox, instance):
|
||||
lines += ["", "%s ist jetzt eigenstaendig. Die Snapshots des Originals "
|
||||
"lassen sich wieder loeschen." % instance.label]
|
||||
@@ -889,7 +891,7 @@ def cmd_flatten(proxmox, args):
|
||||
for volid in already:
|
||||
print(" war schon eigenstaendig: %s" % volid)
|
||||
for volid in other:
|
||||
print(" nicht behandelt (kein Ceph-Datentraeger): %s" % volid)
|
||||
print(" %s: %s" % (volid, flatten_hint(proxmox, volid)))
|
||||
if not linked_volumes(proxmox, instance):
|
||||
print("\n%s ist jetzt eigenstaendig. Die Snapshots des Originals lassen "
|
||||
"sich wieder loeschen." % instance.label)
|
||||
|
||||
Reference in New Issue
Block a user