What I would like to accomplish One is a dedicated pair of RPi's using Wi-Fi Direct (p2p), one GO (group owner) and the other its client. The GO is not to be an access point, as neither RPi needs to connect elsewhere; they only talk to each other.
I have read through these questions and answers: Setting up Wifi direct (wifi p2p) and DHCP server, Howto migrate from networking to systemd-networkd with dynamic failover, and Configure Rpi as router - error when starting network and DHCP interfaces and many other posts here and elsewhere. But my lack of in-depth networking knowledge and skills is a problem.
Current state for both RPi: fresh Buster install using with sudo bash -c 'apt update && apt full-upgrade && reboot'
as suggested in Setting up Wifi direct (wifi p2p) and DHCP server. However, the script that's laid-out is for communication between an RPi and SmartPhone, rather than a second RPi - which is where my knowledge deficit takes over.
Goal: eth0 remains accessible for both devices on my local network (192.168.1.024-IP is static or DHCP assignment), with the wireless connection on a separate network (e.g. 192.168.4.1 & 192.168.4.2). I have read elsewhere that it is possible for the RPi to have eth0 and wlan0 on separate networks.
I understand that the GO needs to be a DHCP server for its wlan, and that the client will be assigned its wireless IP by the GO. Further, I believe the GO also needs to manage the routes for that wireless network.
For now, the two devices sit next to each other (for convenience). With wpa_cli and wpa_gui, I have run through numerous configurations without achieving my goal. I have seen numerous messages between the devices indicating they "see" each other, but have not been able to get them to successfully ping each other. So, suggestions for setting-up such a paired system would be greatly appreciated and would likely contribute to getting a bit more sleep...
Thanks in advance!
Edit - Adding contents of wpa_supplicant-wlan0.config and /etc/system/network configuration files.
p2p GO: wpa_supplicant-wlan0.conf:
ctrl_interface=DIR=/run/wpa_supplicant GROUP=netdev
update_config=1
country=US
eapol_version=1
device_name=DIRECT-RPi3-NanCam
device_type=1-0050F204-1
p2p_go_intent=15
p2p_go_ht40=1
network={
ssid="DIRECT-CA"
psk="12345670"
key_mgmt=WPA-PSK
proto=RSN WPA
}
/etc/systemd/network files: 04-wired.network: (Note: Works as expected)
[Match]
Name=e*
[Network]
#Option using a DHCP server
DHCP=yes
#Option using link-local ip addresses
#LinkLocalAddressing=yes
#MulticastDNS=yes
# Option use static ip address (example, use your settings)
#Address=192.168.1.111/24
#Gateway=192.168.1.1
#DNS=192.168.1.1
08-wifi.network (note: no ip address assigned)
[Match]
Name=wl*
[Network]
#to use static IP (with your settings) toggle commenting the next 8 lines.
Address=192.168.4.61/24
DNS=192.168.4.1
[Route]
Gateway=192.168.4.1
Metric=20
#DHCP=yes
#[DHCP]
#RouteMetric=20
12-p2p-wlan0.network
[Match]
Name=p2p-*
[Network]
Address=192.168.4.1/24
DHCPServer=yes
p2p CL:
wpa_supplicant-wlan0.conf:
ctrl_interface=DIR=/run/wpa_supplicant GROUP=netdev
update_config=1
country=US
eapol_version=1
device_name=DIRECT-RPi3-NanDisp
device_type=1-0050F204-1
p2p_go_intent=15
p2p_go_ht40=1
network={
ssid="DIRECT-CA"
psk="12345670"
key_mgmt=WPA-PSK
proto=RSN WPA
}
/etc/systemd/network files: 04-wired.network: (Note: Works as expected)
[Match]
Name=e*
[Network]
#Option using a DHCP server
DHCP=yes
#Option using link-local ip addresses
#LinkLocalAddressing=yes
#MulticastDNS=yes
#Option use static ip address (example, use your settings)
#Address=192.168.1.111/24
#Gateway=192.168.1.1
#DNS=192.168.1.1
08-wifi.network (note: no ip address assigned)
[Match]
Name=wl*
[Network]
#to use static IP (with your settings) toggle commenting the next 8 lines.
#Address=192.168.50.61/24
DNS=
[Route]
Gateway=192.168.4.1
DHCP=yes
[DHCP]
RouteMetric=20
12-p2p-wlan0.network
[Match]
Name=p2p-*
[Network]
DHCP=yes
[DHCP]
RouteMetric=20
Once again, thanks for helping.