OpenVZ Forum


Home » Mailing lists » Users » HELP:How can one VM interrupt another running VM ??
Re: HELP:How can one VM interrupt another running VM ?? [message #42593 is a reply to message #42590] Tue, 03 May 2011 21:41 Go to previous message
Daniel Pittman is currently offline  Daniel Pittman
Messages: 26
Registered: January 2007
Junior Member
No, that is absolutely impossible. The only mechanism for that Linux
provides for this is using RT scheduling and IPC, and those are not
really available to you. What you are describing sounds very much
like cooperative multitasking, which Linux doesn't do at this level.

Are you sure you don't want, for example, a TCP socket passing data to
the "switch to" process, and then to block until the response comes
back?

Daniel

On Tue, May 3, 2011 at 13:27, shule ney <neyshule@gmail.com> wrote:
> Thanks Daniel, but it's not interrupt for that thread/process, the nice
> value just set higher priority, what I want to do is like stop the current
> running process in one VM, context swiching to another process in another
> VM, when this process finishes, switch back to the original VM, of
> course this preempting VM has higher nice value. Is it possible?
>
> 2011/5/3 Daniel Pittman <daniel@rimspace.net>
>>
>> On Tue, May 3, 2011 at 12:58, shule ney <neyshule@gmail.com> wrote:
>>
>> > I was wondering how can I use one VM to interrupt another running VM, is
>> > there any schedular surpport this function, or any control I can use
>> > to implement it. For OpenVZ, is it possible to achieve this?
>>
>> Not as such, no, but: OpenVZ has a single scheduler across all threads
>> / processes in all VEs.  So, if you imagine the scheduler as working
>> on a single system with all those tasks the normal rules of process
>> scheduling apply.
>>
>> Which means that if you set your higher priority stuff to a high nice
>> level, or real-time priority, it will take precedence over another VE
>> that runs lower priority stuff.
>>
>> Finally, if you assign appropriate CPU shares to the VEs you can
>> ensure that they will get all the time divided appropriately at a high
>> level.
>>
>> Regards,
>>    Daniel
>>
>> PS: Native Linux doesn't support this either. :)
>>
>> --
>> ⎋ Puppet Labs Developer – http://puppetlabs.com
>> ✉ Daniel Pittman <daniel@rimspace.net>
>> ✆ Contact me via gtalk, email, or phone: +1 (503) 893-2285
>> ♲ Made with 100 percent post-consumer electrons
>>
--
⎋ Puppet Labs Developer – http://puppetlabs.com
✉ Daniel Pittman <daniel@rimspace.net>
✆ Contact me via gtalk, email, or phone: +1 (503) 893-2285
♲ Made with 100 percent post-consumer electrons
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: glusterfs/moosefs/etc as openvz backend?
Next Topic: (no subject)
Goto Forum:
  


Current Time: Tue Sep 17 17:34:05 GMT 2024

Total time taken to generate the page: 0.05059 seconds