Operating System - HP-UX
1827801 Members
2276 Online
109969 Solutions
New Discussion

Ksh is locking an access to a table of application Sas

 
uadm26
Super Advisor

Ksh is locking an access to a table of application Sas

Hi, I have an ittanium system, HP-UX 11.13, and something it's appends, starting a process of a Sas application that will create a file and load data to him. But block with an error about an id process is locking that file, and that id is the ksh id.

SAS ERROR:
ERROR: A lock is not available for TESTE.TESTE.DATA, lock held by another process.
NOTE: The SAS System stopped processing this step because of errors.
WARNING: The data set TESTE.TESTE was only partially opened and will not be saved.
NOTE: DATA statement used (Total process time):
real time 1:15.51
cpu time 0.07 seconds
5 REPLIES 5
Mel Burslan
Honored Contributor

Re: Ksh is locking an access to a table of application Sas

This issue is a total application related one and I do not know anything about SAS but it sounds like your process, whne checking the ownership of a file lock, maybe missing the PID and getting PPID (parent process ID) instead and crying foul. Otherwise, I do not see any reason why ksh (unless you specifically try to open the file using vi or something for editing) should lock the file which is being used by another process.
________________________________
UNIX because I majored in cryptology...
Pat Lieberg
Valued Contributor

Re: Ksh is locking an access to a table of application Sas

You can try and take the pid of the ksh process and then compare it to the output of the whodo command. That might help find the culprit if its a child process of that ksh pid.
Pat Lieberg
Valued Contributor

Re: Ksh is locking an access to a table of application Sas

Thought of something else just as I hit submit, but you can also do an fuser -u on the file and that should show you who has the file locked.
Victor BERRIDGE
Honored Contributor

Re: Ksh is locking an access to a table of application Sas

Hi,
What version of SAS are you using?
By what I have seen of the product, it was designed to be used by one user ( nothing like oracle...) so in multi use environment if you have only (like most people...) just the base and some sophiticated stat modules... the easy way to have SAS work for each users is that each users have their own datasets.

You seem to have a file (a .sas7bdat ? ) opened by someone else. This cannot work in SAS...
If not, lets say you had a problem and got kick ed out of the box, you may have something like a stale session : you have some SAS files marked as opened (the lock hasnt been removed).
There is a SAS utility to clean such things but I am no SAS specialist...
If you really dont know what it is called then I will try to find out


All the best
Victor
uadm26
Super Advisor

Re: Ksh is locking an access to a table of application Sas

Hi,
the problem already is resolved. Was nfsktcpd that was blocking the accesses for tcp. After reboot to the server, Sas works fine.

Thanks for all.