Skip to main content

[archive] Transactional Coding Issue

  • April 24, 2009
  • 20 replies
  • 0 views

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?

20 replies

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
How is the data being accessed.. on Unix ... on Windows ... through AcuServer ... using mapped drives ... using Samba. If you are using anything other than AcuServer I suggest at least trying AcuServer to see if the locking issues go away.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
How is the data being accessed.. on Unix ... on Windows ... through AcuServer ... using mapped drives ... using Samba. If you are using anything other than AcuServer I suggest at least trying AcuServer to see if the locking issues go away.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
How is the data being accessed.. on Unix ... on Windows ... through AcuServer ... using mapped drives ... using Samba. If you are using anything other than AcuServer I suggest at least trying AcuServer to see if the locking issues go away.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Data is being accessed directly on the unix server using Thin-Client.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Data is being accessed directly on the unix server using Thin-Client.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Data is being accessed directly on the unix server using Thin-Client.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
I take it that you have changed LOCKS_PER_FILE as well?

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Are you setting MAX-LOCKS and LOCKS_PER_FILE in a configuration file?

If you are setting these in a program, put them into a configuration file.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Are you setting MAX-LOCKS and LOCKS_PER_FILE in a configuration file?

If you are setting these in a program, put them into a configuration file.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Are you setting MAX-LOCKS and LOCKS_PER_FILE in a configuration file?

If you are setting these in a program, put them into a configuration file.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
The limit is controlled by MAX_LOCKS If you do not specify this in the runtime config file it will mirror the MAX_FILES setting.
If you do set it, it is reccomended you set it to at least the same value as MAX_FILES but there is a Maximum limit of 8,191.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
The limit is controlled by MAX_LOCKS If you do not specify this in the runtime config file it will mirror the MAX_FILES setting.
If you do set it, it is reccomended you set it to at least the same value as MAX_FILES but there is a Maximum limit of 8,191.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
The limit is controlled by MAX_LOCKS If you do not specify this in the runtime config file it will mirror the MAX_FILES setting.
If you do set it, it is reccomended you set it to at least the same value as MAX_FILES but there is a Maximum limit of 8,191.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Dilbert if we use a SET ENVIRONMNET statement in the program it will not overwrite the values in the config file for MAX-LOCKS & LOCKS-PER-FILE?

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Thanks Dilbert with you hint we solved the issue. For some reason setting the environment variable inside the program with a SET ENVIRONMENT statement did not work. We put it at the system level in the CBLCONFIG file and everything is golden!!!

Thanks again.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Thanks Dilbert with you hint we solved the issue. For some reason setting the environment variable inside the program with a SET ENVIRONMENT statement did not work. We put it at the system level in the CBLCONFIG file and everything is golden!!!

Thanks again.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
Thanks Dilbert with you hint we solved the issue. For some reason setting the environment variable inside the program with a SET ENVIRONMENT statement did not work. We put it at the system level in the CBLCONFIG file and everything is golden!!!

Thanks again.

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
There are certain environment variables such as these that must be set in the cblconfig file because the runtime needs them set as it starts. I wish there were a list of those that couldn't be changed later. Anyone know of one?

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
There are certain environment variables such as these that must be set in the cblconfig file because the runtime needs them set as it starts. I wish there were a list of those that couldn't be changed later. Anyone know of one?

[Migrated content. Thread originally posted on 24 April 2009]

We have a set of transactional coding that start transaction, opens files, reads files, moves records, closes files & commits. We are getting a 9C-02 error in some cases of this logic but not in all cases. If we get the error we rollback all changes and that all works great so we are not messing up files.

I know that the error is a MAX-LOCKS error, we have increased the MAX-LOCKS environment setting from 500 to 9999 (and lots in between) and the error still happens at the same place every time.

Does anyone have any ideas on how or what to try to fix this issue?
There are certain environment variables such as these that must be set in the cblconfig file because the runtime needs them set as it starts. I wish there were a list of those that couldn't be changed later. Anyone know of one?