Unable to kill a process, file locked

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
Lansha
Premium Member
Premium Member
Posts: 8
Joined: Thu Sep 13, 2007 11:19 am

Unable to kill a process, file locked

Post by Lansha »

First thank DataStage gurus here, helped me resovled a lot of issues, I am totally new to DataStage.
This is my first post here. Please help.

What happened was after I stopeed a job, I couldn't open a sequential file in target, here was what I did:

I stopped my job by clicking on stop button in Director.

Then I tried to open the target sequential file, it's said "The process cannot access the file because it is being used by another process".

So I opened Cleanup Resources in DataStage Director, the process show by job is:
PID Context User Name Last Command Processed
8236 Aggregator_14(Running) Transformer_1(Running) UserName Unavailable

I tried to use Logout, it couldn't kill the job.

On Job Resources locks, I clicked on Show All, no locks associated with this PID.

Then I telnet to the server, LOGTO UV account, then LIST.READU
There was no lock on this job, so I couldn't UNLOCK anything.

Then I used DS.TOOLS, interesting the option for Administer processes/locks is 4 instead of 5 people mentioned in this forum. But anyway, I chose option 4, then option 7 Clear locks held by a process, entered PID 8236, no lock on this process at all.

Then I ran PORT.STATUS, PID 8236 shows up as a phantom. Not sure how to kill this PID since our server is on Windows.

I searched through the forum, the experts here suggested to start the dsdlockd demeon, so I changed the dsdlockd.config file, put start=1, and restarted the DataStage Services. Acutally I restarted Services twice. First time just waited for 30 seconds, second time I waited for 15 minutes to start all DataStage Services. I can see dsdlockd.exe running through task manager.

Unfortunally the PID is still showing up on Job Resources, and I have no idea how to kill it.

The only thing I can think of is to restart the server, but I don't want to do this everytime there is a lock happening like this.

Please help!
ogmios
Participant
Posts: 659
Joined: Tue Mar 11, 2003 3:40 pm

Re: Unable to kill a process, file locked

Post by ogmios »

Why do you think another DataStage process is still using the file. Maybe something else on your system has your file open... I once searched weeks to find out my anti-virus did stuff like that as well :D

One thing you missed could also be ... translate the jobname to its internal number, and then do list_readu again to find the corresponding pid.
In theory there's no difference between theory and practice. In practice there is.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

If you have any of the UNIX utilities installed you could try doing a "fuser -fux" on the file to identify what processes have a file open. I don't think that the normal Windows utilities let you do that.
Lansha
Premium Member
Premium Member
Posts: 8
Joined: Thu Sep 13, 2007 11:19 am

Post by Lansha »

ArndW wrote:If you have any of the UNIX utilities installed you could try doing a "fuser -fux" on the file to identify what processes have a file open. I don't think that the normal Windows utilities let you do that.
Thanks for your suggestion. There isn't any UNIX utilities installed on the server, I will do more research on it. In the meantime, I did a server reboot, which released the lock on file.
Post Reply