A couple of pointers that might help.
1. The nios2configtool application is in the directory:
$ECOS_REPOSITORY/hal/nios2/tools/bin
This should be automatically added to your path if you are using an SDK shell. However this may not happen if you are using an old version of Quartus, in which case you can just add the directory to your path manually.
2. The Altera flash programmer programs the device with it's own SOF file. Therefore after running the "program_flash" script, you will need to remember to reprogram the device with your original SOF before you can do anything.
Hope that helps.