DocMoto
Server
Embedded File Metadata Missing
The DocMoto server automatically extracts embedded metadata from files. This data primarily appears in the extended info section of a file's properties.
An issue can occur where this metadata fails to be extracted for all file types.
The resolution is to adjust the DocMoto server config file.
Adjusting the DocMoto Server Config File
- On the Mac running your DocMoto server open the Terminal app.
- Switch to a superuser by typing sudo -s followed by the superuser password.
- Open the bottom section of the DocMoto Server config file by typing tail -20 /var/opt/docmoto/settings/serverConfig.config
- Look for the line containing module="serverApiPlugins/libAddDocumentProperties.dylib" and take a look at the parameters section towards end of that line. If it reads parameters="change_to_port=3982" you need to edit it.
- To edit the line type vi /var/opt/docmoto/settings/serverConfig.config, this will open the config file in an editor. Navigate to the line mentioned above.
- Press i to insert text and change parameters="change_to_port=3982" to read parameters="port=3982".
- Press the esc key then type :wq. This will save the change and close the file.
- Back on the normal Mac interface select System Preferences find the DocMoto server and stop then restart it.
- Log back into DocMoto and drag in a file (image files make a good test). Highlight the file, expand the properties panel and check for extended info. It should now be present.
Replacing the Missing Data
The php script dmFixExif will replace the missing data. NB. You may need to unzip the script before using.
To use the script you will need direct access to the DocMoto server, you will also need root access to the underlying Mac.
To run the script
- You MUST backup your docmoto Postgres database before running the script.
- Copy the script to the host Mac server, the location is not critical.
- Using a code text editor such as Visual Studio Code (do NOT use TextEdit) set the $startDate and $endDate variables to match the missing data period.
- Open Terminal and login in as root using sudo -s.
- Navigate to the folder where you have placed the script and type php dmFixExif.php press Return and follow the instructions.