RE: [Netnice-kernels] Re: netnice on linux
Status: Alpha
Brought to you by:
taost6
From: kartikey b. <kar...@ho...> - 2006-02-24 09:17:50
|
hi, taka wrote: >how can we control sockets, in the scheme? we may want to control >independent connections, or, may want to prioritize some sockets >(interactive ones) among others (bulk data transfer), in a process. > >one of our advantage is flexible control granularity with hierarchical >resource management scheme, realized by the VIF structure. i cannot >see any merit in your suggestion. what do you mean by the word, >"consistent"? netnice command doesn't provide support for controlling individual sockets, it just allows control over the process. how do you differentiate interactive sockets from bulk data transfer sockets in a process. a process like apache or inetd which creates and terminates several connections , allocating and deallocating pvifnet data structure introduces overhead. rather my approach is that a socket shares the pvifnet data structure with the process and only when it is required to control individual socket we allocate the necessary resources. > > 2. I am enforcing that each process should have at least (and at most) > > one vif associated with the real net_device (ifnet in FreeBSD > > terminology). So a process cannot have more than "1" or less than "1" > > vif associated with eth0 at any given time. Whenever a process creates a > > vif, I am not allocating a new p_vifnet rather I am modifying the > > p_vifnet that is already associated with the vif that connects process > > to the real net_device (interface). When a process deletes the vif it > > simply reverts the p_vifnet to the vif that was associated with it > > before the creation of new vif. > >can you give us a simple figure, describing each scheme? i am not good at figure though i implement my scheme as follows. initially each process has one vif attached to real interface. which is accessible through pvifnet->pipe and real interface is accessible through pvif->pipe->dev. i introduce a new variable prev_pipe in pvifnet data structure. when a process creates a new vif we find out the pvifnet data structure that connects process to the interface and simply update: pvifnet->prev_pipe = pvifnet->pipe; pvifnet->pipe = new_vif: when a process wants to delete an association to the vif the operation becomes: pvifnet->pipe = pvifnet->prev_pipe; this way at any given time each process has at least one vif that associates it with thee real interface thanks --kartikey |