are you directly editing the files and uploading the files (like using any FTP client) ??
few years back, I had a similar issue, I was editing the item_db and save, at the background it was uploading the file to the server.
however, I didnt realize that its still uploading, and I did a reloaditemdb command, everything become an apple, broken.
to fix that, I just re-save the item_db and have it re-upload to the server, wait for the progress to complete before do the reloaditemdb command.
* not sure if you're doing the same things i did tho.