hlr migrate: delete invalid IMSIs first
This commit is contained in:
parent
c3047b3940
commit
2eb3bcb182
1 changed files with 3 additions and 0 deletions
|
@ -29,6 +29,9 @@ if [ -f hlr.db ]; then
|
|||
rm hlr.db-wal hlr.db-shm 2> /dev/null
|
||||
fi
|
||||
|
||||
echo "Clean invalid IMSIs from NITB db"
|
||||
echo 'DELETE FROM subscriber WHERE authorized=0 AND length(imsi)!=15;' | sqlite3 ./hlr.sqlite3
|
||||
|
||||
echo "Importing NITB db form hlr.sqlite3 to hlr.db..."
|
||||
osmo-hlr-db-tool import-nitb-db hlr.sqlite3 -l hlr.db
|
||||
systemctl restart osmo-hlr
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue