MySQL File Corruption

Use this forum if you have installed hMailServer and want to ask a question related to a production release of hMailServer. Before posting, please read the troubleshooting guide. A large part of all reported issues are already described in detail here.
Post Reply
Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

MySQL File Corruption

Post by Hotlanta » 2006-12-11 03:01

I recently installed hMailServer using the default MySQL set up. It's been running great for about a week now. Suddenly, I stopped getting mail deliveries. I ran some tests, and it seemed to be accepting the mail, and allowed me to log in to check mail, However the mail just vanished.

So I looked in the logs. It appeared that the hm_messages.MYI table was corrupted. In attempting to correct the problem, I found this page with instruction on how to file a corrupted file:
http://www.hmailserver.com/documentatio ... pair_mysql

Since this is a default install of MySQL that came with hMailServer, I tried to recover the password per the instructions. When doing this, the instructions tell me:

1. Run the script hMailServerAddonsUtilitiesDecryptBlowfish.vbs.
2. Open up hMailserver.ini, located in your Windows directory or hMailServer bin directory.
3. Copy the password from hMailServer.ini to the DecryptBlowfish dialog.
4. Click OK in DecryptBlowfish to view your password

Unfortunately, this is not specifically how that script runs. It asks for an administrator password first, and then the encrypted password. It appears that both are located in the hMailserver.ini file, but when I put them into this script, it crashed with:

C:\program files\hMailServer\Addons\Utilities\DecryptBlowfish.vbs
Line: 16
Char: 1
Error: You do not have access to this property / method. Ensure that hMailServer.Application.Authenticate() is called with proper login credentials.
Code: 800403E9
Source: hMailServer COM Library

Since I'm a programmer, I decided to edit the blowfish script and I saw that the first adminstrator password it's asking for isn't the encrypted "administrator password" entry from the .ini file, it's the password we use all the time to log into hMailServer. The second password is the first one (not the administrator password) from the .ini file. So, after 20 minutes of mucking around, I finally got the script to run, and I now had my MySQL password. Not to be a pain in the ass, but better instructions are needed here. When you ask us to open the .ini file and then ask us for an administrator password when there is just such a thing in the ini file, it's easy to confuse what you're asking for. If I hadn't opened up the script file to "fix" what I thought was broken in the script, I wouldn't have figure this out. In addition to better instruction, perhaps a more graceful way of handling the wrong administrator password would be nice, too. The way this went down, it just looked like bad script.

At that point, as per the instructions, I downloaded SQLyog, and was able to repair the table. My mail started to fill up almost immediately, although I did lose some of my test mails in the process. I have no idea how much mail was actually lost.

So excuse me for being the doubting Thomas here, but how often does MySQL corrupt files? From what I read in the forum, it's impossible for hMailServer to corrupt files. The machine that this is running on is a Windows 2000 server with virtually nothing else running. I have had no other problems with this machine. Since I've only been running this for a week or so, I have to wonder about the stability of the MySQL system. Is anyone else seeing this problem?

Also, is there any way to handle errors better? It seems to me that when a file is corrupted, there should be an automatic fix to this to rebuild the files, especially when it happens on a regular basis.

For anyone that might like to see what may have caused this corruption, especially since it was the default system, here are snippets of the log when it started.

Regards,

John


...

"ERROR" 1036 "2006-12-09 13:54:03.000" "Source: DNSResolver::_Resolve, Code: HM10081, Description: DNS query failure. Treating as temporary failure. Query: streetrealty.biz, Type: 15, DnsQuery return value: 9002."
"ERROR" 1036 "2006-12-09 13:54:03.000" "Source: DNSResolver::GetEmailServers, Code: HM10082, Description: Failed to resolve email servers."
"ERROR" 2084 "2006-12-09 13:57:46.000" "MySQL: Duplicate entry '179707' for key 1 (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{8CFFD50D-4CA4-4429-A1C5-65162AAB841A}.eml', 1, 'jalalzumar@yahoo.com', '', 1162, 0, 0, 0, 0, 1, '2006-12-09 13:57:27', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 2084 "2006-12-09 13:58:48.500" "MySQL: Duplicate entry '179707' for key 1 (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{BFEE828C-E332-4D6A-BF17-2B973C2C383F}.eml', 1, 'ivo.burkart@gmx.net', '', 1151, 0, 0, 0, 0, 1, '2006-12-09 13:58:29', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 2084 "2006-12-09 13:59:57.828" "MySQL: Duplicate entry '179707' for key 1 (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{DC11AC3C-D825-436F-B038-D3B81A576389}.eml', 1, 'james24732000@yahoo.com', '', 1165, 0, 0, 0, 0, 1, '2006-12-09 13:59:39', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 2084 "2006-12-09 14:00:43.343" "MySQL: Duplicate entry '179707' for key 1 (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{6C8DF658-EFC0-4211-93F0-4AA64ADC8931}.eml', 1, 'intex@mantraonline.com', '', 1167, 0, 0, 0, 0, 1, '2006-12-09 14:00:24', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1780 "2006-12-09 14:01:03.406" "SMTPDeliverer - Message 173732: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 2188 "2006-12-09 14:01:17.515" "SMTPDeliverer - Message 179706: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 2188 "2006-12-09 14:01:17.531" "SMTPDeliverer - Message 173732: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 1536 "2006-12-09 14:01:17.625" "SMTPDeliverer - Message 179706: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 1536 "2006-12-09 14:01:17.640" "SMTPDeliverer - Message 173732: ERROR HM10007: Message could not be delivered since the data file does not exist."

...

"ERROR" 1704 "2006-12-09 14:26:50.171" "SMTPDeliverer - Message 179706: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 1480 "2006-12-09 14:26:50.187" "MySQL: Duplicate entry '179709' for key 1 (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{F3551D39-18BD-4D9F-ADC3-B9E33C1EFD23}.eml', 1, '', '', 681, 0, 0, 0, 0, 1, '2006-12-09 14:26:32', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1704 "2006-12-09 14:26:50.187" "SMTPDeliverer - Message 173732: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 1704 "2006-12-09 14:26:50.187" "SMTPDeliverer - Message 179706: ERROR HM10007: Message could not be delivered since the data file does not exist."

...

"ERROR" 1704 "2006-12-09 14:26:51.250" "SMTPDeliverer - Message 173732: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 1704 "2006-12-09 14:26:51.250" "SMTPDeliverer - Message 179706: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 1704 "2006-12-09 14:26:51.265" "SMTPDeliverer - Message 173732: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 1704 "2006-12-09 14:26:51.265" "SMTPDeliverer - Message 179706: ERROR HM10007: Message could not be delivered since the data file does not exist."
"ERROR" 2076 "2006-12-09 14:27:06.859" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{E9AEE2E9-D9F6-4671-8340-710C05C3DBBD}.eml', 1, 'sentto-13880452-10800-1165691779-SirReal=Hotlanta.com@returns.groups.yahoo.com', '', 26659, 0, 0, 0, 0, 1, '2006-12-09 14:26:48', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1752 "2006-12-09 14:27:09.328" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagelocked = 1 where messageid = 173732")"
"ERROR" 1752 "2006-12-09 14:27:09.328" "Source: SMTPDeliveryManager::DoWork(), Code: HM4216, Description: Failed to lock message."
"ERROR" 1436 "2006-12-09 14:27:16.250" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagenexttrytime = DATE_ADD(CONCAT(CURDATE(), ' ', CURTIME()), INTERVAL 60 MINUTE) ,messagecurnooftries = messagecurnooftries + 1 where messageid = 178206")"
"ERROR" 2080 "2006-12-09 14:27:19.531" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{D19B508F-A7D9-42F5-B2FC-8ED4E1ADDA85}.eml', 1, 'fgaddbeaefcc@casinogambling-sites.com', '', 3341, 0, 0, 0, 0, 1, '2006-12-09 14:27:01', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1448 "2006-12-09 14:27:21.234" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{5E834CF4-53B8-4372-9A3E-58CB8209EF0B}.eml', 1, '', '', 682, 0, 0, 0, 0, 1, '2006-12-09 14:27:03', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1892 "2006-12-09 14:27:24.953" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagenexttrytime = DATE_ADD(CONCAT(CURDATE(), ' ', CURTIME()), INTERVAL 60 MINUTE) ,messagecurnooftries = messagecurnooftries + 1 where messageid = 178194")"
"ERROR" 1752 "2006-12-09 14:27:27.328" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagelocked = 1 where messageid = 179706")"
"ERROR" 1752 "2006-12-09 14:27:27.328" "Source: SMTPDeliveryManager::DoWork(), Code: HM4216, Description: Failed to lock message."
"ERROR" 1436 "2006-12-09 14:27:34.250" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagelocked = 0 where messageid = 178206")"
"ERROR" 2212 "2006-12-09 14:27:37.562" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagenexttrytime = DATE_ADD(CONCAT(CURDATE(), ' ', CURTIME()), INTERVAL 60 MINUTE) ,messagecurnooftries = messagecurnooftries + 1 where messageid = 178224")"
"ERROR" 1448 "2006-12-09 14:27:39.234" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "delete from hm_messages where messageid = 175371")"
"ERROR" 1892 "2006-12-09 14:27:42.953" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagelocked = 0 where messageid = 178194")"
"ERROR" 1752 "2006-12-09 14:27:45.328" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "select * from hm_messages WHERE messagetype = 1 AND (messagenexttrytime <= CONCAT(CURDATE(), ' ', CURTIME())) and messagelocked = 0 order by messageid asc ")"
"ERROR" 1716 "2006-12-09 14:27:52.296" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{5EF42662-1863-4A13-BE62-BD5FF962D487}.eml', 1, '', '', 680, 0, 0, 0, 0, 1, '2006-12-09 14:27:34', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 2212 "2006-12-09 14:27:55.562" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagelocked = 0 where messageid = 178224")"
"ERROR" 1252 "2006-12-09 14:27:57.265" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{96F904A5-13BA-4AFE-B931-C0C695A71EEE}.eml', 1, '', '', 686, 0, 0, 0, 0, 1, '2006-12-09 14:27:39', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1540 "2006-12-09 14:28:01.000" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagenexttrytime = DATE_ADD(CONCAT(CURDATE(), ' ', CURTIME()), INTERVAL 60 MINUTE) ,messagecurnooftries = messagecurnooftries + 1 where messageid = 178209")"
"ERROR" 1716 "2006-12-09 14:28:10.296" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "delete from hm_messages where messageid = 175327")"
"ERROR" 1252 "2006-12-09 14:28:15.265" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "delete from hm_messages where messageid = 175336")"
"ERROR" 2080 "2006-12-09 14:28:17.390" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{7A61E030-AAFA-45F3-8479-B85ED2868F53}.eml', 1, 'cdfcbacfgegfd@casino-bonus-promotion.com', '', 3430, 0, 0, 0, 0, 1, '2006-12-09 14:27:59', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1540 "2006-12-09 14:28:19.000" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagelocked = 0 where messageid = 178209")"
"ERROR" 2084 "2006-12-09 14:28:33.953" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{EAD52024-01F5-4CAF-97BE-E275372F6257}.eml', 1, 'phoneme''sveranda@abrahamandrose.com', '', 1922, 0, 0, 0, 0, 1, '2006-12-09 14:28:15', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1752 "2006-12-09 14:29:03.328" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "select * from hm_messages WHERE messagetype = 1 AND (messagenexttrytime <= CONCAT(CURDATE(), ' ', CURTIME())) and messagelocked = 0 order by messageid asc ")"
"ERROR" 2084 "2006-12-09 14:29:14.437" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{4F295B80-0FF7-4D99-85D5-AF94773D01DB}.eml', 1, 'warmongering''sclues@aardu.easn.sun.com', '', 1924, 0, 0, 0, 0, 1, '2006-12-09 14:28:56', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 2076 "2006-12-09 14:30:05.312" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{BBA134BB-8143-4811-BB17-56933A3011D3}.eml', 1, 'gegcef@castenetto.com', '', 4676, 0, 0, 0, 0, 1, '2006-12-09 14:29:47', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1752 "2006-12-09 14:30:21.328" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "select * from hm_messages WHERE messagetype = 1 AND (messagenexttrytime <= CONCAT(CURDATE(), ' ', CURTIME())) and messagelocked = 0 order by messageid asc ")"
"ERROR" 1344 "2006-12-09 14:30:49.921" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagenexttrytime = DATE_ADD(CONCAT(CURDATE(), ' ', CURTIME()), INTERVAL 60 MINUTE) ,messagecurnooftries = messagecurnooftries + 1 where messageid = 177929")"
"ERROR" 1344 "2006-12-09 14:31:07.921" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "update hm_messages set messagelocked = 0 where messageid = 177929")"
"ERROR" 2088 "2006-12-09 14:31:34.453" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{2CEE6AAC-2BB0-4F55-ADA5-1EA2634E0CF2}.eml', 1, 'ggdaggfea@castres-mazamet.com', '', 4382, 0, 0, 0, 0, 1, '2006-12-09 14:31:16', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1752 "2006-12-09 14:31:39.328" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "select * from hm_messages WHERE messagetype = 1 AND (messagenexttrytime <= CONCAT(CURDATE(), ' ', CURTIME())) and messagelocked = 0 order by messageid asc ")"
"ERROR" 2084 "2006-12-09 14:31:44.937" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{4B3684F4-F785-452C-9DF5-6A014FF3CD92}.eml', 1, 'Darji@18lesbian.com', '', 1939, 0, 0, 0, 0, 1, '2006-12-09 14:31:26', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 2076 "2006-12-09 14:32:21.421" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "insert into hm_messages (messagelocked, messageaccountid, messagefilename, messagetype, messagefrom, messagerecipients, messagesize, messageflagseen, messageflagdeleted, messagefolderid, messagerecipientsparsed, messageflagrecent, messagecreatetime, messageflagflagged, messageflagdraft, messageflaganswered, messagecurnooftries, messagenexttrytime) values (1, 0, 'C:\\Program Files\\hMailServer\\Data\\{653BE009-6765-408D-A11A-A795DB11D445}.eml', 1, 'dafdf@cardwellsheep.com', '', 3056, 0, 0, 0, 0, 1, '2006-12-09 14:32:03', 0, 0, 0, 0, '1901-01-01')")"
"ERROR" 1752 "2006-12-09 14:32:57.328" "MySQL: Can't open file: 'hm_messages.MYI' (errno: 145) (Additional info: "select * from hm_messages WHERE messagetype = 1 AND (messagenexttrytime <= CONCAT(CURDATE(), ' ', CURTIME())) and messagelocked = 0 order by messageid asc ")"

...

^DooM^
Site Admin
Posts: 13861
Joined: 2005-07-29 16:18
Location: UK

Re: MySQL File Corruption

Post by ^DooM^ » 2006-12-11 10:36

Hotlanta wrote:So excuse me for being the doubting Thomas here, but how often does MySQL corrupt files? From what I read in the forum, it's impossible for hMailServer to corrupt files. The machine that this is running on is a Windows 2000 server with virtually nothing else running. I have had no other problems with this machine. Since I've only been running this for a week or so, I have to wonder about the stability of the MySQL system. Is anyone else seeing this problem?
I have been using hmail for well over a year and a half and have never had this issue using the builtin mysql or external using my own dedicated SQL server. I have seen SQL corruptions a few times on this forum though and I know martin is looking into ways to improve things all the time.

On another note I recently used that decrypt blowfish vbscript file myself and didn't have any issues with it either. What version of hmail are you using?
If at first you don't succeed, bomb disposal probably isn't for you! ヅ

raymond
Normal user
Normal user
Posts: 135
Joined: 2006-11-30 07:13
Location: Australia

Post by raymond » 2006-12-11 11:07

Hotlanta wrote: http://www.hmailserver.com/documentatio ... pair_mysql

Since this is a default install of MySQL that came with hMailServer, I tried to recover the password per the instructions. When doing this, the instructions tell me:

1. Run the script hMailServerAddonsUtilitiesDecryptBlowfish.vbs.
2. Open up hMailserver.ini, located in your Windows directory or hMailServer bin directory.
3. Copy the password from hMailServer.ini to the DecryptBlowfish dialog.
4. Click OK in DecryptBlowfish to view your password
http://www.hmailserver.com/documentatio ... pair_mysql
The howto shows 5 steps and not just the 4 you mentioned.

1. Run the script hMailServer/Addons/Utilities/DecryptBlowfish.vbs.
2. Enter your main hMailServer Administrator password. This is the password you specified during installation. Click OK.
3. Open up hMailserver.ini, located in your Windows directory or hMailServer bin directory.
4. Copy the password from hMailServer.ini to the "Enter encrypted password" dialog.
5. Click OK in DecryptBlowfish to view your password

User avatar
martin
Developer
Developer
Posts: 6834
Joined: 2003-11-21 01:09
Location: Sweden
Contact:

Post by martin » 2006-12-11 11:30

That's because I updated that part of the documentation early this morning. (This part of the documentation had not been updated for 4.3).

Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

Post by Hotlanta » 2006-12-11 15:14

Got a call at 8 am from my girlfriend. My mail is bouncing with "Remote host said: 550 Your message was received but it could not be saved." Lovely way to start the day. Went to the logs, and found another table has been corrupted. I'm not sure what the deal is, but this DNSResolver seems to be a precursor to both corruptions. Here's the place in the log where the table gets corrupted...

John

...
"ERROR" 1124 "2006-12-11 03:34:21.531" "Source: DNSResolver::_Resolve, Code: HM10081, Description: DNS query failure. Treating as temporary failure. Query: buildcomfort.com, Type: 15, DnsQuery return value: 9002."
"ERROR" 1124 "2006-12-11 03:34:21.531" "Source: DNSResolver::GetEmailServers, Code: HM10082, Description: Failed to resolve email servers."
"ERROR" 844 "2006-12-11 03:36:14.390" "Source: DNSResolver::_Resolve, Code: HM10081, Description: DNS query failure. Treating as temporary failure. Query: a1mortgageinc.com, Type: 15, DnsQuery return value: 9002."
"ERROR" 844 "2006-12-11 03:36:14.390" "Source: DNSResolver::GetEmailServers, Code: HM10082, Description: Failed to resolve email servers."
"ERROR" 2040 "2006-12-11 03:38:00.093" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185805, 'melissa_fiorillo@rmic.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:38:00.093" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{08F927AE-EFE5-4962-9538-7715134D6F43}.eml even though the message was not deleted."
"ERROR" 2060 "2006-12-11 03:38:21.750" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185806, 'melissabartlett@adelphia.net', 0, 1, 1, 0)")"
"ERROR" 2060 "2006-12-11 03:38:21.750" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{E75BE481-FF85-4CE0-93BA-74C34C08D49B}.eml even though the message was not deleted."
"ERROR" 2052 "2006-12-11 03:38:43.281" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185807, 'metromtg16@bellsouth.net', 0, 1, 1, 0)")"
"ERROR" 2052 "2006-12-11 03:38:43.281" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{731360A3-F77B-45ED-98F1-50E453860816}.eml even though the message was not deleted."
"ERROR" 2084 "2006-12-11 03:38:47.390" "Source: DNSResolver::_Resolve, Code: HM10081, Description: DNS query failure. Treating as temporary failure. Query: fairfaxrealtyinc.com, Type: 15, DnsQuery return value: 9002."
"ERROR" 2084 "2006-12-11 03:38:47.390" "Source: DNSResolver::GetEmailServers, Code: HM10082, Description: Failed to resolve email servers."
"ERROR" 2060 "2006-12-11 03:39:04.625" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185808, 'meyer@meyerfunding.com', 0, 1, 1, 0)")"
"ERROR" 2060 "2006-12-11 03:39:04.625" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{133CC35C-35EA-465D-899D-15F2E850FB3D}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:39:26.015" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185809, 'mfarris@flash.net', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:39:26.015" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{73D1666A-C05A-419B-A9FA-138408716889}.eml even though the message was not deleted."
"ERROR" 2052 "2006-12-11 03:39:47.359" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185810, 'mfarris@wcmlending.com', 0, 1, 1, 0)")"
"ERROR" 2052 "2006-12-11 03:39:47.359" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{F2DA0F50-CF9A-4D30-8864-407E226F3585}.eml even though the message was not deleted."
"ERROR" 2056 "2006-12-11 03:40:08.703" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185811, 'mfavorite@firststatefl.com', 0, 1, 1, 0)")"
"ERROR" 2056 "2006-12-11 03:40:08.703" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{9F17E910-7BD2-4818-914D-D4D4AE0B7E59}.eml even though the message was not deleted."
"ERROR" 2052 "2006-12-11 03:40:30.062" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185812, 'mfe1@earthlink.net', 0, 1, 1, 0)")"
"ERROR" 2052 "2006-12-11 03:40:30.062" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{4D0F00EF-0F87-4918-B311-CDC49B79B760}.eml even though the message was not deleted."
"ERROR" 2060 "2006-12-11 03:40:51.468" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185813, 'mfeske@ccmc-net.com', 0, 1, 1, 0)")"
"ERROR" 2060 "2006-12-11 03:40:51.468" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{8F8BFB06-C473-439E-9A04-D95A88BE8B4F}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:41:12.843" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185814, 'mfloyd@finfedmem.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:41:12.843" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{44479968-AB71-4F8A-AB84-8BEC0B9DF042}.eml even though the message was not deleted."
"ERROR" 2056 "2006-12-11 03:41:34.187" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185815, 'mford@amerfund.com', 0, 1, 1, 0)")"
"ERROR" 2056 "2006-12-11 03:41:34.187" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{C9AA33E2-59E3-4773-A96A-D68B6046F7A0}.eml even though the message was not deleted."
"ERROR" 2060 "2006-12-11 03:41:55.546" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185816, 'mfraga_elg@bellsouth.net', 0, 1, 1, 0)")"
"ERROR" 2060 "2006-12-11 03:41:55.546" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{BFD411CB-B92B-4E75-94FE-04B3F4BF0D62}.eml even though the message was not deleted."
"ERROR" 2056 "2006-12-11 03:42:16.906" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185817, 'mfritsch@talmanmortgage.com', 0, 1, 1, 0)")"
"ERROR" 2056 "2006-12-11 03:42:16.906" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{EC738E3C-ABC2-4902-B9AA-63B9086F47A5}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:42:38.296" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185818, 'mg@royalhq.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:42:38.296" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{D6CD7AB7-EC5B-44DF-A525-451C25CAB878}.eml even though the message was not deleted."
"ERROR" 2060 "2006-12-11 03:42:59.671" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185819, 'mgalvan@scme.com', 0, 1, 1, 0)")"
"ERROR" 2060 "2006-12-11 03:42:59.671" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{979B8D25-3FED-4958-8710-4D475B8DC06B}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:43:21.078" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185820, 'mgaston@pcmaz.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:43:21.078" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{1447AAEB-3661-4506-84C5-1F7955ECFD2F}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:43:42.437" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185821, 'mgerhard@fnbgermantown.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:43:42.437" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{82DB9018-4BF0-4AE2-B229-19A82D5AB0E5}.eml even though the message was not deleted."
"ERROR" 2056 "2006-12-11 03:44:03.828" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185822, 'mgibson@mdgibson.com', 0, 1, 1, 0)")"
"ERROR" 2056 "2006-12-11 03:44:03.828" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{815ADB19-52A0-430F-B660-7CAEC0DF8328}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:44:25.187" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185823, 'mglazer@mlnusa.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:44:25.187" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{F00B2FC2-3643-4C78-B939-34ABF3D6C571}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:44:46.546" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185824, 'mgoldhirsh@fcmdirect.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:44:46.546" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{575FDCC1-5D47-45F5-AF23-BE9B68253F87}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:45:07.937" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185825, 'mgoldman2@bsmfinancial.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:45:07.937" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{FE5D6D82-2FD7-4081-80F0-53D5FF0D78C2}.eml even though the message was not deleted."
"ERROR" 2052 "2006-12-11 03:45:29.296" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185826, 'mgoodwin@firsthorizon.com', 0, 1, 1, 0)")"
"ERROR" 2052 "2006-12-11 03:45:29.296" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{A3504AE5-BFE9-43E6-BD44-2DCEFEA30D36}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:45:50.671" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185827, 'mgr0178@alliedhomenet.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:45:50.671" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{C0168DEC-6B1B-4329-851C-804EA1E1F16C}.eml even though the message was not deleted."
"ERROR" 2056 "2006-12-11 03:46:12.062" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185828, 'mgr0446@alliedhomenet.com', 0, 1, 1, 0)")"
"ERROR" 2056 "2006-12-11 03:46:12.062" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{E5A371E7-0A24-4053-BFFC-768504A1532C}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:46:34.531" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185829, 'mgr0814@alliedhomenet.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:46:34.531" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{54F87B92-2F47-448D-B902-AF59A57F069F}.eml even though the message was not deleted."
"ERROR" 2052 "2006-12-11 03:46:55.968" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185830, 'mgr0859@alliedhomenet.com', 0, 1, 1, 0)")"
"ERROR" 2052 "2006-12-11 03:46:55.968" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{7CDDF943-BE1A-457F-AD7F-CF4D060E9C98}.eml even though the message was not deleted."
"ERROR" 2040 "2006-12-11 03:47:17.359" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185831, 'mgr1267@alliedhomenet.com', 0, 1, 1, 0)")"
"ERROR" 2040 "2006-12-11 03:47:17.359" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{F5792C73-EA32-4E8F-9F30-786C8A50847B}.eml even though the message was not deleted."
"ERROR" 2060 "2006-12-11 03:47:38.781" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185832, 'mgr1324@alliedhomenet.com', 0, 1, 1, 0)")"
"ERROR" 2060 "2006-12-11 03:47:38.781" "Source: PersistentAccountADO::DeleteFile, Code: HM10063, Description: Tried to delete the file C:\Program Files\hMailServer\Data\{DD2C90D4-6D5B-42B0-98DE-72BDA025305F}.eml even though the message was not deleted."
"ERROR" 696 "2006-12-11 03:47:59.640" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185833, 'leads@fsbohotsheet.com', 1, 0, 0, 0)")"
"ERROR" 2040 "2006-12-11 03:48:00.171" "MySQL: Duplicate entry '181222' for key 1 (Additional info: "INSERT INTO hm_messagerecipients (recipientmessageid, recipientaddress, recipientislocal, recipientisenabled, recipientisexisting, recipientlocalaccountid) VALUES (185834, 'mgr1349@alliedhomenet.com', 0, 1, 1, 0)")"
...

^DooM^
Site Admin
Posts: 13861
Joined: 2005-07-29 16:18
Location: UK

Re: MySQL File Corruption

Post by ^DooM^ » 2006-12-11 15:20

^DooM^ wrote:What version of hmail are you using?
I presume you are using the latest stable version? Did you upgrade from an older version or is this a fresh install?
If at first you don't succeed, bomb disposal probably isn't for you! ヅ

User avatar
martin
Developer
Developer
Posts: 6834
Joined: 2003-11-21 01:09
Location: Sweden
Contact:

Post by martin » 2006-12-11 15:29

Doubt the DNS errors are relevant...

Did you reapir the hm_messagerecipients able as well yesterday or was it only hm_messages you touched?

Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

Post by Hotlanta » 2006-12-11 15:34

Only the hm_messages.

Well I fixed the hm_MessagesRecipients, and it worked for about 5 minutes. Then it stopped accepting pop3 connections. I went back to the logs, and this is what I found:

"ERROR" 1896 "2006-12-11 08:33:38.312" "Source: DNSResolver::_Resolve, Code: HM10081, Description: DNS query failure. Treating as temporary failure. Query: equitablecorp.com, Type: 15, DnsQuery return value: 9002."
"ERROR" 1896 "2006-12-11 08:33:38.312" "Source: DNSResolver::GetEmailServers, Code: HM10082, Description: Failed to resolve email servers."
"ERROR" 2064 "2006-12-11 08:33:49.390" "Source: MySQLRecordset::GetStringValue, Code: HM4207, Description: An unknown error occured while reading value from recordset: messagefrom"
"ERROR" 2064 "2006-12-11 08:33:49.390" "Source: MySQLRecordset::GetStringValue, Code: HM4207, Description: An unknown error occured while reading value from recordset: messagefrom"
"ERROR" 2064 "2006-12-11 08:33:49.390" "Source: MySQLRecordset::GetStringValue, Code: HM4207, Description: An unknown error occured while reading value from recordset: messagefrom"
"ERROR" 2064 "2006-12-11 08:33:49.390" "Source: MySQLRecordset::GetStringValue, Code: HM4207, Description: An unknown error occured while reading value from recordset: messagefrom"
"ERROR" 2064 "2006-12-11 08:33:49.390" "Source: MySQLRecordset::GetStringValue, Code: HM4207, Description: An unknown error occured while reading value from recordset: messagefrom"
"ERROR" 2064 "2006-12-11 08:33:49.406" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 1844 "2006-12-11 08:33:49.421" "Source: SocketConnection::OnDataReceived, Code: HM4377, Description: An error occured while parsing data."
"ERROR" 1844 "2006-12-11 08:33:49.484" "Source: IOCPQueueWorkerTask::_ProcessIOAccept, Code: HM4337, Description: An unknown error occured while processing an IOAccept message"
"ERROR" 2064 "2006-12-11 08:33:49.500" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 2064 "2006-12-11 08:33:49.500" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 2200 "2006-12-11 08:33:49.515" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 1844 "2006-12-11 08:33:49.718" "Source: IOCPQueueWorkerTask::_ProcessIORead, Code: HM4374, Description: An error occured while appending the data buffer."
"ERROR" 1844 "2006-12-11 08:33:49.781" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 1844 "2006-12-11 08:33:49.796" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 1844 "2006-12-11 08:33:49.968" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 1844 "2006-12-11 08:33:50.156" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 1844 "2006-12-11 08:33:50.406" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 2496 "2006-12-11 08:33:50.453" "Source: DNSResolver::GetEmailServers, Code: HM10105, Description: An exception was thrown."
"ERROR" 2496 "2006-12-11 08:33:50.453" "Source: DeliveryTask::DoWork(), Code: HM4223, Description: SMTPDeliverer::DeliverMessage() failed"
"ERROR" 2064 "2006-12-11 08:33:50.796" "Source: SocketConnection::_PreParseASCII, Code: HM4378, Description: An error occured while parsing ASCII data."
"ERROR" 1844 "2006-12-11 08:34:31.781" "Source: SocketConnection::OnDataReceived, Code: HM4377, Description: An error occured while parsing data."
"ERROR" 1804 "2006-12-11 08:34:32.281" "Source: RecipientParser::CreateMessageRecipientList, Code: HM4381, Description: An error occured while creating message recipient list."

Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

Post by Hotlanta » 2006-12-11 15:39

The DNSResolver is linked to spam protection if I'm not mistaken. So I'm going to kill the following that's turned on:

Surbl
Spamhaus
SpamCop
dnsbl.net.au
cblabuseat.org
dnssbl.sorbs.net

I'll let you know if it starts behaving...

John

Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

Re: MySQL File Corruption

Post by Hotlanta » 2006-12-11 15:44

^DooM^ wrote:
^DooM^ wrote:What version of hmail are you using?
I presume you are using the latest stable version? Did you upgrade from an older version or is this a fresh install?
This is a fresh install using the default MySQL tables.

John

User avatar
martin
Developer
Developer
Posts: 6834
Joined: 2003-11-21 01:09
Location: Sweden
Contact:

Post by martin » 2006-12-11 15:57

At least something seems seriously broken in that installation, considering that both MySQL and hMailServer seems to misbehave in it.

How much memory is it in the server? Is it a new server or have it been used for other things before?

What anti virus software are you running on it?

Does it work now if you just restart the hMailServer service?

Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

Post by Hotlanta » 2006-12-12 17:43

martin wrote:At least something seems seriously broken in that installation, considering that both MySQL and hMailServer seems to misbehave in it.

How much memory is it in the server? Is it a new server or have it been used for other things before?

What anti virus software are you running on it?

Does it work now if you just restart the hMailServer service?
It's leased, so I'm not sure of it's history. When I got it, it was clean, and my impression is that they put it up for me. AV is not running. It's running 256 MB of memory, and seems to be working properly now since I turned off the anti-spam stuff.

Is 256 MB too little for this application?

iprat
Normal user
Normal user
Posts: 247
Joined: 2005-05-20 16:50
Location: Barcelona, EU
Contact:

Post by iprat » 2006-12-12 18:11

It could be that your memory is faulty but certainly not insuficient.

We ran for about 6 months without any issue with a P4 server that had just 256Mb and acted as hMailServer, web server (small traffic), file server for LAN with big traffic, and also workstation more than 50% of time. The server also ran ASSP and clamav antivirus for hMailServer.

IMO if you don't have hundreds of accounts it is very improbable you have a short memory problem, but I had once a memory failure problem and that gave a very disperse phenomena in many diferent applications.
My perfect combination:
hMailServer 5.6.1 (B2208), ASSP 1.3.3.8 (antispam), Clamav 0.98.6 (antivirus)

mbreitba
Senior user
Senior user
Posts: 340
Joined: 2006-04-14 22:25

Post by mbreitba » 2006-12-12 19:27

I would certainly suggest a lot more ram that 256MB. Even though Windows will start up and say that it's only using 90MB of RAM, it would certainly like to use more. I would increase your memory to 512MB or 1GB, and test in that configuration.

We've seen hundreds of problems over the years that can be directly attributed to not enough memory, even though it appears as though you have enough. Ram is cheap anymore, and there's no reason not to have enough installed.

Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

Post by Hotlanta » 2006-12-12 20:52

Task manager shows it after a reboot as being fine, but memory use slowly creeps up past the 350 MB range, so I suspect that could be an issue. I'm going to slowly turn back on spam checks to see if there's anything I can do at this point that's going to break things again. The error log only shows DNSResolver errors at this point.

User avatar
martin
Developer
Developer
Posts: 6834
Joined: 2003-11-21 01:09
Location: Sweden
Contact:

Post by martin » 2006-12-12 22:43

You may want to check the below page regarding a possible workaround to MySQL corruption. (Still a bit experimental though)


http://www.hmailserver.com/forum/viewtopic.php?t=6913

Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

Post by Hotlanta » 2006-12-13 16:35

In checking the error log this morning, I'm getting mostly DNSResover errors, however I did get a few episodes that I haven't seen before. I'm curious what may be causing these file writing errors.

"ERROR" 1944 "2006-12-13 05:50:53.625" "Source: TransparentTransmissionBuffer::_SaveToFile, Code: HM10012, Description: Failed to write to the file C:\Program Files\hMailServer\Data\{09D3EB93-D14F-4C28-BDB6-CFB3737CECA8}.eml. Data from sender rejected."
"ERROR" 2236 "2006-12-13 05:51:02.421" "Source: SMTPConnection::_OnPreAcceptTransfer(), Code: HM10013, Description: Rejected message because no mail data has been saved in file C:\Program Files\hMailServer\Data\{09D3EB93-D14F-4C28-BDB6-CFB3737CECA8}.eml"
"ERROR" 2236 "2006-12-13 05:51:41.609" "Source: File::DeleteFile(), Code: HM10025, Description: Could not delete the file C:\Program Files\hMailServer\Data\{09D3EB93-D14F-4C28-BDB6-CFB3737CECA8}.eml. Tried 5 times without success. Windows error code: 23 (Unknown)"

Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

Post by Hotlanta » 2006-12-13 16:44

martin wrote:You may want to check the below page regarding a possible workaround to MySQL corruption. (Still a bit experimental though)


http://www.hmailserver.com/forum/viewtopic.php?t=6913
Thanks. That looks like an excellent option, especially since I'm not likely to do anything more than MySQL seems to be able to do automatically for recovery purposes.

John

User avatar
martin
Developer
Developer
Posts: 6834
Joined: 2003-11-21 01:09
Location: Sweden
Contact:

Post by martin » 2006-12-13 16:46

Regarding the file writing errors. Are you suing a virus scanner on the computer which scans files "on the fly"? If so, it could be that the file contained a virus and that your virus scanner automatically removed it. That would lead tot he above error in the log.

Hotlanta
Normal user
Normal user
Posts: 46
Joined: 2006-12-04 20:46

Post by Hotlanta » 2006-12-13 20:06

martin wrote:Regarding the file writing errors. Are you suing a virus scanner on the computer which scans files "on the fly"? If so, it could be that the file contained a virus and that your virus scanner automatically removed it. That would lead tot he above error in the log.
No AV scanning is installed or running (planned to do that later). This is pretty much a virgin machine. hMailServer, SQLyog, and JMail Professional on top of Windows 2000 with all the updates and over 100 gb of disk space.

John

User avatar
martin
Developer
Developer
Posts: 6834
Joined: 2003-11-21 01:09
Location: Sweden
Contact:

Post by martin » 2006-12-13 20:11

The error you got occurs when hMailServer tries to open a file for appending. This should really never fail, unless the operating system tells hMailServer it can't write to that file. The error hMailServer got from Windows, 23, means ERROR_CRC Data error (cyclic redundancy check).

CRC errors while writing to disk occurs if the disk is broken or there is some problems with the drivers. (Other hardware problems and bugs in Windows can probably cause this as well). Run chkdsk to check your disk.

This is most likely the cause of your MySQL corruption as well. So guess MySQL can't be blamed for that one..

decipher
New user
New user
Posts: 11
Joined: 2006-05-12 22:32

Post by decipher » 2007-04-22 19:25

I had been having the same problem. What i finally came up with is that everytime a storm came through, and power was lost to building where the server was, the db was corrupted and i had to pull out a backup. Thats why i started using the external mysql setup cause you can repair those tables easily using sqlyog(free). We used to have an IMail setup for when we were using our domain for our business, but since no longer need it for that, but i wanted to keep my email address. So i went with hmailserver being that it was free, and personally i like it alot better than our old IMail server.

But since i'm rambling, yes if your server looses power, bam instant corruption of the internal DB. Can you fix it, prob, but i couldn't figure it. Hope this helps shed some light on the subject

^DooM^
Site Admin
Posts: 13861
Joined: 2005-07-29 16:18
Location: UK

Post by ^DooM^ » 2007-04-22 20:03

Hmm that is strange, I have lost power to my home server (Due to my 3yr old turning off the socket) a few times but never had a corruption (touch wood). The NTFS file system is supposed to prevent that from being an issue. If you were running on FAT32 then that would most likely be the reason in my opinion.

User avatar
martin
Developer
Developer
Posts: 6834
Joined: 2003-11-21 01:09
Location: Sweden
Contact:

Post by martin » 2007-04-22 20:18

In hMailServer 4.4, I've configured the internal MySQL installation to do auto-repair if a table corruption occurs.

But as ^DooM^ says, it sounds strange that it got corrupt on every server crash. My previous server crashed quite often without causing corrupt MySQL tables.

decipher
New user
New user
Posts: 11
Joined: 2006-05-12 22:32

Post by decipher » 2007-04-22 20:55

you know what, i don't recall if i had thought of that back when it was an issue, the whole fat32/ntfs. maybe that was the problem. I don't care which db i use as long as its reliable and i can repair it easily. We are using a new PC running winxp media center edition, so i prob just assumed it was ntfs, but it was an xp machine previously and i don't remember if i used hmailserver on that or just started with the new one. I'll check it out.

BTW on a different note; ^Doom^, nice lock pic, i play 1 on the new server Rivendare (horde) named Felfire

^DooM^
Site Admin
Posts: 13861
Joined: 2005-07-29 16:18
Location: UK

Post by ^DooM^ » 2007-04-23 01:50

OT: Heh thx, I got bored of my lock, Have lvl 60 Bloodelf pally now. Just about to hit outlands ;)

Post Reply