Bug #45422 | ERROR 1602 (HY000): Corrupted TRG file for table `NAMEOFDATABASE`.`NAMEOFTABLE1` | ||
---|---|---|---|
Submitted: | 10 Jun 2009 5:12 | Modified: | 20 Jul 2009 23:38 |
Reporter: | Roel Van de Paar | Email Updates: | |
Status: | Can't repeat | Impact on me: | |
Category: | MySQL Server: DDL | Severity: | S2 (Serious) |
Version: | 5.1.31 | OS: | Any |
Assigned to: | Sveta Smirnova | CPU Architecture: | Any |
[10 Jun 2009 5:12]
Roel Van de Paar
[10 Jun 2009 5:21]
Sveta Smirnova
"multi delete" error looks same as bug #27525
[10 Jun 2009 5:30]
Roel Van de Paar
Also note bug #45235
[10 Jun 2009 5:41]
Roel Van de Paar
In regards the mysqldump side of things: mysqldump on 5.1.31 (Windows) dumps the incorrect SQL as-is, even when a 1602 has already been shown: ------- mysql> show create trigger NAMEOFTRIGGER; ERROR 1602 (HY000): Corrupted TRG file for table `NAMEOFDATABASE`.`NAMEOFTABLE1` mysql> exit Bye C:\mysql5.1.31\bin>mysqldump -uroot -psystem --opt NAMEOFDATABASE > out.sql C:\mysql5.1.31\bin> ------- The out.sql file contains the incorrect SQL trigger code (as listed already above).
[10 Jun 2009 5:42]
Roel Van de Paar
There seem to be 3 issues here: 1. At some point, server accepted some wrong code for the trigger. 2. mysqldump does not correct it (or warn about it) when dumping. 3. Importing it again gives various 'random' issues, as per the above.
[10 Jun 2009 7:01]
Sveta Smirnova
Regarding to MULTI DELETE error: dump contains mixed register, so it is correct to get such error on Linux => this part is not a bug. Other part about restore on Windows still interesting though.
[10 Jun 2009 7:41]
Sveta Smirnova
Thank you for the report. I can not repeat error which you experienced on Windows. Please provide your configuration file.
[10 Jun 2009 22:48]
Roel Van de Paar
[client] port=5131 [mysql] default-character-set=latin1 [mysqld] log = general.log port=5131 basedir="C:/mysql5.1.31/" datadir="C:/mysql5.1.31/Data/" default-character-set=latin1 default-storage-engine=MyISAM sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION" max_connections=100 query_cache_size=15M table_cache=256 tmp_table_size=18M thread_cache_size=8 myisam_max_sort_file_size=100G myisam_sort_buffer_size=35M key_buffer_size=23M read_buffer_size=64K read_rnd_buffer_size=256K sort_buffer_size=256K innodb_data_home_dir="C:/mysql5.1.31/data/" innodb_data_file_path=ibdata1:700M;ibdata2:200M:autoextend innodb_additional_mem_pool_size=2M innodb_flush_log_at_trx_commit=1 innodb_log_buffer_size=1M innodb_buffer_pool_size=42M innodb_log_file_size=10M innodb_thread_concurrency=8
[10 Jun 2009 22:57]
Roel Van de Paar
Vista Version: C:\Windows\system32>cmd /k Wmic OS get BuildType,Caption,Version|find "M" Multiprocessor Free Microsoft® Windows VistaT Business 6.0.6001
[11 Jun 2009 9:35]
Sveta Smirnova
Thank you for the feedback. I still can not repeat described behavior. Please try on Windows with current version 5.1.35 and if problem still exists provide copy-paste from cmd.exe
[11 Jul 2009 23:00]
Bugs System
No feedback was provided for this bug for over a month, so it is being suspended automatically. If you are able to provide the information that was originally requested, please do so and change the status of the bug back to "Open".
[20 Jul 2009 23:38]
Roel Van de Paar
I've worked out why some of the errors were happening. In the mysqldump-generated .sql file, for some reason, the following statement was there: SHOW WARNINGS; I asked the customer if this was inserted manually, but have not received a response yet. In either case, it explains why the output of running the .sql script looks different at different times; i.e. if an error occurred just before running the SOURCE command, that error was repeated as part of the output because of the SHOW WARNINGS command. However, this does not explain the (only remaining and unaddressed) error: o ERROR 1602 (HY000): Corrupted TRG file for table `NAMEOFDATABASE`.`NAMEOFTABLE1` I have tried to re-create the issue on 5.1.35, without success. Also, 5.1.35 lists a proper error code for the previously mentioned 'incorrect' trigger syntax: ERROR 1235 (42000): This version of MySQL doesn't yet support 'multiple triggers with the same action time and event for one table'
[21 Jul 2009 0:04]
Roel Van de Paar
Also, as the 'incorrect' syntax is no longer accepted by the server in the first place, mysqldump would also not dump it as such, hence mysqldump is 'fixed' by the same token.