From approximately 5-October until 23-November, in-browser video playback in OMwiki was completely broken. Visitors were greeted with a “Video playback is broken at the moment. :-/” top-posted message, which leads to poor first impressions and undermines our overall credibility. So, what happened and how can it be avoided in the future?
Click here to skip the tech breakdown.
All video currently hosted on OpenMeetings.org is encoded in the Ogg Theora format and is stored in the
/archives subdirectory. Currently, there is no content delivery network (CDN) in place, so all video originates from a single server. This server utilizes
oggz-chop, which is part of the
oggz toolset — it’s one of several programs that manipulate Ogg files in helpful ways.
oggz-chop is a binary program that returns the very beginning of an Ogg Theora file proceeded immediately by the section of interest indicated by a query string appended to the URL request (
/archives/video.ogv?query_string). The query string contains the requested start/end time, and makes possible user-friendly jump-to-this-time URLs. Thus, we achieve intelligent seeking.
oggz-chop is a binary program, it is sensitive to changes in the host operating system. Sometime early October, our hosting provider migrated all shared hosting plans to a new compute cluster and operating system. The migration was unannounced as there is a general expectation that shared hosting plans will not run executable binaries; most customers would not have noticed a difference. Compiling natively on both the old and new clusters is disabled for security.
How was it fixed?
The new operating system lacked the
libogg.so shared library, a mandatory dependency. Both
oggz-chop where compiled on a binary-compatible machine and the resulting binaries were copied over. This is a mostly-blind trail-and-error process.
I unsuccessfully attempted to create a single binary that contained both libogg and oggz-chop via static linking. I found alternative route by including a runtime search path (
export CFLAGS='-Wl,-rpath=/home/openmeet') such that
oggz-chop could locate
libogg.so in a non-system directory. Tweak some variable names in
cgi.c, and voilà!
#define DOCUMENT_ROOT “/home/openmeet/public_html”
. . .
getenv (“PATH_INFO”); –change-to–> getenv (“REDIRECT_URL”);
[Post truncated for brevity 11-June-2012]