aau-zid / BigBlueButton-liveStreaming

Streams a given BBB Meeting to an RTMP Server.
GNU General Public License v3.0
200 stars 159 forks source link

streaming stops after few seconds..works fine ..but when i share camera it stucks and stops #56

Closed kaneki666 closed 4 years ago

kaneki666 commented 4 years ago

full log liveStreaming | libavresample 4. 0. 0 / 4. 0. 0 liveStreaming | libswscale 5. 7.100 / 5. 7.100 liveStreaming | libswresample 3. 7.100 / 3. 7.100 liveStreaming | libpostproc 55. 7.100 / 55. 7.100 liveStreaming | [x11grab @ 0x558a84850b00] Stream #0: not enough frames to estimate rate; consider increasing pro besize liveStreaming | Input #0, x11grab, from ':122': liveStreaming | Duration: N/A, start: 1596003871.224501, bitrate: 1988667 kb/s liveStreaming | Stream #0:0: Video: rawvideo (BGR[0] / 0x524742), bgr0, 1920x1080, 1988667 kb/s, 29.97 fps, 1 000k tbr, 1000k tbn, 1000k tbc liveStreaming | Guessed Channel Layout for Input Stream #1.0 : stereo liveStreaming | Input #1, alsa, from 'pulse': liveStreaming | Duration: N/A, start: 1596003871.271654, bitrate: 1536 kb/s liveStreaming | Stream #1:0: Audio: pcm_s16le, 48000 Hz, stereo, s16, 1536 kb/s liveStreaming | Stream mapping: liveStreaming | Stream #0:0 -> #0:0 (rawvideo (native) -> h264 (libx264)) liveStreaming | Stream #1:0 -> #0:1 (pcm_s16le (native) -> aac (native)) liveStreaming | Press [q] to stop, [?] for help liveStreaming | [libx264 @ 0x558a8487a980] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2 liveStreaming | [libx264 @ 0x558a8487a980] profile Constrained Baseline, level 4.2 liveStreaming | [libx264 @ 0x558a8487a980] 264 - core 155 r2917 0a84d98 - H.264/MPEG-4 AVC codec - Copyleft 2003- 2018 - http://www.videolan.org/x264.html - options: cabac=0 ref=1 deblock=0:0:0 analyse=0:0 me=dia subme=0 psy=1 ps y_rd=1.00:0.00 mixed_ref=0 me_range=16 chroma_me=1 trellis=1 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_o ffset=0 threads=1 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_int ra=0 bframes=0 weightp=0 keyint=60 keyint_min=6 scenecut=0 intra_refresh=0 rc_lookahead=0 rc=cbr mbtree=0 bitrate=4 000 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 vbv_maxrate=4000 vbv_bufsize=8000 nal_hrd=cbr filler=1 ip_rati o=1.40 aq=0 liveStreaming | Output #0, flv, to 'rtmps://live-api-s.facebook.com:443/rtmp/3247149751974439?s_bl=1&s_sc=3247149 775307770&s_sw=0&svt=api-s&a=Abwtzvha1Q-SYP_': liveStreaming | Metadata: liveStreaming | encoder : Lavf58.45.100 liveStreaming | Stream #0:0: Video: h264 (libx264) ([7][0][0][0] / 0x0007), yuv420p(progressive), 1920x1080, q=-1--1, 4000 kb/s, 29.97 fps, 1k tbn, 29.97 tbc liveStreaming | Metadata: liveStreaming | encoder : Lavc58.91.100 libx264 liveStreaming | Side data: liveStreaming | cpb: bitrate max/min/avg: 4000000/0/4000000 buffer size: 8000000 vbv_delay: N/A liveStreaming | Stream #0:1: Audio: aac (LC) ([10][0][0][0] / 0x000A), 44100 Hz, stereo, fltp, 160 kb/s liveStreaming | Metadata: liveStreaming | encoder : Lavc58.91.100 aac [alsa @ 0x558a8485b5c0] Thread message queue blocking; consider raising the thread_queue_size option (current value : 1024)

mtsonline commented 4 years ago

could you please describe your problem? "stops" is a bit to less to help you here.

does the streaming start? so can you see the output on the rtmp server?

or does only the live user join the meeting for some seconds but the streaming does not really start?

did you check your servers cpu and memory?

did you change some bbb default settings?

kaneki666 commented 4 years ago

straming starts and when i open camera in bbb streaming stops ..user lefts the meeting..no i haven't changed anything!i am setting up a new server to try again

mtsonline commented 4 years ago

this sounds as if your server does not have enough cpu and memory and crashes because of that.

kaneki666 commented 4 years ago

whats the minimum server requirements for video streaming?

mtsonline commented 4 years ago

there is none defined yet, as there are too less experiences and feedback. You can help to define it, if you tell us how many you have and that it does not work with it. 4 cpu seem to be too few as far as I could notice in the past, but as said, not sure at all.

kaneki666 commented 4 years ago

yes i was using 2 cpu..no i have 6 cpu 20gb ram..its working fine..i will let u know more details..if you want. Btw if i want to make change i have to fork repo then update stream.py and make a image in docker right?? i have to make changes like make the video fullscreem..thank you for your help

mtsonline commented 4 years ago

great that it works now. so we defenitely know that 2cpu is too less. yes please let us know if you have any further details or new informations. regardless what.

if you make such changes / advanced features please fork the repo. change what you need - then start with a docker-compose that builds right away ... if you are fine with your changes make a pull request to the aau-zid repo so we can merge your features into the master branch. And please make such changes optional so people can switch them on/off as they need, that would be awesome.

cheers

kaneki666 commented 4 years ago

ok i will make pull request if those features works!! but i am confused about one thing i would edit the stream.py right? But image: aauzid/bigbluebutton-livestreaming whats this does? doesnt it find file from your repo? so how will docker find me changed repo? do i have to make a docker image like urs? or i just have to edit the stream.py file

mtsonline commented 4 years ago

to build a local version that you checked out from git, change the image: in the docker-compose to:

  bbb-streamer:
    container_name: liveStreaming
    build: 
        context: ./

then the docker image will be build on your local files instead of fetching it from dockerhub.