MySQL replication - ibdata1 huge
If you want to shrink ibdata1, so that it should only contain the metadata, You may try these steps

To shrink ibdata1 once and for all you must do the following:


MySQLDump all databases into a SQL text file (as bkp_all_db.sql) 
Drop all databases (except mysql schema) 
Stop MySQL
/etc/init.d/mysql stop
Add the following lines to /etc/my.cnf

[mysqld]
innodb_file_per_table
innodb_flush_method=O_DIRECT
innodb_log_file_size=1G
innodb_buffer_pool_size=4G

Now remove ibdata1, so that there should only be the mysql schema in /var/lib/mysql


rm -f /var/lib/mysql/ibdata1 /var/lib/mysql/ib_logfile


Start MySQL instance, This will recreate ibdata1, ib_logfile0 and ib_logfile1 at 1G each

service mysqld start
Reload bkp_all_db.sql into mysql (import). ibdata1 will grow but only contain table metadata  


http://mysqlrockstar.blogspot.in/2014/07/mysql-ibdata1-file-shrink.html