Wrapper around mydumper/myloader to optimize data loads
- Run mydumper without any changes (not part of this projects, happens independently elsewhere)
- Move data files out of the exported directory
- Run myloader so database tables are created without data
- Gather Indexes created and generate the create index statements
- Drop all the non primary key indexes
- Move schema files out of exported directory and move data files back in
- Run myloader to load data
- Run create index statements generated from #4
- Move schema files back in for archival purpose
Required parameters:
Path to config file with database credentials
-d
Data directory path
-s
Name of the database to run on
Optional parameters:
-t
Number of threads to use
-v
Verbosity level
Run Command
./index_optimized_loader {Path to config file with database credentials} -d {Path to database schema and data files} -s {Name of the database} -v {Verbosity level: 1,2,3} -t {Number of threads to use}