Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Unclean shutdown detected

Featured Replies

I recently swapped my setup to new hardware. Now, everytime I stop the array I see a message at the bottom "Stopped. Unclean shutdown detected." A parity check runs after starting the array. I'm not sure what the problem is. Any suggestions? Diagnostics attached.

unraid-diagnostics-20180829-0844.zip

  • Replies 64
  • Views 17.1k
  • Created
  • Last Reply

Top Posters In This Topic

Most Popular Posts

  • Thanks for your help. I have now measured it. The array takes 1m 45s to stop. I will revise the script and add the new timeouts.

  • Adriano Frare
    Adriano Frare

    thanks for help. Solved!!!!

Posted Images

Can you put Fix Common Problems into troubleshooting mode and then shutdown, and upload the files which it suggests.

8 minutes ago, aberg83 said:

then stopped and started array.

You need to shutdown or restart.

Unsure.  It started shutting down, then half way through it decided that files were stuck open on the cache drive and disk 4, so it itemized the processes, then the system carried on, unmounted the remaining drives and shut down like nothing happened.

 

I have seen this on occasion on my own system where it believes that the shutdown was unclean even though it was clean (I suspect a race condition somewhere).  When this happens, I hit Fix Common Problems and see what it says.  If it doesn't think that an unclean shutdown happened (the GUI and FCP check for unclean shutdowns differently), then I just cancel the parity check.  (Assuming of course that you haven't hit ignore on that particular warning)

  • Author

FCP doesn't flag this as an unclean shutdown and I have not set it to ignore that warning.

 

On occasion would be one thing, but this is happening on every reboot. Wish there was something I could do.

  • Community Expert
20 minutes ago, aberg83 said:

this is happening on every reboot

It has to be able to write the started/stopped status to config/super.dat on flash. If that doesn't happen for some reason you can get unclean. Maybe put your flash in PC and checkdisk though I didn't see anything in syslog. Also check timestamp of super.dat to see if it corresponds to the shutdown time.

  • 2 years later...

hi Guys

 

Since the last Unraid Update to 6.9.1 I got the message "Unclean shutdown detected" after every restart.
This means that a parity check is started every day, but this takes so long that it is never finished.
The server is shut down again via a script before the parity check is ended.

I activated the syslog according to the instructions and shut down the server (this time even via the Unraid button in the GUI, not via the script).

 

syslog-192.168.187.40.zip unraid-diagnostics-20210421-2004.zip

  • Community Expert

When Unraid forces a shutdown it saves the diags in the logs folder of your flash drive, attach latest ones of those here.

  • Community Expert

There's no shutdown logged on those, they appear to be the same ones you posted earlier.

  • Community Expert

Current set shutdown timeout is not long enough, stop the array manually and time how long it takes for the array to stop, add a few seconds and set that as your VM shutdown timeout, then add 30 seconds or so to that value and set that as the general Unraid timeout.

Thanks for your help. I have now measured it. The array takes 1m 45s to stop.
I will revise the script and add the new timeouts.

Is there a topic in which the shutdown is described. I couldn't find anything.
Unfortunately, my scripting skills are very modest.


Do the VMs actually have to be terminated before the array?
These partially access the array.


Most of them, however, run on the cache drives.

At the moment I have this script installed.

 

#! / bin / bash

echo running powerdown

/ usr / local / sbin / powerdown

 

if you're having problems with the script, the one thing is that you've got spaces within that path that shouldn't be there

It should be

#!/bin/bash

echo running powerdown

/usr/local/sbin/powerdown

 

No the Script works fine.

Sorry the spaces are only a copy paste failure to the post.

 

The problem is, the script terminates the server before the array has shut down correctly.

 

if I understood JorgeB correctly I had to do it like this:
1. End the array
2. Add timeout
3. Quit the server in general

 

I couldn't figure out how to end the array with a command first and the command for the timeout.

  • 6 months later...

im hoping someone can help me.  my server shuts down the arrays and vm, etc.  when i run the log it says there is an unclean shutdown error.  im not sure what this is and im new so i dont really know how to fix it.  hoping this is an easy solution.  it happens intermittently, so say every few weeks or so, then when i start the array back up the parity check starts. i have attached the syslog i grabbed before starting the array back up.

 

any help is much appreciated.

2021-10-27 syslog-unclean shutdown.txt

  • Community Expert
2 hours ago, sirhotness said:

i have attached the syslog i grabbed before starting the array back up.

That doesn't help since it starts over after any reboot.

 

On 4/21/2021 at 7:18 PM, JorgeB said:

When Unraid forces a shutdown it saves the diags in the logs folder of your flash drive, attach latest ones of those here.

 

12 hours ago, JorgeB said:

When Unraid forces a shutdown it saves the diags in the logs folder of your flash drive, attach latest ones of those here.

 

ok i just realized i dont have the syslog enabled.  i will have to enable this and then the next time this happens grab the diags you're talking about from the log folder on the flash drive.  im thinking it might be better to use my old server since its still running to to dump the syslog that you need instead of using the flash drive in order to save wear and tear on the flash drive.  this problem doesnt happen all the time, so would you also suggest the same method i just described?  i have changed the timeouts as you described earlier in this post and im hoping that was the issue, but just incase i'd rather enable the syslog server.

 

  • Community Expert
11 hours ago, sirhotness said:

ok i just realized i dont have the syslog enabled.

It's not the syslog server, it auto generates the logs if it can't shutdown cleanly, they are saved in the flash drive logs folder.

4 hours ago, JorgeB said:

It's not the syslog server, it auto generates the logs if it can't shutdown cleanly, they are saved in the flash drive logs folder.

ok let me check again because i didnt see a logs folder anywhere.  just bare with me because im new so im still figuring things out

21 hours ago, JorgeB said:

It's not the syslog server, it auto generates the logs if it can't shutdown cleanly, they are saved in the flash drive logs folder.

 

is this the log you need?

syslog.txt

  • Community Expert

Nope.

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.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.