Junos Automation (Scripting)
Junos Automation (Scripting)

Error running a script on EX switch

‎12-19-2019 09:33 AM

I have a python script I am trying to run but get the following errors:

user@sw1>op wrn
error: File is neither owned by root nor by a super-user
error: Unable to run Python script 'wrconfig.py'


I can go into the shell and change ownership but I am hoping to find a way to sign the script so that we dont have to go into the shell. I added the checksum to the python file thinking that was how to sign but didn't work

Junos Automation (Scripting)

Re: Error running a script on EX switch

‎12-19-2019 10:14 AM

Hi jamannmtgov,


The error simply means that the user running the script does not have requisite permissions to run the same.

You can either run the script by logging in as root or use the username which was used to put the script there.

With root credentials or the username(used to pull the script), permission can be granted to the file so that other users can access/run.


This usually grants permission for all users:

chmod 777 <filename>


I am sceptical if there is any other way than this!



Accept as Solution = cool ! (Will help other community members with similar queries to be redirected here)
Accept as Solution+Kudo = You are a Star !