From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Bareiro Subject: Re: Administration panel for KVM Date: Sun, 10 Apr 2011 11:59:39 -0300 Message-ID: <20110410145939.GC10576@defiant.freesoftware> References: <20110409194804.GS26511@defiant.freesoftware> <4DA19BE9.307@tu-berlin.de> Reply-To: dbareiro@gmx.net Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="JgQwtEuHJzHdouWu" To: KVM General Return-path: Received: from mailout-de.gmx.net ([213.165.64.23]:45669 "HELO mailout-de.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1753772Ab1DJO7p (ORCPT ); Sun, 10 Apr 2011 10:59:45 -0400 Received: from defiant (defiant.freesoftware [10.1.0.65]) by hermes.freesoftware (Postfix) with ESMTP id D2FDB29CF7 for ; Sun, 10 Apr 2011 11:59:45 -0300 (ART) Content-Disposition: inline In-Reply-To: <4DA19BE9.307@tu-berlin.de> Sender: kvm-owner@vger.kernel.org List-ID: --JgQwtEuHJzHdouWu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sunday, 10 April 2011 14:00:41 +0200, Matthias Hovestadt wrote: > Hi! Hi, Matthias! > > With a group of college buddies, we are evaluating the possibility of > > initiating a project to develop a management panel of KVM virtual > > machines. The idea is to do something similar to OpenXenManager but for > > KVM. > At out university we developed a Perl-based management tool named > "kvm-top". This tool is command-line only, not offering any GUI at > the moment. The initial idea of that tool was to make the start-up of > VMs easier than doing it manually. The tool analyzes a VM-specific > config file like >=20 > GUEST_ID=3D219 > GUEST_NAME=3Dattic > . > . >=20 > defining all parameters for starting up a VM. For actually starting > this VM, a single command now is sufficient: >=20 > asok01 ~ # kvm-top -start attic >=20 > This will not only start-up the VM "attic", but also check if this VM > is running on some other cluster node and connect to the iSCSI target > if required. >=20 > Meanwhile, the tool has evolved, not only consisting of the "kvm-top" > tool, but also a server component named "kvm-ctld" running on each > cluster node. The "kvm-top" tool connects to the "kvm-ctld" running > on the local host, executing the desired command. At this, the > command does not nessecarily have to be executed on the same cluster > node. For instance, it is easily possible to start/stop a VM running > on a different cluster node. >=20 >=20 > However, the main feature of "kvm-top" is giving information about > the current status of the running VMs: >=20 > asok01 ~ # kvm-top > VM NODE AS 5s 30s USER PID #CPU MEM VNC SPICE #LAN > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > attic asok02 4 4 root 6614 1 2048 36003 - 2 > cbase asok08 1 1 root 10222 1 1048 36142 - 1 > cbase-spice asok08 0 0 root 4269 1 1024 36143 5924 1 > cloud-pj asok02 14 18 root 24071 1 1024 36001 - 2 > . > . > . >=20 > where "5s" and "30s" contain the average system load over the last > 5s resp. 30s. There are serveral ways of filtering or sorting the > output, e.g. sorting by cluster nodes: >=20 > asok01 ~ # kvm-top -s node > NODE VM AS 5s 30s USER PID #CPU MEM VNC SPICE #LAN > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > asok01(ENABLED): 0(0) VMs, CPU=3D0%, MEM=3D2%, AGE 00:00 > asok02(ENABLED): 7(8) VMs, CPU=3D13%, MEM=3D99%, AGE 00:05 > attic 4 4 root 6614 1 2048 36003 - 2 > cloud-pj 21 19 root 24071 1 1024 36001 - 2 > . > . >=20 >=20 > The "kvm-top" tool even allows migration of VMs between the cluster > nodes. The following command would migrate the VM "attic" from the > currently used cluster node "asok02" to cluster node "asok07" (note: > the command has been executed on a different cluster node "asok01"): >=20 > asok01 ~ # kvm-top -migrate attic asok07 >=20 >=20 > As I mentioned, the tool is command line only at the moment, however it > shouldn't be too difficult to create a web-based interface, since the > kvm-ctld allows communication not only with kvm-top. Connecting to the > port of kvm-ctld, it's pretty easy to get information about all > currently running VMs or start/stop/migrate VMs. >=20 >=20 > If there's interest in that tool, please let me know. I'll gladly > publish it. Sounds interesting. If you publish it, I'd take a look. Researching on the Internet I found virt-manager [1], although I'm not sure if it can interact with KVM. In any case, virt-manager uses libvirt and my idea was not to use libvirt in the VMHost. I guess "kvm-ctld" will supply some of the functions of libvirt at the remote end. Thanks for your reply. Regards, Daniel [1] http://virt-manager.et.redhat.com/ --=20 Fingerprint: BFB3 08D6 B4D1 31B2 72B9 29CE 6696 BF1B 14E6 1D37 Powered by Debian GNU/Linux Lenny - Linux user #188.598 --JgQwtEuHJzHdouWu Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAk2hxdsACgkQZpa/GxTmHTdr7QCfa75GYiiKdVSUwshQvkxQ6b4a 83wAn0tKuWVoW1LCyink/ZOJHPXXD0jl =kdkx -----END PGP SIGNATURE----- --JgQwtEuHJzHdouWu--