cancel
Showing results for 
Search instead for 
Did you mean: 

SAP ENQ process

Former Member
0 Kudos

Hi all

We are running occasionally into deadlocks in our ECC 6.0 System.

As per the SAP cursor cache we barely use all DIA Wps across all 4x instances that we consist of.

We already considered the number range buffering but due to legal requirements we cannot fully implement this.

We are running on an SAP EC 6.0 SPS11 System on HP-UX with 4 instances consisting of 3x APP Server and 1x DB (CI) based on Oracle 10.2 with around 5000 global users.

On our CI we do have 2x ENQ processes.

I just recently heard that having >1 ENQ (in our case 2x ENQ) could be a cause of deadlocks

The question I would have to the community is how many ENQ processes do you have in your SAP Systems?

I would be eager to hear of large SAP installations that consist of many ENQ WPs

I appreciate all feedback on this topic

best regards

Nesimi

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Thanks for the good tipps

I just got the advise to configure our DB/CI (ECC 6.0) to work with zero SPO WPs and to change those SPO WPs to become DIA WPs.

We are running an SAP System with 4 Instances. 3x APP Server are running with DIA/SPO/BGD/UPD2 WPS and our CI is currently running with:

DIA = 15

UPD = 10

ENQ = 2

BGD = 4

SPO = 5

UPD2 = 2

Planned:

DIA = 20

UPD = 10

ENQ = 2

BGD = 4

SPO = 0

UPD2 = 2

I do remember reading that it is mandatory to have at least one SPO WPs per SAP System. But does that apply per Instance as well?

regards

Nesimi

Former Member
0 Kudos

You do not need SPO on every system, the dispatcher will just send somewhere else but I would recommend it if there is any mass printing going on.

However...... dropping from 5 SPO to 0..... I hope you have appreciation for the spool output at busy times and the implications of a dispatcher queue overflow--- i.e ensure you have enough SPO WP's elsewhere so many spool requests do not queue up

Former Member
0 Kudos

Hi,

On a very update intensive SAP R/3 4.7 system we had to increase the number of ENQ processes from 1 to 2. The performance is now much better with these 2 ENQ processes : The Maximum Fill Level of the Enque Statistics decreased a lot (SM12 --> Extras --> Statistics)

SAP tells in a note that more than 1 ENQ process is only needed on very busy systems.

Regards,

Olivier

Former Member
0 Kudos

I have dealt with quite a few systems with 3 ENQ work processes. Never seen a deadlock based on ENQ, even supporting the BC_CST_EQ component for 3 years at SAP.

Using SM51 to see if there are enqueues queueing is the simplest way to see if you have a bottleneck.

Analyzing various enqueue stats in SM12 statistics also give a good idea and these can be seen over time in RZ20/RZ23N. The number of failed enqueues can start to shoot up very quickly when a nasty lock is held for a while and this can even be alerted on.

One more point just of geeky interest. If you only have a central instance (no ASCS either), you do not need an ENQ WP. And before anyone feaks out, look it up in SAP help. Local Wp's read the lock table directly rather than via the ENQ wich is why you may see some odd stats on a CI.

Edited by: Graham Newport on Jun 13, 2008 1:06 AM

Former Member
0 Kudos

Hi,

>One more point just of geeky interest. If you only have a central instance (no ASCS either), you do not >need an ENQ WP. And before anyone feaks out, look it up in SAP help. Local Wp's read the lock table >directly rather than via the ENQ wich is why you may see some odd stats on a CI.

Do you refer to this sentence from SAP help ?

>The work processes on the central instance have direct access to the lock table functions. This means >that they do not have to send their lock requests via the dispatchers and message server.

I'm not sure to understand that it means you can have no ENQ process.

Regards,

Olivier

Former Member
0 Kudos

oh the doubters. lol

It looks like it is a bit less clear in the help as releases move on. 640 it was a bit plainer.

If you look under Frequently asked Questions: Lock concept

Question

Why is an enqueue work process required in a central system? Don't all work processes have the same access to the shared memory and thus to the lock table?

Answer

Although the enqueue process is not used in a central system, it does not do any harm. Since almost all customers install an application server sooner or later, problems will inevitably arise if the enqueue process is missing. For this reason, the enqueue diagnosis function will output an error if an enqueue process has not been configured.

There you go.... it is inevitable.... but only if you have app servers. The question has the reason why. Central Wp's have direct access to the lock table.

regards

Graham

Former Member
0 Kudos

I just tried to start an instance without enqueue wp, it didn't start at all:

M  ThSetEnqName: rdisp/enqname  = >host1_SID_01< not found in server list
M  ThSetEnqName: set enqname by profile
M  ThISetEnqname: enq name = >host1_SID_01                       <
M  *** ERROR => ThSetEnqName: enq server without enq wps, shutdown server [thxxtool.c   5235]
M  ***LOG R1P=> ThSetEnqName, bad enq configuration () [thxxtool.c   5238]

I agree with the direct access on the central system, it is a good point, but if anybody is able to start a system without any enqueue processes, then let me know how.

Best regards

Michael

Former Member
0 Kudos

Hi Graham,

Thanks for the explanation.

So, on a system with only a CI and no app server, the ENQ process is mandatory but not used...

It seems to me a precaution from SAP for the future installation of app servers !

Regards,

Olivier

Former Member
0 Kudos

Yep, I guess I can understand the precaution, and nowadays the extra RAM and CPU cycles don't come to much

regards

G

Former Member
0 Kudos

Michael,

have you tried starting it after disabling the parameter first?

regards

Graham

Former Member
0 Kudos

have you tried starting it after disabling the parameter first?

it = what?

parameter = which one?

I set rdisp/wp_no_enq = 0 and stopsap / startsap, then the workprocesses terminate because there is no enq process.

Best regards

Michael

Former Member
0 Kudos

This is your error, have you tried commenting out rdisp/enqname because that is what it is complaining about

M ThSetEnqName: rdisp/enqname = >host1_SID_01< not found in server list

M ThSetEnqName: set enqname by profile

M ThISetEnqname: enq name = >host1_SID_01 <

M *** ERROR => ThSetEnqName: enq server without enq wps, shutdown server [thxxtool.c 5235]

M ***LOG R1P=> ThSetEnqName, bad enq configuration () [thxxtool.c 5238

regards

Graham

Former Member
0 Kudos

Ahh, ok, now SAP is starting without enqueue process. But there is no enqueuing at all now. The syslog is full of errors.

13:01:31 DIA 002 000 SAPSYS GJ 0 Incorrect lock handler configuration

13:01:31 DIA 002 000 SAPSYS GZ Z > rdisp/enqname undefined= enxxhead1398

13:01:31 DIA 002 000 SAPSYS GI 0 Error calling the central lock handler

13:01:31 DIA 002 000 SAPSYS GI 2 > Unable to reach central lock handler

13:01:31 DIA 002 000 SAPSYS GI 4 > Dequeue All call failed

13:02:14 DIA 001 570 MHO SM12 GE H Enqueue: Transfer error while reading lock entries

13:02:14 DIA 001 570 MHO SM12 GE H Enqueue: Transfer error while reading lock entries

13:02:14 DIA 001 570 MHO SM12 GZ Z > Destination:

13:02:14 DIA 001 570 MHO SM12 GZ Z > ENQUE_READ exception code: 8

I remember that i also had this while setting up a standalone enqueue services (ASCS instance). If you operate a multiuser system like this you will certainly end up having severe inconsistencies. I am still fully convinced you cannot have a SAP system without enqueue process.

BTW: to have an instance without spool workprocess is not a problem, just make sure you don't only run the CI without having any spool workprocess. If you have them only on the app servers, then you need at least to have one of them up and running.

Regards

Michael

Former Member
0 Kudos

yes yes,

in the 640 help it said it is fine to run like this, you will get loads of syslog messages but nothing is damaged... it is just SAP being forceful. My original point however was to make people understand that in a single instance system, statistics against the ENQ WP may look a little slim because it is not being used

As you are still 'fully convinced' I will see if I can drag out a copy of the 640 that mentions this.... also the 7.0 help does say the same thing and it is clear you do not believe the SAP developers then :)... look, it is theoretical. The messages are such a pain that you should not, but as long as the lock table is local you are fine.

Former Member
0 Kudos

I had another look, I tried to set a lock, you can for example just call transaction DB13, and you can normally see the lock in SM12. Without enq process there is no lock and cannot switch to edit mode. So i cannot get inconsistent, but i cannot work at all.

Could not lock planning table SDBAP - Only display possible

Regards Michael

Edit: however i fully agree to the slim usage issue, on a one instance SAP system, the enqueue process is not doing a lot, and there is almost certainly no need to have multiple enqueue processes.

Edited by: mho on Jun 20, 2008 1:32 PM

Former Member
0 Kudos

Why is this sooo hard.

It is very likely the transaction calls the ENQ WP because it can run on any system and because it cannot it gets cross and refuses to work well for you.

If you want to do a professional Basis test you have to set a trace in SM50 for lock management while you do some updating of tables. That will show you if locking is really happening.

Former Member
0 Kudos

It appears that parameter

rdisp/enqname = >host1_SID_01

is missing or its value is is incorrect.

For instance hostname might be incorrect ( lower case instead upper case or vise versa etc).

Regards,

Alexander

Former Member
0 Kudos

Hi Nesimi,

an SAP 7.0 system you can have only two Enqueue processes if you have a HA setup. That means the system uses replicated enqueue. This is a pair of enqueue processes, but only one is active and replicates all changes to the second process. In case of a problem you can then switch to the second process without interrupting the work on any of the dialog instances. In any other cases you should not have two enqueue processes.

For deadlocks read the note recommended in the other posting.

Regards

Ralph

Former Member
0 Kudos

Hi Guys

@Nesimi: What kind of deadlocks do you have? If you have them on the database (e.g. ORA-00060) then this does not have anything to do with SAP enqueue processing.

@Praveen: note 111291 is for SQL-Server databases, but Nesimi seems to have Oracle, so note 84348 - Oracle-Deadlocks, ORA-00060 might be better

@Ralph: we have a CI with 4 enqueue processes but no HA, but i agree in general it is absolutely ok to have only one enqueue processes

Best regards

Michael

Edited by: mho on Jun 9, 2008 3:50 PM

Former Member
0 Kudos

Hi

I received this feedback from SAP Support so far:

09.06.2008 - 21:06:28 CET - Reply by SAP

Dear Mr. Nesimi Buelbuel

Thank you for contacting SAP support.

It is not reccommended to have more than 3 enq work processes configuredas this can lead to performance issues. From the screen shot this is

the amx number that is allowed in the queue when being waited to be

dispatched does not mean that they need to be increased, if the

waiting requests were a high value this may indicated that they need

to be increased.

(.........)

Support Consultant

SAP GSC Ireland

regards

Nesimi

Former Member
0 Kudos

Hi Nesimi,

Please find the OSS note, which is about deadlocks.

Note 111291 - FAQ: analysis and avoiding deadlocks

Cheers,

Praveen