A download into a pool listed its volume while it was written. The page
let a superuser copy it (the copy got a half-written file, live), attach
it to a VM, or stop the pool under it. Now:
- the copy job claims its source volume shared, and the worker refuses
a copy whose name the source's format changed before the claim;
- attaching an existing volume holds it exclusive from its first read,
so neither a download nor a copy is under way, and its format is read
after the download ended;
- stopping or deleting a pool (page and API) holds the pool exclusive,
and its backup target's claim if it is one; restores claim the pools
they write into shared.
Each is refused with the job in the way named, as a volume delete
already was.
The download recorded its progress every 16 MiB, so a slow server's
bar stayed empty for a long time; it records it each second, with the
cancel check. The worker checks the name is still free before it
starts. A snapshot name or tag typed in the VM list's bulk form keeps
the list from reloading, as a chosen VM did.
Taking the same snapshot of many VMs, before an update say, took each one's
Snapshots tab. The VM list's bulk form now has a snapshot name with Take
snapshots: an external snapshot, without memory and without freezing file
systems (the tab has those choices), queued as a snapshot.create job for
each chosen VM, with the tab's rules (change rights and the snapshot
permission). A VM refused or held is named and the others are queued; the
Jobs page follows them. Enter in any text box of the form sends nothing.
The power and snapshot views share one queuing helper.
Audit and review (Codex, agy) of the host comparison and the bulk tag:
- a read of what a host's VMs need was used again for 5 minutes without a
new one, so a network added to fix a line was still reported: each load
reads again, the last read standing in only when the new one is late;
- a host that stopped answering kept what it said before, and was reported
both as not answering and as a destination lacking things: only hosts that
answer are compared;
- one listing of a host that could not be read (its secrets, say) dropped the
whole host: each listing is read on its own and only those read compared;
- the kept reads no longer keep whole VM definitions (plain strings);
- choosing more VMs than the bulk form takes made Django refuse the form:
past 500 the buttons are off and the count says so; the tag view refuses
them as the power view does.
Tagging many VMs took each one's Settings tab. The VM list's bulk form now
has, for a superuser, a tag box (every tag offered) with Add tag and Remove
tag: under the ownership lock the tag is checked as on the Settings tab,
made if new, and added to (or removed from) the chosen VMs that lack (or
have) it, each with its own log row. Enter in the tag box sends nothing (it
would press Start, the form's first button); only the two tag actions are
taken, and none of the chosen VMs left makes no tag.
Audit and review (Codex) of the bulk power and disk I/O limit:
- the Jobs page showed "Power" for a start, a shut down and a force off
alike: each is a job kind of its own (instance.start, .shutdown,
.force_off) named by its action;
- forcing off a VM already shut off made libvirt refuse after the job had
recorded its intent: it ended uncertain and kept the VM locked. Each job now
refuses a VM its action does not apply to before anything changes, and
recovery reads the VM's state (running after a start, shut off after a
shut down or force off) instead of ending uncertain;
- the Jobs page left out its kind and state filters for owners, whom the VM
list sends there: they apply to every user;
- a running NBD disk's tls, which libvirt fills in, no longer makes it
another disk than the next start's;
- a disk whose running limit differs from the next start's shows both.
Powering many VMs took a click each. On the VM list each VM its user may
power (theirs, or every one for a superuser) has a box; "Choose the VMs
shown" chooses those on screen. Start, Shut down and Force off queue an
instance.power job for each chosen VM: each holds its VM and shares its host,
checks its user and the VM again when it runs, and has the checks of the
page's buttons (a template is not started, a host in maintenance starts none,
a VM an administrator paused is not an owner's to power), its own recovery
and its own log row. A VM the user may not power, or that another job holds,
is named and the others are queued; the Jobs page follows them. A VM a filter
or a collapsed host hides is neither counted nor sent, and the list does not
reload while VMs on screen are chosen.
One VM's busy disk could take its storage from all the others. Under a
disk's Device details on the Disks tab a superuser sets an I/O limit, IOPS
and MiB/s for reads and writes together (0: none). libvirt applies it to each
definition that has the disk: the running VM's at once, and the one for its
next start; a transient VM's live only. A disk whose tuning is more than this
(a throttle group, a burst, read and write apart, bytes not whole MiB/s)
shows "Set in the VM's XML" and is changed there; a disk the next start
replaces is refused until then.
Audit and review (Codex, agy) of the file system list:
- the table had a side margin on a full-width table and ran past the tab's
edge (on a phone its Used column was cut off); it now sits in a box that
scrolls a long mount point, and on a phone the labels above it wrap by word;
- an agent answer that is not a list, an entry that is not an object, a
negative, boolean or oversized size, or a null mount point or type no longer
fails the tab or shows "None"; a "filesystems" key of another command is not
taken for the list; the total is the whole file system's when the agent
tells it (total-bytes-privileged), so used no longer passes it;
- when the agent does not give the file systems, a note says so;
- Turkish labels: "Kernel Version" was "Çekirdek Sürümü" like "Kernel Release",
"OS Pretty-Name" read as a short name, "Timezone / Offset" as a location;
- the bulk migration live test's name no longer claims two at once, which its
unit test checks.
Since Bulk Migrate spreads VMs over hosts (#601) the job takes moves, each
VM with its destination, not a target and instances: the live test still
sent the old form and failed with KeyError 'moves'. Live suite on the
Vagrant computes: 3017 OK, 7 skipped.
A disk filling up inside a guest was seen only from the guest. The Guest Info
tab now lists, from the guest agent, each mounted file system with its type
and used / total size, a bar turning amber from 85 %. File systems the agent
gives no size of (pseudo ones, Windows' System Reserved) are left out; an
agent without the command still shows the rest of the tab.
A VM that vanished from its compute, or whose compute was deleted and added
again, came back with its owners and tags only: it was no longer protected,
its schedules no longer backed it up, and its backups stayed unlinked, so its
Backups tab no longer listed them and retention left them for good. The
Removed VMs record now keeps its protection, its schedules and its own
backups (not those of a copy under the same UUID), and gives them back.
Turning protection on or off waits for the ownership step, so a VM dropped
from its host's list meanwhile is not told protected.
A superuser turns a VM's protection on or off on its Settings tab, not while
a job holds the VM (a deletion or a restore over it that runs would not
stop). While it is on, its deletion (page, API, a queued job at its start)
and a restore of a backup over it are refused; the Destroy tab, the destroy
page and the restore page say so. A VM moved outside the panel keeps it.
The API shows the flag read-only.
A verification of a chain's base refused a verification of its incremental
with "Verify backup is running on this resource": which backup held it was
not said. The job's resource label now follows its name for who may see
the job, as on the Jobs page; not in an audit row or a bulk migration's
error, which others read.
QEMU sends a migrating VM's memory and copied disks in the clear. A
compute gets "Encrypt migrations (TLS)" (edit page, Advanced; API
field migration_tls); a migration between two hosts that both have it
passes VIR_MIGRATE_TLS whenever data moves (not for a shut-off VM's
definition alone), and the log says TLS. The hosts need QEMU's
certificates in /etc/pki/qemu; a host without them refuses before
anything moves. Tried on two AlmaLinux 10 hosts: the TLS stream starts
with a TLS record, the plain one with QEMU's QEVM header.
With dozens of tags the pills took rows of the list's top (six rows for
forty tags, the table below a phone's screen). The pills are now by how many
rows have the tag, the eight most used shown and the others behind "… More
tags N", which shows them as a row's "…" does; its count follows the
search and the state, and it hides when none is left behind it. A pill
behind it chosen (remembered, or by a row's badge) shows them.
A tag pill's count was the page's; the state pills' follow the search and
the tag. Now a tag pill counts the rows with its tag the search and the
state find, and one with none is hidden unless chosen, as a state pill.
- A name typed or pasted into the tag box that cannot be a tag shows the
rule (letters a-z, digits, dots, dashes, underscores; at most 12
characters) instead of nothing; the spaces a paste brings are dropped;
"constructor" is no longer taken for a tag there is.
- "Clear the filters" hides with the message it is in: the search box takes
the focus.
The tag filter was a select beside the search box. It is now a row of
pills as the VM states' are, below them on the VM list and above the table
on the hosts list: All tags, No tag and each tag with how many have it.
The state and tag pills share one helper in table_filter.js; a badge
chooses its tag's pill, the choice is remembered as before.
The host's VM list showed every tag of a VM, widening its Name column as
the VM list did before; it now shows three and the others behind "…".
There its tags are not buttons: the tags "…" shows take the focus, so a
keyboard user is not sent back to the top of the page.
- A tags form carries the names it showed (show_hidden_initial): sent back
unchanged, the VM's or host's tags are left as they are, so a form shown
before a tag was renamed or deleted does not bring the old name back.
- A rename whose tag is deleted while it waits answers 404, not 500.
- A removed VM kept only for a deleted tag leaves the Removed VMs page.
- A kept tag filter the list no longer offers is forgotten, so a name made
again later is not chosen by itself.
Tag badges are smaller than other badges everywhere, and the VM list
shows a VM's first three tags and "…" for the others: it names them in
its tooltip and shows them when pressed, by mouse or keyboard. A VM with
many tags no longer widens the name column and the table with it; the
tag list still filters by any of them.
- Saving a VM's tags unchanged writes no audit row.
- The VM report has a Tags column.
- A host's VM list and a user's VMs (account page) show the VMs' tags.
- The hosts list says "No host matches the filters." with Clear the
filters, as the VM list does; the tag list keeps to a phone's width
with a long tag.
- A removed VM's delete page says its owners and tags no longer come
back; the VM history rows say "owners and tags kept/restored".
- The API's ?tag= is trimmed; Tom Select's "Add tag" line shows the name
in lower case as it is made; Bulk Migrate's tag list goes back to its
title after a choice, so the same tag can be chosen again.
- A VM's tags set while its host's list drops it: the VM is checked
again under the ownership lock and the page says it was moved, instead
of a 500 or a success that kept the old tags in its removed record.
- A tag deleted right after another rename cleans the removed VMs' kept
name it has now; a delete sent while a backup schedule uses the tag
(saved after the page was shown) is refused with the schedules' names.
- A rename to a name another tag took meanwhile is a form error, not a
500; "There is a tag with this name already" is translated.
- Tom Select makes a typed name lower case and offers no new tag for one
that is there in another case; the API's ?tag= is lower-cased too.
On the VM and host lists a tag's badge chooses it in the tag list, the
tag list offers "No tag" for the rows without one, and each choice says
how many of the listed rows it shows ("prod (42)"); an owner counts only
their own VMs.
Administration gets a Tags page: each tag with how many VMs and hosts
have it, renamed (on the VMs, hosts and removed VMs that keep it) or
deleted (taken off all of them). Both are logged.
The API gives a VM's and a host's tags by name, read only, and its VM
and host lists take ?tag= for those with a tag.
The VM list and the hosts list get a tag list next to their search: the
rows with the tag chosen show, together with the search and the state.
It offers the tags of the rows listed only, so an owner sees the tags of
their own VMs, not the panel's. The state counts follow the tag, and the
chosen tag is remembered as the search and state are; Clear the filters
clears it too.
One list of tag names (lower case letters, digits, dot, dash, underscore;
up to 32) given to VMs and hosts. A superuser sets a VM's tags on its
Options tab and a host's on its form; Tom Select suggests the tags there
are and makes a new one typed. The VM list, the VM page and the hosts list
show them as badges, to everyone who sees the VM or host.
A VM's tags stay with it: an out-of-band move adds them to those on the
new host's record, and a VM that leaves its host keeps them on the Removed
VMs page (a VM with only tags too) and gets them back when it returns.
Setting them is audited and held against the VM's move.
- A backup's volume is no longer attached to a VM as an existing volume:
the VM would write into the backup, and the backup's deletion (by hand
or retention) would remove the VM's disk.
- A backup whose create job ended without it (uncertain, then resolved)
stayed "creating" for good and could not be deleted. Only a backup whose
job still runs is being made; the others show as failed and are deleted.
- A VM with an NVDIMM or virtio-pmem device is refused: the host file
behind it is not copied, and its restore would use the original's file.
- A block device's or network NVRAM is refused by its path, instead of a
ready backup without the firmware state.
- A VM owner's restore pages link back to the VM's Backups tab, not to the
superusers' backup list.
libvirt refuses to undefine a domain that has checkpoints unless asked to
drop their metadata. The VM delete job and the shut-off migration's
removal of the source definition now pass CHECKPOINTS_METADATA; a backup
chain ends with them, and the next backup is full.
An audit of host maintenance found:
- refuse_start and refuse_new_vms trusted the compute as the page or job had
read it: a clone started after its host went in maintenance during the disk
copy, and a power-on raced the switch while host devices were checked. They
now read the state from the database, and power-on checks right before the
start; a VM defined from XML is refused as well.
- libvirt starts autostart VMs itself when the host boots. Autostart cannot
be turned on for a VM of a host in maintenance, and the host page names the
VMs that would start, so that their autostart is turned off before a reboot.
- The New VM dialog said "In maintenance" for a host whose maintenance was
only requested: it now says "Maintenance".
- Tests now cover the owner's power-on, the revert job and a stale compute.
The host page in maintenance showed the host's latest bulk migration even
when it was from before the maintenance, as a job of the morning that
"succeeded" while a VM still ran. The host now keeps when it went in
maintenance (maintenance_since; a job that puts it there sets it to the
job's own time), and the page shows a bulk migration from then on, or one
still running.
A refusal of the panel's own (OperationError), such as a VM start on a
host in maintenance, was shown as "libvirt Error - ...": it is shown as is.
After a host was emptied with Bulk Migrate for its maintenance, Balance
proposed moving VMs back onto it, and new VMs and migrations could still be
sent there. A superuser now puts a host in maintenance on its page (and
takes it out), each change audited; the form names the state it sets, so a
second page sent meanwhile does not turn it back.
A host in maintenance (Compute.maintenance, refuse_new_vms):
- takes no migration: migration_target refuses it, so the Migrate tab,
Bulk Migrate, Balance and queued migrate jobs follow one rule; Bulk
Migrate leaves it out of its destinations and its spread;
- takes no new VM: the create and clone jobs refuse it when asked for and
again before they start (the REST API submits the same jobs); the create
pages and the XML define send the user back to the VM list, and the New VM
dialog lists it without a link;
- is left out of Balance: its VMs neither count nor move, and the Balance
job refuses a move from it too, before each migration starts.
Its VMs run on; a migration already started finishes. The Computes page and
the host's page show that it is in maintenance.
The owner found "Evacuate" ("Boşalt") a poor name: the button, page and
job are now Bulk Migrate ("Toplu Taşı"), as Proxmox calls it, and so
are the URL, view, template, script, job kind and claim. The VM list
gets a Select all box in its header, which ticks every VM that can
migrate. The unclear Check button goes: another destination reloads the
list itself, and a host with one destination names it instead of
offering a choice.
The host's Instances page gets an Evacuate button. Its page lists the
host's VMs for a chosen destination: running ones ticked, shut-off ones
left to choose ("Also migrate the shut-off VMs"), and a VM with a disk
file the two hosts do not share refused with the reason, since it needs
a copy chosen on its own Migrate tab.
One "Evacuate host" job migrates them: a migrate job each (live with
auto converge; a shut-off VM offline), at most the chosen number at
once, so a VM that fails stays on the host and the rest go on. The
choice goes up to half the worker's slots, which a host's jobs may take,
less the evacuation's own. Cancelling it cancels the migrations that
run and starts no more. One evacuation runs at a time: it waits in a
worker slot, and several could leave none for their migrations. A VM
that left the host meanwhile is skipped (a migrate job takes the host it
is to leave from the evacuation and refuses another); a host whose record points
elsewhere since, or a worker lowered to one slot, stops it before the
next VM. A busy VM lets the others go first; one an uncertain job holds is
not waited for.
Migrations now hold the hosts' VM sets shared, so several migrate at
once; creates, clones, deletes and the VM list reconcile still wait for
them. A destination gone since the form was shown is refused, not
replaced by another. The uses of the NVRAM directory's pool take turns
(NVRAM_LOCK): two UEFI migrations at once would share a transient pool
that the first destroys under the second.
Since ad9c3ad9 a disk's detach and delete forms post the disk's path, and
since b664e341 a NIC's form posts net-seen, its saved definition as the
page read it; a post without them is refused as made from a stale page.
Four live tests still posted the old fields, were refused and failed;
test_clone then failed too, on the extra disk the refused delete left.
They now post the same values as the forms.
A switch to the serial console removed the graphics device but kept a
serial console of another type, a TCP one say, which the browser does
not open; the audit log said the console type was set. The switch is now
refused, with nothing changed, unless the serial console is a pty one.
A listen address change of a console that listens on a network, a socket
or nowhere did nothing without a word. It is refused with the reason.
The .vv file pointed virt-viewer at "::" for a console on all IPv6
addresses; such a console is reached through the host, as one on
0.0.0.0.
The console form compared what was posted with the settings saved at the
time of the save, so every field of a page opened earlier counted as a
change: an administrator who moved a console to localhost had it opened
to all interfaces again when another one, on an older page, only
generated a new password. The form now sends back a fingerprint of the
type, listen address and keymap it showed, and a save made after these
changed is refused with a message to check them and save again.
A refused save names the reasons without the field names.
The console type list offers VNC and Serial only, so the page of a SPICE
VM showed VNC and any save, of the keymap alone, switched the console:
libvirt refused the definition when the VM had a SPICE channel, and
without one the VM silently got a new VNC console. A console type the
panel does not create is now offered as it is, and kept on save.
A switch from SPICE that is chosen removes the SPICE channels, USB
redirection and smartcards libvirt refuses without SPICE graphics and
mutes SPICE audio. A new VNC console keeps the keymap and a password VNC
can take; a longer one is replaced by a generated password.
The console settings were read from the first graphics device that had
each attribute: with VNC and SPICE devices the page showed VNC's port
with SPICE's password. All are read from the first device, the one the
settings change.
The console settings accepted any password of at most 8 bytes, so "éééé"
was saved, but noVNC derives its key from the characters while QEMU
compares the UTF-8 bytes: the browser console could not log in. A new
password now takes up to 8 printable ASCII characters, which also keeps
control characters out of the definition.
The .vv file wrote the password and the VM name as they are; virt-viewer
reads it as a GLib key file, so a backslash or a leading space changed
the password. Both are escaped as a key file expects.
A new or removed password also drops a passwdValidTo set elsewhere: an
expired one left the new password unusable.
The CPU, memory, disk and network charts of a host and of a VM put their
readings at equal steps: a reading that took 20 s looked like one 5 s
after the one before. The x axis now counts seconds, a reading standing
at the time it came; each tick is at a reading and named with the
panel's time of it, as before. Checked with Chart.js in a browser: a
20 s step is four times as wide as a 5 s one.
The IP search and the VM report parse each address a guest agent
reports. An agent answer that was no address ("invalid-address") raised
a ValueError that only libvirt errors were caught around: the search or
the report ended in a 500 and lost every other guest's addresses. Such
an answer is now skipped, and the guest's other addresses still count.
The VM report was in English in every language but for the VM states:
its headings, sheet names, coverage notes and yes/no now follow the
reader's language.
/api/v1/instances/ listed the panel's VM records without asking the
hosts: a VM undefined or renamed with virsh stayed there as it was, and
one defined outside never appeared, until someone opened a web VM list
(the per-host API list already read its host). It now reads the hosts
it lists first, as the VM list does: all at once, one that does not
answer left as last read. Seen live: a VM defined with virsh appears,
and is gone once undefined.
The VM list reloads when its poll finds a VM added or gone. The search
was kept through the reload, but the chosen state pill (Off, say) went
back to All: on a busy host the filter kept undoing itself. The state is
now remembered with the search, for the tab.
The search compared lower-cased text, which differs in Turkish:
"istanbul" did not find "İSTANBUL". Both sides are now compared without
case and accents (and dotless ı as i).
The VM list and its poll read each host in turn. A host that is up but
stuck (a daemon or an NFS mount that does not answer) kept the call
waiting: the list did not open in 200 s (seen live with compute1's
virtqemud stopped), and the per-host limit freed it only when gunicorn
ended the request after 600 s. The list and the poll now ask all hosts
at once, each in a thread counted on its host like a request, and wait
10 s at most: a host that has not answered is shown as not answering,
and the VMs of the others are listed. Live: the list opens in 10 s,
then in 5 s while the host stays stuck.
The Settings page refuses a whole-number setting outside its range, but
a value an older version saved stays: LOGS_PER_PAGE "abc" made the Logs
page fail with a 500 (seen live). Migration 0026 puts every
whole-number setting outside its range, or not a number, back to its
default.
With VM DRBD Status on, the VM list showed each VM's state as its VM
page last read it, and "None" for a VM never opened. The list now reads
each SSH host's drbdadm status once, all hosts at once, and updates its
VMs from it: a host that does not answer delays the list by one
timeout, not one per host.
Settings refuse disk I/O native with a cache other than none or
directsync, which libvirt refuses. A new VM took the I/O from Settings
and its cache from the create form, unchecked: native I/O with a
writeback cache was queued, the disks were made, and libvirt then
refused the VM. The create job now refuses such a pair when it is asked
for, and again when it runs, before it makes a disk: Settings may have
changed meanwhile.
Two administrators saving the I/O and the cache at once each checked
the pair as their page read it, and both saves made one libvirt refuses.
The pair is now checked again as saved, with its rows locked, when a
change of it is saved; the log row keeps the reason in English.
A rule or reference change reads a filter and defines it again whole:
two admins changing one filter at once each defined their copy, and the
second removed the first's rule. Changes to a host's filters (create,
clone, delete, rules, references, XML) now run one at a time; one that
finds another running is told to try again.
A VM's NIC form sends back its source, model, filter and MAC whole: a
form opened before another admin changed the NIC's filter put the old
filter back. The form now sends a fingerprint of the NIC as it showed
it, and a NIC changed meanwhile is refused.
A pool on shared storage (an NFS share, or a directory mounted from one)
holds the same file at the same path on every host that mounts it. A
VM's delete checks the panel's other computes before it deletes its disk
files, but the pool page, its API and a VM's disk delete checked only
their own host: a disk of a VM on another compute could be deleted. They
now ask the other computes too, and refuse while one uses the file or
cannot be reached. The other computes are asked before this host's lock
is taken, and before a VM's disk is detached.
A live clone freezes the guest's file systems through its agent. When
the worker stopped before the thaw and the VM was paused before the job
was recovered, recovery skipped the thaw without a word: resumed, the
guest stayed frozen. libvirt thaws no paused guest, so the job's warning
now says to resume the VM, then thaw it with virsh domfsthaw.
Settings > "Show Root Password" and "Show SSH Keys" hid their forms on
the Access tab, but an owner who may change the VM could still post to
them and reset its root password or install a key. Both are now refused
while their setting is off.
A password longer than 4096 characters or with a NUL character, which
passlib does not hash, ended in a 500; it is now refused with a message.