Kerio Connect Mailserver.cfg warning


2013/06/05

Let's start by saying that I consider this to be a bug. Kerio tech support says it is "expected behavior". Either way, this is something you need to be aware of.

Here's the issue: under some circumstances, if your operating system crashes, you may end up with an empty "mailserver.cfg" file. The "mailserver.cfg" file contains the major part of your configuration. Kerio Connect can't run without it, and therefore will refuse to start upon reboot.

If you look in the directory where "mailserver.cfg" lives, you'll also find mailserver.cfg.bak. You might reasonably assume that is a backup of your configuration, and it is, but IT IS NOT NECESSARILY A CURRENT BACKUP.

If you experienced a crash that left you with a zero length "mailserver.cfg" file, you might naively assume that a quick copy of the .bak file over the empty file would fix you up. It might, but it might not.

The .bak file is only copied from mailserver.cfg upon a server restart.

Think about that. When was the last time you restarted your mailserver? I know that I restarted mine a few days ago, but that was because I did an upgrade. I don't know when I restarted before that!

If I made changes to my configuration since that upgrade, those changes are NOT in the .bak file. If I simply copied the .bak, I would not have my changes. I may not even remember what those changes were if my last restart was months ago!

Should you experience this problem, you need to recover from backup. As explained at the "kmsrecover" documentation, you'd use "./kmsrecover -m cfg" to do that.

Expected behavior?

First, I hardly think it's expected that an operating system crash should cause Kerio to create a zero length mailserver.cfg file. There may be some circumstances where that's unavoidable; for example if the computer crashed just as configuration changes were about to be written. However, under any other circumstances, I'd call that behavior a bug.

I also wonder about the purpose of the mailserver.cfg.bak file. As noted, this is a copy of mailserver.cfg as of the last restart. Under what circumstances would that have any value?

The only circumstance I can think of is where you managed to mess things up so badly that you cannot restart. That would be more than unusual, wouldn't it? I can't think of any other case where that .bak file would have any value.

I think it would make much more sense if the .bak file were written when the administrator logs out (or is logged out due to inactivity). That would make it reflect the most recent changes.

What can you do?

Because Kerio considers this expected behavior, it's not scheduled to be fixed any time soon. There is a feature request at "Automatic backup of mailserver.cfg or option to backup JUST configuration files". You can access that site from the "Suggest idea" link in your configuration Dashboard and add your vote.

Should you actually experience this issue, use kmsrecover as explained above or contact me for assistance.



Got something to add? Send me email.





(OLDER) <- More Stuff -> (NEWER)    (NEWEST)   

Printer Friendly Version

-> -> Kerio Connect Mailserver.cfg warning


1 comment



Increase ad revenue 50-250% with Ezoic


More Articles by

Find me on Google+

© Anthony Lawrence







Wed Jun 5 15:49:38 2013: 12106   TonyLawrence

gravatar


I thought this was obvious, but a few people have asked "What should we do?"

You don't have to DO anything other than being aware of this - knowing that the .bak file can be out of date is what you need to know.

As to DO, you might want to copy the mailserver.cfg file (or all *.cfg if you want) somewhere safe after making any changes, as copying it back is quicker and easier than running kmsrecover (should it ever be necessary).

Otherwise, use kmsrecover.

------------------------
Kerio Connect Mailserver

Kerio Samepage

Kerio Control Firewall

Have you tried Searching this site?

Unix/Linux/Mac OS X support by phone, email or on-site: Support Rates

This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more.

Contact us





A man can be destroyed but not defeated. (Ernest Hemingway)

What worries me about religion is that it teaches people to be satisfied with not understanding. (Richard Dawkins)







This post tagged: