RSS

Errors with MiroBridge

0 Comments | This entry was posted on May 30 2010

For a while in MythTV 0.22 I was getting an error with MiroBridge saying Miro was not set up properly even though Miro worked just fine and I triple checked all my config files. I waited until upgrading to MythTV 0.23 to fix it because there was a much easier one button install option in Mythbuntu Control Centre. MiroBridge ran successfully once but I started getting files added to my recordings screen that didn’t exist. Once I manually cleared out the files MiroBridge automatically ran again but caused even more problems by having the two non-recordings show up 44 times.

Once I got all of those recordings removed MiroBridge would never successfully run for me again. I could run MiroBridge manually but every time I would get an error

AttributeError: ‘NoneType’ object has no attribute ‘lower’

and MiroBridge would just hang. I would have to force quit the script and never got past that point. I figured out how to fix this issue with a lot of Googling. The problem happens because all of those files that didn’t exist from before were referenced in my database and MiroBridge was trying to remove them. Because they weren’t cleanly removed from the recordings screen (or Miro) MiroBridge couldn’t delete the listings. So what we have to do is clean up these erroneous database references manually. If you have phpMyAdmin installed on your machine you can easily delete these referenced recordings through there but I didn’t want to have something else installed on my MythTV box so I did it through the terminal. Before you go on this is a great chance to learn how to use screen because we are going to want to reference a lot of information from a bunch of different terminal windows. You can either do this with multiple terminals or you can be cool and do it with screen.

Here are the steps you need to take to fix this error.

Step 1. Troubleshoot and Backup
Close out of MythTV and open a terminal. From the terminal run MiroBridge with the simulate option (-s) and redirect the output to a file (>). In MythBuntu 10.04 the command is
/usr/share/doc/mythtv-backend/contrib/imports/mirobridge/mirobridge.py -s > mirobridge.log
BTW this command needs to be run from the local machine and not through ssh because I believe the $DISPLAY variable isn’t set to :0 so MiroBridge gets confused when you are remote. We could change that variable but it is just as easy to work from the local machine.
Now we need to make sure you are having the same error I was having. To do this we are going to read that file you just created and check for any lines that tell MiroBridge to delete old recordings from the database.
cat mirobridge.log | grep oldrecorded
If you don’t have any output from this then you probably have a different error than what I was getting. If you have a bunch of lines outputted that look like this

Simulation: Remove orphaned oldrecorded record (None – ?????)

Then you have the exact same error and should continue on to the next step. Make note of the ????? value cause we will need it later. It should be the name of the video file that was giving us errors.
It is a good idea to always backup your mythconverg database so you may want to run this before continuing
/usr/share/mythtv/mythconverg_backup.pl

Step 2. Close Miro
ps aux | grep miro
Find each line that says something like /usr/bin/miro or mirobridge.py and then get the number at the front of that line and type kill *number* If you have more than 1 line just put each number and it will kill all of the running instances.
Now that Miro and MiroBridge have been killed move on to manually removing the recordings information form the database.

Step 3. Remove old data
First thing you will need is your database username and password. The easiest way to get this is just to use
cat /etc/mythtv/mysql.txt
At the begining of the output you should have DBUserName and DBName. You will need both of those but it is probably mythtv and mythconverg so make sure you also get the DBPassword near the bottom of that output.
Once you have that information connect to your mysql server. Replace ‘password’ with your actual password from the /etc/mythtv/mysql.txt file.
mysql --user=mythtv --password='password'
Then we just want to make sure we have the right mysql server (just because it is better to be safe than sorry).

SHOW DATABASES;
You should see your mythconverg table here so go ahead and use it.

USE mythconverg;
SHOW TABLES;

You should then see a whole lot of tables but the one we want is the oldrecorded table. Just to make sure we have the right information you are going to view all the erroneous database entries before you delete them. For the ????? you need to use the recording name that you got from step 1. Make sure you use the correct case when searching for the information.
SELECT * FROM oldrecorded WHERE subtitle = "?????";
If there were more than one different entry names simply put OR subtitle = “?????” with your next value. In my case I had two different recordings that caused the problem so I used
SELECT * FROM oldrecorded WHERE subtitle = "STALKER_REPORTER_ITUNES.mp4" OR "tekzilla--tzdaily--0464--2009-10-16gmaps--hd.h264.mp4";
This should list all of the entries so now you just need to delete them from the database.

DELETE FROM oldrecorded WHERE subtitle = "?????";
Just like above you can use the OR command to delete multiple entries at once.
Once the entries are deleted just type exit; to leave mysql and go back to the normal shell prompt.

Step 4. Test
Now that the the entries have been deleted repeat step 1 again and you shouldn’t have any lines returned that say
Simulation: Remove orphaned oldrecorded record (None - ?????)
You should then be able to run MiroBridge without the simulation option and get your Miro videos imported into your recordings. It is a good idea to still use the verbose (-V) option just to make sure everything goes smoothly.
/usr/share/doc/mythtv-backend/contrib/imports/mirobridge/mirobridge.py -V

That is all you need to do. Just make sure you set up your cron job to automatically run MiroBridge however often you want and you should be all set.

I hop this helps and leave a comment below if you have any questions.

Making of webOS (r)evolution commercial

0 Comments | This entry was posted on May 17 2010

I know what you are thinking, “how did my wife create that amazing (r)evolution commercial?”



I would like to take a couple minutes to share with everyone how she made it, and what software I used to help her edit it.
First of all here was the setup.



She started with a piece of poster board paper taped to our kitchen floor. Then added a microphone boom with a mini tripod zip tied to the end of the boom. This allowed her to take pictures from the same height every time and also gave a little flexibility in moving the camera around. Finally she added two small halogen lights to either side of the paper to light the “stage”. When taking pictures she took a picture of the whole piece of paper every time and we used software to edit the photos later.

For the commercial she needed 3 full size webOS cards and 6 smaller phones. She started with making the phones.



The phones were made so well it was almost painful to do this to them. The animation was made by crumpling the phones and then playing the animation backward in the commercial.



The cards were pretty easy to make. The hardest part was the animation of the media player. To animate the media player we had to cut slivers off of each album art and then tape them back together one piece at a time. It was time consuming but we were very pleased with the result. The calendar was intentionally longer than the other cards to compensate for when it would be folded.



Once all of the pictures were taken we needed to figure out how to manage 1000+ pictures to make a 1 minute commercial. To start we split up the pictures into folders labeled for each scene and numbered them in order 01_dynatac, 02_nokia, etc. We then used Phatch to trim off edges of each picture and essentially “zoom” into each picture to the size we wanted. Once the pictures were trimmed M├ętomorphose renamed all the pictures in sequence and then Stopmotion stitched all the pictures together into one video file. To add music and narration to the commercial I used Audacity to record the script she wrote for me and then OpenShot and PiTiVi to match up the audio and video and then export to a finished file. We could have just used one video editor, but OpenShot had a weird white frame at the end of the video so we tried PiTiVi and didn’t have a problem.
We hope you all enjoy the video and I just wanted to take the time to show a little behind the scenes for everything that went into making it. If you listen to mintCast you will know how impressed I was with this finished product, and the fact that it was made entirely with free and opensource software.
If you get a chance, head over to webOS Roundup and vote for the commercial.

MythTV how-to video – Part 2

0 Comments | This entry was posted on Nov 24 2009

This is a continuation of Part 1 and in this video I just walk you through a Mythbuntu installation and what options you want to use. The next parts will be about configuring the software past the initial installation.

Sorry for the sound quality. I had to use my digital camera for video (which is what I used in part 1) but for some reason there was a ton of static on the recording.

MythTV how-to video – Part 1

5 Comments | This entry was posted on Oct 31 2009

I have been working on my MythTV box for some time now and finally got around to editing the first part of the how to I recorded when setting it up. The first part is just about setting up the hardware (not much new), but the second part (and probably third and forth) is going to be on setting up the software and getting things configured just the way you want them to be.

HP MediaSmart Server ex485 review

0 Comments | This entry was posted on Sep 12 2009

I bought my HP MediaSmart Server quite a while ago and I have had a few random posts about it but I wanted to do an official review to let you know what I think of it. In order to successfully review this I am going to break it up into 2 sections: hardware and software.
HP MediaSmart ex485

Hardware:

The hardware is almost identical to HP’s old ex475 MediaSmart servers on the outside but the inside now has a Intel Celeron 2.0 Ghz processor with 2 GB of RAM. That is a pretty big upgrade compared to the old AMD 1.8 Sempron with 512 MB RAM. One of the biggest jumps internally for the ex485/ex487 is the jump to a 64-bit processor. While this currently doesn’t matter to much, Microsoft’s next version of Windows Home Server is going to be built off of Windows Server 2008 R8 which is 64-bit only. This means that the ex480 family can technically run the future software without another hardware upgrade.
Externally, the hardware is great. Four hard drive bays right where they should be, three USB in the back, eSATA, and gigabit ethernet. At first I didn’t even think I would use the front USB port but I find that I use it quite often when copying large amounts of information to the server.
I can’t say much about the hardware except for the fact that it is wonderful. I haven’t had any hardware problems and the device is small enough and quiet enough to leave next to my laser printer and no one knows it’s there. The device is fairly quite, but one of my hard drives is a bit old and I think makes more noise than necessary. I would say I have never heard the device over the TV being on, but when the room is completely silent, the hard drive noise is enough to not let me fall asleep.
HP MediaSmart ex485
Pros:
Small
Relatively Quiet
Lots of storage options (4 hard drive bays, 4 USB ports, 1 eSATA port)
Plenty of speed
HP MediaSmart ex485 hard drive tray
Cons:
The bays were a little awkard at first
eSATA not replicating (no daisy chaining eSATA devices like you could with the old systems)

Software:

First of all, the NAS solutions I have used in the past have always been DIY solutions. Even the Buffalo Linkstation I hacked so that I could load a full Debian Linux install on it for more flexibility. Other than that I have used Ubuntu Server, FreeNAS, Windows, and a few other solutions, and have looked at solutions like unRAID, Linksys, and QNap. So far every single system I have used just seemed pieced together and not a finished product. That was until I used Windows Home Server.
Windows Home Server is built off of Windows Server 2003 and this is a very good thing. Windows Home Server is available as a retail purchase or you can buy it pre-installed on a lot of NAS systems out there. The retail version allows you to build your NAS from the ground up. Everything from the hardware, OS, and add-on software can be customized which is great for people that want a bit more control but don’t want all the headaches of some Linux incompatibilities. Plus if you buy the software retail you can start with cheap hardware and then work your way up as you get small amounts of budget instead of plopping down ~$600 for a all-in-on retail solution.
The key feature of WHS is the folder duplication. It allows you to use any hard drive and adds all the storage to a pool of available space, similar to the Drobo. The reason this kicks the Drobo’s ass is if your WHS machine dies, all of the drives are formatted with NTFS so you can just pull the hard drives and get the information off of a new computer. With the Drobo, if your Drobo dies, so does everything stored on it cause it uses a proprietary format. This type of storage is really the way things are moving because people are finally realizing that RAID is not a backup solution. RAID is for speed and eliminates down time, period.
The software does what you would expect and the configuration is handled in a stupidly simple Home Serverwhs_console_1 Console. I actually dislike the console just because I feel like it makes things too easy. As much as you can do with the console some things just aren’t there yet (such as copying from a local USB drive to a share). But because the system runs Windows Server you can just RDP to the machine and copy things that way. I hope small tasks like this are fixed in future releases and it would also be nice to see some sort of official add-on store/repository or at least a official Microsoft site for them. It gets annoying trying to rummage the internet to find the best add-ons.
Add-ons is one area that I find very feature lacking and yet is something that should be so much better. Where is the add-on to let me ping my DNSomatic account? How about the one that integrates with my webcam for security viewing/recording when there is movement? Home automation? Game server? Heck even some more advanced features like Active Directory would be nice for the power users, and people with more than just 1 computer in the house.
I haven’t tried printer sharing through the system but the good news is, if it works in Windows Server 2003 it will work in Windows Home Server. And that is the main thing that separates Windows Home Server from all of the other DIY and Linux systems I have used. Windows Home Server takes a very successfully platform and strips it down to just what you need, and then they allow anyone to make minor additions to the system using add-ons. The software is the same across all platforms that use Windows Home Server. It doesn’t matter if you build it yourself or buy it from HP, Acer, or Shuttle.
This kind of flexibility makes me very excited for the next release which is based off of Windows Server 2008 R2 (a.k.a. Windows 7). If the next version of Windows Home Server lives up to 1/2 of it’s expectations it will still be a killer system that will be worth every penny for a upgrade.
Pros:
DIY availability
Add-ons are compatible with any WHS system
Easy to use
Remote desktop
The first NAS I don’t manage on a weekly basis
Cons:
Console can sometimes be too simple
Key Add-ins are missing
Network warnings for stupid things (firewall turned off, updates needed, etc.)

The HP MediaSmart Server came with one other thing that you won’t get on any other WHS system. Custom HP software built just for the MediaSmart servers. When I first bought the MSS the software wasn’t very feature rich for my needs. I don’t use iTunes so I don’t need the iTunes music server, I don’t have a Mac so I don’t need Time Machine backups, I don’t use snapfish, flickr, facebook, or Picasa for my pictures so I don’t need the Photo Publisher, and I don’t want the server collecting all of my media and putting it wherever it wanted to so I don’t want the HP Media Collector. The other features the MSS includes that retail installs of WHS don’t get are Twonky Media Server, Remote Access, HP Media Streamer, and HP Video Converter. Here is why they all suck.whs_web_01
Twonky Media Server is basically why I bought a MSS and didn’t build my own. You can easily buy Twonky from their site for $30 and install it and you are probably better off. HP by default locks me out of a lot of the advanced settings (but there is a way around it), but at the time I thought I might actually use some of the other features HP includes. Also to compare, I had Twonky on my Linkstation Live and it worked wonderfully with my PS3. With the MSS, Twonkey reports that I don’t have any music, photos, or videos stored on my MSS.
Remote Access lets you set up a website so you can access your WHS from anywhere in the world. While this is just fine (and Microsoft allows for free sites using *.homeserver.com), HP wants you to pay for a TZO site at $30 $10 a year. Not terrible but when free sites like www.dyndns.org and a million others let you do this for free it just seems like a waste. As a matter of fact before the HP 2.5 upgrade there was no option to have a *.homeserver.com site so you had to pay to get access to your server. Unless of course you set that portion up on your router.
HP Photo Viewer is probably the best software out of all the crappy software HP includes in the MSS. Of course first you have to publish all of your pictures locally to the HP Photo Viewer and make sure you put them in albums manually.whs_web_02 Once they are “published” you can password protect them let users order prints download a full album view pictures full screen view the pictures in a small area of your web browser. OK maybe this software does suck. Don’t use it. The only benefit it could possibly have over online sites is you have unlimited storage because it is served locally. But if you need that just buy a domain and set up a gallary2 installation, or pay for flickr, Picasa, etc. At least then you get a off site backup of your pictures at the same time.
So how about the HP Media Streamer and HP Video Converter those at least are worth looking at right? Not for me. The idea is the Video Converter runs in the background and converts your files so that you can share them in the HP Media Streamer and to your iPhone/iPod Touch. The media streamer is supposed to play your music, pictures, and videos to a flash player in your browser wherever you are. The good news is the HP Media Streamer is password protected so at least not just anyone can access your files. The bad news is, ever since I upgraded to the 2.5 version software the HP Media Streamer doesn’t see any of my music or videos. That seems to defeat the purpose. Oh and the video converter converted all of my video files and then seems to have misplaced them because it started to convert all of my video files again, thus overwriting the old video files it just converted. So I just turned it off and forgot the feature was even there. I also have yet to be able to play any music, photos, or video to any of the 3 iPhones I have tested. Every single one either says it cannot connect or there are no files to be played.
Pros:
A good feature list to compare to other WHS’s on the market
Cons:
Nothing works the way it is advertised

Closing

My next WHS box will probably be a home built system with 8-10 hard drive bays. In the long run that will probably be cheaper and I can make sure only the software I need is installed. I still do like the MSS and if you don’t want to mess with it (or have Apple products) it really is the way to go for mass storage on your network.

How-to map network drives based on network location

1 Comment | This entry was posted on Apr 14 2009

This has been driving me crazy and I cannot figure out how to do it. Here is my problem:
I have a work laptop that I obviously use at work as well as at home. At work I have 6 network drives that are mapped automatically if I log into my computer while at work. At home I have a Windows Home Server with 5 shares that I wrote a batch script to connect to them when I get home. The WHS Connector also adds a shortcut to the shares on my desktop but I want the shares mapped so I can use them as local drives in programs. I also had to write 3 more scripts (1 to disconnect my work drives, 1 to connect my work drives, and 1 to disconnect my home drives) in case I go between work and home without fully turning off my computer and instead just putting it to sleep. I am fairly certain this problem can be fixed with AutoIT or some other tool but I am just surprised this sort of functionality isn’t built into ANY operating system. My laptop has Vista and Linux Mint on it but I know this functionality isn’t in OSX either.
Is there anyone out there that can can suggest something to accomplish this? All I want is something that monitors what network I am connected to, and if that network happens to be home or work, map the appropriate drives. I am going to work on this in AutoIT but I am open to suggestions if you have any.
As soon as I find more information or someone points me to a solution I will update this post with how it works.
Leave your idea’s in the comments.

MediaSmart server advanced Twonky settings

3 Comments | This entry was posted on Feb 07 2009

With a new MediaSmart server I was excited to get the TwonkyMedia server up and running to be able to stream all my music and videos over to my PS3. I have some experience with Twonky from my Buffalo NAS and it was the best DLNA server I have ever used. I was a bit disappointed that the server configuration was dumbed down and limited to the MediaSmart console.
twonky restricted

Access is restricted to MediaServer configuration!

To enable to regular Twonky configuration pages you need to do the following steps.

1. RDP onto the server using mstsc.exe from a run command. If you have a version of Windows without remote desktop you will need to find a way to install it (I don’t know how) and open up C:\TwonkyMedia\twonkyvision-mediaserver.ini
2. Locate the line

# Web access
enableweb=1

3. Change it to

# Web access
enableweb=2

4. Save the file
5. Restart the TwonkyMedia service by opening services.msc from the run command, find the service on the list, and click restart on the left column.
twonky service restart

Now all you need to do is browse to your home server in a web page and go to port 9000.
http://hpserver:9000
You should be greeted with the normal Twonky configuration settings now.
twonkyconfig

I hope this helps someone, it certainly helped me.

Mythtv Log

0 Comments | This entry was posted on Jan 31 2009

I decided I needed a better way to keep track of myth MythTV systems I have used in the past, and what I needed to do to get the systems up and running. I started a MythTV Log page that should show up on the left (or the links section depending on my skin). I mainly posted this to help other people that are setting up their own MythTV computers using similar hardware. Check out the hardware I am using, and have used in the past, by looking through the logs.
Let me know if you have any good tips on keeping installation logs organized. I am fairly new to all this.

Vantec NexStar MX enclosure review

5 Comments | This entry was posted on Dec 26 2008

So, when I bought my NAS I started transferring over everything I wanted to keep on it. But then I realized that 500 GB would not be enough room to store everything. Instead of returning the NAS and getting a bigger one, which I did not have money for, I decided to keep the 500 GB NAS for only the things that I really wanted to have available on my home network (pictures, music, and videos). The other stuff that was more just there for storage (program installs, backups) could be put on a external hard drive. So I headed back to Fry’s looking for a USB hard drive enclosure. Here is the one I ended up with.

I bought the Vantec NexStar MX HDD enclosure from Fry’s for 3 reasons.
1. The price: I got the unit for $30. Not sure if it was a sale or if they were making way for the new NexStar with eSATA. Either way I feel like it was a good price for the features.
2. Dual SATA enclosure. Most enclosures I found in this price range would either only hold 1 hard drive, or would only use IDE hard drives. I had 2 SATA drives sitting in my closet that I needed to use. So this would let me use both of them without buying two enclosures.
3. Build quality. The whole unit is brushed aluminum and the enclosure alone seemed thick enough to stop a bullet. Well maybe not bullet proof but it felt good enough to hold my monthly backups.

I don’t feel like re-inventing the wheel with the review so I am just going to link to a couple much more thorough reviews than I could have ever done and tell you my thoughts.
Here are a few reviews for you to read on your own time. Virtual-Hideout, thinkcomputers, and futurelooks.

Overall, I am completely satisfied with my purchase. The drive is a little bit loud but I rarely have it plugged in anyway because it is only for occasional backups and long time storage. If you are looking for something that you want on all the time I would spend the extra money for a unit with more than just USB and something quieter. But if you have a couple extra SATA hard drives and need some long time storage than this is probably the device for you. The software it comes with is Windows only so I didn’t care for it but I was surprised to get any software at all for $30. The price on amazon is $70 and that is probably more than what I would pay for this enclosure. I feel the enclosure is easily worth $50 though if you can find it in that price range.


Let me know in the comments if you have any questions or what your experience with your external enclosure was like.

Compile Lirc on an AOpen mp945-dr with Ubuntu

0 Comments | This entry was posted on Dec 26 2008

I recently traded in my Mac Mini for a AOpen mp945-dr to see if it would work any better with MythTV and Boxee. I started off with Ubuntu 8.10 installed but found some random problems with video not displaying every time the computer would start so I went back to 8.04. On problem I had with both installations was that the remote sensor did not work out of the box. I did some digging and found that Lirc does work with this machine but the latest development branch was not included in Ubuntu for stability reasons. Here are the steps I had to take to get the remote sensor working.

As a overview we are going to:
1. Download the tools needed to compile software in Ubuntu.
2. Download the latest version of Lirc using CVS
3. Compile Lirc source
4. Test it real fast to make sure it works.

If you have Jaunty Jackalope (9.04) see the notes at the bottom.

1. Download the needed compiling tools.
sudo su
apt-get install libtool autoconf automake linux-headers-`uname -r`-generic cvs

This will download and install the compiling tools.

2. Download Lirc
First lets make a folder to put it in

mkdir ~/lirc
cd ~/lirc

Then we will download the newest source from sourceforge. We are using a tool called CVS to read more about it check out here.
cvs -d:pserver:[email protected]:/cvsroot/lirc login
cvs -z8 -d:pserver:[email protected]:/cvsroot/lirc co lirc

Because we ran that command while in the ~/lirc folder everything downloaded there so we just need to run the commands to configure everything before we build it.

./autogen.sh
./setup.sh

In the graphical interface I selected Driver config > USB > mceusb2 (new)

Then continue with compiling

make
make install
modprobe lirc-mceusb2

Because Ubuntu does things slightly different we need to copy a couple files to where Lirc expects them to be.

cp /lib/modules/`uname -r`-generic/misc/lirc_dev.ko /lib/modules/`uname -r`-generic/ubuntu/media/lirc/lirc_dev
cp /lib/modules/`uname -r`-generic/misc/lirc_mceusb2.ko /lib/modules/`uname -r`-generic/ubuntu/media/lirc/lirc_mceusb2

Then we can continue with installing the new Lirc into the running kernel.
rmmod lirc_mceusb2
rmmod lirc_dev
lsmod|grep lirc
/etc/init.d/lirc restart

Everything should be compiled and in place now.

4. To test it out run
irw
and then push some buttons on the remote. You should see the commands you press displayed in the terminal. If you see that then you can just push Ctrl+C to stop irw and you should be all set to go.

I had to change this tutorial slightly from where I originally posted it in the Ubuntu forums so that it would be more universal. If you have problems please leave a comment and check out the original thread here.

I hope this helps.

For Jaunty (9.04) I did not need to install the headers (it actually failed because it was already the newest version) I also needed to install “dialog” and “build-essential”. I had to create the “/lib/modules/`uname -r`/ubuntu/media/lirc/” folder before I could copy the configurations, and the folder I created also changed slightly to cp /lib/modules/`uname -r`-generic/misc/lirc_dev.ko /lib/modules/`uname -r`-generic/ubuntu/media/lirc/lirc_dev
cp /lib/modules/`uname -r`/misc/lirc_mceusb2.ko /lib/modules/`uname -r`/ubuntu/media/lirc/lirc_mceusb2

More updates as I find them.