-
Notifications
You must be signed in to change notification settings - Fork 70
openHistorian FAQs
Disabling the statistics archive is not recommended as you may want to turn daily data quality reports on in the future that will be built upon this data. You can, however, move the files to a different folder and/or drive. This is usually as simple as changing the paths to locations related to "stat" files in the openPDC.exe.config file, see XML snippets below.
It is generally safest to use the "XML Configuration Editor" for changes to the configuration file; this tool will even automatically restart the service for you to apply changes. If you make changes to the XML manually, you must make sure the openPDC is not running before you save any updates to the file and backing up the file is recommended (note that using the XML Configuration Editor also makes a backup for you).
Important! You should setup a new folder with needed rights on the target drive before you make changes to the configuration file (see notes below XML snippet). The example below assumes you are moving files to the E:\
drive in an Archive\Statistics\
folder:
<statMetadataFile>
<add name="FileName" value="e:\Archive\Statistics\stat_dbase.dat" description="Name of the statistics meta-data file including its path."
encrypted="false" />
</statMetadataFile>
<statStateFile>
<add name="FileName" value="e:\Archive\Statistics\stat_startup.dat" description="Name of the statistics state file including its path."
encrypted="false" />
</statStateFile>
<statIntercomFile>
<add name="FileName" value="e:\Archive\Statistics\scratch.dat" description="Name of the statistics intercom file including its path."
encrypted="false" />
</statIntercomFile>
<statArchiveFile>
<add name="FileName" value="e:\Archive\Statistics\stat_archive.d" description="Name of the statistics working archive file including its path."
encrypted="false" />
</statArchiveFile>
The openPDC, by default, runs as the "NT SERVICE\openPDC" user which has security rights to very little, so the service will certainly not be able to write files into a new folder on a different drive until explicitly granted rights to do so.
For example, if you created a new folder on the E:\ drive called "Archive", you would need to right click on the folder an select "Properties" then click on the "Security" tab. Click the "Edit" button" then click "Add". Type in "NT SERVICE\openPDC" (without quotes) and the click the "Locations..." button then select the root computer node and click the "OK" button. You show now be back on the "Select Users or Groups" screen and you can click "OK".
The user "openPDC" should now be in the list. Select the openPDC user and make sure rights for "Modify" is checked, then click "OK" and "OK" again. Now the openPDC should have the needed rights to write new files into this folder.
Before restarting the openPDC with updated configuration changes you will want to move all of the existing files statistic files into the new folder, i.e., move C:\Program Files\openPDC\Statistics\*.*
to E:\Archive\Statistics\
.