leiweibau / Pi.Alert

Scan the devices connected to your WIFI / LAN and alert you the connection of unknown devices. It also warns if a "always connected" device disconnects. In addition, it is possible to check web services for availability. For this purpose HTTP status codes and the response time of the service are evaluated.
https://leiweibau.net
GNU General Public License v3.0
426 stars 30 forks source link

Permission Denied #89

Closed iball closed 1 year ago

iball commented 1 year ago

Trying to upgrade from 2023-03-07 to 2023-03-09 and getting this:

curl -sSL https://github.com/leiweibau/Pi.Alert/raw/main/install/pialert_update.sh | bash

############################################################ Pi.Alert Update ############################################################ Fri Mar 10 22:46:53 CST 2023 Logfile: pialert_update_2023-03-10_22-46.log

Permissions:

drwxr-xr-x 2 iball www-data 4.0K Mar 10 22:47 . drwxr-xr-x 10 iball iball 4.0K Mar 9 07:21 .. -rw-r--r-- 1 iball iball 176 Mar 9 07:21 ._pialert.conf -rw-r--r-- 1 iball iball 176 Mar 9 07:21 ._version.conf -rwxrwxr-x 1 www-data www-data 3.3K Jan 23 21:59 pialert-20230123_215938.bak -rwxrwxr-x 1 www-data www-data 3.5K Mar 3 22:29 pialert-prev.bak -rwxrwxr-x 1 www-data www-data 3.5K Mar 3 22:29 pialert.conf -rwxrwxr-x 1 iball www-data 3.5K Mar 10 22:47 pialert.conf.back -rw-r--r-- 1 iball iball 83 Mar 9 07:21 version.conf

Upgrades always worked before.

leiweibau commented 1 year ago

I think the update has now also basically run through. In the section, the script has tried to write new entries in pialert.conf, which has not happened now. You can also do this manually if necessary. The new entries are:

REPORT_MAIL_WEBMON = False
REPORT_WEBGUI_WEBMON = True
REPORT_TELEGRAM_WEBMON = False
REPORT_NTFY_WEBMON = False
REPORT_PUSHSAFER_WEBMON = False

You can set the parameters to "False" or "True" as you like.

iball commented 1 year ago

OK, the update is going through successfully now and everything is back to normal. Thanks for the quick fix.

curl -sSL https://github.com/leiweibau/Pi.Alert/raw/main/install/pialert_update.sh | bash

############################################################ Pi.Alert Update ############################################################ Sat Mar 11 12:26:52 CST 2023 Logfile: pialert_update_2023-03-11_12-26.log

Pi.Alert (2023-03-11)

Current User: iball

Update HW Vendors Timestamp: 2023-03-11 12:27:00

Updating vendors DB (iab & oui)...

Searching devices vendor............................................................................... Devices Ignored: 1 Vendors Not Found: 30 Vendors updated: 48

Pi.Alert (2023-03-11)

Current User: iball

Check Internet IP Timestamp: 2023-03-11 12:27:00

Retrieving Internet IP... [REDACTED]

Retrieving previous IP... [REDACTED] No changes to perform

Skipping Dynamic DNS update...

DONE!!!

Pi.Alert (2023-03-11)

Current User: iball

Scan Devices Timestamp: 2023-03-11 12:27:00

Scanning... arp-scan Method... arp-scan: Multiple interfaces Pi-hole Method... DHCP Leases Method...

Processing scan results... Devices Detected.......: 44 arp-scan Method....: 42 Pi-hole Method.....: +0 New Devices........: 0

Devices in this cycle..: 43
    Down Alerts........: 0
    New Down Alerts....: 0
    New Connections....: 0
    Disconnections.....: 1
    IP Changes.........: 0

Updating DB Info... Sessions Events (connect / discconnect) ... Creating new devices... Updating Devices Info... Trying to resolve devices without name.... Names updated: 0 Voiding false (ghost) disconnections... Pairing session events (connection / disconnection) ... Creating sessions snapshot... Skipping repeated notifications... Calculate Activity History...

Reporting... Formating report... No changes to report... Notifications: 0

DONE!!!


Update process finished

leiweibau commented 1 year ago

Thank you for your feedback. The update script is always a bit tricky, especially when new things are added ;)