GO HERE Raspberry Pi3 WLAN0 overriding ETH0, IPBX 13-12.5

SMTC

Member
Joined
Jan 22, 2009
Messages
190
Reaction score
13
During distro install I was only eth0 attached. I followed the instructions at http://nerdvittles.com/?p=17094 to mod wpa_supplicant.conf file and got the wlan0 going OK. (pulled out the ethernet cable and rebooted). All good.

But now I want to just use the hardwired eth0 but wlan0 is taking precedence. It just doesn't default everything to the ethernet port.

Removing the SSID and valid PASSWORD from wpa_supplicant.conf causes SSH/Asterisk to not work for about 8 hours until the WIFI finally gives up I guess. It also seesm to latch on automatically to a neighbour's WiFi unsecured Access Point open as GUEST (but still looking for a passcode so no Internet)

Logging in from the console (since SSH non-responsive from whitelisted WAN) shows some ugly URL with a "URL moved" message in place of where the Public IP address is supposed to be on the PBX Status screen.

As a work-around for now I put the command IFCONFIG WLAN0 DOWN into my /etc/rc.local file.

But the questions are why is WiFi coming up first? Why does it take precedence over a readily available and connected ETH0? Can this be the other way around, i.e. IF connection on Ethernet, then that is the main and default, else try on WLAN0?.

John
 
Last edited:

SMTC

Member
Joined
Jan 22, 2009
Messages
190
Reaction score
13
Now this is really weird. Without a reboot, the WLAN0 which was administratively IFDOWN, has come up on its own. Console PBXSTATUS shows two IP's and none of the phones work - a routing issue no doubt due to the second IP on the WLAN0 being the one the RASPI wants to use and it not being the one the Router/FW has the permits for.

:banghead:
 

jerrm

Guru
Joined
Sep 23, 2015
Messages
838
Reaction score
405

SMTC

Member
Joined
Jan 22, 2009
Messages
190
Reaction score
13
root@raspberrypi:/etc $ cat dhcpcd.conf
# A sample configuration for dhcpcd.
# See dhcpcd.conf(5) for details.

# Allow users of this group to interact with dhcpcd via the control socket.
#controlgroup wheel

# Inform the DHCP server of our hostname for DDNS.
hostname

# Use the hardware address of the interface for the Client ID.
clientid
# or
# Use the same DUID + IAID as set in DHCPv6 for DHCPv4 ClientID as per RFC4361.
#duid

# Persist interface configuration when dhcpcd exits.
persistent

# Rapid commit support.
# Safe to enable by default because it requires the equivalent option set
# on the server to actually work.
option rapid_commit

# A list of options to request from the DHCP server.
option domain_name_servers, domain_name, domain_search, host_name
option classless_static_routes
# Most distributions have NTP support.
option ntp_servers
# Respect the network MTU.
# Some interface drivers reset when changing the MTU so disabled by default.
#option interface_mtu

# A ServerID is required by RFC2131.
require dhcp_server_identifier

# Generate Stable Private IPv6 Addresses instead of hardware based ones
slaac private

# A hook script is provided to lookup the hostname if not set by the DHCP
# server, but it should not be run by default.
nohook lookup-hostname
WARNING: Always run Incredible PBX VM behind a secure hardware-based firewall.
root@raspberrypi:/etc $

=================================================================

WARNING: Always run Incredible PBX VM behind a secure hardware-based firewall.
root@raspberrypi:/etc $ ifconfig
eth0 Link encap:Ethernet HWaddr b8:27:::::
inet addr:192.168.1.149 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::1f03:beca:27d8:3fe3/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:79238 errors:0 dropped:0 overruns:0 frame:0
TX packets:78927 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:15954823 (15.2 MiB) TX bytes:18000635 (17.1 MiB)

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:95678 errors:0 dropped:0 overruns:0 frame:0
TX packets:95678 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:329481555 (314.2 MiB) TX bytes:329481555 (314.2 MiB)

wlan0 Link encap:Ethernet HWaddr b8:27::::::
inet addr:192.168.1.108 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::d2fb:35fc:250d:56ea/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:283 errors:0 dropped:6 overruns:0 frame:0
TX packets:442 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:109675 (107.1 KiB) TX bytes:163116 (159.2 KiB)

=================================================================

WARNING: Always run Incredible PBX VM behind a secure hardware-based firewall.
root@raspberrypi:/etc $ route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 192.168.1.1 0.0.0.0 UG 0 0 0 wlan0
default 192.168.1.1 0.0.0.0 UG 202 0 0 eth0
default 192.168.1.1 0.0.0.0 UG 303 0 0 wlan0
192.168.1.0 * 255.255.255.0 U 202 0 0 eth0
192.168.1.0 * 255.255.255.0 U 303 0 0 wlan0
WARNING: Always run Incredible PBX VM behind a secure hardware-based firewall.
root@raspberrypi:/etc $
 

ostridge

Guru
Joined
Jan 22, 2015
Messages
1,628
Reaction score
520
Last edited:

Members online

Forum statistics

Threads
25,804
Messages
167,728
Members
19,232
Latest member
voiplads
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top