2) TopologyForAPs - I manage V2110 with it and this is where APs live, binded to VLAN 22. 192.168.40/23, through this Topology default routing works (GW 192.168.40.1)
3) V38 - its@EWC, binded to VLAN 38, IP range 10.10.32.0/19
4) V39 - its@EWC, binded to VLAN 39, IP range 10.11.32.0/21
The problem is when I connect to WLAN 38 or 39 I get IP from VLAN22. Bootprelay is configured on all switches. Everything is OK on server side, DHCP works. I can reach DHCP server from all EWC interfaces,
How could I solve this issue? I could provide all additional information required.
Looking at the screen shot you sent ... you don't seem to have any topologies that are of type "Physical" which you should have.
The interface on your controller that APs should be registering to should be a Physical interface with your IP of 192.168.40/23 on it, probably untagged for VLAN 22. That interface should have AP Registration and Management checked off/enabled. You should define a default gateway under "Routing Protocols" for the next hop router that your controller can reach out of that Physical interface through VLAN 22. Presumably 192.168.40.1.
It looks like you currently have this configured through a B@EWC topology and you shouldn't. You would likely need to remove the B@EWC topology for VLAN 22 first, then create a new one of type Physical. This would probably need to be done from the CLI of the console in Vmware, since you are probably bringing up the GUI of the controller through that interface presently and if you delete in in the GUI (which you need to do) you'll then lose contact through the GUI.
The following steps might be helpful to provide if you do not already know them, to accomplish that (VLAN 600 and the IP address shown are only examples of course):
------------------------------------------------------------------------------------------------- How to manually configure an ESA Port from the Console of a V2110
Type topology hit enter, prompt changes to topo then type the following:
create "esa0" physical 600 port esa0 untag 10.26.6.51/24
This creates esa0 as a physical port,assigns it to vlan 600, untagged, using port esa0 with IP of whatever mask you specify.
You can use the command SHOW to see what is configured at any time. Make sure to do enable “mgmt.” so you can https: to this new IP from the LAN and to also enable AP registration if the port you’re creating is the one you want APs to register to.
To do that, from the topology prompt, type “l3” and hit enter. At the l3 prompt:
Your admin port should be left at the default of 192.168.10.1/24 with no default gateway defined and should be powered down in Vmware.
The other B@EWC topologies you have defined ... will be using the same physical port probably as is your Physical interface and as such, you make those topologies tagged for their respective VLANs (38 and 39). The switch port that is on the "other side" of your Vmware physical NIC that the V2110 is using .. would then need to be untagged for VLAN 22, and tagged for VLAN's 38 and 39.
Assuming the rest of your LAN is configured properly to switch/route at L2/L3 VLANs 22, 38 and 39 ... and assuming you have defined the Vswitch you are using in Vmware properly (to "Accept" Promiscuous Mode and to allow "All VLANs (4095) ... making that port a trunk port that will carry all VLAN tags) you should have a working configuration.
In the design you have outlined ... you would not need to tag all the APs for VLANs 38 and 39 ... since the topologies are B@EWC ... you simply need to tag the ethernet switch port that the controller connects to for those VLAN's ... and the APs should be untagged in VLAN 22 most probably for them to connect to what should be the untagged VLAN 22 port for the controller.
Here is a link regarding the requirements for promiscuous mode and allowing all VLANs for your Vswitch: