iBeacon shows as expired but it's not

Posted on
Sun May 31, 2020 10:14 am
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

iBeacon shows as expired but it's not

I have a ZUS iBeacon that I used successfully for a year or so. I recently moved and am setting up my indigo from scratch. I now have the PiBeacon app installed and my 1st rPi up and running. I plugged my ZUS into the USB to charge it up (it had been unplugged for months so was dead). It showed up as a device but then went down and now expired. When I check it with two different BLE scanners on my phone it shows as up and active.

Image

I've ensured the phone app (iHere3) is not running (I did a force stop on the phone app to be sure).

I have the Beacon sitting right next to the rPi. I've reloaded the PiBeacon plug-in.

The Mac is 24:DA:11:27:CF:57

Interestingly, it doesn't show a red dot like the other expired beacons.

Log File attached.
Attachments
logsnip.txt
(284.35 KiB) Downloaded 8 times

Posted on
Sun May 31, 2020 12:20 pm
kw123 offline
User avatar
Posts: 7141
Joined: May 12, 2013
Location: Dallas, TX

iBeacon shows as expired but it's not

Can you trace that beacon?

In menu special logging select that beacon.
In plugin.log check if you get any messages from the rpi for that beacon

(Edit)
Did not see your logfile

It seems that it can not connect to the rpi
Permission denied
1.check userid password
2.check known hosts file for ssh connection
Sent from my iPhone using Tapatalk

Posted on
Sun May 31, 2020 1:34 pm
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

Re: iBeacon shows as expired but it's not

Forgive my ignorance, but unsure what you mean when you say 'it can't connect to rPi'. Do you mean the beacon can't connect to the rPi or Indigo can't connect to the rPi?

I can successfully ssh to the rPi using the id pi and my password:
Code: Select all
Johns-MacBook-Pro-3:~ johndeluca$ ssh pi@192.168.0.31
pi@192.168.0.31's password:

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sun May 31 01:09:29 2020
pi@raspberrypi:~ $


I have this same id and password in my PiBeacon->Initial Basic Setup of rPi servers in Indigo Plug-in:
Image

I checked the known_hosts file on my mac and removed the entry for the rpi (192.168.0.31) and re-initiated an SSH connection (to regen the key). I'm way out of my element on this so unsure if I did something bad, but now the rPi shows down in Indigo as well (though I can ssh to it).

EDIT: rPi came back up after a few mins but beacon still expired:

Image
Last edited by johnfdl on Sun May 31, 2020 1:40 pm, edited 1 time in total.

Posted on
Sun May 31, 2020 1:38 pm
kw123 offline
User avatar
Posts: 7141
Joined: May 12, 2013
Location: Dallas, TX

Re: iBeacon shows as expired but it's not

can you switch on debug login all items (99)
the reload the plugin

and post (or email karlwachs@me com) the plugin.log file (mask your password )

Karl

Posted on
Sun May 31, 2020 1:49 pm
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

Re: iBeacon shows as expired but it's not

Thanks Karl,

rPi came back online after a few mins but Beacon shows expired still.

Happy to do a teamviewer session if that's easier for you.
Attachments
logsnip.txt
(21.53 KiB) Downloaded 7 times

Posted on
Sun May 31, 2020 1:58 pm
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

Re: iBeacon shows as expired but it's not

I do notice, when I sssh to the rpi in a terminal window, it takes 15-20 secs after I enter the 'ssh pi@192.168.0.31' command for it to ask me for my password. It accepts the password (and that is the same password I have in the plugin server setup. But I don't remember it taking that long just to ask for my password in ssh sessions in the past.

I raise this only because it does appear to be some password errors in the log file
Code: Select all
2020-05-31 13:00:01 setup pi response (2) message>>>>
spawn sftp -o ConnectTimeout=15 pi@192.168.0.31
pi@192.168.0.31's password:
Permission denied, please try again.

pi@192.168.0.31's password:
Connection closed by 192.168.0.31 port 22

Connection closed

Posted on
Sun May 31, 2020 2:03 pm
kw123 offline
User avatar
Posts: 7141
Joined: May 12, 2013
Location: Dallas, TX

Re: iBeacon shows as expired but it's not

can you do a ping and check how long it takes.

is it on wifi?

and what kind of RPI?

Posted on
Sun May 31, 2020 3:20 pm
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

Re: iBeacon shows as expired but it's not

I think I had some old IP configs in my network settings on the pi. I saw there was a static IP in /etc/network/interfaces that had an old 192.168.2.x address vs. my new 192.168.0.x address.

So I updated the /etc/network/interfaces to this so that it gets an IP from the router's DHCP (it was previously a static address):
Code: Select all
auto lo
iface lo inet loopback
auto eth0
allow-hotplug eth0
iface eth0 inet dhcp

allow-hotplug wlan0
auto wlan0
iface wlan0 inet manual
wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

#iface default inet dhcp


It's an rpi3 and connection is ethernet cable (though it also is getting an IP address for WIFI. This gave me a new address of 192.168.0.43 (and 192.168.0.100 on wifi). This resolved the lag in ssh password prompt....it's almost immediate now when I ssh to the new ip address. I created another rPi entry in the plugin for the new ip address, so now I have two. Not sure if that is the right approach. Ironically, one is up and the other is IP and BLE down.

What I don't understand is why I get other Beacon's showing up....the one I want just never comes out of expired status.
Image
Attachments
logsnip.txt
(25.26 KiB) Downloaded 8 times

Posted on
Sun May 31, 2020 3:24 pm
kw123 offline
User avatar
Posts: 7141
Joined: May 12, 2013
Location: Dallas, TX

Re: iBeacon shows as expired but it's not

Don’t do two.
Select one.
I suggest to use Ethernet
Disable WiFi


Sent from my iPhone using Tapatalk

Posted on
Sun May 31, 2020 3:32 pm
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

Re: iBeacon shows as expired but it's not

Disable wifi in the settings? I just did that and deleted the rPi device I created:
Image

Posted on
Sun May 31, 2020 3:46 pm
kw123 offline
User avatar
Posts: 7141
Joined: May 12, 2013
Location: Dallas, TX

Re: iBeacon shows as expired but it's not

this will disable wifi after it has started, it works, but it takes several minutes to become active after reboot.
i suggest to edit the wpa supplicant file :
with
sudo nano /etc/wpa_supplicant/wpa_supplicant.conf
change the wifi sid or passwd so that it can not connect, or use the full screen on the rpi to remove should then look like:
Code: Select all
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=US

network={
  ssid="wrong-sid"
  psk="abc"
}

you save in nano w CTRL-o and exit with CTRL-x

Karl

Posted on
Sun May 31, 2020 3:56 pm
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

Re: iBeacon shows as expired but it's not

My /etc/wpa_supplicant/wpa_supplicant.conf now looks like this:

Code: Select all
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=US

network={
  ssid="wrong-sid"
  psk="abc"
}


In Indigo: All beacons show expired and rPi shows IP and BLE down

ifconfig shows this:
Code: Select all
eth0      Link encap:Ethernet  HWaddr b8:27:eb:f7:5b:27 
          inet addr:192.168.0.43  Bcast:192.168.0.255  Mask:255.255.255.0
          inet6 addr: 2601:1c2:200:d1e0:ba27:ebff:fef7:5b27/64 Scope:Global
          inet6 addr: 2601:1c2:200:d1e0:f24c:ef2d:762f:e5bb/64 Scope:Global
          inet6 addr: fe80::ba27:ebff:fef7:5b27/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:24723 errors:0 dropped:0 overruns:0 frame:0
          TX packets:9807 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:14010643 (13.3 MiB)  TX bytes:1388271 (1.3 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:802 errors:0 dropped:0 overruns:0 frame:0
          TX packets:802 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1
          RX bytes:179120 (174.9 KiB)  TX bytes:179120 (174.9 KiB)

Posted on
Sun May 31, 2020 3:58 pm
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

Re: iBeacon shows as expired but it's not

And log file now has this:
Code: Select all
2020-05-31 14:58:05 MAC# from RPI message is new B8:27:EB:5D:F1:8D not in internal list .. new RPI?1

Posted on
Sun May 31, 2020 4:13 pm
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

Re: iBeacon shows as expired but it's not

Reloaded plug-in and rPi is up (as are many beacons.....just not the one that should be up).

Edited to add: And a few mins later with making no changes, everything in the plugin is back down with rPi showing BLE and IP down.

Another edit: A few mins after the above, things are back up now (again, except the Beacon that should be up).

Posted on
Sun May 31, 2020 4:35 pm
johnfdl offline
Posts: 173
Joined: May 18, 2017
Location: Atlanta, GA USA

Re: iBeacon shows as expired but it's not

Now the beacon is showing UP! Again, I did nothing, so I am perplexed why things seem to go up and down without any logical reason.

Who is online

Users browsing this forum: No registered users and 0 guests