Jump to content

Issue of partial data visibility on Slave Server

From TetraWiki
Revision as of 09:26, 30 July 2019 by Biswajit (talk | contribs) (Created page with "Category:Radico-Khaitan == Mysql on Linux is Cases sensitive and Mysql on Windows is case insensitive == '''Problem''' The error shows st_tnt_up_excise.'''C'''ompany ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)



Mysql on Linux is Cases sensitive and Mysql on Windows is case insensitive[edit]

Problem The error shows st_tnt_up_excise.Company doesn't exists



Solution[edit]

In my.cnf edit /etc/my.cnf and add the following line after [mysqld]

lower_case_table_names=1

move or remove /var/lib/mysql directory. This will delete all databases!!!!

mv /var/lib/mysql /tmp/mysql

Create a new /var/lib/mysql directory and make mysql user as owner

mkdir /var/lib/mysql
chown -R mysql:mysql /var/lib/mysql
chmod 750 /var/lib/mysql
service mysqld stop 
service mysqld start

Database will get initialized and then you can dump the database and start replication .


Problem 2[edit]

Due to change in SQL Mode the data is not exported from the Slave Server

Solution[edit]

In my.cnf edit /etc/my.cnf and add the following line after [mysqld]

sql_mode = STRICT_TRANS_TABLES,NO_ENGINE_SUBSTITUTION

Reference - https://tableplus.io/blog/2018/08/mysql-how-to-turn-off-only-full-group-by.html

and restart Mysqld