Hi Leandra/Team,<br> I set the <span style="font-family: Georgia,'Times New Roman',Times,serif; font-size: 14px; line-height: 23px;"><span style="font-family: verdana,arial,helvetica,sans-serif; font-size: 12px;">set foreign_key_checks = 0 ;  at mysql DB and then executed;</span></span><br>
/etc/init.d/nova-compute start<br><br>However still I am getting the same error on /var/log/nova/nova-compute.log stating;<br><br><i>sqlalchemy.exc.OperationalError: (OperationalError) (1005, "Can't create table 'nova.network_indexes' (errno: 150)") '\nCREATE TABLE network_indexes (\n\tcreated_at DATETIME, \n\tupdated_at DATETIME, \n\tdeleted_at DATETIME, \n\tdeleted BOOL, \n\tid INTEGER NOT NULL AUTO_INCREMENT, \n\t`index` INTEGER, \n\tnetwork_id INTEGER, \n\tPRIMARY KEY (id), \n\tCHECK (deleted IN (0, 1)), \n\tUNIQUE (`index`), \n\tFOREIGN KEY(network_id) REFERENCES networks (id)\n)ENGINE=InnoDB\n\n' ()<br>
<br></i><br>NOVA server is running on Ubuntu 11.04 - 64 bit server<br>NOVA Compute is running on Ubuntu 10.10  - 64 bit desktop<br><br>I got nova for the compute node Ubuntu repository using apt-get and the version displays as <br>
 nova-compute                         0.9.1~bzr331-0ubuntu2<br><br>Nova version at the Server displays as:   2011.2-0ubuntu1 <br><br>Appreciate your help.<br><br><br>Cheers!<br>Rasika K<br><br><br><br><div class="gmail_quote">
On Tue, Aug 30, 2011 at 12:47 PM, Leandro Reox <span dir="ltr"><<a href="mailto:leandro.reox@gmail.com" target="_blank">leandro.reox@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

Are running diablo milestone ? <br><br>There's only 3 ways to get this mysql error : <br><br><span style="font-family: Georgia,'Times New Roman',Times,serif; font-size: 14px; line-height: 23px;"><ul style="padding: 0px; margin: 0px 0px 15px 40px; color: rgb(0, 0, 0); list-style-type: square;">


<li style="padding: 3px 0px; margin: 0px;">If the two fields ( field and the foreing field) uses non-compatible field types </li>
</ul><ul style="padding: 0px; margin: 0px 0px 15px 40px; color: rgb(0, 0, 0); list-style-type: square;"><li style="padding: 3px 0px; margin: 0px;">
If its using “On Delete Set Null” but the field doesnt allow that</li><li style="padding: 3px 0px; margin: 0px;">
The FK name is not unique </li></ul><div><br></div></span><font face="verdana, arial, helvetica, sans-serif"><span style="font-size: 12px; line-height: 23px;"><br></span></font><span style="font-family: Georgia,'Times New Roman',Times,serif; font-size: 14px; line-height: 23px;"><div>


A quick solution is to disable Foreing Key check before the query and reenabling it, </div><div><span style="font-family: verdana,arial,helvetica,sans-serif; font-size: 12px;"><br></span></div>
<div><span style="font-family: verdana,arial,helvetica,sans-serif; font-size: 12px;">set foreign_key_checks = 0 ; </span></div>
<div><span style="font-family: verdana,arial,helvetica,sans-serif; font-size: 12px;">NOVA DB SYNC <br></span><span style="font-family: verdana,arial,helvetica,sans-serif; font-size: 12px;">now enable by, set foreign_key_checks = 1 </span></div>


<div><br></div><div>but i dont know if this is actually a bug. If youre running on "release" this should not happen. <br><br>Regards</div><div><br></div></span><br><div class="gmail_quote"><div><div></div><div>

On Tue, Aug 30, 2011 at 4:34 AM, Rasika Karunathilaka <span dir="ltr"><<a href="mailto:rasika.karunathilaka@gmail.com" target="_blank">rasika.karunathilaka@gmail.com</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div><div></div><div><br clear="all">Hi Team,<br><br> When I am trying to attach a compute node into Cloud Control node , I am getting following error on /var/log/nova/nova-compute.log . Server1 is the cloud control node, Server2 is the compute node which I am trying to attach.<br>



<br><i>2011-08-30 12:16:18+0500 [-]   File "/usr/lib/python2.6/dist-packages/sqlalchemy/engine/default.py", line 288, in do_execute<br>2011-08-30 12:16:18+0500 [-]     cursor.execute(statement, parameters)<br>2011-08-30 12:16:18+0500 [-]   File "/usr/lib/pymodules/python2.6/MySQLdb/cursors.py", line 166, in execute<br>



2011-08-30 12:16:18+0500 [-]     self.errorhandler(self, exc, value)<br>2011-08-30 12:16:18+0500 [-]   File "/usr/lib/pymodules/python2.6/MySQLdb/connections.py", line 35, in defaulterrorhandler<br>2011-08-30 12:16:18+0500 [-]     raise errorclass, errorvalue<br>



2011-08-30 12:16:18+0500 [-] sqlalchemy.exc.OperationalError: (OperationalError) (1005, "Can't create table 'nova.network_indexes' (errno: 150)") '\nCREATE TABLE network_indexes (\n\tcreated_at DATETIME, \n\tupdated_at DATETIME, \n\tdeleted_at DATETIME, \n\tdeleted BOOL, \n\tid INTEGER NOT NULL AUTO_INCREMENT, \n\t`index` INTEGER, \n\tnetwork_id INTEGER, \n\tPRIMARY KEY (id), \n\tCHECK (deleted IN (0, 1)), \n\tFOREIGN KEY(network_id) REFERENCES networks (id), \n\tUNIQUE (`index`)\n)ENGINE=InnoDB\n\n' ()<br>



2011-08-30 12:22:26+0500 [-] Log opened.</i><b><i><br></i></b><br><font size="4"> Compute node's nova-compute.conf file is;</font><br><br>--ca_path=/var/lib/nova/CA<br>--keys_path=/var/lib/nova/keys<br>--instances_path=/var/lib/nova/instances<br>



--injected_network_template=/usr/share/nova/interfaces.template<br>--libvirt_xml_template=/usr/share/nova/libvirt.qemu.xml.template<br>--libvirt_uml_xml_template=/usr/share/nova/libvirt.uml.xml.template<br>--vpn_client_template=/usr/share/nova/client.ovpn.template<br>



--credentials_template=/usr/share/nova/novarc.template<br>--logfile=/var/log/nova/nova-compute.log<br>--dhcpbridge=/usr/bin/nova-dhcpbridge<br>--logdir=/var/log/nova<br>--lock_path=/var/lock/nova<br>--state_path=/var/lib/nova<br>



--verbose<br>--s3_host=192.168.104.1<br>--rabbit_host=192.168.104.1<br>--cc_host=192.168.104.1<br>--ec2_url=<a href="http://192.168.104.1:8773/services/Cloud" target="_blank">http://192.168.104.1:8773/services/Cloud</a><br>


--fixed_range=<a href="http://192.168.104.0/24" target="_blank">192.168.104.0/24</a><br>
--network_size=8<br>--FAKE_subdomain=ec2<br>--routing_source_ip=192.168.104.1<br>--sql_connection=mysql://root:<passwd>@<a href="http://192.168.104.1/nova" target="_blank">192.168.104.1/nova</a><br>--glance_host=192.168.104.1<br>


--image_service=nova.image.glance.GlanceImageService<br>
<br> Could you please help to resolve this!<br><br>Cheers!<br><font color="#888888">Rasika Karunathilaka.<br>
</font><br></div></div>_______________________________________________<br>
Mailing list: <a href="https://launchpad.net/%7Eopenstack" target="_blank">https://launchpad.net/~openstack</a><br>
Post to     : <a href="mailto:openstack@lists.launchpad.net" target="_blank">openstack@lists.launchpad.net</a><br>
Unsubscribe : <a href="https://launchpad.net/%7Eopenstack" target="_blank">https://launchpad.net/~openstack</a><br>
More help   : <a href="https://help.launchpad.net/ListHelp" target="_blank">https://help.launchpad.net/ListHelp</a><br>
<br></blockquote></div><br>
</blockquote></div><br><br clear="all"><br>-- <font color="#888888"><br></font><br>