sowmini.varadhan at sun.com
2009-Apr-10 19:06 UTC
[crossbow-discuss] property parsing in dladm
I decided to take a stab at 6601421 dladm set-linkprop should support multiple -p options along with some related linkprop fixes, but when I looked into dladm.c, was surprised to find that "dladm_parse_props()" is called from do_create_aggr and do_create_vlan in addition to the expected (by me, at least) do_create_vnic *linkprop functions. What happened here? Why do we pass in property lists for aggr and vlan creation? Even more confusing is the fact that the dladm usage string (emitted when one types dladm with no args) does not have any hint of the -p option for vlans and aggrs. At least that, needs to be fixed! --Sowmini
On Fri, 10 Apr 2009 sowmini.varadhan at sun.com wrote:> I decided to take a stab at > > 6601421 dladm set-linkprop should support multiple -p options > > along with some related linkprop fixes, but when I looked into > dladm.c, was surprised to find that "dladm_parse_props()" is called > from do_create_aggr and do_create_vlan in addition to the > expected (by me, at least) do_create_vnic *linkprop functions. > > What happened here? Why do we pass in property lists for aggr and > vlan creation?We support bandwidth/cpu etc. properties for vlans (via dladm create-vlan - just like a vlan created by dladm create-vnic -v) and aggrs.> > Even more confusing is the fact that the dladm usage string (emitted > when one types dladm with no args) does not have any hint of the > -p option for vlans and aggrs. At least that, needs to be fixed!True, that is a bug. -venu> > --Sowmini > > _______________________________________________ > crossbow-discuss mailing list > crossbow-discuss at opensolaris.org > http://mail.opensolaris.org/mailman/listinfo/crossbow-discuss >
sowmini.varadhan at sun.com
2009-Apr-10 19:22 UTC
[crossbow-discuss] property parsing in dladm
On (04/10/09 12:20), venugopal iyer wrote:> > We support bandwidth/cpu etc. properties for vlans (via dladm create-vlan - > just like a vlan created by dladm create-vnic -v) and aggrs.Ok, that needs to be documented appropriately. another major RFE in this area is for libdladm to use nvlists. libipadm is doing this, and, I gather, so is libnwamd. The libnvpair library is much easier to use both within the library and from apps like ipadm. --Sowmini
> > along with some related linkprop fixes, but when I looked into> > dladm.c, was surprised to find that "dladm_parse_props()" is called > > from do_create_aggr and do_create_vlan in addition to the > > expected (by me, at least) do_create_vnic *linkprop functions. > > > > What happened here? Why do we pass in property lists for aggr and > > vlan creation? > > We support bandwidth/cpu etc. properties for vlans (via dladm create-vlan - > just like a vlan created by dladm create-vnic -v) and aggrs. Is there an inherent neeed to support this rather than just having the admin do a set-linkprop afterwards? -- meem
sowmini.varadhan at sun.com
2009-Apr-10 20:02 UTC
[crossbow-discuss] property parsing in dladm
On (04/10/09 13:04), venugopal iyer wrote:>> Is there an inherent neeed to support this rather than just having the >> admin do a set-linkprop afterwards? > > I suppose from an admin''s point, it does provide a way to create a link > with certain props directly, rather than following dladm create- with a > dladm set-linkprop. Also, this keeps it consistent with dladm create-vnic.but by extension of that thumb-rule, every create-* command now has to support -p even though the only relevant props here bw and cpu(?) --Sowmini
On Fri, 10 Apr 2009, Peter Memishian wrote:> > > > along with some related linkprop fixes, but when I looked into > > > dladm.c, was surprised to find that "dladm_parse_props()" is called > > > from do_create_aggr and do_create_vlan in addition to the > > > expected (by me, at least) do_create_vnic *linkprop functions. > > > > > > What happened here? Why do we pass in property lists for aggr and > > > vlan creation? > > > > We support bandwidth/cpu etc. properties for vlans (via dladm create-vlan - > > just like a vlan created by dladm create-vnic -v) and aggrs. > > Is there an inherent neeed to support this rather than just having the > admin do a set-linkprop afterwards?I suppose from an admin''s point, it does provide a way to create a link with certain props directly, rather than following dladm create- with a dladm set-linkprop. Also, this keeps it consistent with dladm create-vnic. -venu> > -- > meem >
On 04/10/09 12:06, Sowmini.Varadhan at Sun.COM wrote:> I decided to take a stab at > > 6601421 dladm set-linkprop should support multiple -p options >I probably fixed this with my putback for 6796069 <http://monaco.sfbay.sun.com/detail.jsp?cr=6796069> dladm set-linkprop for multiple props succeeds even if some values are invalid I also propagated the same fix for create-vnic/vlan/aggr for consistency.> along with some related linkprop fixes, but when I looked into > dladm.c, was surprised to find that "dladm_parse_props()" is called > from do_create_aggr and do_create_vlan in addition to the > expected (by me, at least) do_create_vnic *linkprop functions. > > What happened here? Why do we pass in property lists for aggr and > vlan creation?Consistency with create-vnic. We''ve always allowed bandwidth specification with create-vnic and then added cpus and priority.> Even more confusing is the fact that the dladm usage string (emitted > when one types dladm with no args) does not have any hint of the > -p option for vlans and aggrs. At least that, needs to be fixed!That''s a bug. -Mike -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.opensolaris.org/pipermail/crossbow-discuss/attachments/20090410/17eb7ea5/attachment.html>
sowmini.varadhan at sun.com
2009-Apr-10 20:17 UTC
[crossbow-discuss] property parsing in dladm
On (04/10/09 13:10), Michael Lim wrote:>> >> 6601421 dladm set-linkprop should support multiple -p options >> > I probably fixed this with my putback for > 6796069 <http://monaco.sfbay.sun.com/detail.jsp?cr=6796069> dladm > set-linkprop for multiple props succeeds even if some values are invalidyes, it appears you did. Thanks, --Sowmini
> >> Is there an inherent neeed to support this rather than just having the> >> admin do a set-linkprop afterwards? > > > > I suppose from an admin''s point, it does provide a way to create a link > > with certain props directly, rather than following dladm create- with a > > dladm set-linkprop. Also, this keeps it consistent with dladm create-vnic. > > but by extension of that thumb-rule, every create-* command now has to > support -p even though the only relevant props here bw and cpu(?) And further, not all link classes have a create-* subcommand, so it ends up asymmetric. -- meem
On 04/10/09 13:02, sowmini.varadhan at sun.com wrote:> On (04/10/09 13:04), venugopal iyer wrote: >>> Is there an inherent neeed to support this rather than just having the >>> admin do a set-linkprop afterwards? >> I suppose from an admin''s point, it does provide a way to create a link >> with certain props directly, rather than following dladm create- with a >> dladm set-linkprop. Also, this keeps it consistent with dladm create-vnic. > > but by extension of that thumb-rule, every create-* command now has to > support -p even though the only relevant props here bw and cpu(?) >How many commands should one run to be able to create a VNIC with some link speed and CPU assignments necessary to configure a virtual machine? Keep in mind that people do run thousands of zones on one machine. This was a very strong feedback from most of the virtualization customers and they love the current mechanism of running one command per virtual machine/zone. Think from a user perspective as well. As for the properties, we have bw limits, cpus and pri today and there are more to come. Cheers, Sunay
On 04/10/09 12:42, Peter Memishian wrote:> > > along with some related linkprop fixes, but when I looked into > > > dladm.c, was surprised to find that "dladm_parse_props()" is called > > > from do_create_aggr and do_create_vlan in addition to the > > > expected (by me, at least) do_create_vnic *linkprop functions. > > > > > > What happened here? Why do we pass in property lists for aggr and > > > vlan creation? > > > > We support bandwidth/cpu etc. properties for vlans (via dladm > create-vlan - > > just like a vlan created by dladm create-vnic -v) and aggrs. > > Is there an inherent neeed to support this rather than just having the > admin do a set-linkprop afterwards?There''s not an inherent need. It''s due to a series of decisions made during Crossbow development. - create-vnic has always had maxbw as an argument - cpus and priority are link properties like maxbw which can be set for vnics and physical links - all 3 properties should be converted to link property framework. (this was also done for flows) - aggrs and vlans can take properties at creation, just like a vnic. (this applies flows as well) -Mike
sowmini.varadhan at sun.com
2009-Apr-10 20:20 UTC
[crossbow-discuss] property parsing in dladm
On (04/10/09 13:17), Sunay Tripathi wrote:> > How many commands should one run to be able to create a VNIC with > some link speed and CPU assignments necessary to configure a virtual > machine? Keep in mind that people do run thousands of zones > on one machine. This was a very strong feedback from most of > the virtualization customers and they love the current mechanism > of running one command per virtual machine/zone. > > Think from a user perspective as well. As for the properties, we > have bw limits, cpus and pri today and there are more to come.not trying to start a flame thread here, but isn''t that (command overloading) one problem with ifconfig? --Sowmini
sowmini.varadhan at sun.com
2009-Apr-10 20:37 UTC
[crossbow-discuss] property parsing in dladm
On (04/10/09 13:37), Sunay Tripathi wrote:> > Not sure what ifconfig got to do with virtualization? In mostthe frequently heard complaint about ifconfig is that, as a CLI, it is overloaded and tries to do too many things in one command line.> virtual machine cases the vnics are never plumbed. Anyway, the > goal is to make it as simple and useful as possible. If > one command line starts extending to multiple lines, then > breaking it up in multiple sub commands makes sense. But > right now I don''t see the need/risk. Things as they are > were done after lot of feedback from users.sure. --Sowmini
On 04/10/09 13:20, sowmini.varadhan at sun.com wrote:> On (04/10/09 13:17), Sunay Tripathi wrote: >> How many commands should one run to be able to create a VNIC with >> some link speed and CPU assignments necessary to configure a virtual >> machine? Keep in mind that people do run thousands of zones >> on one machine. This was a very strong feedback from most of >> the virtualization customers and they love the current mechanism >> of running one command per virtual machine/zone. >> >> Think from a user perspective as well. As for the properties, we >> have bw limits, cpus and pri today and there are more to come. > > not trying to start a flame thread here, but isn''t that (command > overloading) one problem with ifconfig?Not sure what ifconfig got to do with virtualization? In most virtual machine cases the vnics are never plumbed. Anyway, the goal is to make it as simple and useful as possible. If one command line starts extending to multiple lines, then breaking it up in multiple sub commands makes sense. But right now I don''t see the need/risk. Things as they are were done after lot of feedback from users. Cheers, Sunay