Bug Report OBS Stream Disconnects Every 3 Hours

kur1

New Member
I've been encountering a very frustrating (and audience-killing) issue this past month since I've started streaming with OBS. I haven't experienced this issue before on other programs.

Every night during my stream after ~3 hours 20 minutes have elapsed, my stream will "disconnect" from Twitch's servers. The stream is still running with 0% frame drop, but the preview pane is black. Until I resize OBS, it'll remain black.

This disconnect is extremely short, and if my stream preview window didn't go black / people didn't complain in chat I wouldn't know I disconnected at all.

Very strange behavior that seems to be on OBS's side (as I assume a communication error with Twitch would result in dropped frames or some error message to pop up in OBS, not a black screen). Not sure if it has to do with something in the software / game capture algorithms, but would love to figure out what's wrong.

Next stream I will use the test build alpha to see if that fixes the problem. But as it stands, the stable alpha is crashing at the same time every night for no apparent reason.

Using: 0.466 Alpha (32-bit)
Game Streamed: World of Warcraft: MoP (32-bit)
 

dehixem

Member
I'd like to +1 this issue, I happen to have similar problems. The screen goes black sometimes when I stream long enough (in my case over an hour), and I have to reboot the stream.
 

kur1

New Member
Code:
  Multithreaded optimizations: On
  Base resolution: 1920x1080
  Output resolution: 1280x720
------------------------------------------
Loading up D3D10...
------------------------------------------
Using auxilary audio input: FrontMic (Realtek High Definition Audio)
------------------------------------------
Audio Encoding: AAC
    bitrate: 128
Using graphics capture
------------------------------------------
    device: Logitech HD Pro Webcam C910,
    device id \\?\usb#vid_046d&pid_0821&mi_02#7&a1bfdc3&0&0002#{65e8773d-8f56-11d0-a3b9-00a0c9223196}\{bbefb6c7-2fc4-4139-bb8b-a58bba724083},
    chosen type: RGB24, usingFourCC: false, res: 1920x1080 - 1920x1080, fps: 5-30, fourCC: 00000000

Using directshow input
Using text output
Using bitmap image
Using bitmap image
Using bitmap image
Using Window Capture
------------------------------------------
Video Encoding: x264
    fps: 30
    width: 1280, height: 720
    preset: superfast
    CBR: no
    max bitrate: 3000
    buffer size: 6000
    quality: 10
------------------------------------------
SharedTexCapture hooked
Using RTMP service: Twitch / Justin.tv
  Server selection: rtmp://live-lax-backup.justin.tv/app
SO_SNDBUF already at 896000
bufferTime: 2605, outputRateWindowTime: 1000, dropThreshold: 3105
++++++++++++++++++++++++++++++++++++++++++++++++++++++
  New Scene
Using Monitor Capture
Using Monitor Capture
++++++++++++++++++++++++++++++++++++++++++++++++++++++
  New Scene
Using Window Capture
RTMPPublisher::SocketLoop: Socket error, send() returned -1, GetLastError() 10054
Total frames rendered: 350599, number of frames that lagged: 138 (0.04%) (it's okay for some frames to lag)
Number of b-frames dropped: 0 (0%), Number of p-frames dropped: 0 (0%), Total 0 (0%)
=====Stream End=======================================================================
=====Stream Start=====================================================================
  Multithreaded optimizations: On
  Base resolution: 1920x1080
  Output resolution: 1280x720
------------------------------------------
Loading up D3D10...
------------------------------------------
Using auxilary audio input: FrontMic (Realtek High Definition Audio)
------------------------------------------
Audio Encoding: AAC
    bitrate: 128
Using graphics capture
------------------------------------------
    device: Logitech HD Pro Webcam C910,
    device id \\?\usb#vid_046d&pid_0821&mi_02#7&a1bfdc3&0&0002#{65e8773d-8f56-11d0-a3b9-00a0c9223196}\{bbefb6c7-2fc4-4139-bb8b-a58bba724083},
    chosen type: RGB24, usingFourCC: false, res: 1920x1080 - 1920x1080, fps: 5-30, fourCC: 00000000

Using directshow input
Using text output
Using bitmap image
Using bitmap image
Using bitmap image
Using Window Capture
Using Monitor Capture
------------------------------------------
Video Encoding: x264
    fps: 30
    width: 1280, height: 720
    preset: superfast
    CBR: no
    max bitrate: 3000
    buffer size: 6000
    quality: 10
------------------------------------------
SharedTexCapture hooked
Using RTMP service: Twitch / Justin.tv
  Server selection: rtmp://live-lax-backup.justin.tv/app
SO_SNDBUF already at 896000
bufferTime: 2262, outputRateWindowTime: 1000, dropThreshold: 2762
Total frames rendered: 174670, number of frames that lagged: 1 (0.00%) (it's okay for some frames to lag)
RTMPPublisher::SocketLoop: Aborting due to bStopping
Number of b-frames dropped: 0 (0%), Number of p-frames dropped: 0 (0%), Total 0 (0%)
=====Stream End=======================================================================

Profiler results:

==============================================================
frame - [100%] [avg time: 4.392 ms] [avg calls per frame: 1] [children: 94.1%] [unaccounted: 5.94%]
| scene->Preprocess - [37.2%] [avg time: 1.636 ms] [avg calls per frame: 1]
| video encoding and uploading - [56.8%] [avg time: 2.495 ms] [avg calls per frame: 1] [children: 23.3%] [unaccounted: 33.5%]
| | CopyResource - [0.228%] [avg time: 0.01 ms] [avg calls per frame: 0]
| | conversion to 4:2:0 - [0.296%] [avg time: 0.013 ms] [avg calls per frame: 0]
| | call to encoder - [22.5%] [avg time: 0.99 ms] [avg calls per frame: 0]
| | sending stuff out - [0.273%] [avg time: 0.012 ms] [avg calls per frame: 0]
==============================================================

Pretty sure this is the failure:

Using Window Capture
RTMPPublisher::SocketLoop: Socket error, send() returned -1, GetLastError() 10054
Total frames rendered: 350599, number of frames that lagged: 138 (0.04%) (it's okay for some frames to lag)
Number of b-frames dropped: 0 (0%), Number of p-frames dropped: 0 (0%), Total 0 (0%)
=====Stream End=======================================================================
=====Stream Start=====================================================================
 

kur1

New Member
Just bumping since it's falling down the page with no reply.

So as some additional information, I'm residing in Japan and streaming to Twitch.tv's LA Backup server. What usually causes these reply errors? As you can see, relative to the amount of frames streamed my drop rate is fairly low. On the actual program it doesn't even log any dropped frames... which either means they drop ALL AT ONCE before the crash or they're not being reported in the dropped frames box.
 

paibox

heros in an halfshel
The error itself is just that your connection has been terminated on the remote side, so Twitch's server is disconnecting you for some reason, it's just weird that it's doing so at such reliable intervals.

As for why the preview goes black after it reconnects, I unfortunately don't know, I've never seen it happen myself, and when my internet feels like being bad I typically get disconnected a lot.
 

kur1

New Member
I'll try a new ingestion server. Thanks so much for the reply! :D How do you know it's the remote side and not something else?

As an aside, I'm using OpenDNS. My girlfriend uses the designated Google DNSes. Would which DNS servers we're routing through impact anything? Would 3 hours of constantly high upload trigger something?

The 'black screen upon disconnect' thing seemed to have fixed itself as of 0.47a.
 

paibox

heros in an halfshel
Well, I can't know for sure if it is the remote side, but that is what the error code itself indicates, and the error code's pretty much all we have to go on for now. :)

The DNS servers shouldn't be able to impact anything as long as you stay connected, as DNS is only used to resolve hostnames on initial connects and such.
 

Lain

Forum Admin
Lain
Forum Moderator
Developer
I appreciate the report, though I'm not sure as I just talked with someone who streamed for like 8+ hours. I wish I could give you an answer specifically but if I don't respond it does not mean I don't read thread. Your problem is specific and I took note.

Just as a note, I read pretty much every thread on the forum. Only time I usually skip reading is if: a.) It's a dumb/pointless thread b.) someone else seems like they are handling the issue pretty well, or c.) it's some feature they want I'm not interested in or already has been suggested before
 

kur1

New Member
Just to add to the situation, I switched to the Twitch Asia servers (from LA Backup) and just now, 3 hours in, the stream disconnected and reconnected. So I'm not sure it's server-based?
 

kur1

New Member
Just as a bump, this issue is still affecting me after troubleshooting:
1) the router (can't remove, but verified no blocked ports, etc.)
2) various bitrate/buffer settings
3) toggling low latency mode on/off
4) changing Twitch ingestion servers
5) changing from OpenDNS to Google's DNS servers

A bit lost what to do right now. :(
 

Bensam123

Member
I used to have this problem back in november and I'm not entirely sure what fixed it. This bug was a really old friend of mine and there are some posts on it if you search for them. It occurred right around 3:20h for me like clockwork, just like with you and other people were getting the same issue.

Streaming worked fine with Xsplit as same with you.

This may be something you need to mess around with till you find out what fixes it. Have you tried the CBR setting or CFR setting? I know this is a frustrating and a really hard issue to troubleshoot because it takes so long before it happens. Try setting your buffer to the same size as your max bitrate. Also try setting your quality to 8 or 9.
 

kur1

New Member
Just curious, what would adjusting the quality have to do with the crashes?

Right now I'm sitting at quality 6, but I was crashing at the same time at quality 10.

I doubled my buffer tonight (3500/7000kbps respectively), but was crashing Sunday with the same bitrate/buffer (4000/4000kbps then).
 

Bensam123

Member
I don't know, just something to try... I also don't know why your OBS client would be crashing due to a high quality setting. I remember someone else saying something similar. I've never had that happen or had it crash due to a same buffer/bitrate.

Is your system OC'd?
 

kur1

New Member
Yes, my system is OC'd. I have an i7 2600k that I bumped up to 4.5Ghz on air. Tested it in Prime95 and a few other programs in extended overclock testing environments without any crashes, BSODs, or failed cores/overheating. So I'm leaning towards it not being an OC thing.

Edit: I'll try to run the stream in CBR mode tonight just to see if having the data rate not 'fluctuate' as much helps anything.
 

Bensam123

Member
I would also try running a prolonged prime95 test... like overnight if you haven't yet. Easy way to see if this is causing it is just revert it to stock settings for one night and see if it fixes it.
 

kur1

New Member
Hate to necro my own thread, but a few versions later and this issue is still occurring, and still around 3 hours into every stream. Have tried many Twitch ingestion servers, but nothing's fixing it!
 

Lain

Forum Admin
Lain
Forum Moderator
Developer
I have no answer unfortunately. I don't know what's going on in your case. It says the server is disconnecting you from your last log file.
 
Top