ETL task not working when running as a service

Issue

When creating the ETL task the "Run Once" works, but when configured to run as a service, it doesn't work and an error occurs.

Here is an example of what you will see in the error log:

2015-05-22 17:13:59,069 ERROR ETLEngine (TaskName) - Thread ID (119) - Power Monitoring Expert Load Task: Task Power Monitoring Expert Load Task failed
System.ApplicationException: Failed to populate the MetaDataSet. ---> System.Data.SqlClient.SqlException: Cannot open database "ION_Data" requested by the login. The login failed.
Login failed for user 'NT AUTHORITY\SYSTEM'.

Product Line

SmartStruxure Solution

Environment

  • Power Manager
  • ETL

Cause

  1. When testing the ETL task using "Run Once", the Windows account you are currently logged in with will be used to access the SQL database. When the task is then configured to run as a service, the account configured on the service will be used. By default that account is the built-in account 'NT AUTHORITY\SYSTEM'.
     
  2. The Position values for all of the mapped trend logs are set to an unreasonable timestamp. The timestamp is either very old of a data the proceeds the oldest values in the database. 

Resolution

Changing the Windows system account for the ETL service

You can either give the system account access to the database, or you can change the account used to run the service.


Correct/Adjust the timestamp values in Positions tab of ETL

The timestamps can be changed all at once by setting the Intital value field at the top of the "Positions" window in the ETL tool.