我正在运行ALTER TABLE article_attachment CHANGE content content LONGBLOB NULL
在此表上:
CREATE TABLE `article_attachment` (
`id` bigint(20) NOT NULL AUTO_INCREMENT,
`article_id` bigint(20) NOT NULL,
`filename` varchar(250) DEFAULT NULL,
`content_size` varchar(30) DEFAULT NULL,
`content_type` text,
`content_id` varchar(250) DEFAULT NULL,
`content_alternative` varchar(50) DEFAULT NULL,
`content` longblob NOT NULL,
`create_time` datetime NOT NULL,
`create_by` int(11) NOT NULL,
`change_time` datetime NOT NULL,
`change_by` int(11) NOT NULL,
`disposition` varchar(15) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `article_attachment_article_id` (`article_id`),
KEY `FK_article_attachment_create_by_id` (`create_by`),
KEY `FK_article_attachment_change_by_id` (`change_by`)
) ENGINE=InnoDB AUTO_INCREMENT=34672 DEFAULT CHARSET=utf8
并获取错误
Got error 66 "Object is remote" from storage engine InnoDB
Google几乎没有任何关于错误的返回。
我确实将max_allowed_packet
增加到999999488,但这无济于事。
更新
我试图更改同一表中的另一列,然后告诉我The size of BLOB/TEXT data inserted in one transaction is greater than 10% of redo log size. Increase the redo log size using innodb_log_file_size.
也许这是相关的...
好吧,我跟随https://dba.stackexchange.com/a/a/1265/42097,并在my.cnf mysqld中增加了 innodb_log_file_size
。
桌子的mySQL分析告诉我aprate_attachment.content max_length是22942326。因此,我将Innodb_log_file_size设置为300000000。
现在Alter表工作了。