VDSM hook for setting DSCP bits?

Is there a VDSM hook available that can set DSCP bits on a VM's network interface? I want to do some QoS for some traffic across my network, and it would be easier if I could set DSCP bits outside the VM. I see vdsm-hook-qos, but that appears to just set bandwidth control in the Linux host, not DSCP on packets for the rest of the network. -- Chris Adams <cma@cmadams.net>

shouldn't be hard to do. Can you provide the details of what you need to happen to the VM exactly? - domxml changes - other host level changes - whether the VM should be able to live migrate On Tue, Feb 10, 2015 at 2:34 PM, Chris Adams <cma@cmadams.net> wrote:
Is there a VDSM hook available that can set DSCP bits on a VM's network interface? I want to do some QoS for some traffic across my network, and it would be easier if I could set DSCP bits outside the VM.
I see vdsm-hook-qos, but that appears to just set bandwidth control in the Linux host, not DSCP on packets for the rest of the network. -- Chris Adams <cma@cmadams.net> _______________________________________________ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users

Once upon a time, Dan Yasny <dyasny@gmail.com> said:
shouldn't be hard to do. Can you provide the details of what you need to happen to the VM exactly? - domxml changes - other host level changes - whether the VM should be able to live migrate
It looks like libvirt supports setting up DSCP bits with nwfilter, per: https://libvirt.org/formatnwfilter.html I will play with this some to see exactly how to use it (haven't tried it before). If that's the case, there shouldn't be any host-level changes required. I would want the VM to be able to live migrate still (with the DSCP still applied). I'll test this out on a bare libvirt VM and see if that'll do the job, and report back with what XML is needed. Thanks.
On Tue, Feb 10, 2015 at 2:34 PM, Chris Adams <cma@cmadams.net> wrote:
Is there a VDSM hook available that can set DSCP bits on a VM's network interface? I want to do some QoS for some traffic across my network, and it would be easier if I could set DSCP bits outside the VM.
I see vdsm-hook-qos, but that appears to just set bandwidth control in the Linux host, not DSCP on packets for the rest of the network. -- Chris Adams <cma@cmadams.net> _______________________________________________ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
_______________________________________________ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
-- Chris Adams <cma@cmadams.net>

Once upon a time, Chris Adams <cma@cmadams.net> said:
Once upon a time, Dan Yasny <dyasny@gmail.com> said:
shouldn't be hard to do. Can you provide the details of what you need to happen to the VM exactly? - domxml changes - other host level changes - whether the VM should be able to live migrate
It looks like libvirt supports setting up DSCP bits with nwfilter, per:
Oh, on reading this, nwfilter can only match, not set, so that won't help. It doesn't look like libvirt has a way to set something like that. Do VDSM hooks only act on the XML, or is there a way to configure things outside of libvirt? -- Chris Adams <cma@cmadams.net>

On Wed, Feb 11, 2015 at 12:17 PM, Chris Adams <cma@cmadams.net> wrote:
Once upon a time, Chris Adams <cma@cmadams.net> said:
Once upon a time, Dan Yasny <dyasny@gmail.com> said:
shouldn't be hard to do. Can you provide the details of what you need to happen to the VM exactly? - domxml changes - other host level changes - whether the VM should be able to live migrate
It looks like libvirt supports setting up DSCP bits with nwfilter, per:
Oh, on reading this, nwfilter can only match, not set, so that won't help. It doesn't look like libvirt has a way to set something like that.
Do VDSM hooks only act on the XML, or is there a way to configure things outside of libvirt?
The hooks are point is the VMs lifetime where you can insert any code you like. There is a way to edit the domxml at certain points, because it hasn't been passed to libvirt for execution yet. At other points changing the domxml will do nothing useful because the VM is already running, but you can do other things, execute other commands. A classic example is an oVirt independent Vm event monitoring engine, to which you can issue a hook based message at certain lifecycle points, e.g. "VM $VM is starting"; "VM $VM is migrating" etc. No idea why you'd need that engine (it's quite redundant because the ovirt-engine already does all this) but it will definitely work. In short, explore the hooks, note the livecycle points (they are simply aptly named directories on the hosts) and decide what and where you need to execute. If you are modifying a VM, it probably makes sense to do it in before_vm_start, but if you're also live migrating that VM, you need to add the same changes in before_migrate_vm_*, and if the hook script makes changes on the host, you probably want to clean up after the VM is gone, so after_vm_stop and after_vm_migrate_source are the places to start looking. The mechanism is very flexible really, you can do anything you want if the host OS is capable of it
-- Chris Adams <cma@cmadams.net> _______________________________________________ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
participants (2)
-
Chris Adams
-
Dan Yasny