Unlock AD user account using freshservices ticket with n8n

Hi I am getting this error on

“signal”: null,

“stdout”: “”,

“stderr”: “The filename, directory name, or volume label syntax is incorrect.”

},

{

“code”: 1,

“signal”: null,

“stdout”: “”,

“stderr”: “The filename, directory name, or volume label syntax is incorrect.”

},

{

“code”: 1,

“signal”: null,

“stdout”: “”,

“stderr”: “The filename, directory name, or volume label syntax is incorrect.”

},

{

“code”: 1,

“signal”: null,

“stdout”: “”,

“stderr”: “The filename, directory name, or volume label syntax is incorrect.”

}

]

Hey @soma hope all is good.

This is nowhere near the amount of details required for someone to be able to help you. Tell us what you are doing, how you are doing it, share the workflow, explain where and when the error happens, how the AD is related, how the freshservices are related, did it always happen or just started, did this workflow work before or this is a new workflow, … I mean, give us something… :slight_smile:

I think this is windows error message, @soma are u using dockers? or directly in windows?

Samuel

1 Like

The workflow is N8n installed in Docker

[Schedule Trigger]

[HTTP Request to Freshservice]

[Set or Code node → extract data]

[If node → check gatePass / valid user]

[SSH node → Unlock]

Till If is fine ssh is not working i am getting that error

The command(s) executed in the SSH node have a problem with the path.

1 Like

I think by defauly ure in path

[

{

“exitCode”: 0,

“stderr”: “”,

“stdout”: “/home/node”

}

]

also fyi. you could try using execute node, instead of ssh if thats why ure using.

1 Like

I am using the path this below code
powershell -NoProfile -ExecutionPolicy Bypass -Command “& ‘D:\Scripts\UserAccountUnlock.ps1’ -UserId ‘$($json.username)’ -TicketId ‘$($json.ticketId)’ -RequestedBy ‘$($json.requesterEmail)’ -Json”

also am guessing the credentials being used have permission to access that path, have u tried ssh outside of n8n from local machine does that work okay?

u could try run these commands instead first see if they working

powershell -Command “pwd”

powershell -Command “Get-ChildItem ‘D:\Scripts’”

1 Like

Thank you for Reply, yes i have tested in PowerShell
d User creation> Test-Path “D:\Scripts\UserAccountUnlock.ps1”

True

I have done ssh for remote Machin it is working and i am able Execute .ps1
Only issue Working Directory
[

{

“code”: 1,

“signal”: null,

“stdout”: “”,

“stderr”: “The filename, directory name, or volume label syntax is incorrect.”

}

]

Input

2 items

ticketId

13090

requester

subject

unlock in0299

description

username

xxxx

validSam

true

gatePass

true

reason

OK

Output

2 items

code signal stdout stderr
1 [null] [empty] Access is denied.
1 [null] [empty] Access is denied.

I have resolved the issue
Webhook

HTTP Request (Fetch Ticket)

Code (Parse Subject)

IF (gatePass && username)

SSH Command (Unlock)

Parse SSH Output

Send Email Result

Close Ticket (PUT)

and how you solved it?

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.