tfabris / CrowCam

A set of Bash scripts to control and maintain a YouTube live cam from a Synology NAS.
GNU General Public License v3.0
4 stars 3 forks source link

Stream stuck at "starting..." on 2019-06-23 #42

Closed tfabris closed 5 years ago

tfabris commented 5 years ago

The morning of 2019-06-23 07:55 am, I observed the stream was stuck at "starting..." on the YouTube live dashboard page. The only stream data error being shown there was "Check Resolution" like it always says. No other errors were being shown.

Reolink app shows a perfectly fine live video feed at the correct 1296p/3mbps resolution setting.

YouTube stream settings, metadata, etc., are all correct. The secret key hasn't changed either.

Need to check Synology logs to see what's going on here.

Trying: Rebooting the camera from the reolink app.

tfabris commented 5 years ago

Rebooted camera at approximately 2019-06-23 8:05 am. Reolink app shows camera is back up, though the frame rate looks choppy. YouTube stream still stuck at "Starting..."

tfabris commented 5 years ago

Trying second reboot of camera at 8:09 am.

tfabris commented 5 years ago

Bouncing the camera didn't work. At least not at 8:09 am when I tried it twice.

I ran the script (remotely) and I have attached the output. The script thinks the stream is still up, so it's not trying to bounce it or anything. I have attached the script debug output, but the relevant part of the script thinks the stream is still up:

CrowCam Controller - streamStatus: active.
CrowCam Controller - healthStatus: ok.
CrowCam Controller - Live stream is up.
CrowCam Controller - Status - Network up: true - Stream up: true.

I waited until after the midday bounce. Still the stream was stuck at "Starting...." even after midday bounce time. My guess is that it would have bounced the stream since it's the height of summer. I checked the API quotas, those are fine. Nothing seems to be going weird with the YouTube API or anything. All of the stream metadata is correct and unchanged, including the stream live ID and the stream key and publicity status. Nothing is changed, all seems well except for the "Starting..." problem. The Comcast internet settings page (comcast quota) seems OK.

I have looked at the debug output and there is one way to tell that this is occurring. In the $liveBroadcastOutput there is "lifeCycleStatus": "liveStarting"

   "status": {
    "lifeCycleStatus": "liveStarting",
    "privacyStatus": "public",
    "recordingStatus": "recording"
   },

However, even if I detect this state, the most my script could do is bounce the stream. Well, we already did that, at midday, and the stream still isn't up.

I'm going to have to look at what this looks like while I'm at home. I wonder if it's a new Synology bug of some kind. Perhaps there's something going on with it.

Debug output (remote run).txt

tfabris commented 5 years ago

Returned home and looked at the system directly. Attached are some logs and screen shots.

I'm stumped so far.

System Log 2019-06-23 issue 42.txt

Surveillance Station Log 2019-06-23 issue 42.txt

Abnormal Camera Status Screen Shot issue 42

tfabris commented 5 years ago

Tried:

tfabris commented 5 years ago

Tried:

Well, let's see if creating it from scratch again works.

tfabris commented 5 years ago

Creating the livestream from scratch again, worked.

So this must have been entirely a YouTube glitch. But how to detect and fix it?

Conclusions:

Detection of this issue:

IMPORTANT NOTE:

Description: (detailed description that I keep in a separate text file)

Change Thumbnail: (I have a thumbnail that I keep on my local machine that I can upload when I need it)

Category: Pets & Animals

Stream Optimizations: Normal Latency.

(Enable DVR is on by default.)

IMPORTANT: Activate the "Make archive unlisted when complete" feature! This is unchecked by default.

Tags:

Crows, Squirrels, Animals, Live, Cam, Webcam, Birds, Birdwatching

tfabris commented 5 years ago

I've updated my repository with the notes on creating a new stream from scratch, and moved my title card into the repository. I should now be able to fix this issue remotely if I need to.

One idea I did not try, but now that I see what worked, I wonder if it would have worked:

Next time this happens, try that first instead of recreating the whole stream from scratch again.