Lock error AHD05021: Someone else is editing this so you won't be able to make changes
search cancel

Lock error AHD05021: Someone else is editing this so you won't be able to make changes

book

Article ID: 448239

calendar_today

Updated On:

Products

CA Service Management - Service Desk Manager CA Service Desk Manager

Issue/Introduction

The application appears to start correctly.
However, when attempting to edit any record (incident, contact, location, etc.) from the web interface, the following error is consistently displayed:

AHD05021: Someone else is editing this so you won't be able to make changes.
Locked by 'SRVCDESK, DESK SRVC'

This occurs for all records.

 

In stdlog we could see a lot of errors like this few seconds/minutes after the startup

06/05 08:47:14.82 <sdm_server_name> bpvirtdb_srvr          10801 ERROR        vdbsql.c              5384 Process (domsrvr) already holds lock requested for Table (usp_bopsid) Lock ID(400204) on behalf of ((NULL))

06/05 08:47:29.97 <sdm_server_name> bpvirtdb_srvr          10801 ERROR        vdbsql.c              5384 Process (arcpur_srvr) already holds lock requested for Table (session_log) Lock ID(<lock_id>) on behalf of (<uuid> UUID String)

06/05 08:47:29.98 <sdm_server_name> arcpur_srvr            11061 ERROR        row_obj.c              853 Unable to archive and purge record (factory:session_log id:(integer)<lock_id>) because it's locked.

06/05 08:47:29.99 <sdm_server_name> bpvirtdb_srvr          10801 ERROR        vdbsql.c              5384 Process (arcpur_srvr) already holds lock requested for Table (session_log) Lock ID(<lock_id>) on behalf of (<uuid> UUID String)

06/05 08:47:29.99 <sdm_server_name> arcpur_srvr            11061 ERROR        row_obj.c              853 Unable to archive and purge record (factory:session_log id:(integer)<id>) because it's locked.

06/05 08:47:11.31 <sdm_server_name> bpvirtdb_srvr          10801 ERROR        vdbsql.c              5384 Process (domsrvr) already holds lock requested for Table (usp_bopsid) Lock ID(<lock_id>) on behalf of ((NULL))

06/05 08:47:11.31 <sdm_server_name> bpvirtdb_srvr          10801 ERROR        vdbsql.c              5384 Process (domsrvr) already holds lock requested for Table (usp_bopsid) Lock ID(<lock_id>) on behalf of ((NULL))

Environment

ServiceDesk 17.3, 17.4
Database on Oracle

Cause

This problem could be cause by the missing trigger USP_RECORD_LOCK_TRIGGER

Following SQL Query should return 5 triggers.

In example below USP_RECORD_LOCK_TRIGGER is missing

SELECT OBJECT_NAME, OWNER FROM all_procedures WHERE OBJECT_NAME like 'USP%';

OBJECT_NAME                       OWNER
--------------------------------- --------
USP_LOCK_ACQUIRE MDBADMIN
USP_LOCK_CHECK MDBADMIN
USP_LOCK_RELEASE MDBADMIN
USP_LOCK_RELEASE_MULTIPLE MDBADMIN

 

Resolution

  1. Stop ServiceDesk Services

  2. Execute following SQL query on Oracle database :

    CREATE OR REPLACE TRIGGER mdbadmin.usp_record_lock_trigger
      BEFORE INSERT ON mdbadmin.usp_record_lock 
      for each row
      begin
        select usp_record_lock_sequence.nextval into :new.id from dual;
      end;
    /



  3. Start ServiceDesk Services.