On Tue, Jan 3, 2012 at 4:30 PM, Daniel Pittman <[email protected]>wrote:
> On Tue, Jan 3, 2012 at 16:01, Russell Van Tassell <[email protected]> > wrote: > > > For completeness sake, the subsequent error (with trace) is thus... I > think > > at this point, I'm likely stuck -- at least short of wiping the DB and > > starting over, fresh (which I'd prefer to not do). > > Both of those look like MySQL level errors - not specifically about > this database; the first should be resolvable by rebuilding the table > to reduce the number of locks required, according to the MySQL people. > ...I just bumped the innodb_buffer_pool_size as recommended by an old bug. That seemed to make that go away... 8M is a little silly, anyway... -- begin my.cnf excerpt # Default of 8MB for innodb buffer pool is a little small - 2011/01/03 RVT # - Ref: http://bugs.mysql.com/bug.php?id=15667 innodb_buffer_pool_size = 83886080 -- end For the second, you might need to drop the foreign key constraints by > hand, because table changes are not transactional in MySQL. :( I > keep forgetting that, being used to a competent ^W fully transactional > DBMS. > > You should be able to hand-write the appropriate delete constraint > SQL, though, if you want. It isn't that hard. > Okay... looks like I'm in an iterative process, now... this has allowed me to get past the reports table.. -- begin mysql> show create table reports; | reports | CREATE TABLE `reports` ( `id` int(11) NOT NULL AUTO_INCREMENT, `node_id` int(11) DEFAULT NULL, `host` varchar(255) DEFAULT NULL, `time` datetime DEFAULT NULL, `status` varchar(255) DEFAULT NULL, `kind` varchar(255) DEFAULT NULL, `puppet_version` varchar(255) DEFAULT NULL, `configuration_version` varchar(255) DEFAULT NULL, PRIMARY KEY (`id`), KEY `index_reports_on_node_id` (`node_id`), KEY `index_reports_on_time_and_node_id_and_status` (`time`,`node_id`,`status`), CONSTRAINT `fk_reports_node_id` FOREIGN KEY (`node_id`) REFERENCES `nodes` (`id`) ON DELETE CASCADE ) ENGINE=InnoDB AUTO_INCREMENT=594242 DEFAULT CHARSET=utf8 | 1 row in set (0.00 sec) mysql> SET FOREIGN_KEY_CHECKS=0; mysql> alter table reports drop foreign key `fk_reports_node_id`; mysql> SET FOREIGN_KEY_CHECKS=1; -- end ...and now I'm on to resource_statuses for a similar problem. Looks like it's time to dump this in a screen session and let it run until I hit the next big boom (ie. and then try to fix it from home, rinse, repeat, etc). -- begin -- execute("ALTER TABLE reports ADD CONSTRAINT fk_reports_node_id FOREIGN KEY (node_id) REFERENCES nodes(id) ON DELETE CASCADE;") -> 27.5650s -- execute("ALTER TABLE resource_events ADD CONSTRAINT fk_resource_events_resource_status_id FOREIGN KEY (resource_status_id) REFERENCES resource_statuses(id) ON DELETE CASCADE;") -> 903.3903s -- execute("ALTER TABLE resource_statuses ADD CONSTRAINT fk_resource_statuses_report_id FOREIGN KEY (report_id) REFERENCES reports(id) ON DELETE CASCADE;") rake aborted! An error has occurred, all later migrations canceled: Mysql::Error: The table '#sql-5675_a' is full: ALTER TABLE resource_statuses ADD CONSTRAINT fk_resource_statuses_report_id FOREIGN KEY (report_id) REFERENCES reports(id) ON DELETE CASCADE; -- end -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
