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, and 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/commit directory. Commit scripts located on the router's flash drive are accessed from the /config/scripts/commit 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 vice versa, you need to manually move any scripts residing in the former memory location to the new memory location. If you do not move these scripts, the scripts will not be available to the router. |