提交 c402eebc 编写于 作者: G Guannan Ren

cgroup: read more data from cgroup cpuacct.usage_percpu

On NUMA machine, the length of string got from file
cpuacct.usage_percpu is quite large, so expand the
limit of 1024 bytes.

errors like:
Failed to read file \
'/cgroup/cpuacct/libvirt/qemu/rhel6q/cpuacct.usage_percpu': \
Value too large for defined data type
上级 b10ec38d
......@@ -360,7 +360,7 @@ static int virCgroupGetValueStr(virCgroupPtr group,
VIR_DEBUG("Get value %s", keypath);
rc = virFileReadAll(keypath, 1024, value);
rc = virFileReadAll(keypath, 1024*1024, value);
if (rc < 0) {
rc = -errno;
VIR_DEBUG("Failed to read %s: %m\n", keypath);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册