Squid Posted May 11, 2018 Share Posted May 11, 2018 All that's needed is the second line. Don't know why you would want to stop docker, restart it, then reboot. Quote Link to comment
dlandon Posted May 11, 2018 Author Share Posted May 11, 2018 1 hour ago, jeffreywhunter said: I'm wanting a clean reboot on a daily basis and I don't want to cause unclean shutdowns. I run plex, mysql, pydio and other dockers. Will this script work to cleanly shutdown the dockers, then reboot? I'd put this in the User Scripts plugin... /etc/rc.d/rc.docker stop && /etc/rc.d/rc.docker start /usr/local/sbin/powerdown -r Thanks in advance! Why do you stop and then restart the dockers? Quote Link to comment
jeffreywhunter Posted May 11, 2018 Share Posted May 11, 2018 2 hours ago, dlandon said: Why do you stop and then restart the dockers? Good catch @Squid @dlandon. Sorry, that's a typo, I was also working on a daily start/stop process for dockers and just copied it wrong. Proof reading isn't evidently one of my skills... Quote Link to comment
bonienl Posted May 11, 2018 Share Posted May 11, 2018 (edited) To perform a clean shutdown use /sbin/poweroff To perform a clean reboot use /sbin/reboot Edited May 11, 2018 by bonienl Quote Link to comment
Squid Posted May 11, 2018 Share Posted May 11, 2018 To perform a clean shutdown use/sbin/poweroff To perform a clean reboot use/sbin/reboot Yes technically powerdown is deprecated. However, the day that it actually stops working will not be a happy day for me, and an immediate PR will be put it. Quote Link to comment
bonienl Posted May 11, 2018 Share Posted May 11, 2018 37 minutes ago, Squid said: Yes technically powerdown is deprecated. However, the day that it actually stops working will not be a happy day for me, and an immediate PR will be put it. It starts with educating people to use the "new" way... And hopefully one day that PR isn't necessary. Quote Link to comment
Squid Posted May 11, 2018 Share Posted May 11, 2018 58 minutes ago, bonienl said: It starts with educating people to use the "new" way. muscle memory is a hard thing to overcome ? Quote Link to comment
jeffreywhunter Posted May 11, 2018 Share Posted May 11, 2018 1 hour ago, bonienl said: To perform a clean shutdown use /sbin/poweroff To perform a clean reboot use /sbin/reboot Is it /sbin/reboot or /usr/local/sbin/reboot? Quote Link to comment
John_M Posted May 12, 2018 Share Posted May 12, 2018 3 hours ago, jeffreywhunter said: Is it /sbin/reboot or /usr/local/sbin/reboot? It's like he said: root@Mandaue:~# ls -l /sbin/reboot lrwxrwxrwx 1 root root 4 Apr 21 19:00 /sbin/reboot -> halt* root@Mandaue:~# ls -l /usr/local/sbin/reboot /bin/ls: cannot access '/usr/local/sbin/reboot': No such file or directory root@Mandaue:~# Quote Link to comment
jeffreywhunter Posted May 12, 2018 Share Posted May 12, 2018 1 hour ago, John_M said: It's like he said: root@Mandaue:~# ls -l /sbin/reboot lrwxrwxrwx 1 root root 4 Apr 21 19:00 /sbin/reboot -> halt* root@Mandaue:~# ls -l /usr/local/sbin/reboot /bin/ls: cannot access '/usr/local/sbin/reboot': No such file or directory root@Mandaue:~# Sorry, should have been clearer. My script is using /usr/local/sbin/reboot And it works, so was wondering if the path was incomplete. Evidently either works? Quote Link to comment
bonienl Posted May 12, 2018 Share Posted May 12, 2018 (edited) 2 hours ago, jeffreywhunter said: And it works, so was wondering if the path was incomplete. Evidently either works? The "/usr/local/sbin/reboot" command does not exist in the stock installation of unRAID. Something else must have it created. I recommend to use the commands I have given earlier as these are the 'official' ones as used by the GUI too. Edited May 12, 2018 by bonienl Quote Link to comment
jeffreywhunter Posted May 12, 2018 Share Posted May 12, 2018 Thanks, I will do so... Quote Link to comment
trurl Posted May 12, 2018 Share Posted May 12, 2018 5 hours ago, bonienl said: The "/usr/local/sbin/reboot" command does not exist in the stock installation of unRAID. Something else must have it created. Maybe you have the deprecated shutdown plugin installed. Quote Link to comment
jeffreywhunter Posted May 12, 2018 Share Posted May 12, 2018 2 hours ago, trurl said: Maybe you have the deprecated shutdown plugin installed. I rebuilt the server from scratch in December. How would I have installed the deprecated shutdown plugin? Perhaps in rebuilding the server, I inadvertently recreated the problem by installing something in error? All of my plugins and nerd tools are fully updated as far as I can tell... Installed Plugins as of 20180512.txt Quote Link to comment
DZMM Posted June 16, 2018 Share Posted June 16, 2018 On 3/5/2018 at 4:02 PM, Frank1940 said: Am I correct in assuming that one should enter ssh bash in the field for the Processes to kill before Array is Stopped: parameter? EDIT: So per your advice, like this ssh,bash So. If I do this will scripts set to run at array stop via user scripts still run? Quote Link to comment
CreZo Posted July 9, 2018 Share Posted July 9, 2018 (edited) Hey guys, I've got a huge Problem. I switch to another mainboard and CPU (power consumption is much lower) and I've got a popup which tells me that there is an unclean shutdown detected. This happens in ~ 30 - 45 min after I start/reboot the server. At the weekend I build everything in the old system and it worked perfectly but I want to use the new mainboard and CPU. Can someone help me? Edited July 9, 2018 by CreZo Quote Link to comment
Frank1940 Posted July 9, 2018 Share Posted July 9, 2018 I am confused. What hardware are you currently using in the server? Does the problem happen every time after you start the server? How many times has it happened? Did you run a 24 hour memtst on the RAM? ( Memtst is an option in the boot menu and tests the installed memory.) Please provide us with a list of the new hardware that is failing. Quote Link to comment
CreZo Posted July 9, 2018 Share Posted July 9, 2018 (edited) Hey Frank, old hardware: Motherboard Gigabyte Technology Co. Ltd. Z170-HD3P-CF (U3E1) CPU Intel Core i7 6700K new hardware: Motherboard Gigabyte GA-B250M-DS3H CPU Intel Pentium G4560 (2x 3,5GHz + HT) Quote Does the problem happen every time after you start the server? Yes, it does. Quote Did you run a 24 hour memtst on the RAM? Yes, no errors. Quote Please provide us with a list of the new hardware that is failing. I don't know which hardware is failing. I boot the server and everything is fine for ~30 - 45 minutes. After this time when I login into the GUI I get a popup which tells me that there is an unclean shutdown detected. Also, the theme changed from dark to white. My docker and apps are still running but I can't see them in the dashboard anymore. Edited July 9, 2018 by CreZo Quote Link to comment
Frank1940 Posted July 9, 2018 Share Posted July 9, 2018 Do you have the Fix Common Problems plugin installed? (If not , do it) Turn on the 'Troubleshooting mode'. That will write the syslog file periodically to the logs directory. Also connect a monitor up to the console and seen if you see anything on the screen. You may have to sit there and watch it until it reboots. You want to keep an eye on the GUI and watch the system temperatures. Make sure that the CPU coolers are secured locked down to the MB. That has been at least one person who had a flaky PS that caused similar issues. I am assume that the server is actually rebooting. After the first reboot does it do it again in another 30 to 45 minutes? I would stop Docker, shut all of the VM's down and see if that makes a difference. That will tell you if you have some software/hardware conflict or just a hardware problem. There have not been any reports of the base NAS doing anything like this. Quote Link to comment
trurl Posted July 9, 2018 Share Posted July 9, 2018 I suspect flash drive corruption Quote Link to comment
CreZo Posted July 10, 2018 Share Posted July 10, 2018 Thank you, Frank and trurl for your answers. I already did this Frank and there was no reboot or anything else. I also stopped all VM's and apps. Every time I got the same result, a popup with the message in it but the server didn't reboot or shut down. The server is still running. I don't get it but I will the 'Troubleshooting mode' and also the Temperature problem can be a fact maybe this can help. Quote Link to comment
trurl Posted July 10, 2018 Share Posted July 10, 2018 14 hours ago, trurl said: I suspect flash drive corruption Or possibly flash drive USB port disconnected as some point. Go to Tools - Diagnostics and post the complete zip if it happens again. You might also try putting the flash in your PC and letting it checkdisk. Quote Link to comment
CreZo Posted July 12, 2018 Share Posted July 12, 2018 Good morning guys, I solved the problem. I found this topic and my problem was pretty similar after I checked the log files. I bought a new flash drive and since then everything works fine now. Thank you so much!!! Quote Link to comment
John_M Posted August 30, 2018 Share Posted August 30, 2018 I've had a number of unclean shutdowns recently in which my server rebooted during heavy disk I/O. I've traced the problem to a failing HBA and I've replaced it and now I'm in the process of restoring lost data from backups. It made one disk "Unmountable: unsupported partition layout". The effects of a failing HBA can be quite catastrophic. After a spontaneous reboot the Main page indicates that an unclean shutdown has occurred and starting the array will begin a parity check. That's all as expected. However, I notice that if instead of starting the array, I either do a manual reboot or power down in order to investigate the hardware and power up again later, the unclean shutdown message isn't displayed and starting the array doesn't force a parity check. I wondered if anyone else had noticed this and whether it's a quirk, a bug or something else? Running a correcting parity check manually found and fixed 1500 or so errors. A subsequent parity check found zero errors, as expected. This is unRAID 6.5.3. Quote Link to comment
JonathanM Posted August 30, 2018 Share Posted August 30, 2018 10 hours ago, John_M said: I've had a number of unclean shutdowns recently in which my server rebooted during heavy disk I/O. I've traced the problem to a failing HBA and I've replaced it and now I'm in the process of restoring lost data from backups. It made one disk "Unmountable: unsupported partition layout". The effects of a failing HBA can be quite catastrophic. After a spontaneous reboot the Main page indicates that an unclean shutdown has occurred and starting the array will begin a parity check. That's all as expected. However, I notice that if instead of starting the array, I either do a manual reboot or power down in order to investigate the hardware and power up again later, the unclean shutdown message isn't displayed and starting the array doesn't force a parity check. I wondered if anyone else had noticed this and whether it's a quirk, a bug or something else? Running a correcting parity check manually found and fixed 1500 or so errors. A subsequent parity check found zero errors, as expected. This is unRAID 6.5.3. That sounds like something @limetech ought to at least investigate. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.