VLC as a Re-streaming server - proposal
Posted: 29 Jun 2019 14:47
Situation:
Have few stream sources (cameras) on different locations, usually behind NAT. All cameras are connected via VPN to the streaming server. Each camera belongs to each user. Creating simple web interface where single user could log-in and web page display stream from source belong to this specific user. Using VLC as a re-streaming service, managed by VLM. Stream for every single user listen on specific HTTP port. Some sources are physsicaly connected via cellular network with data limit, thus streaming from ALL sources to server should ___ONLY___ run when user is logged-in (watching).
Question 1:
Should I pre-defined streams for all sources at once, and only perform play/stop command via VLM in a moment when user is logged in? Or better solution is define (and start playing) stream in a moment when user log-in? Does many (up to hundred) defined stream consumpting a lot of server resources?
Found in the VLM manual there is some way to keep defined streams accross possible restart, is it suitable for my usecase?
Question 2:
Reading documentation but unable to find moment when server start receiving stream from primary source (camera). In the moment when stream stream is defined or in moment when command 'play' is received by VLM.
Is it possible to set-up VLC in manner that start downloading stream from primary source is triggered by connection client to specific port on the stream server (and stop downloading when client disconnect)?
Question 3:
Plan to add ability to save watched stream into a file on the server, is suitable way to start another vlc instance on the server, start downloading stream from localhost and saving it into a file? Cant realize how to stop such process unless perform TASKKILL command from system shell.
Is there better way to start / stop saving stream into the file? Saving should not be in any way bundled with watching, it should be possible to start saving after stream is started, and stopped before watching is ended.
Have few stream sources (cameras) on different locations, usually behind NAT. All cameras are connected via VPN to the streaming server. Each camera belongs to each user. Creating simple web interface where single user could log-in and web page display stream from source belong to this specific user. Using VLC as a re-streaming service, managed by VLM. Stream for every single user listen on specific HTTP port. Some sources are physsicaly connected via cellular network with data limit, thus streaming from ALL sources to server should ___ONLY___ run when user is logged-in (watching).
Question 1:
Should I pre-defined streams for all sources at once, and only perform play/stop command via VLM in a moment when user is logged in? Or better solution is define (and start playing) stream in a moment when user log-in? Does many (up to hundred) defined stream consumpting a lot of server resources?
Found in the VLM manual there is some way to keep defined streams accross possible restart, is it suitable for my usecase?
Question 2:
Reading documentation but unable to find moment when server start receiving stream from primary source (camera). In the moment when stream stream is defined or in moment when command 'play' is received by VLM.
Is it possible to set-up VLC in manner that start downloading stream from primary source is triggered by connection client to specific port on the stream server (and stop downloading when client disconnect)?
Question 3:
Plan to add ability to save watched stream into a file on the server, is suitable way to start another vlc instance on the server, start downloading stream from localhost and saving it into a file? Cant realize how to stop such process unless perform TASKKILL command from system shell.
Is there better way to start / stop saving stream into the file? Saving should not be in any way bundled with watching, it should be possible to start saving after stream is started, and stopped before watching is ended.