* [Qemu-devel] [PATCH] Add dirty-bytes-rate to output in 'info migrate'
@ 2017-03-14 12:38 Chao Fan
2017-03-14 12:50 ` Chao Fan
0 siblings, 1 reply; 2+ messages in thread
From: Chao Fan @ 2017-03-14 12:38 UTC (permalink / raw)
To: eblake, quintela, dgilbert, qemu-devel, berrange
Cc: caoj.fnst, douly.fnst, maozy.fnst, Chao Fan, Li Zhijian
Because 'dirty-bytes-rate' is in 'bytes/s', so it's better for other
tools to determine the cpu throttle value in different architecture.
Signed-off-by: Chao Fan <fanc.fnst@cn.fujitsu.com>
Signed-off-by: Li Zhijian <lizhijian@cn.fujitsu.com>
---
hmp.c | 6 +++++-
migration/migration.c | 1 +
qapi-schema.json | 5 ++++-
3 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/hmp.c b/hmp.c
index 261843f..c50d7aa 100644
--- a/hmp.c
+++ b/hmp.c
@@ -216,9 +216,13 @@ void hmp_info_migrate(Monitor *mon, const QDict *qdict)
monitor_printf(mon, "dirty sync count: %" PRIu64 "\n",
info->ram->dirty_sync_count);
if (info->ram->dirty_pages_rate) {
- monitor_printf(mon, "dirty pages rate: %" PRIu64 " pages\n",
+ monitor_printf(mon, "dirty pages rate: %" PRIu64 " pages/s\n",
info->ram->dirty_pages_rate);
}
+ if (info->ram->dirty_bytes_rate) {
+ monitor_printf(mon, "dirty bytes rate: %" PRIu64 " bytes/s\n",
+ info->ram->dirty_bytes_rate);
+ }
if (info->ram->postcopy_requests) {
monitor_printf(mon, "postcopy request count: %" PRIu64 "\n",
info->ram->postcopy_requests);
diff --git a/migration/migration.c b/migration/migration.c
index 3dab684..27f13c7 100644
--- a/migration/migration.c
+++ b/migration/migration.c
@@ -649,6 +649,7 @@ static void populate_ram_info(MigrationInfo *info, MigrationState *s)
if (s->state != MIGRATION_STATUS_COMPLETED) {
info->ram->remaining = ram_bytes_remaining();
info->ram->dirty_pages_rate = s->dirty_pages_rate;
+ info->ram->dirty_bytes_rate = s->dirty_bytes_rate;
}
}
diff --git a/qapi-schema.json b/qapi-schema.json
index 32b4a4b..0d5ec8e 100644
--- a/qapi-schema.json
+++ b/qapi-schema.json
@@ -575,6 +575,9 @@
# @postcopy-requests: The number of page requests received from the destination
# (since 2.7)
#
+# @dirty-bytes-rate: how many bytes dirtied by second by the
+# guest (since 2.9)
+#
# Since: 0.14.0
##
{ 'struct': 'MigrationStats',
@@ -582,7 +585,7 @@
'duplicate': 'int', 'skipped': 'int', 'normal': 'int',
'normal-bytes': 'int', 'dirty-pages-rate' : 'int',
'mbps' : 'number', 'dirty-sync-count' : 'int',
- 'postcopy-requests' : 'int' } }
+ 'postcopy-requests' : 'int', 'dirty-bytes-rate' : 'int' } }
##
# @XBZRLECacheStats:
--
2.9.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH] Add dirty-bytes-rate to output in 'info migrate'
2017-03-14 12:38 [Qemu-devel] [PATCH] Add dirty-bytes-rate to output in 'info migrate' Chao Fan
@ 2017-03-14 12:50 ` Chao Fan
0 siblings, 0 replies; 2+ messages in thread
From: Chao Fan @ 2017-03-14 12:50 UTC (permalink / raw)
To: eblake, quintela, dgilbert, qemu-devel, berrange
Cc: caoj.fnst, douly.fnst, maozy.fnst, Li Zhijian
Daniel and Juan,
Sorry for this patch, cause I did not see your reply.
So Nack this patch.
And thank you very much.
Thanks,
Chao Fan
On Tue, Mar 14, 2017 at 08:38:41PM +0800, Chao Fan wrote:
>Because 'dirty-bytes-rate' is in 'bytes/s', so it's better for other
>tools to determine the cpu throttle value in different architecture.
>
>Signed-off-by: Chao Fan <fanc.fnst@cn.fujitsu.com>
>Signed-off-by: Li Zhijian <lizhijian@cn.fujitsu.com>
>---
> hmp.c | 6 +++++-
> migration/migration.c | 1 +
> qapi-schema.json | 5 ++++-
> 3 files changed, 10 insertions(+), 2 deletions(-)
>
>diff --git a/hmp.c b/hmp.c
>index 261843f..c50d7aa 100644
>--- a/hmp.c
>+++ b/hmp.c
>@@ -216,9 +216,13 @@ void hmp_info_migrate(Monitor *mon, const QDict *qdict)
> monitor_printf(mon, "dirty sync count: %" PRIu64 "\n",
> info->ram->dirty_sync_count);
> if (info->ram->dirty_pages_rate) {
>- monitor_printf(mon, "dirty pages rate: %" PRIu64 " pages\n",
>+ monitor_printf(mon, "dirty pages rate: %" PRIu64 " pages/s\n",
> info->ram->dirty_pages_rate);
> }
>+ if (info->ram->dirty_bytes_rate) {
>+ monitor_printf(mon, "dirty bytes rate: %" PRIu64 " bytes/s\n",
>+ info->ram->dirty_bytes_rate);
>+ }
> if (info->ram->postcopy_requests) {
> monitor_printf(mon, "postcopy request count: %" PRIu64 "\n",
> info->ram->postcopy_requests);
>diff --git a/migration/migration.c b/migration/migration.c
>index 3dab684..27f13c7 100644
>--- a/migration/migration.c
>+++ b/migration/migration.c
>@@ -649,6 +649,7 @@ static void populate_ram_info(MigrationInfo *info, MigrationState *s)
> if (s->state != MIGRATION_STATUS_COMPLETED) {
> info->ram->remaining = ram_bytes_remaining();
> info->ram->dirty_pages_rate = s->dirty_pages_rate;
>+ info->ram->dirty_bytes_rate = s->dirty_bytes_rate;
> }
> }
>
>diff --git a/qapi-schema.json b/qapi-schema.json
>index 32b4a4b..0d5ec8e 100644
>--- a/qapi-schema.json
>+++ b/qapi-schema.json
>@@ -575,6 +575,9 @@
> # @postcopy-requests: The number of page requests received from the destination
> # (since 2.7)
> #
>+# @dirty-bytes-rate: how many bytes dirtied by second by the
>+# guest (since 2.9)
>+#
> # Since: 0.14.0
> ##
> { 'struct': 'MigrationStats',
>@@ -582,7 +585,7 @@
> 'duplicate': 'int', 'skipped': 'int', 'normal': 'int',
> 'normal-bytes': 'int', 'dirty-pages-rate' : 'int',
> 'mbps' : 'number', 'dirty-sync-count' : 'int',
>- 'postcopy-requests' : 'int' } }
>+ 'postcopy-requests' : 'int', 'dirty-bytes-rate' : 'int' } }
>
> ##
> # @XBZRLECacheStats:
>--
>2.9.3
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-03-14 12:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-14 12:38 [Qemu-devel] [PATCH] Add dirty-bytes-rate to output in 'info migrate' Chao Fan
2017-03-14 12:50 ` Chao Fan
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.