Thursday, 2025-03-27

jannoCan someone explain to me what has happenend to this commit? https://opendev.org/openstack/openstack-ansible/commit/01765b335868db13656b7221915181126ce5a34a#diff-c2a42d2e96826f541495fed0648d2c0e0d97c3d609:44
jannoYou can find it within the history under https://opendev.org/openstack/openstack-ansible/commits/branch/master09:44
jannobut it seems it has never beed merged to master?09:45
janno*been09:46
noonedeadpunkjanno: you are right and it never was merged: https://review.opendev.org/c/openstack/openstack-ansible/+/80410909:54
jannonoonedeadpunk: Would there have been any chance of finding it myself?09:55
noonedeadpunkbut lately we've also refactored how rabbitmq_upgrade flag behaves during an upgrade09:55
noonedeadpunkjanno: in all commit messages there is a `Change-Id` - you can search by it in gerrit09:56
jannoAh, thank you!09:56
f0onoonedeadpunk: can I change network_mappings post-deployment? i.e. without having to recreate the neutron networks? I noticed that I cannot update network_interface_mappings because the interface is already a port on the other bridge and ovs-vsctl errors with that10:11
noonedeadpunkwell, there's no logic of removing already defined interfaces from bridges, it can only add new ones...10:12
f0oyeah but here both br-ext and br-fip would have the same physical interface which is no possible with vsctl apparently10:13
noonedeadpunkso while you technically can change it - it will not always work if interface was already in use before10:13
f0oso now I'm thinking if I can just change network_mappings instead, would that cause neutron issues? I can do the port-changes manually10:14
noonedeadpunkyou probably can create a veth pair?:)10:14
noonedeadpunkfrankly - I never tried that...10:14
f0ore veth; you mean make a standard bridge, add the physical interface to it, create 2 veths add them to the bridge and also to the ovs-bridge?10:18
noonedeadpunkyeah, kinda10:19
noonedeadpunkor anotrher ovs brdige, just created manually10:20
noonedeadpunkBut eventually, I think it should be possible to change m,ap[pigns during the runtime10:21
f0oarguably its cleaner if I'm allowed to change network_mappings, then I can set both to br-ext and it should just work right?10:21
noonedeadpunkBut I'd guess that you'd need to trigger neutron-ovs-agent to re-wire things10:22
noonedeadpunkit's totally cleaner to change mappings10:22
f0oactually if I move it the other way around; there is no rewiring needed on the gateway nodes10:25
f0obecause br-ext was only used for vlan typed networks whereas br-fip was the public shebang. So from the gateway node's view, br-ext is not used10:26
f0oso if I can change the network_mappings to use vlan:br-fip,fip:br-fip instead of the old vlan:br-ext,fip:br-fip and manually remove br-ext from gatewaynodes and do the port-swap, then it should work right?10:28
f0oall of this with the assumption that I can just change network_mappings :D10:28
f0oBut wait what am I saying - since br-ext is not in use on gateway nodes, I can just del-br it and do the port swap10:30
f0othen I can just use network_interface_mappings as before which is a safe thing10:30
f0oI'm really doing a 180 over and over again here but I think I'm cooking something10:30
f0osorry for being verbose, it did help tho!10:30
noonedeadpunkyeah, sure, it often helps when you start typing :) 10:31
noonedeadpunkso feel free to 10:31
f0owell if my shell drops connectivity we all know that I messed it up :D10:31
noonedeadpunkso if it was ovs, I'd say that you might need to run neutron-ovs-cleanup after changing mappings10:32
noonedeadpunkas iirc it triggers re-wiring for ports10:32
f0owell I think I got the briges sorted out11:24
f0oall of this is now banking on the hope that network_mappings can hold duplicates, namely "vlan:br-ext,fip:br-ext"11:26
noonedeadpunkoh11:26
noonedeadpunkI don't think you can do that11:26
f0o:|11:26
noonedeadpunkactually, I'm pretty sure y9ou can't11:26
f0oso then I'm doomed entirely because I cant merge vlan and fip11:27
f0obut I need them both to run on the same physical interface11:27
noonedeadpunkveth pairs ?:)11:28
f0othat sounds awful for performance11:28
noonedeadpunk(I know)11:28
f0oduplicating packets 3x at a minimum11:28
f0ocan I merge network_vlan_ranges ?11:29
noonedeadpunkbut I really don't think you can use same interface twice in there from neutron prespecitve11:29
noonedeadpunkWell, the problem is that you can't really swap physical interface for the vlan networks in neutron11:29
noonedeadpunkor well, you can't natively11:30
noonedeadpunkyou probably can in db11:30
noonedeadpunkbut then it's smth you totally need to spawn sandbox for and test 11:30
f0oso what if I rewrite network_vlan_ranges from vlan:100:2000,fip:2000:3000 to vlan:100:3000, then network_mappings becomes as easy as "vlan:br-ext" ?11:30
f0oFor the existing fip networks, I would edit the DB entry directly to make them "vlan"11:31
f0owould that work?11:31
noonedeadpunkit can work, yes11:31
noonedeadpunkbut you totally would need to trigger re-wiring of interfaces mnually11:32
noonedeadpunkas neutron will not do that just on basis of db change11:32
noonedeadpunkand also I guess it depends if it's ovn ovs11:32
f0ono re-wiring needed11:33
f0ocompute nodes only use br-ext, gateway nodes only use br-fip. merging them is just a matter of telling vlan:br-ext on compute and vlan:br-fip on gateway nodes11:33
f0oright?11:34
noonedeadpunkeh, dunno11:34
noonedeadpunkso you wnat to make a different mapping based o nthe group?11:34
f0oyeah11:34
noonedeadpunkyou can do that11:34
f0oso that way both classes (compute,gateway) have their currently deployed ovs-bridge as the "vlan" provider. And as long as I make the networks that use `fip` (3 of em luckily) in the DB to use `vlan`, neutron should be happy (given that vlan_ranges are set to vlan:100:3000)11:35
noonedeadpunkbut chaning db record for networks with swapping physicxal network name should require changes in ovs 11:36
noonedeadpunklike to use another briddge in namespaces11:36
f0oI think you're generally right but when you have gatewaynodes the only wiring that exist is for your public/fip networks, not the vlan ones. And you arent changing that location11:37
noonedeadpunkso you still need to tell neutron to re-wire veth for namespaces from one bridge to another?11:37
f0oThats what I'm avoiding by reusing the existing bridges on both classes, they just happen to be named differently between them11:37
noonedeadpunkor dunno, as you're using ovn it's probably different11:38
noonedeadpunkbut then with ovn I guess you'd need to sync state from neutron db to ovn nb db11:38
noonedeadpunk(neutron-ovn-db-sync-util)11:38
noonedeadpunkhttps://docs.openstack.org/openstack-ansible-os_neutron/latest/app-ovn.html#ovn-database-population11:39
f0owhat I did right now was to manually delete br-ext (vlan provider) from all gateway nodes and attached the physical interface of that bridge to the br-fip (fip provider where the public vlan is). I now moved all traffic from the gateway cross-connect to the switch ports, So this went pretty fine as the gateway nodes had no other ports in the br-ext bridge, it was really11:39
f0ounused with no traffic on it at all.11:39
f0oFor the compute nodes the entire thing is reversed, they dont even have a br-fip set up to start with, they only have br-ext.11:40
f0oso to merge them, I claim vlan:br-ext on compute and vlan:br-fip on gateway nodes. This will not change any wiring. But I need to tell neutron that the 3 `fip` networks are now `vlan`11:40
f0oand that last part I can likely just do in the DB and restart the agents/servers11:41
noonedeadpunkyeah, so I'm not sure about that db part, as in ovn restarting agents won't give you anything pretty much11:41
f0oonce all of that is done, I should be able to enable distributed fip making the compute node bind to the vlans of the old fip networks which are now correct vlan11:41
noonedeadpunkas for ovn iirc neutron is not caring much about some of these things being in config11:42
f0oI'm lowkey banking on that as well, and for each OVN chassis nothing has changed. The unused bridge in each respective class (comp,gate) is gone and the used one continues to get ports11:43
f0othat's my hope & dreams at least11:44
f0oI gut says this should work but I'm afraid of some hidden ovs attribute on the bridge or chassis or so that will wreck it :D11:45
noonedeadpunkI'm concerned about flows tbh, but dunno11:49
f0oml2_vlan_allocations is the neutron table I should be concerned about right?11:53
f0oI will check the flows in a bit as well11:53
noonedeadpunkwell, I mean. There's nothing in neutron which will understand that DB has changed and that it need to do anything with that.11:54
noonedeadpunkAnd neutron DB is kinda a reference of how to propogate NB DB11:54
noonedeadpunkso this data could be somewhere in nb db - then you'd need to do respective changes there as well11:55
noonedeadpunkbut again - I feel not that confident when it comes to networking11:55
f0oas far as I understood it, ovn only cares about the physical mapping, in this case br-* - neutron only cares about the "other" mapping (vlan/fip in my case) where the network is assigned to. Since I'm not changing the physical mapping on any node, it should be fine no?11:56
noonedeadpunkyeah true11:57
f0oI do change that "other" mapping by merging fip+vlan physical_network11:57
f0oI checked that there are no networks with the same vlan IDs but different physical_network11:57
f0olike I said, my gutfeeling says this should be working fine but my brain tells me there's something I overlooked and I'm about to nuke everything11:58
f0omaybe I need a whisky first for... plausible deniability or something11:59
noonedeadpunkcould be, hehe11:59
f0ook so ml2_vlan_allocations needs to be cleaned up and networksegments needs the physical_network updated12:09
f0othere's no occurances of br-ext or br-fip in the neutron database12:09
f0onow to the ovs stuff12:09
noonedeadpunkno, it really care only about the mapped naming...12:10
f0othat was what I suspected, just happy to see it was correct :D12:11
f0onb does not have br-* information (took a backup with ovsdb-client backup unix:///run/ovn/ovnnb_db.sock OVN_Northbound and grepped it)12:15
noonedeadpunkYeah, I was just thinking that you wanted to rename "vlan"/"fip" in a way as well12:17
f0ook I found something in the SB DB in the Chassis > Other_Config - there's an attribute ovn-bridge-mappings which reflects the original network_interface_mappings12:20
f0othis might need updating12:20
f0oSB DB also has the `network_name` option set on all Port_Bindings which are either fip or vlan12:22
f0o"all" was a bit wrong. On two. wonder what ports those are12:23
spatelnoonedeadpunk I have upgraded zed to 2023.1 and encounter this error in keystone. I am not able to attach cinder volume to vm now. - https://paste.opendev.org/show/b637xEcAknJygEkAYAcM/15:36
spatelAny clue or did you see this before? 15:37
f0oWell this was a nightmare15:52
f0oit absolutely did not work whatsoever15:52
noonedeadpunkf0o: so it all broke?16:21
f0oyep19:08
f0oand it took a while to revert it all and recover19:08
f0oI think distributed fip is not something that works to switch in runtime19:09
f0obecause I saw the packets arrive on the compute nodes, right vlan too - so L2 existed. However the MAC of the fip was the router's - and nothing replied to it19:10
f0oI tried detaching and reattaching the FIP, shutdown and start the VM, nothing changed19:11
f0oat first I thought I just need to retrigger port creation for the flows or something but nope... The compute nodes wouldnt reply to FIPs no matter what19:11
noonedeadpunkf0o_: and newly created fips were not working either?20:05

Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!