Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
priyarane
Specialist
Specialist

QMC task

Hello Community, For only one document I am getting the below QMC error and for rest of them no failures.

 

Error: The task "Dashboard" failed. Exception: || QDSMain.Exceptions.TaskFailedException: Task execution failed with errors to follow. ---> QDSMain.Exceptions.WritePermissionkException: Failed to get write permission for file: \Dashboard.qvw ---> System.IO.IOException: The process cannot access the file '\Dashboard.qvw' because it is being used by another process. || at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) || at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) || at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access) || at QDSMain.AbstractReloadTask.CheckWritePermissionForFile(String fileName) || --- End of inner exception stack trace --- || at QDSMain.AbstractReloadTask.CheckWritePermissionForFile(String fileName) || at QDSMain.AbstractReloadTask.Reload(String fileName, IExecutingTaskResult executingTaskResult, String sectionAccessUserName, String sectionAccessPassword, eReloadOptions reloadOption, String variableName, String variableValue, Boolean moniterCpuUsage) || at QDSMain.DistributeTask.PerformExecute(IExecutingTaskResult executingTaskResult) || --- End of inner exception stack trace --- || at QDSMain.DistributeTask.PerformExecute(IExecutingTaskResult executingTaskResult) || at QDSMain.Task.AbstractTask.TaskExecution(CurrentExecutionArgs args)

 

 

Can you please over here.

 

_Priya

11 Replies
hopkinsc
Partner - Specialist III
Partner - Specialist III

Does the reload work when running from the QV client?

Brett_Bleess
Former Employee
Former Employee

It appears the QVW associated with that task could not be opened with the file lock, so we would be able to write the updated info back out post reload, which means some other task or process on the server had the file lock.  These can be tricky to figure out, but the obvious thing we ask folks to check is if Anti-virus or any other 'active scanning' tools are running on the servers, and if so, we recommend excluding our directories from those tools to avoid these situations from occurring.  Scans can be done during maintenance windows when the Qlik services are offline etc. at that point.  

To Chris' point though, if you have the Script logs enabled on this app, I expect you got no script/document log in this case, which would confirm we could not open the QVW to do the reload, and the trick is figuring out why the file was in a locked state such that we were not able to open for reload.  Sorry, I have not stated things very clearly here, but hopefully this makes a little sense.

Microsoft SysInternals Process Monitor can be used in these cases if you catch things to try to see what process has the lock etc.  

Oh, just thought of a workaround as well, you could bump up the 'Retries' setting on the Task to more than 1 in this case, that way if this file is sometimes locked, having things retry a few times, hopefully we may be able to always get the lock on a subsequent try and successfully complete things.

Cheers,
Brett

To help users find verified answers, please do not forget to use the "Accept as Solution" button on any post(s) that helped you resolve your problem or question.
I now work a compressed schedule, Tuesday, Wednesday and Thursday, so those will be the days I will reply to any follow-up posts.
priyarane
Specialist
Specialist
Author

Reload is not happening, failed

priyarane
Specialist
Specialist
Author

thanks for the reply, Doc log is not creating for this document. We have many documents over there in the same folder and those are running fine without an issue.
hopkinsc
Partner - Specialist III
Partner - Specialist III

if you make sure the doc logs are enabled for the QVW in question, then try running a manual reload. If no log is created then this confirms the answer that Brett provided. Is there section access on the QVW? 

hopkinsc
Partner - Specialist III
Partner - Specialist III

What if you copy and paste the QVW, the copied version shouldn't have a lock on it (if that's the cause) , you can then test the reload on that one.

 

Are all of the QVWs in the same folder? i.e. are working QVWs in the same folder as the non working QVW? if they are in different folders then you could also try and move it to a folder that has a working QVW (if it doesn't mess up any data locations) and try and reload from there. That will rule out any issues with folder permissions.

 

Has the reload EVER worked from the QMC?

priyarane
Specialist
Specialist
Author

It comes sometimes only for ex if this job runs 10 times then we may get 2 to 3 times
hopkinsc
Partner - Specialist III
Partner - Specialist III

That sounds like its being 'locked' by something if its not every time., as Brett suggested. i would check things like anti virus like he said, make sure the Qlik directories are excluded. it might be that something is happening to that file at the same times the reloads  are failing. 

priyarane
Specialist
Specialist
Author

IT support guys don't agree on it 🙂 as other jobs are not failing from the same folder. Only difference on this dashboard is we have bookmarks on Document and webpage as well.