Thursday, October 14, 2021

IOS XE GuestShell - Execute Script from Flash

Anyone out there willing to help me understand what I'm missing here? I'm attempting to execute a python script from flash. Guestshell is working but I'm unable to execute from flash. HTTP server is enabled and running and I can ping between XE and guestshell.

R1#sh flash: | inc .py

285 222 Oct 14 2021 19:08:56.0000000000 +00:00 /bootflash/sample_script.py

R1#show app-hosting det

App id : guestshell

Owner : iox

State : RUNNING

R1#sh ver

Cisco IOS XE Software, Version 17.03.04a (CSR1000v)

R1#guestshell run python3 /bootflash/sample_script.py

python3: can't open file '/bootflash/sample_script.py': [Errno 2] No such file or directory

R1#guestshell run python3 /flash/sample_script.py

python3: can't open file '/flash/sample_script.py': [Errno 2] No such file or directory

R1#guestshell run python /flash/sample_script.py

env: 'python': No such file or directory

R1#guestshell run python3 /flash:sample_script.py

The run command has been modified to: python3 //flash/sample_script.py

python3: can't open file '//flash/sample_script.py': [Errno 2] No such file or directory

R1#guestshell run python3 bootflash:sample_script.py

The run command has been modified to: python3 /bootflash/sample_script.py

python3: can't open file '/bootflash/sample_script.py': [Errno 2] No such file or directory



No comments:

Post a Comment