<woooork in progress>
What I’m working on is to start a stream and open a Remote port over ssh tunnel – this is going to be designed for extremely high availability hosting.
concept is this
- main audio machine not accessible from external IP – but could open ssh connection out or initiate stream
- would need to be streamed to server – pre encoded to final stream.
- ideally – the system to stream from is Linux based – command line only
- use ssh tunnel push mode (-R1234:localhost:1234) then optimally multistream from external server
- configuration of local machine should remain simple so that this could be replicated anywhere.
Methods
- encode to mp3 mux ogg ?
- encode asf push out.
- user access control
- rewindable ?
Video Stream Example (from http://www.wikihow.com/Stream-Your-Webcam)
uses push method … might work without ssh
Streaming PC
vlc dshow:// :dshow-vdev="ZSMC USB PC Camera (ZS211)"\
":dshow-adev="ESS Maestro" :dshow-size="320x240"
\--sout='#transcode{acodec=mp3,ab=16,vcodec=mp1v,vb=64}'\
':standard{mux=ts,access=udp,dst=tek:1234}'
Transcoder
vlc -vvv udp:1234 --sout '#standard{access=http,mux=ogg,dst=:8080}'
The “-vvv” switch adds lots of debugging information to the output; to run it “silently”, get rid of that once you have everything running smoothly.
Audio mp3 stream example (from: http://www.linuxquestions.org/questions/linux-networking-3/playing-audio-files-over-ssh-connection-linux-linux-432640/)
Streaming PC
vlc -I http --control http:rc --rc-host :4800 --http-host :7000 --no-rc-show-pos --volume 500 --spdif -vvv /home/laptop/all.m3u --random --sout-keep --sout '#duplicate{dst=display,dst="transcode{acodec=vorb,anc=vorbis{quality=2},ab=64,samplerate=44100,channels=2}:standard{access=http,mux=ogg,url=192.168.3.2:8000}"}'
To explain what’s going on:
vlc opens in the background with an http interface available. vlc can be controlled by both the http interface, on port 7000, and a remote control advanced telnet interface on port 4800. It’s playing the all.m3u playlist, at random, and keeps the stream-out alive between tracks. The stream-out (sout) is duplicated: the first stream plays locally (display), whilst the duplicate stream is transcoded via vorbis, to a quality of 2, at a bitrate of 64, 44100 mhz, stereo, with an ogg stream via http on port 8000.
Transcoder
ssh -l username serverĀ -L 8000:127.0.0.1:8000
once you have established your ssh connection using this command, you can point your music player (vlc method) or browser (gnump3 method) to localhost:8000, and voila, you’re listening to music you can’t possibly complain about.