Audio/video stream recording forums (http://stream-recorder.com/forum/index.php)
-   rtmpdump (http://stream-recorder.com/forum/forumdisplay.php?f=54)
-   -  

How to use RTMPDump? - rtmp dump tutorials

(http://stream-recorder.com/forum/showthread.php?t=8911)

hyc 03-10-2010 03:48 PM

Re: How do you use rtmp dump (rtmpdump tutorials)?


 
rtmpdump 2.2 now includes a formatted manual page...

RTMPDUMP(1)
RTMPDUMP(1)

NAME
rtmpdump - RTMP streaming media client
SYNOPSIS
rtmpdump -r url [-n hostname] [-c port] [-l protocol] [-S host:port] [-a app] [-t tcUrl] [-p pageUrl] [-s swfUrl] [-f flashVer] [-u auth] [-C conndata] [-y playpath] [-v] [-d subscription] [-e] [-k skip] [-A start] [-B stop] [-b buffer] [-m timeout] [-T key] [-w swfHash] [-x swfSize] [-W swfUrl] [-X swfAge] [-o output] [-#] [-q] [-V] [-z]
rtmpdump -h
DESCRIPTION
rtmpdump is a tool for dumping media content streamed over RTMP.

rtmpdump makes a connection to the specified RTMP server and plays the media specified by the given url. The url should be of the form
rtmp[t][e]://hostname[:port][/app[/playpath]]
Plain rtmp, as well as tunneled and encrypted sessions are supported.
OPTIONS

Network Parameters
These options define how to connect to the media server.

--rtmp -r url
URL of the server and media content.
--host -n hostname
Overrides the hostname in the RTMP URL.
--port -c port
Overrides the port number in the RTMP URL.
--protocol -l number
Overrides the protocol in the RTMP URL.

0 = rtmp
1 = rtmpt
2 = rtmpe
3 = rtmpte
5 = rtmps
--socks -S host:port
Use the specified SOCKS4 proxy.
Connection Parameters
These options define the content of the RTMP Connect request packet. If correct values are not provided, the media server will reject the connection attempt.

--app -a app
Name of application to connect to on the RTMP server. Overrides the app in the RTMP URL. Sometimes the rtmpdump URL parser cannot determine the app name automatically, so it must be given explicitly using this option.
--tcUrl -t url
URL of the target stream. Defaults to rtmp[e]://host[:port]/app/playpath.
--pageUrl -p url
URL of the web page in which the media was embedded. By default no value will be sent.
--swfUrl -s url
URL of the SWF player for the media. By default no value will be sent.
--flashVer -f version
Version of the Flash plugin used to run the SWF player. The default is "LNX 10,0,32,18".
--auth -a string
An authentication string to be appended to the Connect message. Using this option will append a Boolean TRUE and then the specified string. This option is only used by some particular servers and is deprecated. The more general --conn option should be used instead.
--conn -C type:data
Append arbitrary AMF data to the Connect message. The type must be B for Boolean, N for number, S for string, O for object, or Z for null. For Booleans the data must be either 0 or 1 for FALSE or TRUE, respectively. Likewise for objects the data must be 0 or 1 to end or begin an object, respectively. Data items in subobjects may be named, by prefixing the type with 'N' and specifying the name before the value, e.g. NB:myFlag:1. This option may be used multiple times to construct arbitrary AMF sequences. E.g.

-C B:1 -C S:authMe -C O:1 -C NN:code:1.23 -C NS:flag:ok -C O:0
Session Parameters
These options take effect after the Connect request has succeeded.

--playpath -y path
Overrides the playpath parsed from the RTMP URL. Sometimes the rtmpdump URL parser cannot determine the correct playpath automatically, so it must be given explicitly using this option.
--live -v
Specify that the media is a live stream. No resuming or seeking in live streams is possible.
--subscribe -d stream
Name of live stream to subscribe to. Defaults to playpath.
--resume -e
Resume an incomplete RTMP download.
--skip -k num
Skip num keyframes when looking for the last keyframe from which to resume. This may be useful if a regular attempt to resume fails. The default is 0.
--start -A num
Start at num seconds into the stream. Not valid for live streams.
--stop -B num
Stop at num seconds into the stream.
--buffer -b num
Set buffer time to num milliseconds. The default is 36000000.
--timeout -m num
Timeout the session after num seconds without receiving any data from the server. The default is 120.
Security Parameters
These options handle additional authentication requests from the server.

--token -T key
Key for SecureToken response, used if the server requires SecureToken authentication.
--swfhash -w hexstring
SHA256 hash of the decompressed SWF file. This option may be needed if the server uses SWF Verification, but see the --swfVfy option below. The hash is 32 bytes, and must be given in hexadecimal. The --swfsize option must always be used with this option.
--swfsize -x num
Size of the decompressed SWF file. This option may be needed if the server uses SWF Verification, but see the --swfVfy option below. The --swfhash option must always be used with this option.
--swfVfy -W url
URL of the SWF player for this media. This option replaces all three of the --swfUrl, --swfhash, and --swfsize options. When this option is used, the SWF player is retrieved from the specified URL and the hash and size are computed automatically. Also the information is cached in a .swfinfo file in the user's home directory, so that it doesn't need to be retrieved and recalculated every time rtmpdump is run. The .swfinfo file records the URL, the time it was fetched, the modification timestamp of the SWF file, its size, and its hash. By default, the cached info will be used for 30 days before re-checking.
--swfAge -X days
Specify how many days to use the cached SWF info before re-checking. Use 0 to always check the SWF URL. Note that if the check shows that the SWF file has the same modification timestamp as before, it will not be retrieved again.
Miscellaneous

--flv -o output
Specify the output file name. If the name is - or is omitted, the stream is written to stdout.
--hashes -#
Display streaming progress with a hash mark for each 1% of progress, instead of a byte counter.
--quiet -q
Suppress all command output.
--verbose -V
Verbose command output.
--debug -z
Debug level output. Extremely verbose, including hex dumps of all packet data.
--help -h
Print a summary of command options.
EXIT STATUS
0
Successful program execution.
1
Unrecoverable error.
2
Incomplete transfer, resuming may get further.
ENVIRONMENT
HOME
The value of $HOME is used as the location for the .swfinfo file.
FILES
$HOME/.swfinfo
Cache of SWF Verification information
SEE ALSO
rtmpgw(8)
AUTHORS
Andrej Stepanchuk, Howard Chu, The Flvstreamer Team
<http://rtmpdump.mplayerhq.hu>
RTMPDump v2.2a
2010-03-10
RTMPDUMP(1)

rv123 04-02-2010 10:22 AM

Re: How do you use rtmp dump (rtmpdump tutorials)?


 
Anyone have or can provide a tutorial for a Mac OS user? Not a complete newb (or maybe I am!) but some of the windows command stuff doesn't translate over so well...or at least I can't get it.

Really just the basics of actually running RTMPdump in the terminal

any ANONYMOUS forum user 06-05-2010 10:41 AM

Re: How do you use rtmp dump (rtmpdump tutorials)?


 
rtmpdump -r "rtmp://bbcmedia.fcod.llnwd.net:1935/a1414/e3?as=adobe-hmac-sha256&av=1&te=connect&mp=bbc7/secure_auth/modem/RBN2_bbc7_-_saturday_1000_b0085hk0_2010_06_05_12_28_08.mp4,bb c7/secure_auth/RBN2_bbc7_-_saturday_1000_b0085hk0_2010_06_05_12_27_46.mp4&et =1275766361&fmta-token=d0c7ff443c9b8eb935df30bc2dd8a2b87e5479b15a30 0c661bba5a928a17d368" -a "a1414/e3?as=adobe-hmac-sha256&av=1&te=connect&mp=bbc7/secure_auth/modem/RBN2_bbc7_-_saturday_1000_b0085hk0_2010_06_05_12_28_08.mp4,bb c7/secure_auth/RBN2_bbc7_-_saturday_1000_b0085hk0_2010_06_05_12_27_46.mp4&et =1275766361&fmta-token=d0c7ff443c9b8eb935df30bc2dd8a2b87e5479b15a30 0c661bba5a928a17d368" -f "WIN 9,0,260,0" -W "http://www.bbc.co.uk/emp/9player.swf?revision=18182_20020" -p "http://www.bbc.co.uk/iplayer/console/b0085hk1" -y "mp4:bbc7/secure_auth/RBN2_bbc7_-_saturday_1000_b0085hk0_2010_06_05_12_27_46.mp4" -o RBN2_bbc7_-_saturday_1000_b0085hk0_2010_06_05_12_27_46.mp4

5peaker 08-29-2010 01:49 AM

Re: How do you use rtmp dump (rtmpdump tutorials)?


 
Quote:

Originally Posted by Stream Recorder (Post 10566)
Tutorial on using rtmpdump:

hello.
I have a question of swfsize. What is the swfsize?
is that hashdata of sha256? like a "e2436d6201f4265a0a0ad974165a3b26a6f302ba8e7cfebd6 dfad2cac28105e1" ?
I can't figure out the sha256num of a flash player.


Ed999 09-12-2010 12:23 PM

Re: How do you use rtmp dump (rtmpdump tutorials)?


 
The -W switch in rtmpdump is included for the purpose of calculating the swf size and hash values for you.

All you really need do is include the -f switch giving details of the Flash version installed in your computer, and the -W switch giving the URL of the swf file specified in the webpage which serves the Flash file you want.

Example (for the Windows browser plugin, i.e. for Internet Explorer, where you have the Flash Player 9 release 260 plugin installed):

-f "WIN 9,0,260,0"

-W "http://www.bbc.co.uk/emp/9player.swf?revision=18269_21576"

Cristianovic 10-27-2010 01:33 PM

Re: How do you use rtmp dump (rtmpdump tutorials)?


 
It is said that the rtmpdump can also be used for Mac, but I've only seen for windows and for Android. Is the other one for mac? How to use it as I'm not quite familiar with the Mac command

Tks:o

Stream Recorder 12-23-2010 01:57 PM

Re: How do you use rtmp dump (rtmpdump tutorials)?


 
To install rtmpdump, rtmpsuck, rtmpsrv in Ubuntu 10.10 Maverick, just type the following in the terminal:
Code:

sudo apt-get install rtmpdump

KSV 05-03-2011 08:23 AM

Re: How do you use rtmp dump (rtmpdump tutorials)?


 
RTMPdump is a command line application. you can't run it by double clicking. easiest way for you will be to create a batch file and then run it.

Code:

1. Open up Notepad in Windows.
2. Go to File > Save As...
3. Choose your rtmpdump folder as the location to save.
4. Click on the dropdown box "Save as type:" and select "All files" instead of Text (*.txt).
5. Add .bat to the end of your file name before you save. For example, you would type Commands.bat.
6. Click on Save. If you did this correctly, you should see your file name in the title bar of Windows Notepad. Make sure that it reads as Commands.bat not Commands.bat.txt.

now put your command eg:
Code:

rtmpdump -r "rtmpe://cp40493.edgefcs.net:1935/ondemand?ovpfv=2.1.4" -a "ondemand?ovpfv=2.1.4" -f "WIN 10,2,159,1" -W "http://media.mtvnservices.com/player/prime/mediaplayerprime.1.7.0.swf" -p "http://www.southparkstudios.com/full-episodes/s15e01-humancentipad" -y "mp4:mtvnorigin/gsp.comedystor/com/sp/season-15/1501/acts/sp_1501_act1_1280x720_1200.mp4" -o sp_1501_act1_1280x720_1200.flv
into the batch file, then save and run this batch file to start downloading.

T68 02-28-2012 08:42 AM

Re: How do you use rtmp dump (rtmpdump tutorials)?


 
Hi!

I want to record an ongoing live event that runs for weeks. So I need to record it in segments, like one hour. And I would like this to run automatically so that rtmpdump keeps recording hour long files like file1.flv, file2.flv, file3.flv and so on. Is it possible to do this with the commant line tool? Thanks for any help w this!

cndymn 07-22-2012 06:00 PM

Re: How to use RTMPDump? - rtmp dump tutorials


 
hey guys,

i have a list of 109 rtmp streams
i'm running mac os x 10.8

now i wrote a shell with this code

Code:

rtmpdump -r rtmp://file1.mp4 -o ../1.flv
rtmpdump -r rtmp://file2.mp4 -o ../2.flv
...

The problem is after the first dumping the terminal do not continue with the second line of code.

Another thing: i noticed that the streams got meta data in form of

Code:

INFO:  İnam          VIDEO_TITLE 
INFO:  İalb          WHO_MADE_THIS
INFO:  İgen          TUTORIAL

Is there a way to use this meta data espacially "İnam" for my filename?


All times are GMT -6. The time now is 03:29 AM.