Git Product home page Git Product logo

cockpit-machines's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cockpit-machines's Issues

Libvirtd unattended installation root password is wrong

Hi.
I am going to cockpit -> Virtual Machines -> Create new virtual machine -> Checking "Run unattented installation" -> Setting a root password.
That root password is wrong, and I always have to run this command on host machine:
virt-customize -a /raid5-array/virtual-machines/webserver.qcow2 --root-password password:FooBarPassword

(I have to install libguestfs-tools-c with this command yum install libguestfs-tools-c first, before running virt-customize, and the virtual machine have to be turned off)

machines: consoles show/connect to local ports for VMs on remote machines

Cockpit version: 197.3
OS: Oracle Linux 8.1
Page: Machines

When i click the console tab, it show another machines console. I think there are some problems with ports.

There are 2 different vm which names are test1, test2. they were created with virt-manager. They are working as expected.
when i click the vm test1, it shows test2 console. and test2 show test1

image

machines: Modernize Storage Pools design

It would be better if we reworked the table to be a little more modern.

Originally from cockpit-project/cockpit#15346 (comment):

As deactivation and activation are uncommon, as is deletion, it probably should go into a kebab menu. Additionally, we should try to avoid tabs in expanded tables. If we could show the metadata inline instead of in a key/value pairing (with badge like "labels"), we could have that at the top of an expanded list. And then we could have a secondary list below that.

Like this:

storage-pools-2021-02-16-1545(2)

And the deactivated state could use an empty state pattern when expanded:

storage-pools-2021-02-16-1545(3)

Allow Virtual Machines migrations

Page: Machines

Allow to migrate VMs among different servers added in Cockpit.
Considering Cockpit is replacing virt-manager, this feature is quite important.

Machines: look at libvirtd.socket

Starting in Fedora 31, libvirt now ships a libvirtd.socket which can activate libvirtd.service on demand. That means that the Machines page's service detection should start to look at both, and not simply show the "service is not active" empty state pattern if libvirtd.socket is running, but libvirtd.service is not. This is aggravated by the fact that the empty state pattern doesn't go away when libvirtd.service starts.

machines: Ability to change MAC address for a VM

Hello,

I like to define my own MAC addresses for some of my VMs. Unfortunately, the edit VM UI does not allow me to change the MAC address. This would be nice, I do not think there would be big benefit having this on the new VM UI, just edit VM.

This is just a nice to have. Thanks!

Dependencies seem to use LGPL-3.0+

Cockpit version: 238.1

From the dependencies,

    "@patternfly/react-console": {
      "version": "1.10.46",
      "resolved": "https://registry.npmjs.org/@patternfly/react-console/-/react-console-1.10.46.tgz",
      "integrity": "sha512-uk84hxQ1OjfJwctikPX/jfYxVLHG6pqA+EH7l2BcDDEDqfm0yBqa859Klg6z2wxRt30erGy0ag4tHOQIx2MymA==",
      "requires": {
        "@novnc/novnc": "^1.0.0",
        "@spice-project/spice-html5": "^0.2.1",

The spice-html5 is licensed under LGPL-3.0+. Does this mean that Cockpit should be licensed under LGPL-3.0+ instead now as the spice-project is incorporated in the generated files?

machines: Address Machines details page changes in follow-ups

This is a meta-issue to cover additional issues brought up in cockpit-project/cockpit#14346. Ideally, we should handle these within the next few weeks:

  • disk and networks list need to be adjusted as well (this needs design, it was created at some point but I can't find it)
  • autostart to be converted to switch (#346)
  • hide usage when machine isn't running (kk: I disagree with it as it will make the cards jump around when the user starts the VM)
  • expand icon should be changed to maximize / fit-to-screen icon and have some kind of text
  • hide expand arrow on console when machine isn't running (#346)
  • move main VM list into a card
  • change ct-form info into some variant of a PF4 description list (last usage is bootorder dialog which is about to get completely rewritten #191)
  • change the title from Networks to Network interfaces
  • remove crufty legacy CSS
  • Investigate showing logs per VM (I am not sure about this, we can show /var/log/libvirt/qemu/testvm.log but it's just qemu CLI)
  • change button priority — cockpit-project/cockpit#14593, but also consider this across all of Cockpit (this might be better as a Cockpit-wide PR)
  • try to figure out what to do about the text-mode console (VNC mode is fine and scales)

What we cannot quickly address in this next round of changes should be moved out to separate issues.

Network Bridge Operation not Supported

Cockpit version: Version 225.
OS:
Page: /machines

I'm trying to add a new network interface to bridge to my network, however when I select the following options:
image
I get Unable to add bridge enp3s0 port vnet0: Operation not supported

Steps to reproduce

  1. Create new VM (Ubuntu Server 19.04) on Debian
  2. Create New Network Interface with the options above
  3. Try to start machine

There is Ooops after importing a vm and the whole Virtual Machines doesn't work for lower browser version

Cockpit version: cockpit-232-1.fc33.x86_64
OS:Fedora33
Page: cockpit-machines-232-1.fc33.noarch
Chrome:Version 79.0.3945.88 (Official Build) (64-bit)
Firefox:62.0.3 (64-bit)

There is Ooops after importing a vm and the whole Virtual Machines doesn't work for lower browser version

P.S.:
Not sure whether it's the same root cause with cockpit-project/cockpit#14936, let me file it here in case not
The problem is gone after upgrade Chrome to: Version 87.0.4280.66 (Official Build) (64-bit)

Steps to reproduce

  1. Prepare Fedora33 and cockpit env, and an existing image:
    /var/lib/libvirt/images/cirros.qcow2
  2. Open Virtual Machines page, click Import VM and import the image in step 1, click import

There is Ooops , and the the whole Virtual Machines doesn't work, reboot or refresh doesn't help, the error message:
Refused to apply style from 'http://10.66.144.41:9090/cockpit/$5c00d0ee343098d381fda39264c84983b56c785f81d4c6d9091eca8f68647a5d/shell/nav.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.
ostree.js:303 Refused to apply inline style because it violates the following Content Security Policy directive: "default-src 'self' http://10.66.144.41:9090". Either the 'unsafe-inline' keyword, a hash ('sha256-47DEQpj8HBSa+/TImW+5JCeuQeRkm5NMpJWZG3hSuFU='), or a nonce ('nonce-...') is required to enable inline execution. Note also that 'style-src' was not explicitly set, so 'default-src' is used as a
fallback.
p @ ostree.js:303
t.inject @ ostree.js:303
t.a @ ostree.js:303
(anonymous) @ ostree.js:3
(anonymous) @ ostree.js:3
n @ ostree.js:1
(anonymous) @ ostree.js:327
n @ ostree.js:1
(anonymous) @ ostree.js:303
n @ ostree.js:1
(anonymous) @ ostree.js:1
(anonymous) @ ostree.js:1
cockpit.js:621 grep: /sys/class/dmi/id/power/autosuspend_delay_ms: Input/output error
p @ cockpit.js:621
m @ cockpit.js:631
v @ cockpit.js:526
a.onmessage.o.dispatch_data @ cockpit.js:456
e @ cockpit.js:312
postMessage (async)
(anonymous) @ index.js:34
a.onmessage.o.dispatch_data @ cockpit.js:454
cockpit.js:621 Usage:
ostree remote list [OPTION…]
List remote repository names
Help Options:
-h, --help Show help options
Application Options:
--repo=PATH Path to OSTree repository (defaults to current directory or /sysroot/ostree/repo)
-u, --show-urls Show remote URLs in list
-v, --verbose Print debug information during command processing
--version Print version information and exit
error: Command requires a --repo argument
p @ cockpit.js:621
m @ cockpit.js:631
v @ cockpit.js:526
a.onmessage.o.dispatch_data @ cockpit.js:456
e @ cockpit.js:312
postMessage (async)
(anonymous) @ index.js:34
a.onmessage.o.dispatch_data @ cockpit.js:454
machines.js:345 TypeError: t.toLowerCase(...).replaceAll is not a function
at Ks (machines.js:361)
at Ga (machines.js:345)
at _s (machines.js:345)
at cl (machines.js:345)
at sl (machines.js:345)
at Zs (machines.js:345)
at machines.js:345
at t.unstable_runWithPriority (machines.js:353)
at Ui (machines.js:345)
at qi (machines.js:345)

Screenshot from 2020-11-25 12-27-35

machines: add 'bridge' forward mode in create network dialog

Cockpit version: 164-1
OS: Ubuntu Server 18.04.04
Page: "Network"

By default, VMs are put in "default" bridged network

    <interface type='network'>
      <mac address='52:54:00:cf:cc:50'/>
      <source network='default'/>
      <model type='virtio'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
    </interface>

default network confg

horseinthesky@KVM:~$ sudo cat /etc/libvirt/qemu/networks/default.xml 
<!--
WARNING: THIS IS AN AUTO-GENERATED FILE. CHANGES TO IT ARE LIKELY TO BE
OVERWRITTEN AND LOST. Changes to this xml configuration should be made using:
  virsh net-edit default
or other application using the libvirt API.
-->

<network>
  <name>default</name>
  <uuid>282e4832-14d1-4ed4-9070-b8a3f2ef29eb</uuid>
  <forward mode='nat'/>
  <bridge name='virbr0' stp='on' delay='0'/>
  <mac address='52:54:00:44:8a:d9'/>
  <ip address='192.168.122.1' netmask='255.255.255.0'>
    <dhcp>
      <range start='192.168.122.2' end='192.168.122.254'/>
    </dhcp>
  </ip>
</network>

I want to put it into host network mgmt

horseinthesky@KVM:~$ ip -c a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: ens160: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master mgmt state UP group default qlen 1000
    link/ether 00:0c:29:b9:9d:fb brd ff:ff:ff:ff:ff:ff
3: mgmt: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 5a:47:9e:2a:e7:40 brd ff:ff:ff:ff:ff:ff
    inet 192.168.0.186/24 brd 192.168.0.255 scope global mgmt
       valid_lft forever preferred_lft forever
    inet6 fd1b:3198:44bb:0:5847:9eff:fe2a:e740/64 scope global dynamic mngtmpaddr noprefixroute 
       valid_lft 6870sec preferred_lft 1470sec
    inet6 2a02:2168:91d0:6300:5847:9eff:fe2a:e740/64 scope global dynamic mngtmpaddr noprefixroute 
       valid_lft 1104sec preferred_lft 1104sec
    inet6 fe80::5847:9eff:fe2a:e740/64 scope link 
       valid_lft forever preferred_lft forever

But changing default network config via virsh net-edit default to this:

horseinthesky@KVM:~$ sudo cat /etc/libvirt/qemu/networks/default.xml 
<!--
WARNING: THIS IS AN AUTO-GENERATED FILE. CHANGES TO IT ARE LIKELY TO BE
OVERWRITTEN AND LOST. Changes to this xml configuration should be made using:
  virsh net-edit default
or other application using the libvirt API.
-->

<network>
  <name>default</name>
  <uuid>282e4832-14d1-4ed4-9070-b8a3f2ef29eb</uuid>
  <bridge name='mgmt' stp='on' delay='0'/>
  <mac address='52:54:00:73:6f:4a'/>
</network>

Making me unable to start the VM
image

How can I change the setting to attach all VMs to host mgmt bridge?

Installation source in the 'Import VM' dialog should be renamed

Hello,

I have an existing LVM volume group full of VMs and I reinstalled my OS and started using cockpit to manage those. However I am not able to create VMs as the selection of options is the following:

  • Download OS
  • Cloud-base image
  • Local installation
  • URL
  • PXE

Neither of these options work for me, there is no "installation source" I want to use, my image already is installed.

I am leaving this here as a "nice to have" feature some day. Great job guys, love Cockpit from the day one! :-)

Machines: No ability to add consoles to existing VMs

Page: Machines

During the latest round of usability testing, we found that 8 out of 11 users had issues figuring out what caused performance issues on a VM. One of the things almost all of them tried was connecting to the VM via the console, but it did not work. This is most likely because there was no session to connect to for those VMs. @KKoukiou suggested we should add that ability, and @marusak added that "maybe as we do in docker/podman. If there is TTY, connect to it, otherwise create a new session and connect to it"

machines: Better expose the memory values in progress bars

Cockpit version: 215
OS: Ubuntu 20.04 LTS
Page: Virtual Machines

When creating a VM, the VM uses more memory than is allocated to it during an OS install and during regular usage.

Steps to reproduce

  1. Create a virtual machine (Ubuntu 20.04 LTS, 20 GiB storage, 3 GiB RAM)
  2. Monitor the memory usage as the virtual machine is being installed
  3. Memory usage is highest on the "Select and install software" step.
  4. Notice that more than 3 GiB RAM is in use for that VM. I observed up to 4 GiB in use.
  5. Run a memory-intensive program on the computer (for instance, installing GNOME desktop through apt)

cockpit_extra_memory

Is this expected behavior? The recommended memory requirement for Ubuntu is 1 GiB according to Ubuntu Server docs.

Incorrect wording on Import VM page

It says Installation source while this should probably be Existing image or something like that. Importing is the process when OS usually does not get installed.

image

machines: can't connect to the spice address

Cockpit version: 183
OS: Fedora 28
Page: Machines

I have a VM running on a remote server. I wanted to connect to it using GNOME Boxes. I inputted the address it told me in Cockpit, but it didn't work.

Steps to reproduce

  1. Go to the VM page in Cockpit
  2. Select an existing VM and run it.
  3. Go to the Consoles page
  4. Copy the address there
  5. Open GNOME Boxes
  6. Under the Remote tab, select New and input the address.
  7. Boxes fails to connect

screenshot from 2019-02-21 12-26-45

screenshot from 2019-02-21 12-25-54

screenshot from 2019-02-21 12-26-37

Virtual Machine IP listed as unknown when VM connected via Bridge

Cockpit version: 220
OS:Fedora 32
Page: Machines

I am creating my virtual machines from Cockpit. There is a bridge connection for my machines to reach host network and VM's connect to network via bridge. When I add the VM to bridge machine connected to external DHCP and take IP address but it still shows as Unknown in Network Interfaces tab. In virt-manager I can see the VM's IP.

Steps to reproduce

  1. Create a bridge network
  2. Create a virtual machine
  3. Add this bridge connection from Network Interface
  4. Run VM and see ıf it is getting an IP from DHCP
  5. Check network interfaces tab to see IP set to unknown or VM's IP

'Ipv4 network' field is misleading in virtual networks

In the "Virtual Machine" -> "Virtual Network" -> "Create virtual network", it was asking me for:
"Ipv4 network:", this should be changed to "Ipv4 address", as i did write xx.xx.xx.0 there, and was struggling in many days to figure why the VMs did not have network.
Based on how this is written and the rest of fields, it is easy to think it should be an address like 192.168.1.0.
So I just suggest to change that field to be more clearly written.

machines: Guidance about what might be causing performance issues

It's currently difficult to know which VMs are using resources.

Switching from circle graphs hidden in tabs to usage bars in the VM details page PR is a step in the right direction.

It would be nice to be able to pull over some of the concepts of resource usage from the Overview and Performance pages to the Machine page.

Ideas:

  • Current health status:
    • if a VM has constant load, show an indicator icon in the VM list (on the overview) and details page
    • show CPU & memory usage relative to the host machine on the VM overview page
  • On the details page, show:
    • Current resource usage within the VM... if this is even possible

Machines: domain xml metadata lost when create-install are done in two steps

Cockpit version: 221
OS: debian 10 with debian-backports for cockpit (221.1-1~bpo10+1)
Page:
Machines

When I do on the cokpit web interface:
1/ create a VM without starting it (uncheck the start immediately) in cockpit machines, using URL
https://cdimage.debian.org/debian-cd/current/amd64/iso-cd/debian-10.4.0-amd64-netinst.iso
and OS type "debian 10"
2/ change the network interface (to a bridge vlan10)
3/ then edit it with virsh edit (add metadata and change network interface)
metadata added:

    <ttnn:config xmlns:ttnn="http://tetaneutral.net/">
      <ttnn:network mode="routed">
        <ttnn:tap name="tapvm1">br0 U1 T10</ttnn:tap>
      </ttnn:network>
    </ttnn:config>

interface edited to an ethernet tap:

    <interface type='ethernet'>
      <mac address='52:54:00:d6:d4:e3'/>
      <target dev='tapvm1'/>
      <model type='virtio'/>
      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
    </interface>

3/ then click on "install" via cockpit, metadata I added is lost, interface change are overwritten
with virsh dumpxml after clicking on install shows metadata is lost:

  <metadata>
    <libosinfo:libosinfo xmlns:libosinfo="http://libosinfo.org/xmlns/libvirt/domain/1.0">
      <libosinfo:os id="http://debian.org/debian/10"/>
    </libosinfo:libosinfo>
  </metadata>

Attached files :

vm8-before.xml => when I'm done with create without starting
vm8-edit.xml => I add metadata and change interface with virsh edit
vm8-install.xml => I clicked on install

Renaming virtual machines

Page: Virtual Machines

It would be nice to have the option to rename existing virtual machines in order to better distinguish between multiple VMs on the same host.

vv file is wrong. Fails to open remote session to VM.

Cockpit version: that witch ships with fedora 33
OS: fedora 33 (cockpit + qemu-kvm) and Ubuntu 20.04 (client)
Page:
remote to VM

when you create a VM in cockpit, the vm is inaccessible using the tool in cockpit. You CANNOT connect to the VM console using virt-viewer and the vv file downloaded:
[virt-viewer]
type=spice
host=127.0.0.1
port=5900
delete-this-file=1
fullscreen=0

[...............................GraphicsConsole]

Should the host not be the ip of the server hosting the vm?

Do you do some kind of loop-back magic that does not work?

I have no idea where to even begin... hard to find documentation that is helpful.

Steps to reproduce
From an Ubuntu client:

  1. make VM on the fedora box via cockpit
    image

  2. click on "launch remote viewer"
    image

  3. watch it fail
    image

The intention is that this should work I presume? Otherwise why would there be a button at all?

Machines: polkit rules not called by cockpit/libvirt

Fedora 32
cockpit 223-1
cockpit-machines 223-1

  • Using cockpit https web interface on port 9090
  • There is a virtual machine "vmtest" created using cockpit and running, visible and manageable by root.
  • I created a login with no particular priviledge and want to give it access to some management function over the VM in cockpit web interface
  • As suggested on IRC I tried polkit
    https://libvirt.org/acl.html
    https://libvirt.org/aclpolkit.html

Here is what I did:

# id test1
uid=1010(test1) gid=1010(test1) groupes=1010(test1)
# cat /etc/polkit-1/rules.d/100-libvirt-acl.rules 
polkit.addRule(function(action, subject) {
    if (subject.user == "test1") {
       polkit.log("action=" + action);
       polkit.log("subject=" + subject);
       if (action.id == "org.libvirt.api.domain.getattr") {
          if (action.lookup("domain_name") == 'vmtest') {
            return polkit.Result.YES;
          } else {
            return polkit.Result.NO;
          }
       }
   }
});

## edit libvirtd.conf to add polkit as access_driver
# grep access_driver /etc/libvirt/libvirtd.conf
access_drivers = [ "polkit" ]

## restart both 
# systemctl restart polkit
# systemctl restart libvirtd

login as test1 on https://localhost:9090
I see "Limited Access" on the top right of the web page
When I click on "machine" I see no machine at all and the polkit.log don't appear in journalctl -u polkit

After I while I see only:

# journalctl -u polkit|grep 100-libvirt
 polkitd[176528]: /etc/polkit-1/rules.d/100-libvirt-acl.rules:3: action=[Action id='org.freedesktop.login1.inhibit-delay-shutdown']
 polkitd[176528]: /etc/polkit-1/rules.d/100-libvirt-acl.rules:4: subject=[Subject pid=179294 user='test1' groups=test1 seat=null session=null local=false active=true]

The issue seem that with my setup polkit rules don't seem to be called by cockpit/libvirt.

Drop publish-dist retry loop

I don't like this loop, and I think we should be doing this differently:

  • on pull requests, we should push only a tag, as a commit on top of the most recent commit on the main branch.
  • on merge to main, we then push an update also to the main branch here

random PRs ending up on the main branch seems weird, and is also exactly the source of the potential conflict here.

thoughts?

Originally posted by @allisonkarlitskaya in #84 (comment)

Passthrough PCIE Devices

Page: Machines

It would be great if PCIE devices such as GPU and NIC could be passed to VMs using this.

cockpit-machines: GRAPHICS_PARAM should check for qemu.conf listen configuration, but 127.0.0.1 is hardcoded

Cockpit version: 217
OS: Fedora 32
Page: Machines

Issue Description

When creating a VM via the cockpit interface, the listening address for external SPICE and VNC viewers will always be 127.0.0.1. Setting the default listen address in /etc/libvirt/qemu.conf has no effect on this, because the 127.0.0.1 address is hardcoded in GRAPHICS_PARAM

Steps to reproduce

  1. Install cockpit, libvirtd, cockpit-machines, and all other relevant packages.
  2. Modify /etc/libvirt/qemu.conf to define vnc_listen and spice_listen as = "0.0.0.0". restart libvirt etc.
  3. Create a VM via the web interface.

Actual results:
A VM is created and VNC & SPICE are bound and listening to 127.0.0.1

Expected results:
VNC & SPICE should be listening to the address as it is defined in qemu.conf, and 127.0.0.1 by default otherwise.

Mouse clicks does not work

Hi,

I'm using cockpit with my KVM server, but since last update i can´t install anything using the web console because my clicks on the mouse doesn't reflect on the screen. Do you know how to fix this?
Thank you

vnc password in /etc/libvirt/qemu.conf breaks cockpit vnc console

Cockpit version: 215
OS: Ubuntu server 20.04
Page: machines, consoles tab

I want to use both cockpit browser based vnc console and external vnc desktop viewers (krdc and remmina).

The problem is when I set the vnc_password in /etc/libvirt/qemu.conf to allow external vnc viewers to connect, it breaks the browser based vnc console.

When I disable vnc_password in /etc/libvirt/qemu.conf the browser based vnc console works but all external vnc viewers are refused.

Steps to reproduce

  1. uncomment vnc_password in /etc/libvirt/qemu.conf
  2. service libvirtd restart
  3. goto machines console tab (shows connecting but never loads.)

screenshots
https://askubuntu.com/questions/1301001/setting-vnc-password-in-etc-libvirt-qemu-conf-breaks-cockpit-vnc-console

Machine: No support for rbd pools

Hello,

I noticed in the code that there is no support for rbd pool types in Cockpit, even though they are supported in libvirt.

What is missing to add support for it?

Thank you

Support configuring static guest IP addresses by using the libvirt networks

Page: Machines > Network

Problem
As a sysadmin, I want to have some VMs use static network addresses, so I need to limit the DHCP range on that subnet.

User story
Jeff is a new Linux admin. He's done a lot of system administration in the past, but on other OSes.
He runs a couple of VMs on a virt host that he manages using cockpit.
He has a VM that he wants to keep using the same addresses all the time, so that all the other VMs can reach it in a predictable manner.

He logs in to the web console, dives into the VM and sets it's address to the static address 192.168.122.254.
He then edits it's virtual network to only give out new addresses and changes the DHCP range from 192.168.122.2-192.168.122.254 to 192.168.122.2-192.168.122.253
Now the DHCP server for the virtual network won't be able to accidentally hand out the 192.168.122.254 address.

machines: Accessibility issues

On the Machines page, there are the following a11y issues;

Details page:

  • The description list has children elements of the <dl> that are not <dt> or <dd> elements, the only two elements that it may contain (although those elements can have other elements as children)

Storage pool:

  • Progress bars lack accessible names. They should use aria-label/aria-labelledby/title or, in this case, aria-hidden="true" or role="presentation" as they visually present textual information immediately to the side.

Networks:

  • The description list has children elements of the <dl> that are not <dt> or <dd> elements (see above)
  • Autostart checkbox lacks label. The text "Run when host boots" should be either included next to the checkbox and both the text and the checkbox wrapped with <label> or the text should be wrapped <label for=""> with the for pointing to the (unique) ID of the checkbox. Also: It appears as though this might not be a PF4 checkbox.

Virtual Machines Consoles connects to VMs only on main Cockpit host on other connected Cockpits

Cockpit version: 217
OS: Fedora 32
Page: Virtual Machines -> [Virtual machine] -> Consoles Tab

When using Consoles in Cockpit for virtual machines on a remotely connected Cockpit it will connect to/show the wrong virtual machine.

Steps to reproduce:

  1. Prepare two Cockpit instances both with "Virtual Machines" set up. The cockpit plugin as well as actual virtual machines to connect to.
  2. Connect one Cockpit to the other to be able to access both via one Cockpit instance.
  3. Navigate to the Virtual Machines section on the "main" Cockpit instance and open the console to access a virtual machine. This will show the correct VM.
  4. Navigate to the Virtual Machines section on a connected Cockpit and try accessing a VM via the Consoles. This will show the wrong virtual machine.

A screen recording says more than 131 words:

cockpit_vm_confusion

Machines list: misalignment of action widgets (needs lib sync?)

There was a regression in the alignment of the actions in the top-right of the machines list (probably related to a PF update), but it was fixed in Cockpit before the split. It has regressed again.

Screenshot from 2021-04-14 11-25-38

As this was already fixed, syncing over the latest versions of the common libraries used by Cockpit would most likely fix this again.

Request: Shared folder host / virtual machine (libvirtd)

Page:
Virtual Machine / Libvirtd

I wish it was an feature in cockpit to configure a shared folder between the host and the virtual machine. Currently it is possible to use NFS-share, and I have explored (googled) and figured out it would be possible with some custom configuration.

RFE: Machines - network: support macvlan

Page: Machines

Under Virtual Machine | Network | Create a Network

Support the creation of macvlan bridge types that allow VMs direct access to the "wire" without passing thru a host bridge/switch

writeup: https://blog.scottlowe.org/2016/02/09/using-kvm-libvirt-macvtap-interfaces/

The host interface can remain without IP, and the guest VM MAC is exposed directly on the wire. Unlike macvlan "direct" still allows guest/host communication without VEPA enabled switches.

macvlanX interfaces show up as unmanaged interfaces in Networking page.

Feature Request: Snapshot and Backup System

It would be cool if there was a way to make a snapshot or have automatic backups.

This is how I like to make my backups via CLI if it gives any ideas:

virsh suspend domain
rsync -avP /var/lib/libvirt/images/domain.qcow2 /bak/
virsh resume domain
gzip /bak/domain.qcow2

virsh also has snapshot stuff built in already.

# virsh help | grep snapshot-
    snapshot-create                Create a snapshot from XML
    snapshot-create-as             Create a snapshot from a set of args
    snapshot-current               Get or set the current snapshot
    snapshot-delete                Delete a domain snapshot
    snapshot-dumpxml               Dump XML for a domain snapshot
    snapshot-edit                  edit XML for a snapshot
    snapshot-info                  snapshot information
    snapshot-list                  List snapshots for a domain
    snapshot-parent                Get the name of the parent of a snapshot
    snapshot-revert                Revert a domain to a snapshot

NFS and VM Permissions

Cockpit version: 224.2.
OS: Cent0S 8
Page: Virtual Machines, VM, Add Disk

This maybe an issue to do with NFS. When I create a new disk on block-based storage the file permissions are correctly set - and the VM starts-up.

When I create a disk on NFS mount the permission doesn't allow the VM to start.

The error in cockpit reads:

internal error: process exited while connecting to monitor: 2021-03-27T07:18:00.959587Z qemu-kvm: -blockdev {"driver":"file","filename":"/containers/test.qcow2","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}: Could not open '/nfsexport/test.qcow2': Permission denied

The output of the ls command reads as:

-rw-------. 1 1024 users 193K Mar 27 2021 test.qcow2
-rwxrwxrwx. 1 1024 users 3.5G Mar 27 2021 os.qcow2

The odd thing when I do this on a block based storage - the permission on the test.qcow2 disk is also -rw....

machines: Add support for cloud-init options in create VM dialog

Page: Machines

As a sysadmin, I want to be able to create VMs from images that doesn't have a hardcoded root password and sign in to those easily

If I download the RHEL 8.0 qcow2 image from redhat.com, it doesn't come with any account.
This is a pretty common issue, judging from the number of comments in the solution article on redhat.com
There are a couple of ways to fix it, either do some dance with guestfs, use virt-customize or cloud-init.

This also goes for the qcow2 images built with Composer, where you don't hardcode a username and password into the image (and that might not always be desirable).

It would be great if cockpit could pass a cloud-init configuration on the fly. Ideally reusing credentials that's already on the host.

Wrong memory limit in create VM when libvirt is started for fist time via cockpit in a fresh install

Cockpit version: cockpit-240-1.fc33.x86_64
OS: F33 with latest updates

Hey guys,

I just installed completely fresh F33, updated, rebooted, enabled Cockpit and when creating new VM the form does not allow me to put more than 1 GiB of memory while my host has 32 GB of RAM.

I have found this: I started libvirt from cockpit itself. Just to experience how it would be to install and manage services through cockpit, it was nice sure, but it looks like when the libvirt daemon is started through cockpit, some kind of maximum memory limit is applied (by systemd or namespaces?).

Anyway, workaround for the problem is to restart the libvirtd from a terminal and then it works.

Cheers!

machines: Unattended installation breaks with underscores in hostnames

  1. Create an Ubuntu machine on the VM page
  2. Name type something like "ubuntu server", which gets changed to "ubuntu_server"
  3. Select unattended installation
  4. Let Cockpit install
  5. While the disk is named appropriately, installation fails due to an invalid hostname

Failure screen:

Screenshot_2021-03-18 Virtual Machines - garrett Rain(4)

Context:

Screenshot_2021-03-18 Virtual Machines - garrett Rain(3)

This may happen with other distros, most likely Debian as well. Unsure if it happens with Fedora/CentOS/RHEL or others.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.