VMware Cloud Community
orian
Hot Shot
Hot Shot
Jump to solution

delete file from appliance

Hi,

How can I delete a specific file from the orchestrator appliance?

If I use "Delete file in guest" workflow I receive the following error:

Failed to authenticate with the guest operating system using the supplied credentials.

However If I connect ssh to appliance with same user and password it works fine.

Thanks!

Tags (2)
Reply
0 Kudos
1 Solution

Accepted Solutions
inevp
Enthusiast
Enthusiast
Jump to solution

Hello,

I guess you are trying to use the "Delete file in guest" workflow from the vCenter plugin? Not sure why that would be failing but you could try using the "Run SSH command" from the SSH plugin with a command like 'rm /path/to/file'.

Another alternative would be to write your own custom script like:

var file = new File(path);

file.deleteFile();

Where "path" is a string input parameter representing the absolute path to the file on the file system. To use this approach you would need to allow the vRO file access to the directory where the file is located as explained here: Rules in the js-io-rights.conf File Permitting Write Access to the vRealize Orchestrator System

View solution in original post

Reply
0 Kudos
1 Reply
inevp
Enthusiast
Enthusiast
Jump to solution

Hello,

I guess you are trying to use the "Delete file in guest" workflow from the vCenter plugin? Not sure why that would be failing but you could try using the "Run SSH command" from the SSH plugin with a command like 'rm /path/to/file'.

Another alternative would be to write your own custom script like:

var file = new File(path);

file.deleteFile();

Where "path" is a string input parameter representing the absolute path to the file on the file system. To use this approach you would need to allow the vRO file access to the directory where the file is located as explained here: Rules in the js-io-rights.conf File Permitting Write Access to the vRealize Orchestrator System

Reply
0 Kudos