Unable to unlock jobs in v8

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

bcarlson
Premium Member
Premium Member
Posts: 772
Joined: Fri Oct 01, 2004 3:06 pm
Location: Minnesota

Unable to unlock jobs in v8

Post by bcarlson »

We are having increasing problems with locked jobs in v8.0.1.
Unable to open the Job.

The Job 'dly_ddatran_dtl_src_import' is locked by user 'carlb0x'
(SessionID '36642854-233B-4B1F-AAE5-49DDC6FB3A84)
The process we used in the past with v7 does not appear to work, at least not consistently:
  • 1. Open DS Director and go to Job/Cleanup Resources
    2. Click 'Show All' in the Processes window and select the userid in question.
    3. Click the 'Show by Process' in the Locks window to see what project is affected by the user process
    4. Repeat steps 2 and 3 until you identify the process that holds the lock for you project/job. When you find the process that touches the project in question, click Release All.
    5. Reselect the process in the Processes window and click Logout.
    6. Click Refresh and validate that the process has been removed.
This has worked consistenly in v7, but not so well in v8. As I understand it, there is a session manager of some sort on the Web app, right? What permissions/roles are needed for a user to unlock jobs/sessions from there? What are the steps required to unlock it? The reason I ask is that it seems there is a specific order in v7 to release them correctly, do we have a similar situation in v8?

If there is a good reference in the documentation, let me know.

Thanks!

Brad
It is not that I am addicted to coffee, it's just that I need it to survive.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Go to the Web Console for Information Server. On the Adminstration tab open the twisty for Session Management and choose Active Sessions. In the grid on the right find the session ID from the error message and select that session via its option button. Then, in the menu on the right, choose Disconnect to disconnect that particular session, if you are sure that it is no longer an active session. This will also release any locks held by that session.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
bcarlson
Premium Member
Premium Member
Posts: 772
Joined: Fri Oct 01, 2004 3:06 pm
Location: Minnesota

Post by bcarlson »

Hmmm... I tried that and I can see other sessions, but I cannot find the one in question. I checked on Unix and all of my sessions are gone.

What do we do if we can't find the session? Did my initial steps screw it up, or is there something else going on?

Is this the only way to remove locked jobs? The reason I ask is that in v7, the owner of a session could release their own lock via Director and the steps I listed before. It looks like this method requires admin access. Or can anyone do it, but they can't affect someone elses sessions?

Questions, questions, questions. :)

Brad.
It is not that I am addicted to coffee, it's just that I need it to survive.
bcarlson
Premium Member
Premium Member
Posts: 772
Joined: Fri Oct 01, 2004 3:06 pm
Location: Minnesota

Post by bcarlson »

Never mind, answered part of my own question. I logged in with an id that did not have the admin rights and could not even see the session mangement option. :(

With more and more developers on our system, I don't want to have to have someone on call just to unlock jobs. How have other shops managed this? A few people onshore and few offshore with admin access to fix this?

Brad
It is not that I am addicted to coffee, it's just that I need it to survive.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Would you like to experiment with the product role DataStage Administrator (issued from Web Server Console) to see whether this user can release locks relating to DataStage or whether one needs to be a suite administrator? I'm on a single user system at the moment, and don't really have the time to set up locking scenarios.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
bcarlson
Premium Member
Premium Member
Posts: 772
Joined: Fri Oct 01, 2004 3:06 pm
Location: Minnesota

Post by bcarlson »

I'll need to do some experimenting later. We have some other issues going on and have had to bounce our server and apply some OS patches. But get this - the whole Unix server was bounced and DS was brought back up and the job is STILL locked. That doesn't make sense...

Brad
It is not that I am addicted to coffee, it's just that I need it to survive.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Isn't that because the "locks" are records in the XMETALOCKINFO database table?
-craig

"You can never have too many knives" -- Logan Nine Fingers
lstsaur
Participant
Posts: 1139
Joined: Thu Oct 21, 2004 9:59 pm

Post by lstsaur »

Yes exactly. In my shop I have a DB trigger to clean them up automatically.
bcarlson
Premium Member
Premium Member
Posts: 772
Joined: Fri Oct 01, 2004 3:06 pm
Location: Minnesota

Post by bcarlson »

lstaur - Can you pass on the trigger?

All, we did finally get the jobs unlocked thanks to the cleanup_abandoned_locks.sh program (see Adding new Folders in a new Project impossible).

Does anyone know what this program actually does? We'd love to understand it better - may give us insight into how to reduce or prevent the locking to begin with.

Brad.
It is not that I am addicted to coffee, it's just that I need it to survive.
lstsaur
Participant
Posts: 1139
Joined: Thu Oct 21, 2004 9:59 pm

Post by lstsaur »

Brad,
Didn't you say that you don't want to have someone on call just to unlock jobs? You need to utilize the database triggers to do the "unlock jobs" on 24x7 automatically.
bcarlson
Premium Member
Premium Member
Posts: 772
Joined: Fri Oct 01, 2004 3:06 pm
Location: Minnesota

Post by bcarlson »

What triggers? Are these triggers that you or your DBA created or do they come with DataStage/WAS? I think this is exactly what we need, but I am not sure where to find the details about the triggers. Can you point us in the right direction?

Thanks!

Brad
It is not that I am addicted to coffee, it's just that I need it to survive.
toshea
Participant
Posts: 79
Joined: Thu Aug 14, 2008 6:46 pm

Post by toshea »

Locks are stored in the XMETALOCKINFO table. When a session terminates cleanly, the locks belonging to that session are removed from the XMETALOCKINFO table. If a session is not terminated cleanly because you killed the Designer client or the whole server went down without shutting down the WAS cleanly, then locks remain in the XMETALOCKINFO table that belong to sessions that no longer exist. The cleanup_abandoned_locks.sh script checks for locks that don't belong to active sessions and it removes them.
lstsaur
Participant
Posts: 1139
Joined: Thu Oct 21, 2004 9:59 pm

Post by lstsaur »

Brad,
Triggers don't come with IIS. It seems like that you don't have the authority to create the triggers. Then, you should work with your Oracle DBA to create this trigger for you.
bcarlson
Premium Member
Premium Member
Posts: 772
Joined: Fri Oct 01, 2004 3:06 pm
Location: Minnesota

Post by bcarlson »

Do you have copies of the triggers that you can post or send to me or pseudo-code? I am guessing I am not the only one interested in those!

We are using DB2 for our repository. We can convert them as needed, and I can forward it to our DBA group.

Thanks!

Brad.
It is not that I am addicted to coffee, it's just that I need it to survive.
lstsaur
Participant
Posts: 1139
Joined: Thu Oct 21, 2004 9:59 pm

Post by lstsaur »

Brad,
Show the following trigger (Oracle) to your DB2 DBA:

CREATE OR REPLACE TRIGGER TRIG4Brad
AFTER INSERT
ON XMETA.XMETALOCKINFO
BEGIN
DELETE FROM XMETA.XMETALOCKINFO;
END TRIG4Brad;
/
Post Reply