[conspire] get back to me first
Rick Moen
rick at linuxmafia.com
Tue May 17 19:49:43 PDT 2011
Quoting Bruce Coston (jane_ikari at yahoo.com):
> I need to get a distro on one of my many small -ish laptop partitions
> that will play back youtube videos I suck at the library after I
> suspend to disk and go home during our many summer internet outages .
> My elive install suffers real problems with this after I take it off
> disk suspend back home . Kde3. prefered , the kde. situation has me
> contemplating open bsd. . I could sacrifice my 32g usb flash drive to
> this project .
>
> I don't have the skill to do this anymore and need to know ahead of
> the event .
Bruce --
I'm going to make a longer post on this subject that aims to be more
comprehensive, but here's the short version:
You're relying on local cache state of the Adobe Flash interpreter being
useful and complete after suspend to disk. Bad strategy. Instead,
install scripts or browser extensions to download the clips to local
disk.
Slight elaboration: I'm assuming Flash (Sorenson H.263 encoding in FLV
container) for the sake of discussion, though Google's YouTube service
also offers video in MPEG Licensing Authority's patent-problematic
H.264 encoding in either FLV or MP4 (MPEG-4 Part 14) containers (often
inaccurately called 'HTML5' video), in Google's (ex-On2) VP8 encoding in
WebM containers (which along with Vorbis encoding in a Matroshka
container is part of the HTML5 draft), and in MPEG-4 Visual encoding in
3GP containers (a format primarily intended for mobile 'phones). It's
pretty much the same problem regardless.
Why a problem? Your media player plugin (Adobe Flash, for the sake of
discussion) is streaming in the inbound A/V bistream and dumping it into
~/.mozilla/firefox/[hash]/Cache on an ongoing basis, _but_ that cached
copy isn't guaranteed complete and useful at any given moment. Also,
it's not the least bit surprising to hear that Adobe Flash acts stunned
and stupid if it suddenly wakes up after being suspended to disk. So,
no, you're actually lucky if that ever works, because you can be sure
that the buggy spaghetti code in question isn't designed to do it.
So, let's say you look at the page HTML on a YouTube page to try to find
the .flv direct link so you can pull a copy down using wget or curl.
Surprise, you can't find it. Why not? Because you are not Google's
customer; you are their product -- and they are far, far more eager to
make Our Lords in Hollywood happy than they are you. So, they cause
YouTube to wrap the .flv link in inscrutable JavaScript, in order to
make it difficult to puzzle out. Moreover, they gratuitously change
that JavaScript obfuscation occasionally, to screw people up who've
de-obscured the latest version and are letting others know how.
_Nonetheless_, there are folks who gamely keep up with the changes, and
you can & should benefit from their work:
o clive (Perl script)
o cclive (newer C++ rewrite of clive)
o youtube-dl (Python script)
o Flash Video Downloader (Firefox extension)
o Easy YouTube Downloader (Firefox extension)
Get 'em all.
There are distro packages for clive, cclive, youtube-dl (judging by
Debian). You _may_ find the disto packages' frequency of update
adequate to keep up with JavaScript mischief at YouTube, Photobucket,
Dailymotion, Metacafe, Facebook, Yahoo, depositfiles.com, etc. -- or
not. If not, you might need to have them as locally installed and
updated software.
ALSO:
There's a persistent misconception, spread about by various twits,
that the open source Flash interpreters (Gnash, Swfdec, and GPLFlash)
are inadequate to handle the Flash served by YouTube. No, wrong. It's
really just the obfuscatory JavaScript. Which, if you use a downloader
such as those listed above, and it works, suddenly becomes a
non-problem. So, in addition to the recommendations above, please
consider losing the Adobe Flash proprietary garbage, or at least using
gnash in preference. (For one thing, the gnash developers don't spy on
users, about which please see http://lwn.net/Articles/129729/ .)
More information about the conspire
mailing list