Re: [libvirt] [PATCH] Added timestamps to storage volumes

2012-08-03 Thread Hendrik Schwartke
Thanks for your support Eric! Hendrik On 03.08.2012 01:14, Eric Blake wrote: On 07/25/2012 01:43 AM, Hendrik Schwartke wrote: The access, birth, modification and change times are added to storage volumes and corresponding xml representations. Listing the actual output XML in the commit

Re: [libvirt] [PATCH v3 0/2] capture network traffic

2012-07-30 Thread Hendrik Schwartke
Hi, it would be nice if someone could have a short look at my patch. I'm not quite sure if i did the error handling correct and how to avoid the "end of file while reading data" error. Thanks! Hendrik On 26.07.2012 13:15, Hendrik Schwartke wrote: Thanks again for your

Re: [libvirt] [PATCH] Added timestamps to storage volumes

2012-07-30 Thread Hendrik Schwartke
Hi Eric, could you give me a short feedback on the status of my patch? Thanks Hendrik On 25.07.2012 09:43, Hendrik Schwartke wrote: The access, birth, modification and change times are added to storage volumes and corresponding xml representations. --- bootstrap.conf|1

[libvirt] [PATCH v3 2/2] Add the command iface-capture to virsh

2012-07-26 Thread Hendrik Schwartke
The purpose of the iface-capture command is to sniff network traffic on a (remote) interface. E.g. "virsh iface-capture virbr0 icmp --promisc | tcpdump -n -r -" prints all icmp pakets on stdout. --- tools/virsh.c | 87 + 1 file changed, 87

[libvirt] [PATCH v3 1/2] Add virNetDevCapture

2012-07-26 Thread Hendrik Schwartke
e GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + * Auth

[libvirt] [PATCH v3 0/2] capture network traffic

2012-07-26 Thread Hendrik Schwartke
ow to avoid the "End of file while reading data" error when closing the stream. So, please review the whole thing. Hendrik Hendrik Schwartke (2): Add virNetDevCapture Add the command iface-capture to virsh include/libvirt/libvirt.h.in | 13 +++ src/Makefile.am |1

Re: [libvirt] Dumping network traffic

2012-07-26 Thread Hendrik Schwartke
Thanks for your detailed comments on that! And yes, it felt strange to put that pcap-code in netcf_driver.c. So I will move the code to src/util/virnetdevcapture.{c,h}, as suggested by Daniel and rename the the functions *.capture. Meanwhile I had written v2. The code is still in netcf_driver.c

[libvirt] [PATCH 1/2] Add virInterfaceDumpTraffic

2012-07-25 Thread Hendrik Schwartke
With virInterfaceDumpTraffic network traffic can be sniffed on an interface an send via the streaming api to a remote client. --- include/libvirt/libvirt.h.in |6 ++ src/driver.h |9 ++ src/interface/netcf_driver.c | 217 ++ src/libv

[libvirt] [PATCH 0/2] Dumping network traffic with libvirt

2012-07-25 Thread Hendrik Schwartke
which use streams but couldn't find a solution for this. However, it would be nice if someone could have a look at the patches. Thanks Hendrik Hendrik Schwartke (2): Add virInterfaceDumpTraffic Add the command iface-dumptraffic to virsh include/libvirt/libvirt.h.in |6 +

[libvirt] [PATCH 2/2] Add the command iface-dumptraffic to virsh

2012-07-25 Thread Hendrik Schwartke
The purpose of the iface-dumptraffic command is to sniff network traffic on a (remote) interface. E.g. "virsh iface-dumptraffic virbr0 icmp --promisc | tcpdump -n -r -" prints all icmp pakets on stdout. --- tools/virsh.c | 84 + 1 file chan

[libvirt] [PATCH] Added timestamps to storage volumes

2012-07-25 Thread Hendrik Schwartke
The access, birth, modification and change times are added to storage volumes and corresponding xml representations. --- bootstrap.conf|1 + docs/formatstorage.html.in| 16 docs/schemas/storagevol.rng | 34 ++ src/conf/

[libvirt] changed timestamp format

2012-07-25 Thread Hendrik Schwartke
Hi Eric, I changed the timestamp format again. I hope the following patch is ok now. Is stat-time ready to be added in bootstrap.conf or is there anything to do? regards Hendrik -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

[libvirt] Dumping network traffic

2012-07-23 Thread Hendrik Schwartke
I'm currently working on a feature that dumps the network traffic of a virtual interface over the streaming api of libvirt. The goal is to offer the possiblity to debug network related problems of guests without the need to have access to a shell on the host. E.g. "virsh iface-dumptraffic virbr0

[libvirt] [PATCH] Proof of concept on dumping network traffic with libpcap

2012-07-23 Thread Hendrik Schwartke
--- include/libvirt/libvirt.h.in |2 ++ src/driver.h |9 + src/interface/netcf_driver.c | 80 ++ src/libvirt.c| 47 + src/libvirt_public.syms |5 +++ src/remote/remote_driver.c

Re: [libvirt] [PATCH] Added timestamps to storage volumes

2012-07-20 Thread Hendrik Schwartke
On 19.07.2012 16:08, Eric Blake wrote: On 07/19/2012 01:13 AM, Hendrik Schwartke wrote: I reconsidered the way timestamps are represented. I think that an event at 100.91 happened before 100.200 is misleading. Yep, definite bug - you have to zero-pad the subsecond resolution, and also consider

[libvirt] [PATCH 2/2] Add stat-time to get timestamps

2012-07-19 Thread Hendrik Schwartke
!!! DON'T PUSH until stat-time lgpl 3 issue is fixed !!! To tests this change lgpl version to 3 in bootstrap.conf:176 stat-time offers a much cleaner way of getting timestamps than the current implementation. Therefor the implementation is changed. --- bootstrap.conf|1 + src/

[libvirt] [PATCH 1/2] Added timestamps to storage volumes

2012-07-19 Thread Hendrik Schwartke
The access, birth, modification and change times are added to storage volumes and corresponding xml representations. --- docs/formatstorage.html.in| 27 +++ docs/schemas/storagevol.rng | 39 +++ src/conf/storage_conf.c |

Re: [libvirt] [PATCH] Added timestamps to storage volumes

2012-07-19 Thread Hendrik Schwartke
econd patches the first and does use stat-time. I would be nice if at least the first one could be commited before the next version is tagged. Thanks Hendrik On 13.07.2012 17:14, Eric Blake wrote: On 07/13/2012 08:38 AM, Hendrik Schwartke wrote: !!! DON'T PUSH until stat-time lgpl 3 issu

Re: [libvirt] [PATCH] Added timestamps to storage volumes

2012-07-16 Thread Hendrik Schwartke
On 16.07.2012 09:45, Hendrik Schwartke wrote: On 13.07.2012 17:14, Eric Blake wrote: On 07/13/2012 08:38 AM, Hendrik Schwartke wrote: !!! DON'T PUSH until stat-time lgpl 3 issue is fixed !!! To tests this change lgpl version to 3 in bootstrap.conf:176 The access, birth, modificatio

Re: [libvirt] [PATCH] Added timestamps to storage volumes

2012-07-16 Thread Hendrik Schwartke
On 13.07.2012 17:14, Eric Blake wrote: On 07/13/2012 08:38 AM, Hendrik Schwartke wrote: !!! DON'T PUSH until stat-time lgpl 3 issue is fixed !!! To tests this change lgpl version to 3 in bootstrap.conf:176 The access, birth, modification and change times are added to storage volume

[libvirt] [PATCH] Added timestamps to storage volumes

2012-07-13 Thread Hendrik Schwartke
!!! DON'T PUSH until stat-time lgpl 3 issue is fixed !!! To tests this change lgpl version to 3 in bootstrap.conf:176 The access, birth, modification and change times are added to storage volumes and corresponding xml representations. --- bootstrap.conf|1 + docs/formatstorage

Re: [libvirt] [PATCH] Added timestamps to storage volumes

2012-07-11 Thread Hendrik Schwartke
On 11.07.2012 15:10, Eric Blake wrote: On 07/11/2012 07:09 AM, Eric Blake wrote: On 07/11/2012 01:12 AM, Hendrik Schwartke wrote: +atime->tv_sec = sb.st_atime; +mtime->tv_sec = sb.st_mtime; +catime->tv_sec = sb.st_ctime; +#if _BSD_SOURCE || _SVID_SOURCE +atime

Re: [libvirt] [PATCH] docs: added description of the vendor_id attribute

2012-07-11 Thread Hendrik Schwartke
On 11.07.2012 14:03, Jiri Denemark wrote: On Wed, Jul 11, 2012 at 09:00:05 +0200, Hendrik Schwartke wrote: On 10.07.2012 21:57, Jiri Denemark wrote: I know I'm late in this vendor_id stuff but it hasn't been released yet so I'm not too late. I assume the reason for introducing i

Re: [libvirt] [PATCH] Added timestamps to storage volumes

2012-07-11 Thread Hendrik Schwartke
On 10.07.2012 17:36, Eric Blake wrote: On 07/10/2012 09:22 AM, Hendrik Schwartke wrote: The access, modification and change times are added to storage volumes and corresponding xml representations. --- docs/formatstorage.html.in| 13 + docs/schemas/storagevol.rng | 23

Re: [libvirt] [PATCH] docs: added description of the vendor_id attribute

2012-07-11 Thread Hendrik Schwartke
On 10.07.2012 21:57, Jiri Denemark wrote: I know I'm late in this vendor_id stuff but it hasn't been released yet so I'm not too late. I assume the reason for introducing it is to be able to lie to a guest. Please, correct me, if this is not the case. Well, the reason is to specify a vendor_id wh

[libvirt] [PATCH] Added timestamps to storage volumes

2012-07-10 Thread Hendrik Schwartke
The access, modification and change times are added to storage volumes and corresponding xml representations. --- docs/formatstorage.html.in| 13 + docs/schemas/storagevol.rng | 23 +++ src/conf/storage_conf.c | 12 src/conf/storage_co

[libvirt] [PATCH] Added timestamps to volumes

2012-07-10 Thread Hendrik Schwartke
The access, modify and change times are added to volumes and corresponding xml representations. --- docs/schemas/storagevol.rng | 17 + src/conf/storage_conf.c |9 + src/conf/storage_conf.h |9 + src/storage/storage_backend.c |4 4 f

[libvirt] [PATCH] docs: added description of the vendor_id attribute

2012-07-10 Thread Hendrik Schwartke
--- docs/formatdomain.html.in |6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index 94c555f..b6e0d5d 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -779,7 +779,11 @@ in which case

Re: [libvirt] [PATCH] Added the attribute vendor_id to the cpu model

2012-07-03 Thread Hendrik Schwartke
On 03.07.2012 12:06, Michal Privoznik wrote: On 28.06.2012 12:21, Hendrik Schwartke wrote: Introducing the attribute vendor_id to force the CPUID instruction in a kvm guest to return the specified vendor. --- docs/schemas/domaincommon.rng |7 + src/conf/cpu_conf.c | 64

[libvirt] [PATCH] Added the attribute vendor_id to the cpu model

2012-06-28 Thread Hendrik Schwartke
Introducing the attribute vendor_id to force the CPUID instruction in a kvm guest to return the specified vendor. --- docs/schemas/domaincommon.rng |7 + src/conf/cpu_conf.c | 64 + src/conf/cpu_conf.h |3 ++ src/qemu/qemu_c

Re: [libvirt] [PATCH] Added the attribute vendor_id to the cpu model

2012-06-28 Thread Hendrik Schwartke
On 27.06.2012 18:29, Michal Privoznik wrote: On 27.06.2012 18:09, Hendrik Schwartke wrote: Thank you Michal and Eric for fast On 27.06.2012 17:22, Eric Blake wrote: On 06/27/2012 09:14 AM, Michal Privoznik wrote: On 21.06.2012 16:58, Hendrik Schwartke wrote: Introducing the attribute

Re: [libvirt] [PATCH] Added the attribute vendor_id to the cpu model

2012-06-27 Thread Hendrik Schwartke
Thank you Michal and Eric for fast On 27.06.2012 17:22, Eric Blake wrote: On 06/27/2012 09:14 AM, Michal Privoznik wrote: On 21.06.2012 16:58, Hendrik Schwartke wrote: Introducing the attribute vendor_id to force the CPUID instruction in a kvm guest to return the specified vendor

Re: [libvirt] [PATCH] Added the attribute vendor_id to the cpu model

2012-06-27 Thread Hendrik Schwartke
Hi, last week I posted a patch to fake the vendor_id of the guest cpu. I'm writing an application which depends on this feature so I'm wondering if anyone has had a look at it? Best regards Hendrik On 21.06.2012 16:58, Hendrik Schwartke wrote: Introducing the attribute vendor_i

[libvirt] [PATCH] Added the attribute vendor_id to the cpu model

2012-06-21 Thread Hendrik Schwartke
Introducing the attribute vendor_id to force the CPUID instruction in a kvm guest to return the specified vendor. --- docs/schemas/domaincommon.rng |7 + src/conf/cpu_conf.c | 61 - src/conf/cpu_conf.h |3 ++ src/qemu/qemu_c

[libvirt] How to disconnect a NIC

2012-04-27 Thread Hendrik Schwartke
he domain is running. Any thoughts would greatly appreciated. Hendrik Schwartke -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] Using Libvirt to change the bridge a virtual network card of a running vm is connected to

2012-03-16 Thread Hendrik Schwartke
int linkstate); +int qemuDomainChangeNetBridge(virDomainNetDefPtr olddev, + virDomainNetDefPtr newdev); int qemuDomainDetachPciDiskDevice(struct qemud_driver *driver, virDomainObjPtr vm, virDomainDeviceDefPtr

Re: [libvirt] Generic processing of xml data

2012-02-01 Thread Hendrik Schwartke
n't work, or does it? However, this patch will make my life much easier. Great Work! On 01.02.2012 16:41, Eric Blake wrote: On 02/01/2012 07:01 AM, Hendrik Schwartke wrote: There are some changes made to the conf code to handle some new tags like or to add some "metadata" to a d

[libvirt] Generic processing of xml data

2012-02-01 Thread Hendrik Schwartke
I think it would be worth the effort. Hendrik Schwartke -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] virDomainNetGetActualBridgeName doesn't return the actual bridge

2012-02-01 Thread Hendrik Schwartke
k.actual if the struct exists. But it doesn't exist. Is this indented or is the code to create this structure simply missing? On 31.01.2012 17:00, Cole Robinson wrote: On 01/30/2012 08:15 AM, Hendrik Schwartke wrote: Hi, calling virDomainNetGetActualBridgeName on a bridge with type VIR_DOMA

[libvirt] virDomainNetGetActualBridgeName doesn't return the actual bridge

2012-01-30 Thread Hendrik Schwartke
Hi, calling virDomainNetGetActualBridgeName on a bridge with type VIR_DOMAIN_NET_TYPE_NETWORK seems to return NULL in any case, because iface->data.network.actual is NULL. Is that intented? What is the best way to determine the bridge the interface is connected to? Hendrik Schwar

[libvirt] Segfault fixed

2012-01-30 Thread Hendrik Schwartke
Hi, there is a segfault in qemu_monitor_text.c. If some error accurs in qemuMonitorTextGetBlockInfo then the cleanup code calls VIR_FREE(info) without ensuring that info is initialized. Patch based on c6ec021b3c19c3ecc97d60d35b12eaa0b94da701: diff --git a/src/qemu/qemu_monitor_text.c b/src/q

Re: [libvirt] Feature Request: sniff a virtual interface of a guest

2012-01-30 Thread Hendrik Schwartke
Hi Dave, I'm using libvirt for quite a while but I'm relatively new to the code. So thank you for your hints. I will have a look at the streaming api this week. Thanks Hendrik On 27.01.2012 15:39, Dave Allan wrote: On Fri, Jan 27, 2012 at 09:28:21AM +0100, Hendrik Schwartke

[libvirt] Feature Request: sniff a virtual interface of a guest

2012-01-27 Thread Hendrik Schwartke
could then be forwarded by ssh to a wireshark process running on a desktop. I created a feature request for that: https://bugzilla.redhat.com/show_bug.cgi?id=784893 Any thoughts or hints to implement that? Hendrik Schwartke -- libvir-list mailing list libvir-list@redhat.com https://www.redha

Re: [libvirt] Using Libvirt to change the bridge a virtual network card of a running vm is connected to

2012-01-26 Thread Hendrik Schwartke
int linkstate); +int qemuDomainChangeNetBridge(virDomainNetDefPtr olddev, + virDomainNetDefPtr newdev); int qemuDomainDetachPciDiskDevice(struct qemud_driver *driver, virDomainObjPtr vm, virDomainDeviceDefPtr dev); On 26.0

Re: [libvirt] Using Libvirt to change the bridge a virtual network card of a running vm is connected to

2012-01-26 Thread Hendrik Schwartke
I fixed the patch and added it to https://bugzilla.redhat.com/show_bug.cgi?id=784767. -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] Using Libvirt to change the bridge a virtual network card of a running vm is connected to

2012-01-25 Thread Hendrik Schwartke
emud_driver *driver, virDomainObjPtr vm, virDomainDeviceDefPtr dev); Host definition: test 32768 32768 1 hvm destroy restart restart /usr/bin/kvm Interface definition: Best regards Hendrik Schwartke -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list