MediaBrowser / Emby

Emby Server is a personal media server with apps on just about every device.
https://emby.media
GNU General Public License v2.0
4.14k stars 805 forks source link

"Shutting Down Media Browser Server" message hangs #98

Closed CBers closed 11 years ago

CBers commented 11 years ago

Please see posts here (http://mb3dev.ebrsoft.com/forum/viewtopic.php?f=12&t=332&p=10222#p10222) and here (http://mb3dev.ebrsoft.com/forum/viewtopic.php?f=12&t=332&start=390#p10865) in relation to problems with "Shutting Down Media Browser Server" message hangs.

ebr11 commented 11 years ago

I don't fully understand how this is happening since we wait for our calling process to exit before continuing in the update situation. Somehow, even though that process reports it has ended, we still find it when we search for it by name in running processes (or, there is another mediabrowser.serverapplication process going).

I have added a short delay after the first wait for exit and a timeout on the second wait for exit. Hopefully, this will catch this situation. In any case, the update process won't hang indefinitely - although, it may still fail if the process is still really running after the timeout.

CBers commented 11 years ago

The Shutting Down Media Server message just sits there doing nothing, or so it seems, with just the Mediabrowser.Installer.exe *32 process running.

MB3 Server is shut down, ie. there is no MediaBrowser.ServerApplication.exe *32 process running, but nothing else happens, no download occurs or anything,

How long is the time-out for the Shutting Down message ?? It's been running since before I started composing this response, some 2 minutes.

If I hit cancel, and answer yes to the "Cancel the installation" message, I can use the normal URL to install the latest version and everything is fine again.

I do have MB2 running on the same PC, so could this be causing an issue ??

ebr11 commented 11 years ago

If you ran the update from the Dashboard then you are still running the old version. It will take two update cycles to get this code in because it is the actual update code...

FantaXP7 commented 11 years ago

I posted this in the development forums, so here is a copy and paste of what I observed:

this morning and now this update tonight, I get the dialog box that says "shutting down media browser server" that doesn't leave.

Also at the bottom of web interface it still asks to restart the server to finish the update.

So what I did this morning and this evening is click cancel on the dialog box, click ok on the message about canceling installation, then re-open mb theater and everything appears fine and up to date.

https://www.dropbox.com/s/h9tx0pioivrnq8h/Server-635006017611017142.log

Also if it matters, I initiated the update from my laptop rather than directly at the machine it is running on.

ebr11 commented 11 years ago

As I stated in my previous comment. If you did an update today via the dashboard, you still had the old update code. It will take two updates to get the new code to you. So, the next update you do via the dashboard will have the new code and, hopefully, no longer have this problem.

ebr11 commented 11 years ago

If you did the update both yesterday afternoon and this morning (twice since my first comment above) then, hopefully, this is resolved - or at least changed behavior.

FantaXP7 commented 11 years ago

Yes, update this morning was successful and without the same errors mentioned here.

Thanks

ebr11 commented 11 years ago

Excellent, thanks. CBers, you too?

CBers commented 11 years ago

I didn't get the shutting down message this morning.

FantaXP7 commented 11 years ago

Hey ebr,

I've noticed this again this morning.

ebr11 commented 11 years ago

Can you tell me exactly what you did and what happened? Also, how long did you wait with the message up?

FantaXP7 commented 11 years ago

To be honest I am not sure. This morning when I got to work, I went to the dashboard and noticed a pending restart message at the bottom. I hit it and noticed nothing was happening. Logged into my server and saw the shutting down message.

ebr11 commented 11 years ago

If you can make it happen again, please let it sit for a minute without canceling it.

FantaXP7 commented 11 years ago

Ok, I'll keep an eye out for the next update.

Maybe you want to log into the server to observe as I update?

ebr11 commented 11 years ago

Yeah, that could be helpful. We can actually force it to do the update again. It's possible (via a couple hoops) to install back-versions...

FantaXP7 commented 11 years ago

https://join.me/657-285-400.

Whenever you feel like it.

CBers commented 11 years ago

I nearly clicked on that link :)

FantaXP7 commented 11 years ago

heh, well the more the merrier.

CBers commented 11 years ago

Might get it fixed quicker :)

FantaXP7 commented 11 years ago

ebr if you got a second I still can't re-install. Command is not open either.

CBers commented 11 years ago

The "Shutting Down Media Browser Server" hanging message is back again, sitting on-screen for ages - been 5 minutes now.

Server log: https://dl.dropbox.com/u/8367652/Server-635008032000079377.log

CBers commented 11 years ago

OK, latest build seems to have fixed this again.

LukePulverenti commented 11 years ago

I wouldn't mark this closed as it appears to be completely random.

CBers commented 11 years ago

Re-opened.

ebr11 commented 11 years ago

Yeah, I think it must be some sort of timing issue but I also really don't know how it can be happening at all based on the logic.

I think the next pass I'll just try and bypass the check for the running server when we are doing an update as that seems to be what is tripping it up somehow.

ebr11 commented 11 years ago

Xzener or CBers, can you help me test this today since It never happens on my machine?

You need to download this into any temporary folder outside of the mediabrowser-server folder.

Then bring up a cmd prompt and go to where you downloaded the temporary copy and type:

MediaBrowser.Installer product=server class=Beta version=3.0.4843

That should install an older version of the server.

Next - very important step - You have to copy the temporary version of MediaBrowser.installer.exe back into your system folder since it was just replaced by the update.

Then you can go to the dashboard and do an update and see how it goes. You can do these two steps multiple times to see if the issue crops back up. Thanks.

FantaXP7 commented 11 years ago

Are updates set to being automatic?

I woke up today and noticed my web dashboard is asking me to restart to finish updating...and I am about 99% sure I didn't hit update late last night.

LukePulverenti commented 11 years ago

yes they're automatic.

On Sat, Apr 6, 2013 at 12:39 PM, FantaXP7 notifications@github.com wrote:

Are updates set to being automatic?

I woke up today and noticed my web dashboard is asking me to restart to finish updating...and I am about 99% sure I didn't hit update late last night.

— Reply to this email directly or view it on GitHubhttps://github.com/MediaBrowser/MediaBrowser/issues/98#issuecomment-15999302 .

Luke Pulverenti

FantaXP7 commented 11 years ago

Ok, I was waiting for a new update to maybe show ebr while the update was running.

Anyways I hit restart, a mediabrowser installer window popped up then I hit ok, it went away...then I had the restart to finish message another two times...but no shutting down media browser box.

ebr11 commented 11 years ago

The normal update process is still running the old code. You will have to go through the steps I outlined above to test the new code.

xzener commented 11 years ago

Ebr,

I downloaded and put the file outside of the mediabrowser-server folder. I put in in my "c:/users/username/" in a folder named temp.

I then typed "c:/users/username/temp/MediaBrowser.Installer product=server class=Beta version=3.0.4843" and pressed enter...

The installer window pops up but does nothing.

Am I doing something wrong??

ebr11 commented 11 years ago

Can you further define "does nothing"? What message is in the window?

CBers commented 11 years ago

I concur.

The Installing Media Browser Server message just sits there and does nothing.

https://dl.dropbox.com/u/8367652/Capture406.JPG

I closed off MB3 server before starting MediaBrowser.Installer product=server class=Beta version=3.0.4843

xzener commented 11 years ago

Ebr,

I get the UAC popup about the system wanting to run the "MediaBrowser.Installer.exe" I click yes, then I get the installer window, but the progress bar doesn't scroll...

Capture

ebr11 commented 11 years ago

Okay. For some reason, you guys can't install the back versions. Let's just wait for the next two updates then. Thanks.

CBers commented 11 years ago

Currently running Version 3.0.4844.17703.

LukePulverenti commented 11 years ago

can this be closed or is it still happening?

CBers commented 11 years ago

Been OK today.