There is also the CREATE LIKE route.
CREATE db2.newtable LIKE db1.oldtable
This will copy the structure, then you can run an insert...
INSERT INTO db2.newtable
SELECT * FROM db1.oldtable
You would then just need a way to iterate through the result set of all tables in db1 and run the queries.
SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = 'db1'