<?xml version="1.0"?>
<rss version="2.0" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:yt="http://gdata.youtube.com/schemas/2007" xmlns:atom="http://www.w3.org/2005/Atom">
   <channel>
      <title>Yong Sheng Gong OpenStack</title>
      <description>Pipes Output</description>
      <link>http://pipes.yahoo.com/pipes/pipe.info?_id=bb3905a64a08b9d8167502028410a1e8</link>
      <atom:link rel="next" href="http://pipes.yahoo.com/pipes/pipe.run?_id=bb3905a64a08b9d8167502028410a1e8&amp;_render=rss&amp;page=2"/>
      <pubDate>Sat, 25 May 2013 07:56:59 +0000</pubDate>
      <generator>http://pipes.yahoo.com/pipes/</generator>
      <item>
         <title>Quantum Folsom</title>
         <link>https://www.ibm.com/developerworks/community/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/entry/quantum_folsom12?lang=en</link>
         <description>&lt;ul&gt;&lt;li&gt;Openstack and Quantum&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Quantum consists of many components in Folsom release:&lt;/p&gt;&lt;div&gt;&lt;ol&gt;&lt;li&gt;Quantum-server provides REST API  for outside to access and manage the virtual network models.  Inside the quantum-server, there is a plugin (Also AKA backend) to operate the models in Database. Quantum-sever is should be deployed on the controller node and HA can be put before multiple quantum-server processes to deal with large cloud system.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;By now, l3-agent communicates with quantum-server by REST API via quantum client library. L3-agent is used to manage floating ip and router. One L3-router can only manage one external network.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;plugin agent runs with nova-compute, which maps the virtual networks to actual network environment so that to assure the connectivity of VMs.&lt;/li&gt;&lt;li&gt;DHCP agent runs per-subnet.&lt;br /&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;p&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/Openstackarchi_1.png
&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/Openstackarchi_1.png&quot; style=&quot;display:block;margin:0 auto;text-align:center;&quot;/&gt;&lt;br /&gt;&lt;/a&gt;&lt;/p&gt;&lt;div&gt;&lt;ul&gt;&lt;li&gt; quantum models&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;These are some core models in quantum:&lt;/p&gt;&lt;div&gt;&lt;ol&gt;&lt;li&gt;network. Network can be imagined as a big and big switch. we can create limitless ports on it.&lt;/li&gt;&lt;li&gt;Subnet. Subnet is a segment of IP address, which is assigned to port&lt;/li&gt;&lt;li&gt;Port. Port is able to be attached by a device, such as VM, floatingip or router&lt;/li&gt;&lt;li&gt;Router. Router is a kind of device in quantum, which connect the traffic from a subnet to external network.  Each router can has on gateway port on an external network and multiple interfaces on internal network. Once the subnet in the internal network is connected to an external network, the VMs on that subnet can access outside through the router.&lt;/li&gt;&lt;li&gt;floating IP. Floating ip is used to get an IP from external network and associate it with a port on the internal network and the port is attached by a VM. After a given VM has a floating ip, external world can access the VM with that floating ip.&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;/div&gt;&lt;p&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/models.png
&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/models.png&quot; style=&quot;display:block;margin:0 auto;text-align:center;&quot;/&gt;&lt;/a&gt;&lt;/p&gt;&lt;div&gt;&lt;ul&gt;&lt;li&gt; categories of networks&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;network is divided into physical network and virtual network in quantum. the network object in quantum model is for virtual networks. we identify each physical network as a name in plugin's configure file. Physical network is actual existing network in the infrastructure.  It may be a VLAN with a given vlan id, or a flat network. Virtual networks are realized by a given kind of physical network via network biding object. Virtual networks also are divided into tenant network or provider network. But most of the time, we cannot see much difference between them. If we provide the physical network name, type and segment id, it is a provider network, or we are creating a tenant network. Tenant network's network binding object is selected from a pool, defined in configure file.&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/network_1.png
&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/network_1.png&quot; style=&quot;display:block;margin:0 auto;text-align:center;&quot;/&gt;&lt;/a&gt;&lt;/p&gt;&lt;div&gt;&lt;ul&gt;&lt;li&gt; another view into networks&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;In general, we create VM's ports on internal networks, while create floating ip, router's gateway ports on external networks. Provider networks are often shared networks while tenant networks are typically private networks.&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/network_2_1.png
&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/network_2_1.png&quot; style=&quot;display:block;margin:0 auto;text-align:center;&quot;/&gt;&lt;/a&gt;&lt;/p&gt;&lt;div&gt;&lt;ul&gt;&lt;li&gt;collaboration among quantum components&lt;/li&gt;&lt;/ul&gt;&lt;ol&gt;&lt;li&gt;nova boot will get into compute driver, which will call quantum api to create port &lt;/li&gt;&lt;li&gt;quantum-server creates the port object and allocates it with ip address from subnets&lt;/li&gt;&lt;li&gt;quantum-server notifies quantum-dhcp agent with the created port object&lt;/li&gt;&lt;li&gt;quantum-dhcp agent configs the dhcp server with the port object, such as IP, Mac, gateway and routes&lt;/li&gt;&lt;li&gt;compute-driver gets the network information, and then create port on br-int ovswitch, and then starts the VM with a tap device attached on the ovs port.&lt;/li&gt;&lt;li&gt;ovs-quantum-agent detects and gets to know there is a new ovs port created&lt;/li&gt;&lt;li&gt;ova-quantum-agent asks information from quantum-server&lt;/li&gt;&lt;li&gt;ova-quantum-agent set up the port, such as the flows and vlan id of the ovs port. After this step, the VM's network is connected.&lt;/li&gt;&lt;li&gt;VM gets the IP address with the dhcp client.&lt;br /&gt;&lt;/li&gt;&lt;/ol&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/dataflow-bootingnet.png
&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/dataflow-bootingnet.png&quot; style=&quot;display:block;margin:0 auto;text-align:center;&quot;/&gt;&lt;/a&gt;   &lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</description>
         <author>YongShengGong</author>
         <guid isPermaLink="false">urn:lsid:ibm.com:blogs:entry-ec12ff1d-12ec-417d-b011-b916b51a9497</guid>
         <pubDate>Mon, 17 Sep 2012 12:30:16 +0000</pubDate>
      </item>
      <item>
         <title>Openstack's Floating IPs</title>
         <link>https://www.ibm.com/developerworks/community/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/entry/openstack_s_floating_ips7?lang=en</link>
         <description>&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;To see how floating IPs are
implemented, we first associate a floating IP to our instance's fixed IP.  We assume the
fixed IP of our instance is 10.10.10.2.&lt;/p&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;To create a range of floating ips in
default pool:&lt;/p&gt;

&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoNormalTable&quot; height=&quot;41&quot; style=&quot;border-collapse:collapse;border:medium none;&quot; width=&quot;667&quot;&gt;
 &lt;tbody&gt;&lt;tr style=&quot;&quot;&gt;
  &lt;td style=&quot;width:231.45pt;border:solid windowtext 1.0pt;padding:0in 5.4pt 0in 5.4pt;&quot; valign=&quot;top&quot; width=&quot;309&quot;&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;#nova-manage floating create --ip_range=192.168.1.232/30&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;To allocate a floating ip from
this pool:&lt;/p&gt;

&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoNormalTable&quot; height=&quot;54&quot; style=&quot;border-collapse:collapse;border:medium none;&quot; width=&quot;665&quot;&gt;
 &lt;tbody&gt;&lt;tr style=&quot;&quot;&gt;
  &lt;td style=&quot;width:231.45pt;border:solid windowtext 1.0pt;padding:0in 5.4pt 0in 5.4pt;&quot; valign=&quot;top&quot; width=&quot;309&quot;&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;# Nova floating-ip-create&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;We got an IP 192.168.1.233. And
then assign it to our instance, which has id
8f773639-c04f-4885-9349-ac7d6a799843:&lt;/p&gt;

&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoNormalTable&quot; height=&quot;35&quot; style=&quot;border-collapse:collapse;border:medium none;&quot; width=&quot;667&quot;&gt;
 &lt;tbody&gt;&lt;tr style=&quot;&quot;&gt;
  &lt;td style=&quot;width:231.45pt;border:solid windowtext 1.0pt;padding:0in 5.4pt 0in 5.4pt;&quot; valign=&quot;top&quot; width=&quot;309&quot;&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;#nova add-floating-ip 8f773639-c04f-4885-9349-ac7d6a799843
  192.168.1.233&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;

&lt;p class=&quot;MsoNormal&quot;&gt; &lt;/p&gt;

&lt;h2&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;_Toc327277661&quot;&gt;Floating ip bound to public interface&lt;/a&gt;&lt;/h2&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt; FLAGS.public_interface is used
to bind floating IPs. After we run “nova add-floating-ip” command, we can see
we got this floating IP under the public_interface:&lt;/p&gt;

&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoNormalTable&quot; height=&quot;270&quot; style=&quot;border-collapse:collapse;border:medium none;&quot; width=&quot;668&quot;&gt;
 &lt;tbody&gt;&lt;tr style=&quot;&quot;&gt;
  &lt;td style=&quot;width:231.45pt;border:solid windowtext 1.0pt;padding:0in 5.4pt 0in 5.4pt;&quot; valign=&quot;top&quot; width=&quot;309&quot;&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;# ip addr list dev wlan0&lt;/p&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;3: wlan0:…&lt;/p&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;&quot;&gt;    &lt;/span&gt;link/ether
  08:11:96:75:91:54 brd ff:ff:ff:ff:ff:ff&lt;/p&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;&quot;&gt;    &lt;/span&gt;inet
  192.168.1.90/16 brd 192.168.255.255 scope global wlan0&lt;/p&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;&quot;&gt;    &lt;/span&gt;inet
  192.168.1.233/32 scope global wlan0&lt;/p&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;&quot;&gt;    &lt;/span&gt;inet6
  fe80::a11:96ff:fe75:9154/64 scope link &lt;/p&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;&quot;&gt;       &lt;/span&gt;valid_lft
  forever preferred_lft forever&lt;/p&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family:Monospace;
color:black;&quot;&gt;&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;

&lt;p class=&quot;MsoNormal&quot;&gt; &lt;/p&gt;

&lt;h2&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;_Toc327277662&quot;&gt; Rules in nat table for floating IP&lt;/a&gt;&lt;/h2&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;After instance gets a floating
IP, on nova-network host, there are rules:&lt;/p&gt;

&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoNormalTable&quot; height=&quot;126&quot; style=&quot;border-collapse:collapse;border:medium none;&quot; width=&quot;670&quot;&gt;
 &lt;tbody&gt;&lt;tr style=&quot;&quot;&gt;
  &lt;td style=&quot;width:231.45pt;border:solid windowtext 1.0pt;padding:0in 5.4pt 0in 5.4pt;&quot; valign=&quot;top&quot; width=&quot;309&quot;&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;-A nova-network-OUTPUT -d 192.168.1.233/32 -j DNAT
  --to-destination 10.10.10.2&lt;/p&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;-A nova-network-PREROUTING -d 192.168.1.233/32 -j DNAT
  --to-destination 10.10.10.2 &lt;/p&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;-A nova-network-float-snat -s 10.10.10.2/32 -j SNAT
  --to-source 192.168.1.233&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;We can see that DNAT rule is
used to translate the floating IP into the instance's fixed IP. So if a packet
is arriving nova-network host with the floating IP as target IP, the target IP
will be translated. And then we have a SNAT rule, which will translate our
traffic from the instance's fixed IP into the floating IP. Since all the
traffic from VMs to outside of the fixed network will be pointed to gateway
which is set by nova-network's dnsmasq process, with this SNAT rule, the
traffic out from VMs can be masked as from the floating IP successfully. In
addition, we have a DNAT rule in wrapped OUTPUT chain, which will allow local
process on nova-network to access VMs with floating IP.&lt;/p&gt;

&lt;p class=&quot;MsoNormal&quot;&gt; &lt;/p&gt;

&lt;h2&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;_Toc327277663&quot;&gt;Ping VMs with floating IP&lt;br /&gt;&lt;/a&gt;&lt;/h2&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;To allow pinging VMs with
floating IP, we need some more rules. Remember that on nova-compute host, we
have a specific chain for each instance, and the rules in it just allow the
traffic from IPs in the fixed subnet. If we ping floating IP, the traffic will
be dropped by those rules since the source IP of the ping packet is not within
the fixed subnet. Obviously, we need add a rule to allow icmp traffic.&lt;/p&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;To add rule allowing ping, we
use OpenStack's security group rule concept:&lt;/p&gt;

&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoNormalTable&quot; height=&quot;54&quot; style=&quot;border-collapse:collapse;border:medium none;&quot; width=&quot;677&quot;&gt;
 &lt;tbody&gt;&lt;tr style=&quot;&quot;&gt;
  &lt;td style=&quot;width:231.45pt;border:solid windowtext 1.0pt;padding:0in 5.4pt 0in 5.4pt;&quot; valign=&quot;top&quot; width=&quot;309&quot;&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;# nova secgroup-add-rule default icmp -1 -1 0.0.0.0/0&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;After that, we can see we have
one more rule created under that instance's specific chain:&lt;/p&gt;

&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoNormalTable&quot; height=&quot;54&quot; style=&quot;border-collapse:collapse;border:medium none;&quot; width=&quot;674&quot;&gt;
 &lt;tbody&gt;&lt;tr style=&quot;&quot;&gt;
  &lt;td style=&quot;width:231.45pt;border:solid windowtext 1.0pt;padding:0in 5.4pt 0in 5.4pt;&quot; valign=&quot;top&quot; width=&quot;309&quot;&gt;
  &lt;p class=&quot;MsoNormal&quot;&gt;-A nova-compute-inst-1 -p icmp -j ACCEPT&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;

&lt;p class=&quot;MsoNormal&quot; style=&quot;text-indent:12.25pt;&quot;&gt;We can use the same way to
enable ssh to the VMs with floating IP.&lt;/p&gt;&lt;div&gt;&lt;h2&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;_Toc327277663&quot;&gt;Table in database&lt;br /&gt;&lt;/h2&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/floating_ips.png&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/floating_ips.png&quot; style=&quot;display:block;margin:1em 1em 0pt 0pt;float:left;&quot;/&gt;&lt;/a&gt;   &lt;/div&gt;&lt;/a&gt;&lt;/span&gt;</description>
         <author>YongShengGong</author>
         <guid isPermaLink="false">urn:lsid:ibm.com:blogs:entry-e05f71fd-497b-42c8-b9fc-b8c5f19e22c5</guid>
         <pubDate>Sat, 07 Jul 2012 00:28:08 +0000</pubDate>
      </item>
      <item>
         <title>OpenStack VNC console</title>
         <link>https://www.ibm.com/developerworks/community/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/entry/openstack_vnc_console18?lang=en</link>
         <description>&lt;div&gt; &lt;/div&gt;&lt;div&gt;In computing, Virtual Network Computing (VNC) is a graphical desktop sharing system that uses the RFB protocol to remotely control another computer. It transmits the keyboard and mouse events from one computer to another, relaying the graphical screen updates back in the other direction, over a network. In IaaS system like OpenStack, VNC is a very convenient tool for end user to access the VMs by GUI. &lt;/div&gt;&lt;div&gt; &lt;/div&gt;&lt;div&gt; Nova provides two kinds of VNC proxies: noVNC and nova-xvpvncproxy.&lt;br /&gt;&lt;h1&gt;Components&lt;/h1&gt;&lt;/div&gt;&lt;div&gt; To enable VNC console to access VMs started by OpenStack, we need many components to collaborate:
		&lt;ul&gt;&lt;li&gt;
				Components on controller node
				&lt;ul&gt;&lt;li&gt;
						nova-api, which is API server of OpenStack&lt;/li&gt;&lt;li&gt;
						nova-consoleauth, which is used to authorize VNC client&lt;/li&gt;&lt;li&gt;
						noVNC, which is a VNC proxy for browser. An alternative proxy is 
nova-xvpvncproxy, which can be accessed by a Java client at 
https://github.com/cloudbuilders/nova-xvpvncviewer.&lt;/li&gt;&lt;/ul&gt;
			&lt;/li&gt;&lt;li&gt;
				Components on compute node
				&lt;ul&gt;&lt;li&gt;
						nova-compute, which is a nova binary to instantiate VMs&lt;/li&gt;&lt;li&gt;
						libvirt driver, which is used by nova-compute to interact with libvirt server&lt;/li&gt;&lt;li&gt;
						VNC server, which is part of hypervisor?&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;/ul&gt;&lt;h1&gt;Steps for user to access VNC console&lt;/h1&gt;&lt;div&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/vncconsole.png&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/vncconsole.png&quot; style=&quot;display:block;margin:0 auto;text-align:center;&quot;/&gt;&lt;/a&gt;  &lt;br /&gt;&lt;/div&gt;&lt;div&gt; The picture above shows the process how the noVNC starts to work:&lt;/div&gt;&lt;div&gt; 1. user requests the noVNC console URL by command：
		&lt;table border=&quot;0&quot; cellpadding=&quot;1&quot; cellspacing=&quot;1&quot; style=&quot;width:100%;&quot;&gt;
			&lt;tbody&gt;
				&lt;tr&gt;
					&lt;td style=&quot;background-color:grey;&quot;&gt;
						[root@robinlinux utils]# nova  get-vnc-console myserver20 novnc&lt;br /&gt;
						 &lt;/td&gt;
				&lt;/tr&gt;
			&lt;/tbody&gt;
		&lt;/table&gt;
	
	&lt;p&gt;
		nova-api accepts this request, and then sends out &amp;quot;get_vnc_console&amp;quot; message to VM's related compute host&lt;/p&gt;
	&lt;p&gt;
		2. nova-compute running on that compute host accepts that message, 
generates a token and calls libvirt driver's get_vnc_console methods.&lt;/p&gt;
	&lt;p&gt;
		3. Libvirt driver will connect with libvirt server to get VM's vnc 
port, and look up the vnc host from FLAGS.vncserver_proxyclient_address.&lt;/p&gt;
	&lt;p&gt;
		4. nova-api will send out &amp;quot;authorize_console&amp;quot; message to 
nova-consoleauth, which then caches the connection information returned 
by compute-node with token as key&lt;/p&gt;
	&lt;p&gt;
		5. user browsers the URL returned the previous command, like below:&lt;/p&gt;
	&lt;table border=&quot;0&quot; cellpadding=&quot;1&quot; cellspacing=&quot;1&quot; style=&quot;width:100%;&quot;&gt;
		&lt;tbody&gt;
			&lt;tr&gt;
				&lt;td style=&quot;background-color:grey;&quot;&gt;
					[root@robinlinux utils]# nova  get-vnc-console myserver20 novnc&lt;br /&gt;
					+-------+----------------------------------------------------------------------------------+&lt;br /&gt;
					|  Type |                                       Url                                        |&lt;br /&gt;
					+-------+----------------------------------------------------------------------------------+&lt;br /&gt;
					| novnc | http://controlnode:6080/vnc_auto.html?token=34ce7a44-6186-43d8-be14-2ea9e028b8fa |&lt;br /&gt;
					+-------+----------------------------------------------------------------------------------+&lt;br /&gt;
					 &lt;/td&gt;
			&lt;/tr&gt;
		&lt;/tbody&gt;
	&lt;/table&gt;
	&lt;p&gt;
		6. noVNC, which is listening on 6080 HTTP port, accepts the URL request, sends out &amp;quot;check_token&amp;quot; message to nova-consoleauth&lt;/p&gt;
	&lt;p&gt;
		7. nova-consoleauth checks the cached connections and returns one according to the requested token key&lt;/p&gt;
	&lt;p&gt;
		8. noVNC begins the proxy work, connecting the VNC server&lt;/p&gt;&lt;div&gt;&lt;h1&gt;
		About configuration items in nova.conf&lt;/h1&gt;
	&lt;table border=&quot;0&quot; cellpadding=&quot;1&quot; cellspacing=&quot;1&quot; style=&quot;width:100%;&quot;&gt;
		&lt;tbody&gt;
			&lt;tr&gt;
				&lt;td style=&quot;background-color:grey;&quot;&gt;
					#read by nova-compute to compose vnc-console URL&lt;br /&gt;
					# for novnc&lt;br /&gt;
					novncproxy_base_url=http://controlnode:6080/vnc_auto.html&lt;br /&gt;
					# for xvpvnc&lt;br /&gt;
					xvpvncproxy_base_url=http://controlnode:6081/console&lt;br /&gt;
					#read by nova-compute to instantiate VMs&lt;br /&gt;
					vncserver_listen=0.0.0.0&lt;br /&gt;
					&lt;br /&gt;
					#read by libvirt driver to compute vnc-console URL&lt;br /&gt;
					vncserver_proxyclient_address=compute_node&lt;br /&gt;
					 &lt;/td&gt;
			&lt;/tr&gt;
		&lt;/tbody&gt;
	&lt;/table&gt;

&lt;p&gt; 
	&lt;br /&gt;&lt;/p&gt; &lt;/div&gt;&lt;/div&gt;&lt;/div&gt;</description>
         <author>YongShengGong</author>
         <guid isPermaLink="false">urn:lsid:ibm.com:blogs:entry-4347080d-6703-4fae-99a7-76b2d7060b24</guid>
         <pubDate>Wed, 30 May 2012 12:55:13 +0000</pubDate>
      </item>
      <item>
         <title>OpenStack nova-scheduler and its algorithm</title>
         <link>https://www.ibm.com/developerworks/community/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/entry/openstack_nova_scheduler_and_its_algorithm27?lang=en</link>
         <description>&lt;h1 class=&quot;western&quot;&gt;Abstract&lt;/h1&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Among
the current core projects of OpenStack, Nova project is the core of
the cores. Just as described in OpenStack website, Nova is a cloud
computing fabric controller, the main part of an IaaS system. There
are more than 20 binaries in OpenStack nova project. Among them,
nova-scheduler is responsible to decide which compute node host
should launch an image instance (server in terms of OpenStack) among
other responsibilities. This article describes the way this component
does its job together with other components and how it makes
decisions faced with more than one compute node host and one
instantiation request.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt;&lt;h1 class=&quot;western&quot;&gt;Overview&lt;/h1&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Just
as said on the OpenStack website, OpenStack's mission is to produce
the ubiquitous Open Source Cloud Computing platform that will meet
the needs of public and private clouds regardless of size, by being
simple to implement and massively scalable. In such cloud
environments, there is often more than one compute node to
instantiate image instances on.  How to manage and measure these
compute nodes is a very prominent problem. Based on some data, how to
react to one user's request is a hot spot as well.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Let
first look at where the nova-scheduler works in big picture.&lt;br /&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/novaarch.png&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/novaarch.png&quot; style=&quot;display:block;margin:0pt auto;text-align:center;&quot;/&gt;&lt;/a&gt; &lt;br /&gt; &lt;/div&gt; &lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;Note: This figure is
from
&lt;font color=&quot;#000080&quot;&gt;&lt;u&gt;&lt;a rel=&quot;nofollow&quot; class=&quot;western&quot; target=&quot;_blank&quot; href=&quot;http://ken.pepple.info/openstack/2012/02/21/revisit-openstack-architecture-diablo/&quot;&gt;http://ken.pepple.info/openstack/2012/02/21/revisit-openstack-architecture-diablo/&lt;/a&gt;&lt;/u&gt;&lt;/font&gt;.&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Just
as shown by above figure, nova-scheduler interacts with other
components through queue and central database repo. For scheduling,
queue is the essential communications hub.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;All
compute nodes (also known as hosts in terms of OpenStack)
periodically publish their status, resources available and hardware
capabilities to nova-scheduler through the queue.  nova-scheduler
then collects this data and uses it to make decisions when a request
comes in.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/novafilter.png&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/novafilter.png&quot; style=&quot;display:block;margin:0pt auto;text-align:center;&quot;/&gt;&lt;/a&gt;  &lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;Note: this picture
comes from nova project.&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Above
picture shows us the general idea of how the scheduler does its main
job. The whole process divides into two phases. Filtering phase will
generate a list of suitable hosts by applying filters. Weighting
phase will sort the hosts according to their weighted cost scores,
which are given by applying some cost functions. The sorted list of
hosts is candidates to fulfill the user's request. How many hosts in
this list will be used depends on the number of instances requested
in one request.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Following
this overview, the rest contents of this article will describe:&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;1.What
	an instantiation request looks like and how it goes to
	nova-scheduler;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;2.What
	are the main components in nova-scheduler;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;3.How
	the nova-scheduler components collaborate to finish the scheduling
	work.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;/div&gt;
&lt;h1 class=&quot;western&quot;&gt;Scheduler
Invocation&lt;/h1&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;To
depict the work of nova-scheduler, we have to talk a little about
nova-api first. Just as with other nova binaries, nova-api is a WSGI
server. Python Routes is adopted to map RESTful URL into internal
Controller's method.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/novacontroller.png&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/novacontroller.png&quot; style=&quot;display:block;margin:0pt auto;text-align:center;&quot;/&gt;&lt;/a&gt;  &lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;We
can know from above figure that the main methods involved for
nova-api to response to the image instantiation request. First the
HTTP request is mapped to Controller's create() method. This method
processes the request body and then invokes compute_api's create()
method, and then method _create_instance() is called.  At last the
_schedule_run_instance() method will call rpc_method() to send out
message onto message queue for nova-scheduler.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;The
rpc_method is called as follows:&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;table border=&quot;1&quot; cellpadding=&quot;4&quot; cellspacing=&quot;0&quot; width=&quot;665&quot;&gt;
	&lt;col width=&quot;655&quot;/&gt;
	&lt;tbody&gt;&lt;tr&gt;
		&lt;td valign=&quot;TOP&quot; width=&quot;655&quot;&gt;
			&lt;p class=&quot;western&quot;&gt;rpc_method(context,&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;FLAGS.scheduler_topic,&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;{&amp;quot;method&amp;quot;:
			&amp;quot;run_instance&amp;quot;,&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&amp;quot;args&amp;quot;:
			{&amp;quot;topic&amp;quot;: FLAGS.compute_topic,&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&amp;quot;request_spec&amp;quot;:
			request_spec,&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&amp;quot;admin_password&amp;quot;:
			admin_password,&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&amp;quot;injected_files&amp;quot;:
			injected_files,&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&amp;quot;requested_networks&amp;quot;:
			requested_networks,&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&amp;quot;is_first_time&amp;quot;:
			True,&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;&amp;quot;filter_properties&amp;quot;:
			filter_properties}})&lt;/p&gt;
		&lt;/td&gt;
	&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Of
the RPC message, Field injected_files represents files that will be
injected into VM disk image, while requested_networks is for network
information, such as which network(s) will be used by the
instance(s).&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Another
two parts of this message, request_spec and filter_properties, need
further explanation. &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;We
will use f&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;ollowing
command to generate sample values in following sections:&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;table border=&quot;1&quot; cellpadding=&quot;7&quot; cellspacing=&quot;0&quot; width=&quot;680&quot;&gt;
	&lt;col width=&quot;664&quot;/&gt;
	&lt;tbody&gt;&lt;tr&gt;
		&lt;td valign=&quot;TOP&quot; width=&quot;664&quot;&gt;
			&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;b&gt;nova
			boot --image a3fb743d-42df-49ba-b9c4-8042ebbd344e --flavor 1
			myserver --hint test=testvalue –availability_zone=myzone::testhost&lt;/b&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
		&lt;/td&gt;
	&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;

&lt;h2 class=&quot;western&quot;&gt;filter_properties&lt;/h2&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;The
filter_properties part of RPC message is to help nova-scheduler.
Normally, it will contain scheduler_hints information from user
request. We have sample content like this from previous nova boot
command&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;:&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;table border=&quot;1&quot; cellpadding=&quot;4&quot; cellspacing=&quot;0&quot; width=&quot;665&quot;&gt;
	&lt;col width=&quot;655&quot;/&gt;
	&lt;tbody&gt;&lt;tr&gt;
		&lt;td valign=&quot;TOP&quot; width=&quot;655&quot;&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;filter_properties:{&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'scheduler_hints':
			{&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'force_hosts':
			[u'testhost']&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u'test':
			u'testvalue'&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;}&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;}&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
		&lt;/td&gt;
	&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;If
our availability_zone complies with the pattern zone:xx:host,
force_hosts field will be in scheduler_hints. The value of
force_hosts can target the request to a given host directly before
going through scheduler's filters.  Also there can be ignore_hosts in
scheduler_hints, which means the specified hosts will be skipped
during scheduling. Both force_hosts and ignore_hosts are applied
before going through filters. Please see following section &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;Inside
of FilterScheduler.&lt;/p&gt;

&lt;h2 class=&quot;western&quot;&gt;request_spec&lt;/h2&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;The
requst_spec part of RPC message is encapsulation or normalization of
HTTP request.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Below
table is the sample content of request_spec in the RPC message by
previous nova boot command. &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;
&lt;/p&gt;

&lt;table border=&quot;1&quot; cellpadding=&quot;4&quot; cellspacing=&quot;0&quot; width=&quot;665&quot;&gt;
	&lt;col width=&quot;655&quot;/&gt;
	&lt;tbody&gt;&lt;tr&gt;
		&lt;td valign=&quot;TOP&quot; width=&quot;655&quot;&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;{&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'num_instances':
			1,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'block_device_mapping':
			[],&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'image':
			{&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'status':
			'active',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'name':
			'cirros_blank',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'deleted':
			False,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'container_format':
			'ami',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'created_at':
			'2012-04-05 14:26:24',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'disk_format':
			'ami',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'updated_at':
			'2012-04-05 14:26:25',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'properties':
			{&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;            &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'kernel_id':
			'46bf134e-2e6e-472a-a159-f4cd51f36d84',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;            &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span lang=&quot;nl-NL&quot;&gt;'ramdisk_id':
			'106dc550-783e-4de7-951d-f4f3d5427698'&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;},&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'min_ram':
			'0',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'checksum':
			'2f81976cae15c16ef0010c51e3a6c163',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'min_disk':
			'0',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'is_public':
			True,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'deleted_at':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'id':
			'a3fb743d-42df-49ba-b9c4-8042ebbd344e',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'size':
			25165824&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;},&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'instance_type':
			{&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;'root_gb':
			0L,&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'name':
			u 'm1.tiny',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'deleted':
			False,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'created_at':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;'ephemeral_gb':
			0L,&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'updated_at':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;'memory_mb':
			512L,&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;'vcpus':
			1L,&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span lang=&quot;nl-NL&quot;&gt;'flavorid':
			u '1',&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; lang=&quot;nl-NL&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'swap':
			0L,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'rxtx_factor':
			1.0,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'extra_specs':
			{},&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'deleted_at':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'vcpu_weight':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'id':
			2L&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;},&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'instance_properties':
			{ # used to comsume virtual resources&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'vm_state':
			'building',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;'ephemeral_gb':
			0L,&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'access_ip_v6':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'access_ip_v4':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'kernel_id':
			'46bf134e-2e6e-472a-a159-f4cd51f36d84',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'key_name':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'ramdisk_id':
			'106dc550-783e-4de7-951d-f4f3d5427698',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'instance_type_id':
			2L,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'user_data':
			'',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'vm_mode':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'display_name':
			u 'myserver',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'config_drive_id':
			'',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'reservation_id':
			'r-bdbnl7aa',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'key_data':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;'root_gb':
			0L,&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'user_id':
			u '81ced34d11954800906096555539c885',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'uuid':
			u '4ccc7c93-cbde-4233-a7cb-5db81f82489b',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'root_device_name':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;'availability_zone':
			u 'myzone', # default to &lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#000000&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;FLAGS.default_schedule_zone&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'launch_time':
			'2012-04-11T15:08:55Z',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'metadata':
			{},&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'display_description':
			u 'myserver',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;'memory_mb':
			512L,&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'launch_index':
			0,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;span style=&quot;background:none repeat scroll 0% 0% rgb(255, 0, 0);&quot;&gt;'vcpus':
			1L,&lt;/span&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'locked':
			False,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'image_ref':
			u 'a3fb743d-42df-49ba-b9c4-8042ebbd344e',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'architecture':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'power_state':
			0,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'auto_disk_config':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'progress':
			0,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'os_type':
			None,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'project_id':
			u '9d049e4b60b64716978ab415e6fbd5c0',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'config_drive':
			''&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;},&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'security_group':
			['default']&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;}&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			
		&lt;/td&gt;
	&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;p class=&quot;western&quot;&gt;&lt;br /&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Some
values in instance_properties are copied from instance_type. Both
copies of these values play a role in scheduler&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;s
work. Red colored parts are important to nova scheduler. Most of them
can be used in filters and cost functions.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt;&lt;h1 class=&quot;western&quot;&gt;Nova-scheduler
class diagram&lt;/h1&gt;&lt;div&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/novaschedulerclassdia.png&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/novaschedulerclassdia.png&quot; style=&quot;display:block;margin:0pt auto;text-align:center;&quot;/&gt;&lt;/a&gt;  &lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Before
diving into how the nova-scheduler deals with the instantiation
request message, we had better have a look at the data structure it
used.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Just
as shown by above figure, many classes or modules work together in
nova-scheduler:&lt;/font&gt;&lt;/font&gt;&lt;br /&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font size=&quot;4&quot;&gt;1.SchedulerManager sits between
	the queue and the other nova-scheduler components. It receives
	requests from queue and delegates jobs to its driver. The driver is
	defined by configuration option FLAGS.scheduler_driver with
	&lt;/font&gt;&amp;quot;&lt;font size=&quot;4&quot;&gt;nova.scheduler.multi.MultiScheduler&lt;/font&gt;&amp;quot;&lt;font size=&quot;4&quot;&gt;
	as default value.&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font size=&quot;4&quot;&gt;2.Scheduler, parent class for all
	other schedulers, has compute_api and host_manager attributes. The
	value of compute_api is nova.compute.api.API. The value of
	host_manager is defined by FLAGS.scheduler_host_manager with
	&lt;/font&gt;&amp;quot;&lt;font size=&quot;4&quot;&gt;nova.scheduler.host_manager.HostManager&lt;/font&gt;&amp;quot;&lt;font size=&quot;4&quot;&gt;
	as default value.&lt;/font&gt;&lt;/p&gt;&lt;font size=&quot;4&quot;&gt;3.MultiScheduler is a subclass of
	Scheduler designed to delegate to configurable drivers per resource
	type (compute and volume today). Value of compute_driver is defined
	by configur&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;ation&lt;/font&gt;&lt;font size=&quot;4&quot;&gt; option
	FLAGS.compute_scheduler_driver with default value
	&amp;quot;nova.scheduler.filter_scheduler.FilterScheduler&amp;quot;. Value
	of volume_driver is not within the article's scope.&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;br /&gt;4.FilterScheduler is responsible
	for selecting hosts and provisioning resources. It chooses the host
	by applying filters and calculate&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;s&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;
	weighted cost. Host which passes filters and &lt;/font&gt;&lt;font size=&quot;4&quot;&gt;has&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;
	least cost wins.&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;br /&gt;5.ChanceScheduler chooses the host
	randomly from running hosts&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;br /&gt;6.SimpleScheduler chooses the host
	based on the running cores. Host with least running cores wins out.&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;br /&gt;7.API is compute API, used to call
	API service of OpenStack compute.&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;br /&gt;8.HostManager is for collect&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;ing
	and saving&lt;/font&gt;&lt;font size=&quot;4&quot;&gt; host data&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;.&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;br /&gt;9.Module least_cost contains the
	&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;cost&lt;/font&gt;&lt;font size=&quot;4&quot;&gt; function and
	WeightedHost class.&lt;/font&gt;&lt;br /&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;10.WeightedHost is a value object,
	with weight and hoststate as two fields&lt;/font&gt;.&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;br /&gt;11.HostState records host's
	capabilit&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;ies and virtual consumptions of
	resources during one request processing&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;.&lt;/font&gt;
&lt;br /&gt;&lt;h1 class=&quot;western&quot;&gt;Inside
of nova-scheduler&lt;/h1&gt;&lt;div&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/schedulercallchain.png&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/schedulercallchain.png&quot; style=&quot;display:block;margin:0pt auto;text-align:center;&quot;/&gt;&lt;/a&gt; &lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;When
the request is sent out in the form of RPC message, it will be
received by nova-scheduler, which will call SchedulerManager&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;s
run_instance() method. Following the calling chain, the control will
arrive at FilterScheduler&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;s
scheduler_run_instance() method in the end.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;
&lt;h2 class=&quot;western&quot;&gt;Inside of FilterScheduler&lt;/h2&gt;
&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;By
default, compute related scheduling will come to this class. Its
&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;schedule_run_instance&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;()
method will take the control to fulfill user request.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt; &lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/filterscheduler.png&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/filterscheduler.png&quot; style=&quot;display:block;margin:0pt auto;text-align:center;&quot;/&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt; &lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Above&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;
diagram shows us the main tasks done by schedule_run_instance method&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;:&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;1. _schedule()&lt;/font&gt;&lt;/font&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;This
method selects some hosts to instantiate the image. By design, the
instantiation request can be to create more than one instance. So it
will return a sorted list of WeightedHosts by the weight. Least
weight comes first.&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;
Also this function will populate filter_properties with more data,
such as request_spec, config_options and instance_type, etc before
calling filters and cost functions.&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;1.1 get_cost_function()&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;br /&gt;
&lt;dl&gt;&lt;dl&gt;&lt;dd&gt;
		&lt;table border=&quot;1&quot; cellpadding=&quot;4&quot; cellspacing=&quot;0&quot; width=&quot;591&quot;&gt;
			&lt;col width=&quot;581&quot;/&gt;
			&lt;tbody&gt;&lt;tr&gt;
				&lt;td valign=&quot;TOP&quot; width=&quot;581&quot;&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;######
					(FloatOpt) How much weight to give the fill-first cost function.
					A negative value will reverse behavior: e.g. spread-first&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;compute_fill_first_cost_fn_weight=-1.0&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;######
					(ListOpt) Which cost functions the LeastCostScheduler should use&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;least_cost_functions=&amp;quot;nova.scheduler.least_cost.compute_fill_first_cost_fn&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
					&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;######
					(FloatOpt) How much weight to give the noop cost function&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
				&lt;/td&gt;
			&lt;/tr&gt;
		&lt;/tbody&gt;&lt;/table&gt;
	&lt;/dd&gt;&lt;/dl&gt;&lt;/dl&gt;
&lt;div&gt; &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;FilterScheduler's
cost functions are organized in a list of tuples of weight and cost
function. Functions are defined by FLAGS. least_cost_functions, and
corresponding weights are defined in separated options. For example,
in above configuration fragment, compute_fill_first_cost_fn_weight
defines weight for default function
nova.scheduler.least_cost.compute_fill_first_cost_fn. As of writing,
this function just return free RAM of a HostState:&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
&lt;dl&gt;&lt;dl&gt;&lt;dd&gt;
		&lt;table border=&quot;1&quot; cellpadding=&quot;4&quot; cellspacing=&quot;0&quot; width=&quot;585&quot;&gt;
			&lt;col width=&quot;575&quot;/&gt;
			&lt;tbody&gt;&lt;tr&gt;
				&lt;td valign=&quot;TOP&quot; width=&quot;575&quot;&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font color=&quot;#0000ff&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;def&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;
					&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#000000&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;b&gt;compute_fill_first_cost_fn&lt;/b&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#000000&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;(host_state,&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;
					&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#000000&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;weighing_properties):&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;
					   &lt;/font&gt;&lt;font color=&quot;#00aa00&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;&amp;quot;&amp;quot;&amp;quot;More
					free ram = higher weight. So servers will less free&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font color=&quot;#00aa00&quot;&gt;
					   &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;ram will be
					preferred.&amp;quot;&amp;quot;&amp;quot;&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
					&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;    &lt;/font&gt;&lt;font color=&quot;#0000ff&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;return&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;
					&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#000000&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;host_state.free_ram_mb&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
				&lt;/td&gt;
			&lt;/tr&gt;
		&lt;/tbody&gt;&lt;/table&gt;
	&lt;/dd&gt;&lt;/dl&gt;&lt;/dl&gt;
&lt;p class=&quot;western&quot;&gt;&lt;br /&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;1.2 get_all_host_states()&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;It
returns a dict of all the hosts the HostManager knows about. Also,
each of the consumable resources in HostState is pre-populated and
adjusted based on capabilities data of HostManager. A sample of the
returned dict looks like {&lt;/font&gt;&lt;/font&gt;&amp;quot;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;host1&lt;/font&gt;&lt;/font&gt;&amp;quot;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;:hoststate
for host1, &lt;/font&gt;&lt;/font&gt;&amp;quot;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;host2&lt;/font&gt;&lt;/font&gt;&amp;quot;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;:hoststate
for host2,...}. Please see later sections for hoststate.&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt; &lt;/div&gt;&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;1.3 filter_host()&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;div&gt; &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;This
function takes a list of HostStates and filter_properties as
parameters and returns those which can pass the filters.&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;Filters
allowed are defined by FLAGS.scheduler_available_filters with
&amp;quot;nova.scheduler.filters.standard_filters&amp;quot; as default value.
In fact, it will traverse the filter path and return a list of filter
classes. As of now, the list is such as:&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;

&lt;dl&gt;&lt;dl&gt;&lt;dd&gt;
		&lt;table border=&quot;1&quot; cellpadding=&quot;4&quot; cellspacing=&quot;0&quot; width=&quot;583&quot;&gt;
			&lt;col width=&quot;573&quot;/&gt;
			&lt;tbody&gt;&lt;tr&gt;
				&lt;td valign=&quot;TOP&quot; width=&quot;573&quot;&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.isolated_hosts_filter.IsolatedHostsFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.compute_filter.ComputeFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.availability_zone_filter.AvailabilityZoneFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.ram_filter.RamFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.json_filter.JsonFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.all_hosts_filter.AllHostsFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.core_filter.CoreFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.affinity_filter.AffinityFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.affinity_filter.DifferentHostFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.affinity_filter.SameHostFilter'
					&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;
					&lt;/p&gt;
					&lt;p class=&quot;western&quot; style=&quot;margin-right:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;&lt;i&gt;'nova.scheduler.filters.affinity_filter.SimpleCIDRAffinityFilter&lt;/i&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
				&lt;/td&gt;
			&lt;/tr&gt;
		&lt;/tbody&gt;&lt;/table&gt;
	&lt;/dd&gt;&lt;/dl&gt;&lt;/dl&gt;
&lt;div&gt; &lt;/div&gt;&lt;div&gt; &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;For
how each filter filters host, please see &lt;/font&gt;&lt;/font&gt;&lt;a rel=&quot;nofollow&quot; class=&quot;western&quot; target=&quot;_blank&quot; href=&quot;https://github.com/openstack/nova/blob/master/doc/source/devref/filter_scheduler.rst&quot;&gt;&lt;font color=&quot;#000080&quot;&gt;&lt;u&gt;&lt;font size=&quot;4&quot;&gt;Filter&lt;/font&gt;&lt;/u&gt;&lt;/font&gt;&lt;font color=&quot;#000080&quot;&gt;&lt;u&gt;&lt;font size=&quot;4&quot;&gt;Scheduler
development reference&lt;/font&gt;&lt;/u&gt;&lt;/font&gt;&lt;/a&gt;&lt;font size=&quot;4&quot;&gt;.&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;&lt;br /&gt;Filters
used are defined by FLAGS.scheduler_default_filters with
&amp;quot;AvailabilityZoneFilter,RamFilter,ComputeFilter&amp;quot; as default
value.&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Each
Filter has defined a host_passes() function which receives HostState
and filter_properties as parameters and returns bool to indicate if
the host specified in HostState is a good candidate for this filter.&lt;/font&gt;&lt;/font&gt;&lt;font size=&quot;4&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;br /&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;1.4 &lt;/font&gt;&lt;/font&gt; &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Passes_filters()&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;With
each HostState object, filter_host() method will call its
passes_filters() to check if the host can pass all filters defined.
Before going through filters, this method checks if the host complies
with rules defined by&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;
&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;force_hosts
and ignore_hosts&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;
&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;fields
of scheduler_hints. If field ignore_hosts&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;
&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;exists
and the host represented by the HostState is in the list, the host
fails. If field&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;
&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;force_hosts&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;
&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;font size=&quot;4&quot;&gt;exists,
whether the host represented by the HostState object passes depends
on if it is in force_hosts. After these rules, if not filtered out,
the host will go through the filters until one of the filters fails.
If all filters pass, the host will be ok to next phase-cost
weighting.&lt;/font&gt;&lt;br /&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;1.5 Weighted_sum()&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt; &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;With
cost_functions returned by get_cost_function(), HostStates returned
by filter_host(), and filter_properties as parameters, this function
will first score each host by running each cost function to generate
a grid kind of like the table below:&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
&lt;dl&gt;&lt;dl&gt;&lt;dd&gt;
		&lt;table border=&quot;1&quot; cellpadding=&quot;4&quot; cellspacing=&quot;0&quot; width=&quot;584&quot;&gt;
			&lt;col width=&quot;76&quot;/&gt;
			&lt;col width=&quot;159&quot;/&gt;
			&lt;col width=&quot;158&quot;/&gt;
			&lt;col width=&quot;158&quot;/&gt;
			&lt;tbody&gt;&lt;tr valign=&quot;TOP&quot;&gt;
				&lt;td width=&quot;76&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;&lt;br /&gt;
					&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;159&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;fn#1&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;158&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;fn#2&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;158&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;fn#n&lt;/p&gt;
				&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr valign=&quot;TOP&quot;&gt;
				&lt;td width=&quot;76&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Host1&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;159&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Score#1_1&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;158&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Score#1_2&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;158&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Score#1_n&lt;/p&gt;
				&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr valign=&quot;TOP&quot;&gt;
				&lt;td width=&quot;76&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Host2&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;159&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Score#2_1&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;158&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Score#2_2&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;158&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Score#2_n&lt;/p&gt;
				&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr valign=&quot;TOP&quot;&gt;
				&lt;td width=&quot;76&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Hostn&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;159&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Score#n_1&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;158&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Score#n_2&lt;/p&gt;
				&lt;/td&gt;
				&lt;td width=&quot;158&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;Score#n_&lt;/p&gt;
				&lt;/td&gt;
			&lt;/tr&gt;
		&lt;/tbody&gt;&lt;/table&gt;
	&lt;/dd&gt;&lt;/dl&gt;&lt;/dl&gt;

&lt;div&gt; &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;And
then it will calculate the weighted scores for each host by
multiplying score and weight of each cost function to generate a list
of weighted final scores. The formula used is:&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
&lt;dl&gt;&lt;dl&gt;&lt;dd&gt;
		&lt;table border=&quot;1&quot; cellpadding=&quot;7&quot; cellspacing=&quot;0&quot; width=&quot;604&quot;&gt;
			&lt;col width=&quot;588&quot;/&gt;
			&lt;tbody&gt;&lt;tr&gt;
				&lt;td valign=&quot;TOP&quot; width=&quot;588&quot;&gt;
					&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Final
					score of a certain host = ∑(weight of cost function * score
					returned by this function for the host)&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
				&lt;/td&gt;
			&lt;/tr&gt;
		&lt;/tbody&gt;&lt;/table&gt;
	&lt;/dd&gt;&lt;/dl&gt;&lt;/dl&gt;

&lt;div&gt; &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;And
then it will associate the scores with HostStates to generate a list
of tuples of score and HostState.&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Last
it will sort the tuples and return a WeightedHost using the first
tuple. This way the least cost host will win.&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt; &lt;/div&gt;&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;1.6 getHostState()&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;It
returns the HostState object from selected WeightedHost&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;1.7 consume_from_instance()&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;It
takes instance_properties as parameter, which comes from
request_spec. This function adjusts HostState object&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;s
data to virtually consume the resources so that the HostState object
can enter into the next loop of host choosing for this request&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;s
next instance.&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;2 _provision_resource()&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;This
function creates requested resource, such as an image instance.&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;2.1 cast_to_compute_host()&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt; &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;This
function casts a queue message to target host so that it will create
an image instance according to the request_spec.&lt;/font&gt;&lt;/font&gt;&lt;/div&gt;
&lt;h2 class=&quot;western&quot;&gt;Scheduler’s intelligent data - Host
Capabilities&lt;/h2&gt;&lt;div&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;https://www.ibm.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/schedulercolla.png&quot;&gt;&lt;img alt=&quot;image&quot; src=&quot;https://dw1.s81c.com/developerworks/mydeveloperworks/blogs/e93514d3-c4f0-4aa0-8844-497f370090f5/resource/BLOGS_UPLOADED_IMAGES/schedulercolla.png&quot; style=&quot;display:block;margin:0pt auto;text-align:center;&quot;/&gt;&lt;/a&gt; &lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;Host
capability data is &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;another
important input for the scheduler. Every OpenStack service, such as
nova-compute or nova-network, can publish its capabilities. Above
figure depicts how the compute host updates its capabilities of
compute service and publishes them to nova scheduler, &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;and
&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;how
the nova scheduler saves this data for later use. Roughly, the whole
process splits into three parts:&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;br /&gt;1. To
	collect capabilities&lt;/font&gt;&lt;/font&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;ComputeManager&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;s
_report_driver_status() method is a periodic task, which calls
update_service_capabilityes() to update the capabilities.
LibvirtConnection (There are other connection types. Which one to use
depends on the configuration in nova.conf and is usually hypervisor
dependent) is the one that does actual job. Its method
get_host_stats() is used to collect host capabilities.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;One
sample of capabilities data looks like:&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;table border=&quot;1&quot; cellpadding=&quot;4&quot; cellspacing=&quot;0&quot; width=&quot;665&quot;&gt;
	&lt;col width=&quot;655&quot;/&gt;
	&lt;tbody&gt;&lt;tr&gt;
		&lt;td valign=&quot;TOP&quot; width=&quot;655&quot;&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;{&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'disk_available': 226,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'cpu_info': {&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'vendor': u 'Intel',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'model': u 'Westmere',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'arch': u 'x86_64',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'features': [u 'rdtscp', u 'x2apic', u 'xtpr', u 'tm2', u 'est', u
			'vmx', u 'ds_cpl', u 'monitor', u 'pbe', u 'tm', u 'ht', u 'ss', u
			'acpi', u 'ds', u 'vme'],&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'topology': {&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;            &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'cores': u '2',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;            &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'threads': u '2',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;            &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'sockets': u '1'&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;        &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;}&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;},&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'hypervisor_type': u 'QEMU',&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'vcpus_used': 0,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'vcpus': 4,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;&lt;font color=&quot;#000000&quot;&gt;
			   &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'host_memory_free': 1718,&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'disk_total': 375,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'host_memory_total': 3845,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'hypervisor_version': 15000,&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;    &lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;u
			'disk_used': 149&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
			&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;}&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
		&lt;/td&gt;
	&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;p class=&quot;western&quot;&gt;&lt;br /&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;2. To
	publish capabilities&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;The
method publish_service_capabilities() is another periodic task of
ComputerManager. It will delegate scheduler api to send out the
capabilities onto message queue. The message has topic &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;scheduler&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;,
service name &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;compute&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;&lt;font size=&quot;4&quot;&gt;
and hostname besides the capabilities.&lt;/font&gt;&lt;br /&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class=&quot;western&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;3. To
	Receive Capabilities&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;When
the message is on the queue, nova-scheduler will get it and call the
SchedulerManager. And then it will call Scheduler&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;s
update_service_capablilites() method, which  will invoke the
HostManager&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;2&quot;&gt;'&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;s
update_service_capablilites() method. After that the capabilities
data of that given service for that given host will be saved by
HostManager until next update.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;div&gt;&lt;h1 class=&quot;western&quot;&gt;Summary&lt;/h1&gt;
&lt;p class=&quot;western&quot;&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;To
wrap up, a&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;s
a cloud scales to two hosts, &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;the
&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;scheduler
plays a role. More hosts there are in&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;
a&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;
cloud, more important the scheduler is. Among all the inputs to
nova-scheduler, three are important. They are configuration in
nova.conf, service capabilities of each host and the request spec.
The configuration in nova.conf decides the static and run-time class
structure, service capabilities works as base intelligent data and
request spec is the service target. Nova-scheduler can schedule to
certain hosts and skip some hosts according to request spec. In
addition to the hosts specified in request spec, zone concept can
&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;also
&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color=&quot;#1a1a1a&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;help
scheduler to distribute requests to zone member hosts. After knowing
the inside, default behavior of nova-scheduler can be easily modified
in nova.conf.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;

&lt;h1 class=&quot;western&quot;&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__723_330443341&quot;&gt;Resources&lt;/a&gt;&lt;/h1&gt;&lt;h1 class=&quot;western&quot;&gt;1. &lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;font color=&quot;#000080&quot;&gt;&lt;u&gt;&lt;a rel=&quot;nofollow&quot; class=&quot;western&quot; target=&quot;_blank&quot; href=&quot;http://wiki.openstack.org/&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;OpenStack
	wiki website&lt;/font&gt;&lt;/font&gt;&lt;/a&gt;&lt;/u&gt;&lt;/font&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/h1&gt;&lt;h1 class=&quot;western&quot;&gt;2. &lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;font color=&quot;#000080&quot;&gt;&lt;u&gt;&lt;a rel=&quot;nofollow&quot; class=&quot;western&quot; target=&quot;_blank&quot; href=&quot;https://github.com/openstack/nova&quot;&gt;&lt;font face=&quot;Monospace, MS Mincho&quot;&gt;&lt;font size=&quot;4&quot;&gt;OpenStack
	Nova GitHub website&lt;/font&gt;&lt;/font&gt;&lt;/a&gt;&lt;/u&gt;&lt;/font&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/h1&gt;&lt;h1 class=&quot;western&quot;&gt;3.&lt;span style=&quot;text-decoration:underline;&quot;&gt; &lt;/span&gt;&lt;a rel=&quot;nofollow&quot; target=&quot;_blank&quot; href=&quot;http://ken.pepple.info/openstack/2012/02/21/revisit-openstack-architecture-diablo/&quot;&gt;Revisiting 	OpenStack Architecture: Essex Edition&lt;/a&gt;&lt;/h1&gt;&lt;h1 class=&quot;western&quot;&gt;4.&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;a rel=&quot;nofollow&quot; class=&quot;western&quot; target=&quot;_blank&quot; href=&quot;https://github.com/openstack/nova/blob/master/doc/source/devref/filter_scheduler.rst&quot;&gt;&lt;font color=&quot;#000080&quot;&gt;&lt;u&gt;&lt;font size=&quot;4&quot;&gt; Filter&lt;/font&gt;&lt;/u&gt;&lt;/font&gt;&lt;font color=&quot;#000080&quot;&gt;&lt;u&gt;&lt;font size=&quot;4&quot;&gt;Scheduler
	development reference&lt;/font&gt;&lt;/u&gt;&lt;/font&gt;&lt;/a&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/h1&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt; &lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/u&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h1 class=&quot;western&quot;&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;u&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__717_330443341&quot;&gt;&lt;/u&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__717_330443341&quot;&gt;&lt;/u&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__717_330443341&quot;&gt;&lt;/u&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__717_330443341&quot;&gt;&lt;/u&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__717_330443341&quot;&gt;&lt;/u&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__717_330443341&quot;&gt;&lt;/u&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__717_330443341&quot;&gt;&lt;/u&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__717_330443341&quot;&gt;&lt;/u&gt;&lt;a rel=&quot;nofollow&quot; name=&quot;__RefHeading__717_330443341&quot;&gt;&lt;/u&gt;&lt;/h1&gt;&lt;/div&gt;&lt;p class=&quot;western&quot; style=&quot;margin-bottom:0in;&quot;&gt;
&lt;/p&gt;&lt;/div&gt;&lt;/a&gt;&lt;/a&gt;&lt;/a&gt;&lt;/a&gt;&lt;/a&gt;&lt;/a&gt;&lt;/a&gt;&lt;/a&gt;&lt;/a&gt;</description>
         <author>YongShengGong</author>
         <guid isPermaLink="false">urn:lsid:ibm.com:blogs:entry-c6513273-ef48-4d5e-a30e-58d0728a9789</guid>
         <pubDate>Fri, 27 Apr 2012 23:12:12 +0000</pubDate>
      </item>
   </channel>
</rss>
<!-- fe1.yql.bf1.yahoo.com compressed/chunked Sat May 25 07:56:59 UTC 2013 -->
