Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with Running Script as a User/Secret #3933

Open
emoeckel opened this issue Oct 18, 2024 · 0 comments
Open

Issue with Running Script as a User/Secret #3933

emoeckel opened this issue Oct 18, 2024 · 0 comments
Labels
bug Something isn't working PowerShell Universal Issue relates to PowerShell Universal. requires triage Issue has not yet been verified by the development team.

Comments

@emoeckel
Copy link

Version

5.0.12

Severity

High

Environment

msi

Steps to Reproduce

Create Script, Set Script to Execute as User.

Expected behavior

Works

Actual behavior

Timing out after 15 seconds. Using "Agent". Don't see any errors on the Windows Event log that show this is the error.

Debug Log Level - 
2024-10-18 12:33:00.875 -07:00 [INF][PowerShellUniversal.CustomQueueAttribute] Selected queue for job 2641: default
2024-10-18 12:33:00.905 -07:00 [INF][UniversalAutomation.ExecutionService] Job 2641 started.
2024-10-18 12:33:00.967 -07:00 [INF][UniversalAutomation.JobProcessManager] Starting job using Process as SYSTEM.
2024-10-18 12:33:16.259 -07:00 [WRN][UniversalAutomation.Services.GrpcExecutionService] Job process exited before handshake was received. Exit code: 0
2024-10-18 12:33:16.260 -07:00 [INF][UniversalAutomation.ExecutionService] Error executing job 2641: PowerShell did not respond in a timely fashion. PowerShell Universal is currently waiting 15 seconds for PowerShell to start running the script.
You can increase the timeout by setting the 'Job Handshake Timeout' setting in the Settings \ General \ Automation page.
If you are still experiencing issues, you may need to consider increasing the resources available on your system or take advantage of the Random Delay parameter for schedules to stagger jobs.
    at UniversalAutomation.Services.GrpcExecutionService.ExecuteScript(Job job, ExecutionEnvironment environment, ExecuteScriptRequest request, ExecutionCallback executionCallback) in C:\actions-runner\_work\universal\universal\src\Universal.Server\Services\Automation\GrpcExecutionService.cs:line 113
   at UniversalAutomation.ExecutionService.ExecutePowerShell(Script script, IEnumerable`1 parameters, Job job, Schedule schedule, ExecutionCallback callback) in C:\actions-runner\_work\universal\universal\src\Universal.Server\Services\Automation\ExecutionService.cs:line 815
   at UniversalAutomation.ExecutionService.TryExecute(Job job, Schedule schedule) in C:\actions-runner\_work\universal\universal\src\Universal.Server\Services\Automation\ExecutionService.cs:line 390
   at UniversalAutomation.ExecutionService.TryExecute(Job job, Schedule schedule) in C:\actions-runner\_work\universal\universal\src\Universal.Server\Services\Automation\ExecutionService.cs:line 490
   at UniversalAutomation.ExecutionService.Execute(Int64 jobId, Nullable`1 scheduleId) in C:\actions-runner\_work\universal\universal\src\Universal.Server\Services\Automation\ExecutionService.cs:line 196 System.Exception

Additional Environment data

5.0.12 Nightly
We do see one Audit Failure in the event log for the privilege "SeTcbPrivilege", however, we have given the user that permission and actually see it being granted that permission right before the Audit Failur.

Screenshots/Animations

image

image

@emoeckel emoeckel added bug Something isn't working PowerShell Universal Issue relates to PowerShell Universal. requires triage Issue has not yet been verified by the development team. labels Oct 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working PowerShell Universal Issue relates to PowerShell Universal. requires triage Issue has not yet been verified by the development team.
Projects
None yet
Development

No branches or pull requests

1 participant