Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Set number of file locks

Status
Not open for further replies.

alayaho

IS-IT--Management
Feb 21, 2002
27
ID
Hi,

We recently set up a Unixware 7.1.1 server to run a multi-user application. During single user testing it seemed to run fine, but during our first run with many users (around 19) we got errors regarding file locks. The majority of the error messages stated "No Locks Available".

How do file locks work, and how can I check what our current settings are (and how many are used / available)? How do we set the maximum number of locks available?

Also, are there any good sample scripts using netcat to print? I found a lot, but I think they are based on a different original script. When I try to follow the changes they make, I cannot find the appropriate line in the script.


Thanks
 
"sar -v" (check the man page, I might be wrong) will show locks, but I'm surprised that is a problem because I thought that was autotuned. Anyway, if you can't increase it through Scoadmin->System Tuner, use "idtune"

As to netcat, the concept is the send the output through it. The minimalist script is:


shift; shift; shift; shift; shift
# throw away everything but the file names
cat $* | netcat -h printer -p 9100



Tony Lawrence
SCO Unix/Linux Resources tony@pcunix.com
 
Hi Tony,

I tried sar -v, but it just returned the UnixWare version we're using and the date (same as running sar with no options). I checked the man page, and it also states that the -v option should return lock statistics.

Any ideas why this is happening?

How do I enable auto-tuning, or set its parameters?


Thanks
 
I also forgot to add that when using idtune, I didn't know the name of the lock variable. What is the variable name and how can I get a list of parameter tunable using idtune.


Thanks
 
You probably ran sar right after booting, so there was nothing to show yet.

Run it like this:

sar -v 5 5

which will give 5 samples 5 seconds apart (see for more on sar)

Locks is probably FLCKREC; I don't have a UW machine here to look at but you can look at /etc/conf/cf.d/mtune, and EVERY tunable parameter is discussed in the "tunables" section of your on-line docs. It probably defaults to a couple of hundred locks; since it pronbably doesn't use up much memory, you could increase it qquite a bit- but do check the docs- they'll tell you recommended maximum values.

BTW, I'd be surprised if that is not in the System Tuner..





Tony Lawrence
SCO Unix/Linux Resources tony@pcunix.com
 
I did find the FLCKREC in the system tuner, and its set to 300. I read somewhere (Caldera site I think) that values can range from 100 to 2000. What I wanted to do is to get Unixware to allocate locks as necessary. Most people I've asked (including yourself) seem to think that this should be auto-tuned. Is this so, and how can I do this?


Thanks
 
Hi Tony,

I tried tuning the parameter, but now the software does not work at all. How do I restore the system to its previous state (old kernel, etc)? I don't think this is the problem, but I can't see what else went wrong.


Thanks
 
Just in case anyone has worked with DataFlex on Unixware before, the error message is:

Cannot Open User Count .DFR File <<STATUS 28692>>

Would appreciate any advice.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top