Thursday, June 8, 2017

Mongodb secondary database - database list and collection is not visible

MongoDB secondary replica does not have collections as in primary

Error : 
"$err" : "not master and slaveOk=false", "code" : 13435

Solution :
serverdb:SECONDARY> rs.slaveOk()

Running Command rs.slaveOk() on secondary instance is the solution.

Thursday, May 18, 2017

Mysql installation conflict with mariadb

Error :
Renaming removed key_buffer and myisam-recover options (if present)


mysql_upgrade: Got error: 1524: Plugin 'unix_socket' is not loaded while connecting to the MySQL server


Upgrade process encountered error and will not continue.
mysql_upgrade failed with exit status 11


dpkg: error processing package mysql-server-5.7 (--configure):subprocess installed post-installation script returned error exit status 1


Errors were encountered while processing:mysql-server-5.7


Solution :
If you have installed MariaDB and then you have removed it to install mysql. This can be the cause of this issue. If you try to purge all old config filess and set everything up from scratch then it should work. 

Take Back up your important data before doing it.

# sudo apt purge mysql-client-5.7 mysql-client-core-5.7 mysql-common mysql-server-5.7 mysql-server-core-5.7 mysql-server
# sudo apt update 
# sudo apt dist-upgrade && sudo apt autoremove && sudo apt -f install
# sudo apt install mysql-server

Saturday, April 8, 2017

Odoo - Remove Manage Databases link from Login page

Odoo - Remove Powered by Odoo Text from Login page

Edit file addons/web/views/webclient_templates.xml
sudo nano /opt/odoo/addons/web/views/webclient_templates.xml

Remove or Comment text "Manage Databases" and "Powered by Odoo".


Now you tried to restart the odoo server but you are not able to see your changes on the browser.

Here you need to load the web module because you ahve changed content in the file of web module. Without loading web module, you will not be able to see your changes. Restarting Odoo does not load the web module.


sudo -S su postgres -c "./odoo-bin start --update=web"

--update=all loads all modules but we need to reload only web module to see the changes. Now changes will be visible.