<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">Hi,<br>
Thanks ondra. It works . When i specify the
"usages=types.NetworkUsage.Migration" it was throwing me an error.
I was missing [] braces.<br>
<br>
Thanks<br>
kasturi.<br>
On 09/22/2016 06:45 PM, knarra wrote:<br>
</div>
<blockquote
cite="mid:b58ac583-9f1d-f21e-74f5-1307872d3092@redhat.com"
type="cite">
<meta http-equiv="content-type" content="text/html;
charset=windows-1252">
<p>Hi,</p>
<p> I am trying to create a non vm network using the following
code, but it still go a head and creates vm network. Can some
one please help me to resolve this? Or can you let me know in
case i am missing some parameter to add here?</p>
<p>
<meta http-equiv="content-type" content="text/html;
charset=windows-1252">
</p>
<pre style="background-color:#ffffff;color:#000000;font-family:'DejaVu Sans Mono';font-size:13.5pt;"><span style="color:#000080;font-weight:bold;">def </span>create_gluster_network(network_name):
networks_service = connection.system_service().networks_service()
<span style="color:#808080;">network </span>= networks_service.add(types.<span style="background-color:#e4e4ff;">Network</span>(<span style="color:#660099;">name</span>=network_name, <span style="color:#660099;">data_center</span>=types.DataCenter(<span style="color:#660099;">name</span>=<span style="color:#008000;font-weight:bold;">'Default'</span>), <span style="color:#660099;">description</span>=<span style="color:#008000;font-weight:bold;">'new gluster network'
</span><span style="color:#008000;font-weight:bold;"> </span>))
Thanks
kasturi
</pre>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@ovirt.org">Users@ovirt.org</a>
<a class="moz-txt-link-freetext" href="http://lists.ovirt.org/mailman/listinfo/users">http://lists.ovirt.org/mailman/listinfo/users</a>
</pre>
</blockquote>
<p><br>
</p>
</body>
</html>