September 2, 201411 yr Community Expert Is there a way to run a user script during the powerdown sequence? I would like to do things like tidily unmounts drives that are not part of the array. I thought of adding entries to the go file to create a script in the appropriate place every time unRAID boots, but I thought there is probably a tidier way.
September 2, 201411 yr There are events in emhttp that you can hook into. I don't have more specifics about it, Search on the board and/or wiki. Perhaps someone else will chime in and provide more details.
September 2, 201411 yr Author Community Expert There are events in emhttp that you can hook into. I don't have more specifics about it, Search on the board and/or wiki. Perhaps someone else will chime in and provide more details. I was hoping for something simpler. I am not worried about the array shutdown, but the system shutdown. This is the sort of thing I would normally expect to handle in a rc_* type script. My current solution is to simply copy one into place from the USB stick in my go file. I was wondering if I should be doing something else as an official alternative?
September 2, 201411 yr Similar to the go file, you can create a stop file in /boot/config/. It will be executed from /etc/rc.d/rc.local_shutdown.
September 2, 201411 yr Along the lines of Freddie's comment... The latest powerdown plugin offers start and stop scripts. Very nice to ensure orderly VM shutdown.
September 2, 201411 yr Author Community Expert Similar to the go file, you can create a stop file in /boot/config/. It will be executed from /etc/rc.d/rc.local_shutdown. Thanks - that is exactly what I was looking for! Perhaps a dummy stop file (containing only some comments) should be included as standard in the unRAID distribution?
Archived
This topic is now archived and is closed to further replies.