When re-installing the ODBC server driver, the error "used by another process" or "service already exists" is received.

Document ID : KB000009116
Last Modified Date : 14/02/2018
Show Technical Document Details
Issue:

1. Whilst attempting to manually install the ODBC drivers on a CA Service Desk Manager server using the command, "oa72_server_setup.bat", the following error is received:

The process cannot access the file because it is being used by another process.

        0 file(s) copied.

  ERROR: command failed: copy /y "C:\PROGRA~2\CA\SERVIC~1\bin\casdodbc.dll" "C:\PROGRA~2\CA\SERVIC~1\add-ons\oaserver72\ip\bin\casdodbc.dll

Terminating setup due to error

 

Use command "oa72_server_setup -s 0.4" to resume setup at this step

 

2. After resolving the earlier situation, the command is run again, but the following error is received:

   ERROR: command failed: "C:\PROGRA~2\CA\SERVIC~1\add-ons\oaserver72\admin\oaclasil.exe" -e "C:\Users\ADMINI~1\AppData\L

ocal\Temp\2\oaserver.log" -dbg -d "C:\PROGRA~2\CA\SERVIC~1\add-ons\oaserver72\cfg\oadm.ini" ServiceRegister 'CA Service

Desk Manager ODBC Agent'

  [OpenAccess error 3142] Failed to register the specified OS service, because the service already exists.

 

Terminating setup due to error

Use command "oa72_server_setup -s 10.3.2.7" to resume setup at this step

Environment:
CA Service Desk Manager 17.x on Windows
Cause:

For the first symptom, the root cause is that at least one of the windows services, "CA Service Desk Manager ODBC Data Access" or  "CA Service Desk Manager ODBC Agent" has a status of "Running". 


For the second symptom, the root cause is that at least one of the ODBC Windows services is already registered.

Here is a screenshot showing the 2 ODBC services:

ODBCServices.png

Resolution:

To resolve the issue, uninstall and re-install the ODBC services, as follows:

  1. From Windows Services, STOP both services:

    CA Service Desk Manager ODBC Agent
    CA Service Desk Manager ODBC Data Access

  2. Open a Command prompt window, and enter EACH of the following commands sequentially:

    nxcd bin

    oa72_client_uninstall.bat

    oa72_server_uninstall.bat

    oa72_client_setup.bat

    oa72_server_setup.bat



Your results should be similar to the following:

ODBCUninstall.png

 

C:\PROGRA~2\CA\SERVIC~1\bin>oa72_client_setup.bat

About to install CA Service Desk Manager ODBC client
Installation directory: C:\PROGRA~2\CA\SERVIC~1\add-ons\oaodbc72
8.3.1.3 Configure registry update file...
       1 file(s) copied.
 Success!
8.3.1.4 Register driver and data source...
 Success!
8.99 Copy and configure pdm_isql command...
       1 file(s) copied.
 Success!
CA Service Desk Manager ODBC client installation successful

 

C:\PROGRA~2\CA\SERVIC~1\bin>oa72_server_setup.bat

About to setup CA Service Desk Manager ODBC server
Installation directory: C:\PROGRA~2\CA\SERVIC~1\add-ons\oaserver72
Open Access administrator account: CASDM17PRI\Administrator
0.0 Refresh mmcoa.ini...
       1 file(s) copied.
 Success!
0.1 Refresh oacla.ini...
       1 file(s) copied.
 Success!
0.2 Refresh oasql.ini...
       1 file(s) copied.
 Success!
0.3 Refresh oadm.ini...
       1 file(s) copied.
 Success!
0.4 Copy casdodbc.dll to C:\PROGRA~2\CA\SERVIC~1\add-ons\oaserver72\ip\bin...
       1 file(s) copied.
 Success!
10.3.2.2 Licensing OpenAccess 7.2 server...
 Success!
10.3.2.3-1 Removing ServiceTemplates...
 Success!
10.3.2.3-2 Copying agent service template...
 Success!
10.3.2.3-3 Copying ODBC service template...
 Success!
10.3.2.3-4 Initializing configuration file...
 Success!
10.3.2.4-1 Initializing new management console file...
       1 file(s) copied.
 Success!
10.3.2.4-2 Registering MMC snap-in...
 Success!
10.3.2.5 Creating agent service...
 Success!
10.3.2.6 Creating Service Desk data access service...
 Success!
10.3.2.7 Registering agent service...
 Success!
10.3.2.8-1 Registering CA Service Desk Manager data access service...
  Success!
10.3.2.8-2 Setting CA Service Desk Manager data access service to start automatically...
[SC] ChangeServiceConfig SUCCESS
 Success!
10.3.2.10-1 Configuring CA Service Desk Manager data access service IP module...
 Success!
10.3.2.10-2 Configuring CA Service Desk Manager data access service engine module...
 Success!
10.3.2.11-1 Set default data source IP type...
 Success!
10.3.2.11-2 Set default data source logon method...
 Success!
10.3.2.12 Starting agent service...
 Success!
10.3.2.13 Starting CA Service Desk Manager data access service...
 Success!
Successfully created file C:\PROGRA~2\CA\SERVIC~1\site\ODBC.properties
Successfully created file C:\PROGRA~2\CA\SERVIC~1\bin\pdm_odbc_start.bat
Successfully created file C:\PROGRA~2\CA\SERVIC~1\bin\pdm_odbc_stop.bat
CA Service Desk Manager ODBC server installation successful

Additional Information:
File Attachments:
TEC1241136.zip