Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am currently experiencing an issue while scheduling the Repctl command embedded in a batch file through Task Scheduler, as well as using the PowerShell script.
repctl -d "F:\Replicate\data" connect; gettaskstatus TSK_PROD_REPL ; disconnect;
When running the batch file and PowerShell script individually as an administrator, they both execute successfully. However, when scheduling them through Task Scheduler with a Service account, I encounter the following error:
REPCTL initialization - failed to initialize environment (status 1000196)
Hi @jyeragi
Can you please open a support case for the same
Thank you
Avidar
This error is 99.9% sure to be cause by a security issue for the username (that service account) trying to acitvate repctl. That in turn is most likely caused by lack of access permission to mk.dat.
I do not think a support case is needed. There is nothing wrong with Replicate. It tries to open a file and cannot due to the permission configuration on the server.
Ask your server support team! Ask them whether that service user can currently access mk.dat and how to make that possible.
Hein.
Hello @jyeragi ,
Totally agree with @Heinvandenheuvel . Try to change the service "Qlik Replicate Server" property "Log On As" from "Local system account" to "Administrator" account and restart the service.
Hope this helps
John.
Thank you @Heinvandenheuvel
Yes. I understand that it is a security issue but I did not find any documentation about what permission or security needs to be added.
let me check if the service account can access the mk.dat file. I was able to resolve the issue with another service account but I don't want to give an elevated account to the account and hence, looking for specific permission to be granted.
-Jayesh
Thanks @john_wang
I was trying to move away from system or administrator to a more specific service account with specific permissions...
As specified by @Heinvandenheuvel , let me check if granting access to the mk.dat file resolves the issue.
-Jayesh
Dear @jyeragi ,
The error message indicates that the initialization of the ‘ENCRYPTION_CLASS’ failed.
Thew issue could be related to the permissions of the Service account used to run the Task Scheduler. When you run the batch file and PowerShell script individually as an administrator, they execute successfully because the administrator account has the necessary permissions.
The error log suggests that there’s a failurre to read the server password and open the file mk.dat. This could be due to the Service account not having the required permissions to access this file or read the server password.
As a resolution, you might need to ensure that the command prompt is run as an administrator.
Right-click on the Command Prompt and click ‘Run as administrator’. This should provide the necessary permissions for the task to execute successfully.
If the issue persists, it would be beneficial to check the permissions of the Service account and ensure it has the necessary access rights.
If you found our response useful, we kindly ask you to click on “Accept as Solution”. This will aid other users in finding the answer more effortlessly.
Thank you! 😊
Best Regards,
Deepak