From dc91ab9c54459dc579ce37b7d4cf84eb68a5ff9e Mon Sep 17 00:00:00 2001 From: Esteban Mackay Q Date: Fri, 11 Aug 2023 16:37:31 -0500 Subject: [PATCH] update --- install.sh | 21 +++++++++++++++------ update.sh | 30 ++++++++++++++---------------- 2 files changed, 29 insertions(+), 22 deletions(-) diff --git a/install.sh b/install.sh index e7ef094..a9237c5 100644 --- a/install.sh +++ b/install.sh @@ -770,6 +770,13 @@ then rm mon.db fi +mysql -u root -e "DROP TABLE IF EXISTS selfcare.last_heard;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.lstheard_log;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.peer_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.subscriber_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.talkgroup_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.tg_count;" +cd /opt/FDMR-Monitor python3 mon_db.py --create python3 mon_db.py --update @@ -966,12 +973,14 @@ then rm mon.db fi -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS last_heard;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS lstheard_log;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS peer_ids;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS subscriber_ids;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS talkgroup_ids;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS tg_count;" + +mysql -u root -e "DROP TABLE IF EXISTS selfcare.last_heard;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.lstheard_log;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.peer_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.subscriber_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.talkgroup_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.tg_count;" +cd /opt/FDMR-Monitor2 python3 mon_db.py --create python3 mon_db.py --update diff --git a/update.sh b/update.sh index 52fb1e8..f81886a 100644 --- a/update.sh +++ b/update.sh @@ -968,18 +968,17 @@ sudo sed -i "s/THEME_COLOR = .*/THEME_COLOR = pro/g" /opt/FDMR-Monitor/fdmr-mon. #sudo sed -i "s/SUBSCRIBER_URL = .*/SUBSCRIBER_URL = https:\/\/freedmr-lh.gb7fr.org.uk\/json\/subscriber_ids.json/g" /opt/FDMR-Monitor/fdmr-mon.cfg #sudo sed -i "s/TGID_URL = .*/TGID_URL = https:\/\/freedmr.cymru\/talkgroups\/talkgroup_ids_json.php/g" /opt/FDMR-Monitor/fdmr-mon.cfg -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS last_heard;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS lstheard_log;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS peer_ids;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS subscriber_ids;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS talkgroup_ids;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS tg_count;" - if [ -f "mon.db" ] then rm mon.db fi - +mysql -u root -e "DROP TABLE IF EXISTS selfcare.last_heard;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.lstheard_log;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.peer_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.subscriber_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.talkgroup_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.tg_count;" +cd /opt/FDMR-Monitor python3 mon_db.py --create python3 mon_db.py --update @@ -1193,14 +1192,13 @@ if [ -f "mon.db" ] then rm mon.db fi - -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS last_heard;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS lstheard_log;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS peer_ids;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS subscriber_ids;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS talkgroup_ids;" -mysql -u "root" "selfcare" -e "DROP TABLE IF EXISTS tg_count;" - +mysql -u root -e "DROP TABLE IF EXISTS selfcare.last_heard;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.lstheard_log;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.peer_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.subscriber_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.talkgroup_ids;" && +mysql -u root -e "DROP TABLE IF EXISTS selfcare.tg_count;" +cd /opt/FDMR-Monitor2 python3 mon_db.py --create python3 mon_db.py --update