...
Login into SO Mariadb
Code Block root@esy22-rancher:~# kubectl -n onap get pods | grep mariadb-galera dev-mariadb-galera-mariadb-galera-0 1/1 Running 0 10d dev-mariadb-galera-mariadb-galera-1 1/1 Running 0 10d dev-mariadb-galera-mariadb-galera-2 1/1 Running 0 10d dev-vid-vid-mariadb-galera-0 1/1 Running 0 2d22h root@esy22-rancher:~# kubectl -n onap exec -it dev-mariadb-galera-mariadb-galera-0 bash bash-4.2$
login to database and connect to
catalogdb
Code Block bash-4.2$ env | grep -i password MYSQL_PASSWORD=my-password MYSQL_ROOT_PASSWORD=secretpassword bash-4.2$ mysql -uroot -psecretpassword Welcome to the MariaDB monitor. Commands end with ; or \g. Your MariaDB connection id is 188369 Server version: 10.1.24-MariaDB MariaDB Server Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. MariaDB [(none)]> connect catalogdb; Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Connection id: 188371 Current database: catalogdb MariaDB [catalogdb]>
Change SERVICE_TYPE Null value to *
Code Block MariaDB [catalogdb]> select * from northbound_request_ref_lookup; +-----+-------------------+-----------------------------------+--------------------------+-------------+-----------------+-----------------+-----------------+-------------+--------------+ | id | REQUEST_SCOPE | MACRO_ACTION | ACTION | IS_ALACARTE | MIN_API_VERSION | MAX_API_VERSION | IS_TOPLEVELFLOW | CLOUD_OWNER | SERVICE_TYPE | +-----+-------------------+-----------------------------------+--------------------------+-------------+-----------------+-----------------+-----------------+-------------+--------------+ | 86 | Service | Service-Create | createInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 89 | Service | Service-Delete | deleteInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 92 | Service | Service-Macro-Assign | assignInstance | 0 | 7 | 7 | 1 | CloudOwner | NULL | | 95 | Service | Service-Macro-Activate | activateInstance | 0 | 5 | 7 | 1 | CloudOwner | NULL | | 98 | Service | Service-Macro-Unassign | unassignInstance | 0 | 7 | 7 | 1 | CloudOwner | NULL | | 101 | Service | Service-Macro-Create | createInstance | 0 | 5 | 7 | 1 | CloudOwner | NULL | | 104 | Service | Service-Macro-Delete | deleteInstance | 0 | 5 | 7 | 1 | CloudOwner | NULL | | 107 | Network | Network-Create | createInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 110 | Network | Network-Delete | deleteInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 113 | Vnf | VNF-Macro-Recreate | recreateInstance | 0 | 7 | 7 | 1 | CloudOwner | NULL | | 116 | Vnf | VNF-Macro-Replace | replaceInstance | 0 | 7 | 7 | 1 | CloudOwner | NULL | | 119 | Vnf | VNF-Create | createInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 122 | Vnf | VNF-Delete | deleteInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 125 | VolumeGroup | VolumeGroup-Create | createInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 128 | VolumeGroup | VolumeGroup-Delete | deleteInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 131 | VfModule | VFModule-Create | createInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 134 | VfModule | VFModule-Delete | deleteInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 137 | NetworkCollection | NetworkCollection-Macro-Create | createInstance | 0 | 7 | 7 | 1 | CloudOwner | NULL | | 140 | NetworkCollection | NetworkCollection-Macro-Delete | deleteInstance | 0 | 7 | 7 | 1 | CloudOwner | NULL | | 143 | VfModule | VFModule-ScaleOut | createInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 146 | VfModule | VFModule-DeactivateAndCloudDelete | deactivateAndCloudDelete | 1 | 7 | 7 | 1 | CloudOwner | NULL | | 149 | Service | Service-Macro-Deactivate | deactivateInstance | 0 | 5 | 7 | 1 | CloudOwner | NULL | | 152 | Network | Network-Update | updateInstance | 1 | 7 | 7 | 1 | CloudOwner | NULL | +-----+-------------------+-----------------------------------+--------------------------+-------------+-----------------+-----------------+-----------------+-------------+--------------+ 23 rows in set (0.00 sec) MariaDB [catalogdb]> UPDATE northbound_request_ref_lookup set SERVICE_TYPE='*'; Query OK, 0 rows affected (0.00 sec) Rows matched: 23 Changed: 0 Warnings: 0
Command to remove old images from docker
Code Block |
---|
docker images | grep " [1 days ago|months|weeks]* ago" | awk '{print $3,$4,$5}' | xargs docker rmi --force $3 |