Home › Forums › FABRIC General Questions and Discussion › Create L3 network error
- This topic has 3 replies, 2 voices, and was last updated 2 years, 5 months ago by Chengyi Qu.
-
AuthorPosts
-
June 8, 2022 at 9:01 am #2023
Hi,
I’m facing one error when creating l3 network in my slice.
Running post_boot_config … Error: ‘NoneType’ object has no attribute ‘get_layer’
Traceback (most recent call last):
File “/tmp/ipykernel_55/3472008977.py”, line 62, in <module>
slice.submit() #(wait_progress=True)
File “/opt/conda/lib/python3.9/site-packages/fabrictestbed_extensions/fablib/slice.py”, line 1220, in submit
self.wait_jupyter(timeout=wait_timeout, interval=wait_interval)
File “/opt/conda/lib/python3.9/site-packages/fabrictestbed_extensions/fablib/slice.py”, line 1164, in wait_jupyter
self.post_boot_config()
File “/opt/conda/lib/python3.9/site-packages/fabrictestbed_extensions/fablib/slice.py”, line 1109, in post_boot_config
iface_thread.result()
File “/opt/conda/lib/python3.9/concurrent/futures/_base.py”, line 433, in result
return self.__get_result()
File “/opt/conda/lib/python3.9/concurrent/futures/_base.py”, line 389, in __get_result
raise self._exception
File “/opt/conda/lib/python3.9/concurrent/futures/thread.py”, line 52, in run
result = self.fn(*self.args, **self.kwargs)
File “/opt/conda/lib/python3.9/site-packages/fabrictestbed_extensions/fablib/interface.py”, line 286, in ip_link_toggle
self.get_node().ip_link_down(None, self)
File “/opt/conda/lib/python3.9/site-packages/fabrictestbed_extensions/fablib/node.py”, line 1240, in ip_link_down
if interface.get_network().get_layer() == NSLayer.L3:
AttributeError: ‘NoneType’ object has no attribute ‘get_layer’Is there anything like ‘tag’ I missed? I checked the Fablib github, did not find the l3 network tutorial has any change in this update.
June 8, 2022 at 9:17 am #2024When I want to reserve l2 network, still facing the same problem….
Here is my code:
# Add host node h1
h1 = slice.add_node(name=h1_name, site=site_1)
h1.set_capacities(cores=host_cores, ram=host_ram, disk=host_disk)
h1.set_image(image)
h1_iface = h1.add_component(model=’NIC_ConnectX_5′, name=”h1_nic”).get_interfaces()[0]# Add host node h2
h2 = slice.add_node(name=h2_name, site=site_1)
h2.set_capacities(cores=host_cores, ram=host_ram, disk=host_disk)
h2.set_image(image)
h2_iface = h2.add_component(model=’NIC_ConnectX_5′, name=”h2_nic”).get_interfaces()[0]# Add host node h3
h3 = slice.add_node(name=h3_name, site=site_2)
h3.set_capacities(cores=host_cores, ram=host_ram, disk=host_disk)
h3.set_image(image)
[h3_iface,h3_iface_pub] = h3.add_component(model=’NIC_ConnectX_5′, name=”h3_nic”).get_interfaces()# Add host node h4
h4 = slice.add_node(name=h4_name, site=site_2)
h4.set_capacities(cores=host_cores, ram=host_ram, disk=host_disk)
h4.set_image(image)
h4_iface = h4.add_component(model=’NIC_ConnectX_5′, name=”h4_nic”).get_interfaces()[0]# Add host node h5
h5 = slice.add_node(name=h5_name, site=site_2)
h5.set_capacities(cores=host_cores, ram=host_ram, disk=host_disk)
h5.set_image(image)
h5_iface = h5.add_component(model=’NIC_ConnectX_5′, name=”h5_nic”).get_interfaces()[0]#Add control panel networks
host_net1 = slice.add_l2network(name=net_1_name, interfaces=[h1_iface,h2_iface, h3_iface, h4_iface,h5_iface])And I got the same error as in the first post.
June 8, 2022 at 9:23 am #2025I think this is an error that is unnecessarily reported when fablib tries to setup a network interface that is not connected to a network. In your case, I suspect you are using only one of the two interfaces on a baremetal NIC.
Since you are not actually using the extra interface, this exception should not affect outcome the experiment. Try to just ignore this exception and see if your experiment works.
We will fix this by suppressing this exception in the future. Let me know if your experiment doesn’t work because of this exception and we can find another short-term solution.
Paul
June 8, 2022 at 9:53 am #2026Thank you for the explaination. I tried to assigne ip addresses and ping between nodes, and everything works fine as normal.
Thank you for your help. I will just ignore this exception.
-
AuthorPosts
- You must be logged in to reply to this topic.