Overview
Kerio Connect is vastly deployed on MacOS, and this issue can happen every time a sudden reboot or an unexpected shutdown of the Mac system or a disconnection of the external storage drive occurs.
The steps outlined in this article can also be used if you simply want to remove any cached/stale disk mount points from your macOS that were created at some point in the past because of an unexpected shutdown.
Environment
Kerio Connect, all version, the issue is exclusive to MacOS systems.
Requirements
Admin/root access to the MacOS server.
Root Cause
Due to the way of MacOS handling storage, it creates virtual connectors called mount points. Upon an unexpected shutdown/reboot, it creates a false mount point, leading to the data to appear no longer visible, as the path to the actual storage drive has changed.
Resolution
-
Try reindexing the data from the web admin console > Users > More Actions > Reindex
-
If the above fails to fix the issue, it means that the external drive is mounted to a false mount point.
-
Bring up the Terminal console and input:
-
sudo -s
-
cd /Volumes
-
ls -l
-
-
If this shows 2 drives (Data and Data1), it means that the external drive is mounted to a false mount point, and that is why the data is missing or the server is not accessible.
-
Navigate to the false mailstore using the Finder app.
-
Perform a copy of the false mailstore to an external directory.
-
Make sure Kerio Connect server is stopped.
-
Eject the external drive.
-
Bring up the Terminal console and input:
-
sudo -s
-
cd /Volumes
-
ls -l
to make sure that the external disk is ejected (only Data is shown). -
rename current data drive:
mv Data KerioFalse
-
ls -l
to make sure the drive has been renamed.
-
-
Mount the external drive back using DiskUtil.
-
Merge the contents of the copied false mailstore folder with the contents of the correct one. It is required to rename all *.eml files to not conflict with those already existing (they start with 00000001.eml in each folder) and copy them over to target store.
-
WARNING: the copy option on MacOS in Finder application is actually a replace function, not merge function, so use SSH/Terminal.
-
-
Once done, you can run reindex for all user accounts from GUI, or rename all
index.fld
files toindex.bad
(do not delete them, just rename them). -
Start the Kerio Connect server.
Confirmation
The emails are visible in the accounts in webmail and other mail clients.