Re: [Qemu-devel] [PATCH 00/35] pc: ACPI memory hotplug

2014-04-04 Thread Dr. David Alan Gilbert
t pluggable like this (i.e. no memory would be allocated in the normal way) 2) Does something stop it being invoked during a migration? Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH v5 00/10] migration: Optimizate the xbzrle and fix one corruption issue

2014-04-04 Thread Dr. David Alan Gilbert
| 101 > +++-- > qapi-schema.json | 9 +++- > qmp-commands.hx| 15 -- > xbzrle.c | 48 ++-- > 10 files changed, 144 insertions(+), 130 deletions(-) > > -- > 1.7.12.4 > > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] For 2.0? Re: [PATCH v5 00/10] migration: Optimizate the xbzrle and fix one corruption issue

2014-04-04 Thread Dr. David Alan Gilbert
2 + > > include/migration/page_cache.h | 10 ++-- > > migration.c| 3 ++ > > page_cache.c | 101 > > +++-- > > qapi-schema.json | 9 +++- > > qmp-commands.hx

Re: [Qemu-devel] [PATCH v5 07/10] xbzrle: don't check the value in the vm ram repeatedly

2014-04-04 Thread Dr. David Alan Gilbert
* arei.gong...@huawei.com (arei.gong...@huawei.com) wrote: > From: ChenLiang > > xbzrle_encode_buffer checks the value in the vm ram repeatedly. > It is risk if runs xbzrle_encode_buffer on changing data. > And it is not necessary. > > Reported-by: Dr. David Alan Gil

Re: [Qemu-devel] [PATCH v5 08/10] xbzrle: check 8 bytes at a time after an concurrency scene

2014-04-04 Thread Dr. David Alan Gilbert
sizeof(long)) { > +break; Is it not possible to make this code the same as the other loop, you could xor in the same way just change the comparison? (What do other people think - I was thinking that would just be better since it would be symmetric?) Dave > +} > +} > } > } > > -- > 1.7.12.4 > > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH v5 09/10] migration: optimize xbzrle by reducing data copy

2014-04-04 Thread Dr. David Alan Gilbert
* arei.gong...@huawei.com (arei.gong...@huawei.com) wrote: > From: ChenLiang > > Reducing data copy can reduce cpu overhead. > > Signed-off-by: ChenLiang > Signed-off-by: Gonglei Yes, with the previous patches that's now correct. Reviewed-by: Dr. David Alan Gilbert

Re: [Qemu-devel] [Qemu-trivial] [PATCH v4] scripts: add sample model file for Coverity Scan

2014-04-07 Thread Dr. David Alan Gilbert
version of the code. Hence it needs to be version controlled with the code, hence the best place is inside the qemu sources. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 03/97] vmstate: return error in case of error

2014-04-07 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > If there is an error while loading a field, we should stop reading and > not continue with the rest of fields. > > Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert > --- > vmstate.c | 3 +++ > 1 file

Re: [Qemu-devel] [PATCH 80/97] vmstate: Create VMSTATE_SYNTHETIC

2014-04-07 Thread Dr. David Alan Gilbert
gs, ARMCPU, 16), > -{ > -.name = "cpsr", > -.version_id = 0, > -.size = sizeof(uint32_t), > - .info = &vmstate_cpsr, > -.flags = VMS_SINGLE, > -.offset = 0, > -}, > +VMSTATE_SYNTHETIC("cpsr", vmstate_cpsr, sizeof(uint32_t)), > VMSTATE_UINT32(env.spsr, ARMCPU), > VMSTATE_UINT32_ARRAY(env.banked_spsr, ARMCPU, 6), > VMSTATE_UINT32_ARRAY(env.banked_r13, ARMCPU, 6), > -- > 1.9.0 > > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 96/97] vmstate: Rename VMS_VBUFFER to VMST_VBUFFER_INT32 for consintency

2014-04-07 Thread Dr. David Alan Gilbert
e.c > +++ b/vmstate.c > @@ -33,7 +33,7 @@ static int vmstate_size(void *opaque, VMStateField *field) > { > int size = field->size; > > -if (field->flags & VMS_VBUFFER) { > +if (field->flags & VMS_VBUFFER_INT32) { > size = *(int

Re: [Qemu-devel] [PATCH for 2.1 00/97] VMState simplification (massive)

2014-04-07 Thread Dr. David Alan Gilbert
nternally, it seems like we're discouraging providing easy to parse/record versionining info out of the tree. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH v4 1/1] Make qemu_peek_buffer loop until it gets it's data

2014-04-08 Thread Dr. David Alan Gilbert
* (chenliang0...@icloud.com) wrote: > > ?? 2014??4??810:29??Dr. David Alan Gilbert (git) > ?? > > > From: "Dr. David Alan Gilbert" > > > > Make qemu_peek_buffer repeatedly call fill_buffer until it gets > > all the data it requ

Re: [Qemu-devel] [PATCH v4 1/1] Make qemu_peek_buffer loop until it gets it's data

2014-04-09 Thread Dr. David Alan Gilbert
* (chenliang0...@icloud.com) wrote: > > > * (chenliang0...@icloud.com) wrote: > >> > >> ?? 2014??4??8????10:29??Dr. David Alan Gilbert (git) > >> ?? > >> > >>> From: "Dr. David Alan Gilbert" > >

Re: [Qemu-devel] [PATCH v4 1/1] Make qemu_peek_buffer loop until it gets it's data

2014-04-09 Thread Dr. David Alan Gilbert
* (chenliang0...@icloud.com) wrote: > > > * (chenliang0...@icloud.com) wrote: > >> > >>> * (chenliang0...@icloud.com) wrote: > >>>> > >>>> ?? 2014??4??810:29??Dr. David Alan Gilbert (git)

Re: [Qemu-devel] Error propagation in generated visitors and command marshallers

2014-04-09 Thread Dr. David Alan Gilbert
void visit_type_str(Visitor *v, char **obj, const char *name, Error > **errp) > { > v->type_str(v, obj, name, errp); > } > > Should execute roughly the same number of conditional branches. > > Tedious repetition of "if (err) goto out" in the caller, but that's what > we do elsewhere, and unlike elsewhere, these one's are generated. The other problem is I had a tendency to typo some of the cases to if (*err) and it's quite hard to spot and you wonder what's going on. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] Error propagation in generated visitors and command marshallers

2014-04-11 Thread Dr. David Alan Gilbert
* Markus Armbruster (arm...@redhat.com) wrote: > "Dr. David Alan Gilbert" writes: > > > * Markus Armbruster (arm...@redhat.com) wrote: > >> I stumbled over this while trying to purge error_is_set() from the code. > > > >> Here's how we commonly

Re: [Qemu-devel] [PATCH V2 1/4] vmxnet3: validate interrupt indices coming from guest

2014-04-11 Thread Dr. David Alan Gilbert
* Dmitry Fleytman (dmi...@daynix.com) wrote: > CVE-2013-4544 > > Signed-off-by: Dmitry Fleytman > Reported-by: Michael S. Tsirkin > Signed-off-by: Michael S. Tsirkin Reviewed-by: Dr. David Alan Gilbert > --- > hw/net/vmxnet3.c | 36 ++--

Re: [Qemu-devel] [PATCH V2 2/4] vmxnet3: validate queues configuration coming from quest

2014-04-11 Thread Dr. David Alan Gilbert
* Dmitry Fleytman (dmi...@daynix.com) wrote: > CVE-2013-4544 > > Signed-off-by: Dmitry Fleytman > Reported-by: Michael S. Tsirkin > Signed-off-by: Michael S. Tsirkin > --- Reviewed-by: Dr. David Alan Gilbert > hw/net/vmxnet3.c | 19 ++- > 1 file chan

Re: [Qemu-devel] [PATCH V2 3/4] vmxnet3: validate interrupt indices read on migration

2014-04-11 Thread Dr. David Alan Gilbert
* Dmitry Fleytman (dmi...@daynix.com) wrote: > CVE-2013-4544 > > Signed-off-by: Dmitry Fleytman > Reported-by: Michael S. Tsirkin > Signed-off-by: Michael S. Tsirkin Reviewed-by: Dr. David Alan Gilbert Dave > --- > hw/net/vmxnet3.c | 2 ++ > 1 file changed, 2 inser

Re: [Qemu-devel] [PATCH V2 4/4] vmxnet3: validate queues configuration read on migration

2014-04-11 Thread Dr. David Alan Gilbert
* Dmitry Fleytman (dmi...@daynix.com) wrote: > CVE-2013-4544 > > Signed-off-by: Dmitry Fleytman > Reported-by: Michael S. Tsirkin > Signed-off-by: Michael S. Tsirkin Reviewed-by: Dr. David Alan Gilbert > --- > hw/net/vmxnet3.c | 1 + > 1 file changed, 1 insertion

Re: [Qemu-devel] [PATCH V2 0/4] CVE-2013-4544

2014-04-11 Thread Dr. David Alan Gilbert
guest (even in this case a broken one) triggerable. But, lets get the fix in. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] Unresponsive linux guest once migrated

2014-04-15 Thread Dr. David Alan Gilbert
ing to continue > > > > > > > > I've tried to disassemble where VM kernel (3.8.something from Ubuntu) is > > spinning (using qemu-monitor, registers info and symbols from guest kernel) > > and it was loop inside __run_timers function from kernel/timer.c: > > > > while (time_after_eq(jiffies, base->timer_jiffies)) { > > ... > > } > > > > However my disassembly and qemu debugging skills are limited, would it help > > if I dump memory of broken VM and send it you somehow? > > > > -- > > mg > > > > > > > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] segfault while booting from saved snapshot

2014-04-15 Thread Dr. David Alan Gilbert
b5c in main (argc=, argv=, > envp=) at vl.c:4457 > (gdb) > > I even tried the command > > guest-fsfreeze-freeze as mentioned here: > > http://wiki.qemu.org/Features/Snapshots > > But the Qemu Monitor says the command doesnt exist. Do we need to issue a > command to flush the tlb buffer? Please advise. > > -- > Shehbaz Jaffer -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] Global overview

2014-04-15 Thread Dr. David Alan Gilbert
particular command line option, guest instruction or monitor command. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

[Qemu-devel] [Bug 1259499] Re: QEmu 1.7.0 cannot restore a 1.6.0 live snapshot made in qemu-system-x86_64

2013-12-23 Thread Dr. David Alan Gilbert
Yes, my understanding of the bug is that 1.7+ should load your 1.3.x images and then snapshots taken on 1.7.x should be OK into the future. I don't think there's currently a way of fixing those 1.6.0 snapshots; that workaround will let you load them in 1.7, but I think if you were then to take a s

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-13 Thread Dr. David Alan Gilbert
* Stefan Priebe (s.pri...@profihost.ag) wrote: > Am 10.02.2014 17:07, schrieb Dr. David Alan Gilbert: > >* Stefan Priebe (s.pri...@profihost.ag) wrote: > >>i could fix it by explicitly disable xbzrle - it seems its > >>automatically on if i do not set the migration ca

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-14 Thread Dr. David Alan Gilbert
* Stefan Priebe (s.pri...@profihost.ag) wrote: > > Am 13.02.2014 21:06, schrieb Dr. David Alan Gilbert: > >* Stefan Priebe (s.pri...@profihost.ag) wrote: > >>Am 10.02.2014 17:07, schrieb Dr. David Alan Gilbert: > >>>* Stefan Priebe (s.pri...@profihost.ag) wrote: &

Re: [Qemu-devel] [PATCH] Fix two XBZRLE corruption issues

2014-02-14 Thread Dr. David Alan Gilbert
see the line above which is: p = get_cached_data(XBZRLE.cache, current_addr); That changes the 'p' to point to the page in the cache and thus forces that qemu_put_buffer to send the page in the cache; my patch doesn't change that, it just stops it using the qemu_put_buffer_async so that the cache is read immediately not at some point in the future when the cache may have changed. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] qemu_rdma_cleanup seg - related to 5a91337?

2014-02-17 Thread Dr. David Alan Gilbert
* Michael R. Hines (mrhi...@linux.vnet.ibm.com) wrote: > On 02/06/2014 08:26 PM, Dr. David Alan Gilbert wrote: > >Hi Isaku, > >I hit a seg in qemu_rdma_cleanup in the code changed by your > >'[PATCH] rdma: clean up of qemu_rdma_cleanup()' > > > >migra

Re: [Qemu-devel] [RFC PATCH v2 02/12] mc: timestamp migration_bitmap and KVM logdirty usage

2014-02-18 Thread Dr. David Alan Gilbert
_PAGE_SIZE; > +acct_info.norm_pages++; > +} > } Is that last change intended for this patch; it doesn't look timestamp related. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [RFC PATCH v2 01/12] mc: add documentation for micro-checkpointing

2014-02-18 Thread Dr. David Alan Gilbert
der computers, this feature > only gives you the benefit of lower CPU-utilization at the expense of Isn't there a generic kernel DMA ABI for doing this type of thing (I think there was at one point, people have suggested things like using graphics cards to do it but I don't know if it ever happened). The other question is, do you always need to copy - what about something like COWing the pages? Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH] Fix two XBZRLE corruption issues

2014-02-18 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > "Dr. David Alan Gilbert (git)" wrote: > > From: "Dr. David Alan Gilbert" > > > > Push zero'd pages into the XBZRLE cache > > A page that was cached by XBZRLE, zero'd and then XBZRLE'

Re: [Qemu-devel] [PATCH] XBZRLE: Fix qemu crash when resize the xbzrle cache during migration

2014-02-19 Thread Dr. David Alan Gilbert
> + */ > +unsigned int cache_page_size(PageCache *cache); > + > #endif > diff --git a/page_cache.c b/page_cache.c > index 3ef6ee7..92e401c 100644 > --- a/page_cache.c > +++ b/page_cache.c > @@ -234,3 +234,16 @@ int64_t cache_resize(PageCache *cache, int64_t > new_num_pages) > > return cache->max_num_items; > } > + > +int64_t cache_max_num_items(PageCache *cache) > +{ > +g_assert(cache); > +return cache->max_num_items; > +} > + > +unsigned int cache_page_size(PageCache *cache) > +{ > +g_assert(cache); > +return cache->page_size; > +} > + > -- > 1.6.0.2 > > > Best regards, > -Gonglei > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [RFC PATCH v2 01/12] mc: add documentation for micro-checkpointing

2014-02-19 Thread Dr. David Alan Gilbert
* Michael R. Hines (mrhi...@linux.vnet.ibm.com) wrote: > On 02/18/2014 08:45 PM, Dr. David Alan Gilbert wrote: > >>+The Micro-Checkpointing Process > >>+Basic Algorithm > >>+Micro-Checkpoints (MC) work against the existing live migration path in > >>QEMU,

Re: [Qemu-devel] [RFC PATCH v2 01/12] mc: add documentation for micro-checkpointing

2014-02-20 Thread Dr. David Alan Gilbert
* Michael R. Hines (mrhi...@linux.vnet.ibm.com) wrote: > On 02/19/2014 07:27 PM, Dr. David Alan Gilbert wrote: > > > >I was just wondering if a separate 'max buffer size' knob would allow > >you to more reasonably bound memory without setting policy; I don't thi

Re: [Qemu-devel] [RFC PATCH v2 01/12] mc: add documentation for micro-checkpointing

2014-02-20 Thread Dr. David Alan Gilbert
* Michael R. Hines (mrhi...@linux.vnet.ibm.com) wrote: > On 02/20/2014 06:09 PM, Dr. David Alan Gilbert wrote: > >* Michael R. Hines (mrhi...@linux.vnet.ibm.com) wrote: > >>On 02/19/2014 07:27 PM, Dr. David Alan Gilbert wrote: > >>>I was just wondering if a separat

Re: [Qemu-devel] [RFC PATCH v2 01/12] mc: add documentation for micro-checkpointing

2014-02-21 Thread Dr. David Alan Gilbert
* Michael R. Hines (mrhi...@linux.vnet.ibm.com) wrote: > On 02/21/2014 12:32 AM, Dr. David Alan Gilbert wrote: > > > >I'm happy to use more memory to get FT, all I'm trying to do is see > >if it's possible to put a lower bound than 2x on it while still maint

Re: [Qemu-devel] [PATCH v2] XBZRLE: Fix qemu crash when resize the xbzrle cache

2014-02-21 Thread Dr. David Alan Gilbert
; > if (!XBZRLE.cache) { > +XBZRLE_cache_unlock(); > DPRINTF("Error creating cache\n"); > return -1; > } > +XBZRLE_cache_unlock(); > > /* We prefer not to abort if there is no memory */ > XBZRLE.encoded_buf = g_try_malloc0(TARGET_PAGE_SIZE); > @@ -681,7 +733,6 @@ static int ram_save_setup(QEMUFile *f, void *opaque) > XBZRLE.encoded_buf = NULL; > return -1; > } > - > acct_clear(); > } > > -- > 1.6.0.2 > > Best regards, > -Gonglei Thanks, Reviewed-by: Dr. David Alan Gilbert -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH v2] XBZRLE: Fix qemu crash when resize the xbzrle cache

2014-02-21 Thread Dr. David Alan Gilbert
le. > To be honest, we can't follow your meaning. Can you explain it in detail. These two functions are called from a few places, including ram_save_block even if xbzrle isn't enabled; I was just suggesting you might not want to check the lock if xbzrle is disabled; however, I think it's simpler to leave it as is, and doubt the overhead is worth the complexity. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] Some line of codes in a file that I cant understand

2014-02-25 Thread Dr. David Alan Gilbert
he VMSTATE_UINT8 is a macro declaring that there is a byte/uint8 member see ./include/migration/vmstate.h and docs/migration.txt for a bit of a description. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 1/7] XBZRLE: Fix one XBZRLE corruption issues

2014-02-28 Thread Dr. David Alan Gilbert
nglei Nice catch. Reviewed-by: Dr. David Alan Gilbert > --- > arch_init.c | 25 + > 1 file changed, 13 insertions(+), 12 deletions(-) > > diff --git a/arch_init.c b/arch_init.c > index fe17279..bc8d0eb 100644 > --- a/arch_init.c > +++ b/arc

Re: [Qemu-devel] [PATCH 2/7] migration: Add counters of updating the dirty bitmap

2014-02-28 Thread Dr. David Alan Gilbert
* Gonglei (Arei) (arei.gong...@huawei.com) wrote: > Add counters to log the times of updating the dirty bitmap. Reviewed-by: Dr. David Alan Gilbert > Signed-off-by: ChenLiang > Signed-off-by: Gonglei > --- > arch_init.c | 20 > 1 file changed, 20 inser

Re: [Qemu-devel] [PATCH 3/7] XBZRLE: optimize XBZRLE to decrease the cache missing

2014-02-28 Thread Dr. David Alan Gilbert
*/ > it = cache_get_by_addr(cache, addr); > > +if ((it->it_data != NULL) && (it->it_age + 2 > current_age)) { > +/* the cache page is fresh, don't replace it */ > +return -1; > +} A magical constant '2' - should probably

Re: [Qemu-devel] [PATCH 4/7] XBZRLE: rebuild the cache_is_cached function

2014-02-28 Thread Dr. David Alan Gilbert
uint64_t current_age) > +{ > +CacheItem *it = NULL; > + > +it = cache_get_by_addr(cache, addr); > + > +if (it->it_addr == addr) { > + /* updata the it_age when the cache hit */ > +it->it_age = current_age; &

Re: [Qemu-devel] [PATCH 0/7] migration: Optimization the xbzrle and fix two corruption issues

2014-02-28 Thread Dr. David Alan Gilbert
ess than the dirty page number. Now the > hot pages in the cache will not be replaced by other pages. Nice, what do you use as your performance test case for xbzrle? Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 5/7] migration: Fix the migrate auto converge process

2014-02-28 Thread Dr. David Alan Gilbert
} > - bytes_xfer_prev = bytes_xfer_now; > +if (get_bitmap_sync_cnt() > 15) { > +mig_throttle_on = true; > +} That is a lot simpler, and I suspect as good - again I'd move that magic '15' to a constant somewhere. What have you tested this on - have you tested with really big RAM VMs? What's it's behaviour like with rate-limiting? Dave > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 6/7] migraion: optimiztion xbzrle by reducing data copy

2014-02-28 Thread Dr. David Alan Gilbert
AGE_SIZE); > } > > /* Send XBZRLE based compressed page */ > -- > 1.7.12.4 > > > Best regards, > -Gonglei > > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 0/7] migration: Optimization the xbzrle and fix two corruption issues

2014-02-28 Thread Dr. David Alan Gilbert
* Gonglei (arei.gong...@huawei.com) wrote: > On 2014/2/28 17:19, Dr. David Alan Gilbert wrote: > > > * Gonglei (Arei) (arei.gong...@huawei.com) wrote: > > > > Hi, > > > >> a. Optimization the xbzrle remarkable decrease the cache misses. > >>

Re: [Qemu-devel] [RFC]VM live snapshot proposal

2014-03-03 Thread Dr. David Alan Gilbert
ersions of the pages but I don't think you can just put a marker in and say that the point represents a single consistent view of RAM. In many ways this is the opposite of Michael Hines's microcheckpointing approach; which stops everything and takes the snapshot regularly; I did suggest a modification to that would be to COW those checkpoints. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [RFC]VM live snapshot proposal

2014-03-04 Thread Dr. David Alan Gilbert
til we have something to post. > One question: > Can post-copy fallback if exceptions happen during post-copy? What do you mean by 'exceptions' here? Generally postcopy can't fall back to precopy because once you're in postcopy mode the state is split between the two machines. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 3/3] Add a 'name' parameter to qemu_thread_create

2014-01-28 Thread Dr. David Alan Gilbert
* Michael S. Tsirkin (m...@redhat.com) wrote: > On Tue, Jan 28, 2014 at 03:20:39PM +0000, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > If enabled, set the thread name at creation (on GNU systems with > > pthread_set_np) >

Re: [Qemu-devel] [PATCH 0/3] Name threads

2014-01-28 Thread Dr. David Alan Gilbert
* Paolo Bonzini (pbonz...@redhat.com) wrote: > Il 28/01/2014 16:20, Dr. David Alan Gilbert (git) ha scritto: > >From: "Dr. David Alan Gilbert" > > > >This series uses pthread_setname_np (when available) to set the names on > >threads that QEMU creat

Re: [Qemu-devel] [PATCH 2/3] Add 'namethreads' suboption to --name

2014-01-28 Thread Dr. David Alan Gilbert
* Michael S. Tsirkin (m...@redhat.com) wrote: > On Tue, Jan 28, 2014 at 03:20:38PM +0000, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > Add flag storage to qemu-thread-* to store the namethreads flag > > > > Signed-off

Re: [Qemu-devel] [PATCH v2 0/3] Name threads

2014-01-30 Thread Dr. David Alan Gilbert
* Eric Blake (ebl...@redhat.com) wrote: > On 01/30/2014 03:20 AM, Dr. David Alan Gilbert (git) wrote: > > > The first patch converts --name to use QemuOpts, a side effect of this is > > that > > --name process=foo,bar > > no longer allows a process name of '

Re: [Qemu-devel] [PATCH 5/6] Don't abort on out of memory when creating page cache

2014-01-30 Thread Dr. David Alan Gilbert
DPRINTF("Error allocating encoded_buf\n"); > +return -1; > +} > + > +XBZRLE.current_buf = g_try_malloc(TARGET_PAGE_SIZE); > +if (!XBZRLE.current_buf) { > +DPRINTF("Error allocating current_buf\n"); > + return -1; &g

Re: [Qemu-devel] [PATCH 6/6] Don't abort on memory allocation error

2014-01-30 Thread Dr. David Alan Gilbert
stopper, but worth fixing sometime). > } > > -it->it_data = g_memdup(pdata, cache->page_size); > +memcpy(it->it_data, pdata, cache->page_size); > + > it->it_age = ++cache->max_item_age; > it->it_addr = addr; > + > +return 0; > } > > int64_t cache_resize(PageCache *cache, int64_t new_num_pages) > -- > 1.8.3.1 Reviewed-by: Dr. David Alan Gilbert Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH v2 6/6] Don't abort on memory allocation error

2014-01-30 Thread Dr. David Alan Gilbert
c | 16 +++- > 3 files changed, 17 insertions(+), 7 deletions(-) Reviewed-by: Dr. David Alan Gilbert > > diff --git a/arch_init.c b/arch_init.c > index 1fa5f1f..80574a0 100644 > --- a/arch_init.c > +++ b/arch_init.c > @@ -284,7 +284,9 @@ sta

Re: [Qemu-devel] [PATCH v2 5/6] Don't abort on out of memory when creating page cache

2014-01-30 Thread Dr. David Alan Gilbert
* Orit Wasserman (owass...@redhat.com) wrote: > Signed-off-by: Orit Wasserman > --- > arch_init.c | 18 -- > page_cache.c | 18 ++ > 2 files changed, 30 insertions(+), 6 deletions(-) Reviewed-by: Dr. David Alan Gilbert > > diff

Re: [Qemu-devel] [PATCH v2 4/6] XBZRLE cache size should not be larger than guest memory size

2014-01-30 Thread Dr. David Alan Gilbert
if (value > ram_bytes_total()) { > +error_set(errp, QERR_INVALID_PARAMETER_VALUE, "cache size", > + "exceeds guest ram size "); > +return; > +} > + > new_size = xbzrle_cache_resize(value); > if (new_size < 0)

Re: [Qemu-devel] [PATCH v2 4/6] XBZRLE cache size should not be larger than guest memory size

2014-01-30 Thread Dr. David Alan Gilbert
* Orit Wasserman (owass...@redhat.com) wrote: > Signed-off-by: Orit Wasserman Reviewed-by: Dr. David Alan Gilbert > --- > migration.c | 7 +++ > 1 file changed, 7 insertions(+) > > diff --git a/migration.c b/migration.c > index 46a7305..25add6f 100644 > -

Re: [Qemu-devel] [PATCH v2 4/6] XBZRLE cache size should not be larger than guest memory size

2014-01-30 Thread Dr. David Alan Gilbert
* Orit Wasserman (owass...@redhat.com) wrote: > On 01/30/2014 08:23 PM, Dr. David Alan Gilbert wrote: > >* Orit Wasserman (owass...@redhat.com) wrote: > >>Signed-off-by: Orit Wasserman > >>--- > >> migration.c | 7 +++ > >> 1 file changed, 7 inse

Re: [Qemu-devel] qemu segfauls with spiceport chardev and isa-serial

2014-02-03 Thread Dr. David Alan Gilbert
#5 g_main_context_dispatch (context=context@entry=0x7fee3fa49470) > at > /var/tmp/portage/dev-libs/glib-2.38.2/work/glib-2.38.2/glib/gmain.c:3642 > #6 0x7fee3dccdde7 in glib_pollfds_poll () at main-loop.c:189 > #7 os_host_main_loop_wait (timeout=) at main-loop.c:234 > #8 main_loop_wait (nonblocking=) at main-loop.c:483 > #9 0x7fee3db61501 in main_loop () at vl.c:2018 > #10 main (argc=, argv=, envp=) > at vl.c:4410 -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 7/8] Don't abort on memory allocation error

2014-02-04 Thread Dr. David Alan Gilbert
ing page\n"); > +return -1; > +} Hmm that wasn't the latest version of that patch (or the previous one in the series). Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] migration: broken ram_save_pending

2014-02-05 Thread Dr. David Alan Gilbert
ompression ratio is particularly high, which because of the hpratio it is if we're just dirtying one word in an entire host page. What I'm not too sure of is you'd think if only a few pages were dirtied that the loop would happen quite quickly and thus the delay would also be small, and so bytes-on-wire would be divided by a small value and thus not be too bad. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] qemu segfauls with spiceport chardev and isa-serial

2014-02-05 Thread Dr. David Alan Gilbert
* Peter Crosthwaite (peter.crosthwa...@xilinx.com) wrote: > On Tue, Feb 4, 2014 at 4:45 AM, Dr. David Alan Gilbert > wrote: > > (cc'ing in Peter Crosthwaite and Michael Tokarev due to a serial fifo change > > - see below!) > > > > * Martin Kletzander (mkl

Re: [Qemu-devel] migration: broken ram_save_pending

2014-02-05 Thread Dr. David Alan Gilbert
* Paolo Bonzini (pbonz...@redhat.com) wrote: > Il 05/02/2014 10:09, Dr. David Alan Gilbert ha scritto: > >I think the case Alexey is hitting is: > > 1 A few dirtied pages > > 2 but because of the hpratio most of the data is actually zero > > - indeed most of t

Re: [Qemu-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-05 Thread Dr. David Alan Gilbert
Do you get any messages on either the source or destination qemu during the migrate? Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] migration: broken ram_save_pending

2014-02-06 Thread Dr. David Alan Gilbert
* Alexey Kardashevskiy (a...@ozlabs.ru) wrote: > On 02/06/2014 03:45 AM, Paolo Bonzini wrote: > > Il 05/02/2014 17:42, Dr. David Alan Gilbert ha scritto: > >> Because: > >> * the code is still running and keeps redirtying a small handful of > >>

[Qemu-devel] qemu_rdma_cleanup seg - related to 5a91337?

2014-02-06 Thread Dr. David Alan Gilbert
gt;cm_id); rdma->qp = NULL; should that have been rdma_destroy_qp(rdma->qp)? Dave (who doesn't yet know enough RDMA to be dangerous) -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-06 Thread Dr. David Alan Gilbert
) You said before that it was happening on a 32GB image - is it *only* happening on a 32GB or bigger VM, or is it just more likely? I think you also said you were using 1.7; have you tried an older version - i.e. is this a regression in 1.7 or don't we know? Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] migration: broken ram_save_pending

2014-02-07 Thread Dr. David Alan Gilbert
* Alexey Kardashevskiy (a...@ozlabs.ru) wrote: > On 02/06/2014 10:24 PM, Dr. David Alan Gilbert wrote: > > * Alexey Kardashevskiy (a...@ozlabs.ru) wrote: > >> On 02/06/2014 03:45 AM, Paolo Bonzini wrote: > >>> Il 05/02/2014 17:42, Dr. David Alan Gilbert ha scritto: &g

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-07 Thread Dr. David Alan Gilbert
es ;-( Only being able to test on your production VMs isn't fun; is it possible or you to run an extra program on these VMs - e.g. if we came up with a simple (userland) memory test? Dave > > Stefan > > > > > > ----- Mail original - > > > >

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-07 Thread Dr. David Alan Gilbert
* Stefan Priebe - Profihost AG (s.pri...@profihost.ag) wrote: > > Am 07.02.2014 10:15, schrieb Dr. David Alan Gilbert: > > * Stefan Priebe - Profihost AG (s.pri...@profihost.ag) wrote: > >> Am 07.02.2014 09:15, schrieb Alexandre DERUMIER: > >>> > >

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-07 Thread Dr. David Alan Gilbert
U 7(0x) at 0x7f4d8aa00180(0x0:DIMM > Unknown): read:0x, reread:0x0000 > expected:0x > Report Error: miscompare : DIMM Unknown : 1 : 572s > Page Error: miscompare on CPU 7(0x) at 0x7f4d8aa00188(0x0:DIMM > Unknown): read:0x0

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-07 Thread Dr. David Alan Gilbert
frame where > the google stress app reports memory errors than when the migration > finishes it runs fine again. > > It seems to me it is related to pause and unpause/resume? But do you have to pause/resume it to cause the error? Have you got cases where you boot it and then leave it running for a few hours and then it fails if you migrate it? Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-07 Thread Dr. David Alan Gilbert
* Stefan Priebe - Profihost AG (s.pri...@profihost.ag) wrote: > Hi, > > Am 07.02.2014 14:08, schrieb Dr. David Alan Gilbert: > > * Stefan Priebe - Profihost AG (s.pri...@profihost.ag) wrote: > >> first of all i've now a memory image of a VM where i can reproduce

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-07 Thread Dr. David Alan Gilbert
t;>>migration _and_ it finishes? > >> > >>Sorry no i meant i have a VM where i saved the memory to disk - so i > >>don't need to wait hours until i can reproduce as it does not happen > >>with a fresh started VM. So it's a state file i think. > >> > >>>Another test: > >>> > >>>- start the VM with -S, migrate, do errors appear on the destination? > >> > >>I started with -S and the errors appear AFTER resuming/unpause the VM. > >>So it is fine until i resume it on the "new" host. > >> > >>Stefan > >> > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-10 Thread Dr. David Alan Gilbert
ng, and does make it easier to tie down. Dave > > Stefan > > Am 07.02.2014 21:10, schrieb Stefan Priebe: > >Am 07.02.2014 21:02, schrieb Dr. David Alan Gilbert: > >>* Stefan Priebe (s.pri...@profihost.ag) wrote: > >>>anything i could try or debug? to he

Re: [Qemu-devel] [PATCH v2 3/3] Add a 'name' parameter to qemu_thread_create

2014-02-10 Thread Dr. David Alan Gilbert
* Laszlo Ersek (ler...@redhat.com) wrote: > comments below Thanks, > On 01/30/14 11:20, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > If enabled, set the thread name at creation (on GNU systems with > > pthread_set_np)

Re: [Qemu-devel] [PATCH v2 1/3] Rework --name to use QemuOpts

2014-02-10 Thread Dr. David Alan Gilbert
* Laszlo Ersek (ler...@redhat.com) wrote: > On 01/30/14 11:20, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > Signed-off-by: Dr. David Alan Gilbert > > Reviewed-by: Alex Bennée > > --- > > vl.c | 52 ++

Re: [Qemu-devel] [PATCH v2 2/3] Add 'debug-threads' suboption to --name

2014-02-10 Thread Dr. David Alan Gilbert
* Laszlo Ersek (ler...@redhat.com) wrote: > a few irrelevant comments below: > > On 01/30/14 11:20, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > Add flag storage to qemu-thread-* to store the namethreads flag > >

Re: [Qemu-devel] [pve-devel] QEMU LIve Migration - swap_free: Bad swap file entry

2014-02-10 Thread Dr. David Alan Gilbert
Other than xbzrle what else do you have enabled? How long is the migrate taking for you? Thanks, Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH bugfix v1 1/1] char/serial: Fix emptyness check

2014-02-11 Thread Dr. David Alan Gilbert
* Peter Crosthwaite (peter.crosthwa...@xilinx.com) wrote: > This was guarding against a full fifo rather than an empty fifo when > popping. Fix. > > Signed-off-by: Peter Crosthwaite > --- Reviewed-by: Dr. David Alan Gilbert I think this brings it back to how it was on th

Re: [Qemu-devel] [PATCH bugfix v1 1/1] char/serial: Fix emptynesscheckk

2014-02-11 Thread Dr. David Alan Gilbert
* Alex Benn?e (alex.ben...@linaro.org) wrote: > > Dr. David Alan Gilbert writes: > > > * Peter Crosthwaite (peter.crosthwa...@xilinx.com) wrote: > >> This was guarding against a full fifo rather than an empty fifo when > >> popping. Fix. > >&

[Qemu-devel] Postcopy codebase status?

2013-12-11 Thread Dr. David Alan Gilbert
ERFAULT/remap_anon_pages ideas. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

[Qemu-devel] [Bug 1259499] Re: QEmu 1.7.0 cannot restore a 1.6.0 live snapshot made in qemu-system-x86_64

2013-12-13 Thread Dr. David Alan Gilbert
Hi Francois, I've managed to reproduce this, in my log file (/var/log/libvirt/qemu/machinename.log) I see: Unknown ramblock ":02.0/qxl.vram", cannot accept migration qemu: warning: error while loading state for instance 0x0 of device 'ram' qemu-system-x86_64: Error -22 while loading VM stat

[Qemu-devel] [Bug 1259499] Re: QEmu 1.7.0 cannot restore a 1.6.0 live snapshot made in qemu-system-x86_64

2013-12-13 Thread Dr. David Alan Gilbert
Hi Francois, I've done some more digging. It looks like the problem you've hit is related to the same one that's fixed by: http://lists.gnu.org/archive/html/qemu-devel/2013-11/msg00513.html however that only fixes older restores ; there is a work around which is to pass to QEMU: -global i440FX

Re: [Qemu-devel] QEMU 2.0 RC with Spice

2014-04-15 Thread Dr. David Alan Gilbert
periences? > I don't care to divert anybody's energy if this a spice thing - how best to > determine this? You say qemu aborts; can you get a backtrace and the abort message? Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] Unresponsive linux guest once migrated

2014-04-15 Thread Dr. David Alan Gilbert
being ""): Out of interest what created the config file with kvmclock enabled? virt-manager doesn't seem to have done over here. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

[Qemu-devel] [Bug 1270397] Re: Systemd segfaults after live migration

2014-04-15 Thread Dr. David Alan Gilbert
Hi Mateusz, How are you migrating? If you are using the compress/xbzrle option, try turning it off and see if that helps, there are some corruption fixes for xbzrle in 2.0.0. Dave -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU.

Re: [Qemu-devel] QEMU 2.0 RC with Spice

2014-04-16 Thread Dr. David Alan Gilbert
if=none,id=cd,file=/dev/sg1 \ > > -device virtio-scsi-pci,id=scsi \ > > -device scsi-generic,drive=cd \ > > -balloon virtio \ > > -soundhw hda \ > > -device usb-ehci > > > > > > Thanks, > > -Rick > > > > On Tuesday 15 April 2014 15:22

Re: [Qemu-devel] [PATCH 007/124] vmstate: Return error in case of error

2014-04-22 Thread Dr. David Alan Gilbert
qemu_file_set_error(f, ret); > +} qemu_file_set_error already checks for an existing error, so you don't need that check. Dve > trace_vmstate_load_field_error(field->name, ret); > return ret; > } > -- > 1.9.0 > > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 008/124] vmstate: Reduce code duplication

2014-04-22 Thread Dr. David Alan Gilbert
a -ve number print a warning and return 0. at the moment it's broken in the corner case of VMS_VARRAY_UINT32 and a huge value. Dave > Signed-off-by: Michael S. Tsirkin > Cc: "Dr. David Alan Gilbert" > Signed-off-by: Juan Quintela > --- > vmstate.c | 10

Re: [Qemu-devel] [PATCH 069/124] vmstate: Remove VMSTATE_BUFFER_MULTIPLY

2014-04-22 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > It was unused. > > Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert > --- > include/migration/vmstate.h | 13 - > vmstate.c | 3 --- > 2 files changed, 16 deletions(-) >

Re: [Qemu-devel] [PATCH 009/124] vmstate: Refactor opening of files

2014-04-22 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert I guess it's a bit simpler this way. Dave > --- > tests/test-vmstate.c | 38 +++--- > 1 file changed, 19 insertions(+), 19 delet

Re: [Qemu-devel] [PATCH v2 000/124] VMState Simplification (Massive)

2014-04-22 Thread Dr. David Alan Gilbert
bsection for the new version of the data, but I don't see how it could have otherwise kept it's compatibility. Dave -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 007/124] vmstate: Return error in case of error

2014-04-22 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > "Dr. David Alan Gilbert" wrote: > > * Juan Quintela (quint...@redhat.com) wrote: > >> If there is an error while loading a field, we should stop reading and > >> not continue with the rest of fields. And we shoul

Re: [Qemu-devel] [PATCH 007/124] vmstate: Return error in case of error

2014-04-22 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > Juan Quintela wrote: > > "Dr. David Alan Gilbert" wrote: > >> * Juan Quintela (quint...@redhat.com) wrote: > >>> If there is an error while loading a field, we should stop reading and > >>> not c

Re: [Qemu-devel] [PATCH 010/124] vmstate: Refactor & increase tests for primitive types

2014-04-22 Thread Dr. David Alan Gilbert
native order. > +bool skip_c_e; > +} TestStruct; > > static const VMStateDescription vmstate_versioned = { > -.name = "test", > +.name = "test/versioned", > .version_id = 2, > .minimum_version_id = 1, > .fields = (VMStateField[]) { > @@ -202,7 +358,7 @@ static bool test_skip(void *opaque, int version_id) > } > > static const VMStateDescription vmstate_skipping = { > -.name = "test", > +.name = "test/skip", > .version_id = 2, > .minimum_version_id = 1, > .fields = (VMStateField[]) { > @@ -337,8 +493,7 @@ int main(int argc, char **argv) > temp_fd = mkstemp(temp_file); > > g_test_init(&argc, &argv, NULL); > -g_test_add_func("/vmstate/simple/save", test_simple_save); > -g_test_add_func("/vmstate/simple/load", test_simple_load); > +g_test_add_func("/vmstate/simple/primitive", test_simple_primitive); > g_test_add_func("/vmstate/versioned/load/v1", test_load_v1); > g_test_add_func("/vmstate/versioned/load/v2", test_load_v2); > g_test_add_func("/vmstate/field_exists/load/noskip", test_load_noskip); > -- > 1.9.0 > > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK

Re: [Qemu-devel] [PATCH 010/124] vmstate: Refactor & increase tests for primitive types

2014-04-22 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > "Dr. David Alan Gilbert" wrote: > > * Juan Quintela (quint...@redhat.com) wrote: > >> This commit refactor the simple tests to test all integer types. We > >> move to hex because it is easier to read values of d

<    1   2   3   4   5   6   7   8   9   10   >