Post Olympics

You might be curious as to what's happening to my setup once the Olympics finish on 12th August 2012. Well, here's the current plans:

Processing the recordings on the first PC

With one hour of an HD recording taking 4GB of disk space, the doubling-up of a lot of the recordings, the extra "auto-padding" (2 minutes before, 5 minutes after) I'll be adding to every recording, plus the inclusion of extra padding programmes as a precaution in case a recording overruns into a schedule gap that I'm not recording, there'll be an awful lot of video to remove, edit and ultimately re-encode.

It's likely one of the two PCs will be dedicated to this - I will try to script as much as possible and set up a set of queued jobs probably to be run overnight. I've already experimented with the commands needed to both start/end at a timed position in the recording and re-encode down to about a 2GB per hour file. The likelihood is that I'll actually have to schedule some time to do this each day - copying the next chunk onto SSD, viewing the video to decide the start and end points (I will probably high-speed FF through it to look for any obvious glitches too), adding that info to the script's overnight job config file and then leaving the PC on overnight to do the re-encoding (yes, I'll experiment with doing 2 or more encodes at once since I have a quad core i7 with 8 threads). Once the re-encoding is done on SSD, I'll still have to high speed FF the re-encoded file looking for issues and then it'll be copied back to HDD of course. With 2,500 hours of video to process, I'll have to make as much as of this as friendly/quick as possible.

I'm expecting this to take several months to complete though, since I'll be back at work for the rest of the year until a few weeks before Christmas 2012. It will done on the quieter PC in my bedroom, which will become a normal CentOS 6.3 workstation desktop. It might be cute to see if I can set up a second HDMI connection (first will be to a Dell 24" monitor) that hooks to the 50" plasma and if I can run a virtual desktop on that second connection. If that works, then a VM running Ubuntu+XBMC+PVR in that second desktop fullscreen would actually eliminate the need for the Revo in my bedroom. I'm not doing that setup in the Olympics because it's all too much of a single point of failure.

Second PC becomes a media centre

The second PC (the "noisier" one!) in the downstairs lounge will become a dedicated media centre post-Olympics, which at the moment means Ubuntu + XBMC + tvheadend, but that could change over time. This will use one set of tuners for satellite/terrestrial and may actually be hooked directly up to a plasma, rather than using a Revo as a viewing client. It will probably only need an SSD and a single 3TB drive to start with and will be pressed into normal non-Olympics recording service very quickly after the closing ceremony. I will probably still run my SSD -> HDD shifting C program that I've coded for the Olympics. It will also run a script that will suspend the PC when no recording or viewing is taking place and wake up again about 5 minutes before the next recording is due. A Wake On LAN request will be issued to it when another client PC boots to wake it up early if a client needs to use it for viewing live channels or recordings or playing various media.

Revos potentially get decommissioned

If I can use each of the desktop PCs to drive both a 24" monitor and a plasma with separate fullscreen desktops, then ultimately the two Revos could be decommissioned not long after the Olympics finish. The reason I'm using the Revos as viewing clients during the Olympics is that I can mess around with them, including reboots, code changes etc. and not affect the recording of the Olympics channels (which are done on non-Revo PCs). After the Olympics, at least one of the Revos may become redundant, but that's not an issue because I can set one up for a friend or family and pass along a USB Freeview HD tuner with it too.

Organising the recordings directory structures

tvheadend will be recording mkv's in the format YYYY-MM-DD/Channel-Name/EPG-Name.mkv, though they do appear in the Live TV section of XBMC as "EPG Name". Yes, I 've set tvheadend to use dashes instead of spaces in filenames because spaces cause grief on the Linux command line. To avoid the Live TV section getting clogged up with thousands of entries during the Olympics, I will be clearing that out (the entries, not the mkv files!) regularly - probably on a daily basis. Hence, post-Olympics, it will be the Videos section of XBMC that will be used and the data/channel/EPG Name arrangement for the filename (which is what gets displayed on the Videos browser) isn't satisfactory really.

The additional snag is that I'll be doing 2 types of recording - one dedicated to a single sport (i.e. from one of the 24 HD channels) and one that's a mix of sports (i.e. from the remaining BBC Olympics channels). Hence, the best solution to this is to put them in two dirs - "Olympics_2012_Sports" and "Olympics_2012_Channels" - because I'll probably have other non-Olympics video dirs at that level too.

Inside the Olympics_2012_Sports dir, the obvious top-level structure should be the sport name and if it's split into sub-events, they should go one level down (e.g. 100m, 200m etc. for athletics). The filename should include the group/round/heat number of a round if it applies and also any competitors/countries if it's a solo or duo sport. It would be a good idea to use something like "_GB" in a filename (e.g. Round_1_Heat_1_GB.mkv) to indicate that a British competitor was involved to make it easier to pick out when scrolling through filenames. As you can see, even the dir/filenaming convention is quite a lot of work.

So that all works when a channel is dedicated to a single sport throughout the day, as all the 24 HD channels will be. However, other channels such as BBC One HD, BBC HD etc. are probably going to air a mix of sports, even within a single short transmission slot. Hence, they will need a separate structure that is date-based and inside an "Olympics_2012_Channels" dir. I'd just have date sub-directories (e.g. 0725, 0726) and channel sub-directories underneath those (e.g. BBC_One_HD, BBC_Two and so on). The filename would be probably be just the start transmission time (e.g. 0930.mkv) rather than the actual EPG programme title (which is probably always something like "Olympics 2012" anyway). Hopefully, any meta-data is saved in the mkv, so the filename doesn't mean a lot really.

Extracting events out to USB stick

Should I want to put any events onto a USB stick (e.g. to view on the move via a netbook), then I'll probably write a script to copy one or more mkv files based on a menu of options (e.g. pick a sport, then one or more sub-events, then one or more actual video files within that). An option here might be to offer to transcode it away from H.264/mkv to another format, but that could be slow if a lot of mkv's are involved.

Yes, there will be even more spare hardware

People keeping track of my expensive setup may actually realise that, post-Olympics, I actually won't be using the satellite dish, terrestrial aerial or the PC tuners in my bedroom any more! This is mainly because running two media centre PCs outside of the Olympics is just overkill really. Also note that I suspect it's not possible to run tvheadend in a VM w.r.t. configuring TV tuners since it'll need to talk to PCI hardware directly (otherwise I would have run tvheadend in an Ubuntu VM on my bedroom PC).

Hence, I will probably still have to keep the Olympics recording setup in a partition on the bedroom PC and that will still allow me to boot into it occasionally, should I have trouble with the media centre PC. Over time, though, this might get neglected if the media centre PC remains stable. The only difference in the recording setup. BTW, is the terrestrial TV regions in each room, but since I never watch "local" programmes - much preferring to record programmes from satellite where possible - it's unlikely I'd ever boot into the recording setup on the bedroom PC just to watch/record a different terrestrial TV region!

Long-term backup of Olympics video

I have eight 3TB hard drives in total, so after any post-Olympics video editing/removal/re-encoding, the plan is to try to get the entire Olympics coverage on three of the 3TB drives. One copy will be archived long-term in anti-static bags and then in padded envelopes and then into a drawer somewhere.

A second copy will be put into the media centre PC and mounted read-only to avoid deletion (though if it is deleted or corrupted, that drive can be replaced and then the corresponding first copy drive can be cloned back to the second copy). Any spare 3TBs will added to the first PC, though one of these spares may not be used much if at all to act as a hot spare for either PCs hard drives.

1 comment:

  1. Hello,

    I'm trying to get hold of a recording of Day 13 Athletics (Rudisha and Bolt) as I was fortunate enough to go and want a record of it Ideally both the BBC screening for the UK but also the more generic one for the rest of the world. I had set my video to record but one of the children turned it off!!

    Obviously I'm quite happy to pay a reasonable fee for the work.

    Do you know how I can arrange this? Your advice would be really helpful.

    Many thanks,

    Richard Marriott

    ReplyDelete