[one-users] A question about the utilization of VMs

Antonio Messina amessina at ictp.it
Tue Dec 6 12:37:37 PST 2011


On 06/12/11 20.10, Fabian Wenk wrote:
> Hello Adnan
>
> On 04.12.2011 18:18, Adnan Pasic wrote:
>> I can't really tell you what lookbusy does, as it's not a
>> programme coded by
>> me, but found on the internet to fulfill its duties ;)
>
> Or it does not properly as you would need it.
>
>> Also, the website where I downloaded it from doesn't say anything
>> on how the
>> programme is really working, and if it's possible to somehow
>> upgrade it with
>> for the purpose of, e.g. filling zeros.
>
> Google pointed me to [1], is this the one you are using? If yes, you
> could ask the developer, if he could adjust it for your needs (eg.
> filling the memory with random data, or even changing it during
> runtime), or ask some other developer which knows about C, if he
> could do it for you.
>
> [1] http://www.devin.com/lookbusy/

it's a quite simple program, less than 1000 lines of code. The 
answer is yes, btw, it does fill the memory with "random" data 
during initialization:

     for (p = mem_stir_buffer; p < mem_stir_buffer + sz; p++) {
         *p = (char)((uintptr_t)p & 0xff);
     }

and keep using it:

     while (1) {
         const size_t copysz = pagesize;

#ifdef HAVE_MEMMOVE
         memmove(dp, sp, copysz);
#else
         memcpy(dp, sp, copysz);
#endif
         sp += pagesize * 1;
         dp += pagesize * 5;

I think that the problem is not related to KSM but to virtio 
balloons: it is possible that the memory allocated by the lookbusy 
program is not freed by the guest os (actually, by kvm). I never 
tried, but I would give a try to something like "virsh setmem 
102400" and see what happen...

.a.

-- 
Antonio Messina
I.T. Specialist

email: amessina at ictp.it      |  The Abdus Salam ICTP
phone: +39 040-2240-691      |  Strada Costiera, 11
fax:   +39 040-2240-7691     |  34151 Trieste, Italy

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2949 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20111206/9f67942b/attachment-0003.bin>


More information about the Users mailing list