Write DB metadata to file.  Much faster.