From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alexandre Bezroutchko Subject: extra parameters for a custom vif-script Date: Wed, 10 Apr 2013 15:21:26 +0200 Message-ID: <51656756.3020200@gremwell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org Hello, I am trying to develop custom xen vif- and network- scripts and can't figure out how to passing parameters. When creating a domain, I would like to be able to specify two additional parameters for each vif and get access to them via from my custom vif-script. I have done some research and found I can easiliy extend the list of parameters accepted by 'xm create' command by editing /usr/lib/xen-4.0/lib/python/xen/xm/create.py. It all works just fine in the dry mode, I see the parameters and their value dumped on the output. But when the domain gets created these values don't see to be retained in the config, I see no traces of them in the output of 'xm list VMID'. I have also attempted to edit vif_params in main.py to add same two parameters to 'network-attach' command handler. It has not helped, the parameter don't seem to make it into the config nor xenstore anyway. I could use an advice how this can be implemented properly. I thinking about customizing create.py further, to store values I need to persist in xenstore under /vm/UUID/device/vif/NNN/. Just wondering if I am overlooking some more elegant solution. Any advise is appreciated. PS. I use xm toolstack on Xen 4.0.1 on Debian. Best regards, Alex