Page 1 of 1

JOB FAILED TO EXECUTE DUE TO USER ENVIRONMENT/FORK FAILURE

Posted: 09 Dec 2010 4:03
by Venkateshwarulu
Greetings!!!

We have installed the new Control-M Agent (version 6.4.01 Fixpack 3) on Windows 2008 and trying to execute the .exe files which is written in powerbuilder. FYI...Control-M server (version 6.3.02) is installed on Solaris.

When I ran the jobs first time and it failed due owner issues. I mean the job is trying to execute as SYSTEM insted of owner defined in the job. It seems it does not have access to any network resources. I have fixed this issue with the below steps.
1. Modified Control-M/Agent service: (Control Panel -> Administrative Tools -> Services)

Open the service's properties, select the 'Log On' tab.
Check the 'This Account' radio button.
Specify an existing Windows user (logon name@domainname) account that has access to the network drive the job refers to (your own logon for example). Ensure this network drive is mapped to the user's security context.

2. Set the Agent to 'Logon as User'
Open the Agent GUI, Customize Menu -> Windows Configuration Parameters
Check the box 'Logon as User'

3. Created 2 user entries in the password file using the 'ctmpwd' utility
C:\ctmpwd -ACTION add -USER <logon> -PASSWORD <password>

For one of the entries, created the user logon user@services.reinternal.comand for the second, just write the logon name without '@domainname' & ensure the passwords are the same as is in Windows

Restarted the Control-M/Agent service.

4. Assigned the following privileges/policies to the user
Administrative Tools -> Local Security Policy -> Local Policies -> User Rights Assignment. (Select the relevant user from 'Look in' the domain name of your network.)
- Act as part of Operating System
- Log on as a Batch Job
- Increase Quotas
- Replace a Process Level Token
- Logon as Service

5. In the job definition updated the logon name as “SERVICES\user” 'owner' field on the General tab.

After making these changes, When I reran the jobs, now some of the jobs are executing sucessfully. But some jobs are failing with below error message.


08/12/10 10:05:38 CS5065 ORDERED JOB:2000780; DAILY FORCED, ODATE 20101208
08/12/10 10:05:39 SL5120 JOB STATE CHANGED TO Wait Condition
08/12/10 11:18:43 SL5105 SUBMITTED TO win2k8
08/12/10 11:18:47 TR5101 STARTED AT 20101208111843 ON win2k8
08/12/10 11:18:47 TR5120 JOB STATE CHANGED TO Executing
08/12/10 11:19:19 TR5100 ENDED AT 20101208111919. OSCOMPSTAT -1. RUNCNT 1
08/12/10 11:19:19 TR5111 JOB FAILED TO EXECUTE DUE TO FORK FAILURE

08/12/10 11:19:19 TR5134 ENDED NOTOK
08/12/10 11:19:19 TR5120 JOB STATE CHANGED TO Analyzed
08/12/10 11:19:19 SL5120 JOB STATE CHANGED TO Post processed
08/12/10 15:34:45 SL5120 JOB STATE CHANGED TO Wait Condition
08/12/10 17:32:38 SL5105 SUBMITTED TO win2k8
08/12/10 17:32:42 TR5101 STARTED AT 20101208173238 ON win2k8
08/12/10 17:32:42 TR5120 JOB STATE CHANGED TO Executing
08/12/10 17:33:18 TR5100 ENDED AT 20101208173318. OSCOMPSTAT -2. RUNCNT 2
08/12/10 17:33:18 TR5112 JOB FAILED TO EXECUTE DUE TO USER ENVIRONMENT

08/12/10 17:33:18 TR5134 ENDED NOTOK
08/12/10 17:33:18 TR5120 JOB STATE CHANGED TO Analyzed
08/12/10 17:33:18 SL5120 JOB STATE CHANGED TO Post processed

Why I am getting 2 different error messages (JOB FAILED TO EXECUTE DUE TO USER ENVIRONMENT/JOB FAILED TO EXECUTE DUE TO FORK FAILURE)? Please advice any suggestions or solution to reslove this issue?

Thanks in advance for your reply.

Regards
Venkat

Posted: 09 Dec 2010 7:36
by rchkevin
Ensure that the user† that runs the CONTROL-M jobs has Read & Execute permissions on %SYSTEMROOT%\System32\cmd.exe

† where user is:
- the job's owner, if you have the "Logon as User" parameter on the Agent configured to Y (ctmwincfg)
or
- the "Logon as" account defined in the CONTROL-M/Agent's services, if you have the "Logon as User" parameter on the Agent configured to N

Posted: 09 Dec 2010 1:32
by Venkateshwarulu
Yes. user† has Read & Execute permissions on %SYSTEMROOT%\System32\cmd.exe.

Posted: 09 Dec 2010 1:42
by rchkevin
Control-M Agent version cannot be higher than the Control-M Server version. Please check the compatibility chart.

If you still have issues. Enable debug on the agent and run the job and review the logs in proclog directory of the agent.

Posted: 09 Dec 2010 3:39
by Venkateshwarulu
I don't think Control-M agent version is problem here. Because we have job running on other Agents which is on 6.4 version.

Anybody has any suggestions please?

Thanks
Venkat

Posted: 13 Dec 2010 3:36
by LordOfAfford
Step should read :

5. In the job definition updated the logon name as “name@domainname” 'owner' field on the General tab.

5. In the job definition updated the logon name as “SERVICES\user” 'owner' field on the General tab.

Posted: 14 Dec 2010 9:35
by rchkevin
Set the Debug level to 4 on the agent and run the job. Check the logs on PROCLOG directory on agent to see for exact error.

Posted: 15 Dec 2010 5:44
by sharas
Hi Venky,

Did you add your Control-M user in password file ?

Below is the command to add it.

ctmpwd -action add -user USERNAME -password PASSWORD -agent default

Please replace "default" by your agent name if you given any specific name .