InnoDB Cluster config

There is not a lot of information that is easy to understand to get innodb cluster running,

The following is the terminal dump of what I needed to do to get it working, important notes.

you must bind mysql to 0.0.0.0

prior to adding a server to the cluster execute RESET MASTER; to clear the logs.

apt install python -y
wget http://dev.mysql.com/get/mysql-apt-config_0.8.4-1_all.deb
dpkg -i ./mysql-apt-config_0.8.4-1_all.deb
apt-get update
apt-get install mysql-server mysql-shell -y

mysql_ssl_rsa_setup –uid mysql

mysqlsh

\connect [email protected]:3306

dba.configureLocalInstance();

1) Create remotely usable account for ‘root’ with same grants and password
2) Create a new admin account for InnoDB cluster with minimal required grants
3) Ignore and continue
4) Cancel

Please select an option [1]: 2
Please provide an account name (e.g: [email protected]%) to have it created with the necessary
privileges or leave empty and press Enter to cancel.
Account Name: [email protected]%

shell.connect(‘[email protected]:3306’);
var cluster = dba.createCluster(‘cluster name’, { memberSslMode: ‘REQUIRED’, ipWhitelist:’192.168.0.0/16,127.0.0.1/8′});

cluster.addInstance(‘[email protected]:3306’, { memberSslMode: ‘REQUIRED’, ipWhitelist:’192.168.0.0/16,127.0.0.1/8′});

GRANT ALL PRIVILEGES ON *.* TO ‘icroot’@’%’ IDENTIFIED BY ‘password’ WITH GRANT OPTION;
flush privileges

Redis promote slave to master

https://redis.io/commands/slaveof

ansible run playbook with sudo password as extra var

 

Ansible disk space

ansible <host>, -m shell -a “df -H”

What to do when MySQL or MariaDB shits the bed

Had a server outage mid transaction?

Now you can’t start MYSQL ?

You probably have a transaction stuck and the service won’t come back up until you deal with it…

 

Here is how you deal with it.

mysqld --tc-heuristic-recover=ROLLBACK

service mysql start

set connection multi-source Mariadb replication

SET @@default_master_connection=”

mariadb db replication reset

How to Reset ( Re-Sync ) MySQL Master-Slave Replication

Updating listview – android

Calling

Is not enough when updating the content of cells. The only way to guarantee data is updated correctly, and tags are set correctly is to setAdapter(newAdapter instance)

Android adb location

~/Library/Android/sdk/platform-tools/adb install app-release.apk

to debug

 

http://stackoverflow.com/questions/38167117/how-to-debug-inapp-billing-in-android

Git remove commit history

http://stackoverflow.com/questions/13716658/how-to-delete-all-commit-history-in-github