By default, commit, automation, and event policy scripts are stored on the router's hard drive. However, you can save these scripts to the flash memory by including the load-scripts-from-flash statement at the [edit system scripts] hierarchy level:
- [edit system scripts]
- load-scripts-from-flash;
The load-scripts-from-flash statement applies to all commit, automation, and event policy scripts. It only changes the physical location of these scripts. This statement does not affect the script's operation. Commit scripts located on the router's hard drive are accessed from the /var/db/scripts/event directory. Commit scripts located on the router's flash drive are accessed from the /config/scripts/event directory.
You can view the currently active scripts on the router by viewing the scripts located in the /var/run/scripts/commit directory on the router. This directory allows you to view the active scripts without having to search through the configuration.
![]() |
Note: When you switch from storing the files on the hard drive to storing files on the flash drive, or you switch from storing the files on the flash drive to storing files on the hard drive, you need to manually move any scripts residing on the former memory location to the new memory location. If this is not done, the scripts will not be available to the router. |