Archive for the ‘Ubuntu’ Category:
MythTV how-to video – Part 2
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
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.
How-to Modify the Default User Settings in Linux
Just like my other two posts here is how you can modify your default user settings in Linux. This is similar to OSX but instead of “/System/Library/User\ Templates/English.lproj” being our template directory. It is “/etc/skel”.
The skel directory stands for skeleton and it is where the default files and settings come from when you create a new user in Linux. The skel directory is a lot more basic than Windows or OSX mainly because A) not much is needed to create a Linux profile and B) all of the configuration files are stored in plan text and not some fancy .plist or .dat file.
Typically, most distros will only include three files in their “/etc/skel” directory. Those files are “.bash_logout”, “.bash_profile”, and “.bashrc”. If you want to include any more files/settings you can simply edit the configuration in your profile (or a temporary user), copy the setting files to the “/etc/skel” directory, and chown the files with root:root.
What if you don’t want to overwrite the files that came with your distro but you still want to make a skeleton directory? Simple, edit the “/etc/adduser.conf” file and set the SKEL value to whatever you want. Just make sure that the folder is available to root when you are trying to create the new user. In other words, don’t put the folder on a removable drive.
If you are using the GUI to create the new user the files and settings will be copied automatically and if you are using the adduser command just make sure you use the -m flag.
That is really all there is too it. Let me know if you have more tips for creating a user profile or if this helped you out in the comments.
Linux Mint 7 review
Linux Mint 7 “Gloria” RC came out this past week and I spent some time installing it this morning. While it is based on Ubuntu 9.04, my first impressions of Linux Mint 7 are drastically different.
Here is a mini review of why I still use Linux Mint as my main OS at home.
The install was painless, as usual, and the theme was just as elegant and smooth as ever.
After the install I went ahead and updated my video card drivers and turned on advanced desktop effects. From there I needed to install some software that I use day-to-day. Instead of turning on the package manager like I normally would I opened the mintInstall tool expecting the software to refresh it’s list for the next 30 minutes. I was very surprised to have mintInstall ready to install software right when I opened it. I was even more pleased to find the featured applications option. One click on that button and it had a list of popular software that isn’t install by default. With a few check boxes I installed VLC, amarok, f-spot, picasa, etc. The only software not on the list that I needed to install was Audacity and Conduit. Ten minutes past my fresh install I had all my software installed and I was back up and running. Thanks to storing all of my information on either a network drive or a separate partition I had a fully functional Linux Mint 7 installation at this point.
One of my biggest complaints with Linux Mint in the past was the mintMenu application. While I loved its functionality of allowing you to search for programs and documents all right when the menu is open, it never had the ability to open with a hotkey, until now. I found out by accident. I pushed the “Super” key and started typing Firefox because that is what I usually do in Vista. About half way though “fire” I realized I had opened the mintMenu with the “Super” key. After reading the changlog I found that you can also change the key which is very helpful in Linux because many other programs use the “Super” key for activation (Gnome Do, Compiz shortcuts, etc.).
One other change that I didn’t expect, but am OK with, is the fact that Gnome Do does not start up by default. Because past mintMenu’s could not open with a shortcut key I began relying on Gnome Do to launch my programs and find my documents. I very much like the program but with mintMenu being able to open with just a keypress I don’t know if Gnome Do is needed any more in Linux Mint, at least not for program launching.
The only other surprising feature to find was that Evolution was not the default mail client and instead Thunderbird still held that title. While I still do like Thunderbird I feel like Evolution is a step in the right direction and I love that it can not only manage all of my personal email addresses but it can also painlessly get my works Exchange email.
In summary, Linux Mint 7 is absolutely wonderful. I have all the features and support of Ubuntu with all the polish and software I have come to love in Linux Mint. I look forward to using Linux Mint 7 more and hopefully I will be able to keep this install for at least 6 months until Linux Mint 8 comes out. Great job Clem and team, another success in my book.
Ubuntu (9.04) Jaunty Jackalope first impressions
I installed Ubuntu 9.04 on my main laptop (HP Compaq 8510p) and I wanted to post what my first impressions:
My first issue was with the installation. I am not sure if this feature was taken out or if there was just some other reason I couldn’t do it, but what happened to the ability to resize your Windows partition to install Ubuntu on the newly created free space? I only had two options on my install, use the entire disk (erasing Windows), or manually select which partitions to use (without the ability to resize a partition). What I ended up having to do was boot back into Windows Vista and resize my main partition to free up unallocated space on my drive manually. While this wasn’t horrible to do, I can imagine there are quite a few people out there that don’t know how to do this. After I had freed up 15 GB on my drive I had a third option to install Ubuntu on the largest available free space but it was still a bit of a hassle to do in the first place.
Once I actually booted into Ubuntu I was greeted with all of my hardware working out of the box…until I rebooted.
I am not sure why but my sound wasn’t working past the login screen. It worked just fine on the first boot and it has never failed to work in any previous Ubuntu installation on this laptop (8.04-9.04). I was eager to play some of my music, but I soon remembered one of the reasons I switched to Linux Mint…and that sent me to the package manager to install the restricted extra’s package so I could listen to my music in MP3 format. Once I finally had the package installed I then realized I couldn’t hear any music coming from the Rythumbox player. I started up Firefox and headed to YouTube to see if I had any audio there. Back to the package manager to install flash and then restarted Firefox to see if I had sound from YouTube. This confirmed that I had no sound working whatsoever. I went to the forums and installed the Gnome ALSA mixer cause I heard it solved the problem for some people but for me it would just open up with a blank window with no options but to exit. So I gave up on my sound thinking I could just use my USB sound card that has worked with every other distribution of Ubuntu I have tried it on (back to 7.10). Wrong I was. The USB sound card did not work with Audacity however after 3 more reboots all of a sudden my onboard sound worked again. I tested it with Audacity and I was set to record the next mintCast.
During all of this work to get my sound working again I probably had Firefox crash on me, I’d say, 6 times. While I am not new to having Firefox crash, especially not in Linux, I was quite surprised to have this sort of instability for a newly released OS. Sure I installed the Adobe Flash add-on but in the past when Flash crashed it just wouldn’t play videos anymore until I rebooted the browser. These crashes were full system locking, power button holding, not even RSEIUB would help kind of crashes. I will admit in the second day I used Jaunty I haven’t had Firefox crash on me once but the bitter taste of a unstable browser still frightens my every keystroke.
With everything working as it should I decided to test this famed boot speed improvements using ext4. I have seen video’s of sub 20 second boot times and I am very curious what my laptop can do. With Linux Mint 6 installed my boot times from the time I pushed the power button till the time I loaded a webpage with Firefox was about 50 seconds. I defiantly felt like Jaunty was faster than that, but after 2 tests (with auto login and and Firefox set to auto run) my best time was still only 41 seconds. Once again, a little bit of a downer.
Next thing to test was one of my outstanding problems with Ubuntu/Linux Mint. At work and at home I use a docking station to dock my laptop to be able to use a full keyboard/mouse and large monitor. When my computer is docked I get video on the external display but it never detects as a second monitor through the docking port, and instead it just mirrors my display and never lets me change my resolution on the external monitor. If I plug the monitor in to the VGA port on the laptop it is just fine however. I tried to open system preferences and all I was greeted with was this empty window that I had to force quit every time I opened it. This was finally another strike that made me very sad and disappointed that Jaunty isn’t what I thought it would be. 
The final little nagging feature was the pop-up that asks you to confirm your shutdowns and restarts just like OSX. I heard an interview with Mark Shuttleworth and he said that this was necessary for the new desktop notifications so I wasn’t too bummed about it but it does make shutting down a little more annoying.
On the plus side I do like the pop-up notifications, which I didn’t think I would, and I like the improvements made to Evolution (and it is really winning me over from Thunderbird). I think 9.04 isn’t a step backwards like 8.10 was compared to 8.04, but I don’t feel like 9.04 is living up to the hype.
I have no plans to stop using Linux Mint or Ubuntu (or Linux in general). I think they are both fantastic operating systems and I am so thankful for the countless people that put in all of their free time and talent into the system. I try to contribute in as many ways as I know how and will continue to support the community whenever I have the chance.
For now, I am looking forward to what Ubuntu 9.10 will have in store.
Let me know what things you love and hate about 9.04 in the comments.
Error with CIFS on shutdown in Linux
I kept getting this error with Linux Mint and my NAS.
When I shutdown I got an error saying:
CIFS VFS server not responding
and the system would hang before shutting down and sometimes not shutdown at all. Of course with so many people using Linux the problem was only a Google search away.
I found that the problem is because Linux Mint would turn off the network connection before it would unmount the mounted volumes I had. It does this for security reasons because if you have system folders or home folders mapped to network shares it needs to have those system folders until it is done shutting down. Of course you would still run into problems when the network connection is killed but I don’t program so I am sure there are other reasons why it is done this way.
Anyway, a good solution is to have the drives unmounted earlier in the shutdown process. To do this we are going to make symbolic links to the script that unmount the volumes for us and then just put that in the folder that is processed earlier during shutdown and reboot. I found bits and pieces on how to do this in the Ubuntu forums but I found a good blog with all this info in one place here. here.
The code you need to run to make the symbolic links is here.
ln -s /etc/init.d/umountnfs.sh /etc/rc0.d/K15umountnfs.sh
ln -s /etc/init.d/umountnfs.sh /etc/rc6.d/K15umountnfs.sh
Here is a quick explanation of what this does from the other blog I found.
This will create two symbolic links to the umountnfs.sh script, one in runlevel 0 (shutdown) and one in runlevel 6 (reboot). The links have a “K” prefix to let the init system know that the script should be called with “stop” as an argument, and they have a priority of 15 to ensure that they are run before avahi-daemon and dhcdbd are stopped
OK that fix didn’t work. I finally found a solution that really works. Do this in a terminal instead.
cd /etc/rc6.d
ls -la
You will see two files S31umountnfs.sh and S15wpa-ifupdown.sh. The number still represents the order at which the script runs. All you need to do is change when the umountnfs.sh script runs. Do that by typing in:
sudo mv S31umountnfs.sh S14umountnfs.sh
You will need to run the command one more time in the /etc/rc0.d folder too.
Now my shutdown doesn’t hang anymore on unmounting the CIFS mounts.
I hope this helps.
My 2009 predictions
I have never done this before but I thought I would take a swing and making some predictions at what I think is going to happen this year with technology.
Computers:
1. Smaller, faster, better. Duh. That is obvious but I think there will be some big improvements in “alternate” input for computers. Apple is rumored to release a multi-touch imac. Windows 7 has multi-touch support and is just waiting for hardware/software to take advantage of it. In 2009 I expect to see the biggest improvements in multi-touch software. Games will probably be first, with the iPod touch and iPhone helping with lots of ideas, and then we will get some cool browser and media solutions. I for one would love to see cooliris with some multi-touch support. After multi-touch will probably come touchless input but I don’t think that will gain a lot of ground in 2009.
2. GNU Linux will gain at least 1% (double) market share (putting it up to 2%) before the end of the year spearheaded by Ubuntu. At this point I believe every major computer retailer (except Apple of course) offers GNU Linux on at least 1 model line, and when people see the boot speed and stability improvements of the next Ubuntu release more and more people are going to start “giving it a shot”.
3. 2009 will be the year of Microsoft solutions. I know Apple is gaining on Microsoft’s market share and they still will for a good part of 2009. But I don’t think market share ever really tells a full story. All I hear about now is how Apple is the coolest thing since super cooled capacitors, but I sense a bit of a change in the wind. I think Windows 7 will launch in 2009 and will greatly restore faith in Microsoft as a company. I also think that the next version of Windows Mobile will finally catch Microsoft up in the mobile platform market. The Windows Mobile OS won’t surpass what is currently out with Android or iPhone but it will make it respectable in what it can do and how it looks. I also think that the Windows Home Server market will gain popularity and the Xbox line will continue to grow. Finally, I think Zune sales will skyrocket (mainly cause Zune media player will be in Windows Mobile 6.5). Right now the Zune is in spot 3 behind Scandisk and Apple. I think as more and more people become unhappy with their iPods but they don’t want to upgrade to iPod touches or iPhones they will turn to the Zune. Last I checked Zune had 5% market share, but by the end of the year I see that number doubling to 10% of the mp3 player market. A big jump but it is truly a worthy mp3 player in my book.
Video games:
1. The Wii will crash. They have enjoyed a crazy amount of sales for far too long and they haven’t come out with any good software for months. I am so glad this day will finally come because I haven’t liked the Wii from the start. They will quickly be outsold for a few months by the Xbox 360 and the Wii will drop in price (my guess is to ~$180). Either way it will be hard to recover and it will probably just die out until Nintendo unveils the Wii HD or something ridiculous. By this time the Wii will not be “the console to have” and most people will finally see the console for what it truly is.
2. The PS3 will jump in sales. I already see this at my work. Two of my co-workers who previously bought Wii’s finally want to either A. Play real video games again or B. Watch Blu-ray movies. Their obvious choice was the PS3. Although the price is a big jump, people will finally realize all the features you get out of a PS3 and will start buying them mainly for Blu-ray players and eventually for gaming systems. The PS3 will also start to gain popularity because the Xbox 360 will run out of juice (aka. storage space) and the PS3’s potential will finally start to be tapped into. Sony will begin to push out better programming tools and maybe even Valve will come to the dark side and program their own crap for the PS3.
3. Online systems will be key this year. Xbox Live is fantastic but costs money. More and more people are getting tight on money and Xbox Live will probably suffer because of that. The PSN has been mediocre at best, but at the cost of free I think more people will sign up for this than ever before. Also Nintendo will realize the error in their ways in not offering a online service and will make plans for it with the Wii HD.
4. I think the PS3 will offer 3D gaming to some extent. Most people don’t realize their Samsung HDTV can display the 3D content and the market is ripe for the picking. I think the PS3 will be the only console that can really handle the amount of power it will take and storage space to contain 3D content.
Other:
1. February 17th will be a very dark day for a lot of people. Best Buy will be crowded as hell, and people will be very upset their antenna doesn’t work anymore. The biggest impact will be in low income/minority neighborhoods. There will probably be some bill passed to make sure they are not forgotten about in the future. HDTV sales will continue to decline until after February 17th when they will get a small kick in the pants until the economy levels out.
2. Because of the DTV transition online television distribution systems will benefit. Hulu, Vudu, Boxee, Apple TV, Windows Media Center will all see a lot more users than ever before. It is going to be a big quantity over quality issue but the amount of free content online will win in the end. After online distribution systems gain some ground they will start to push better quality to the users.
3. Displays are going to rock. Not just TV’s either. Laptop displays, computer monitors, projectors are all going to improve. OLED will make a big push (“organic” isn’t just for your foods) and I think we will probably see some sort of built in projector for a laptop this year. Pocket projectors will also finally become something worth looking at.
4. The internet will have a new awesome site. There will be some new MySpace/Facbook site for 2009 and it will include all the other sites in one. It will finally truly be able to combine your online accounts (at least social accounts) in one place. I have a feeling this site will be run in some way by Google (or at least bought by Google in the end). I think the first step to this will be Google NOT buying Facebook. If they do buy them then there would be no point in making an all inclusive social site. Their new site will easily tie in with YouTube, Blogger, Google Calendar, etc. The next step would be for Google to buy Twitter.com. As more people don’t have time to blog, they will turn to Twitter to allow them to blog on the go.
Well that is it. I know it was a heck of a lot of reading and I thank you for reading it (or at least skimming it). I will hopefully follow up 1 year from today to see how these predictions were met.
Let me know your predictions in the comments or if you agree/disagree with any of mine.
Compile Lirc on an AOpen mp945-dr with Ubuntu
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:anonymous@lirc.cvs.sourceforge.net:/cvsroot/lirc login
cvs -z8 -d:pserver:anonymous@lirc.cvs.sourceforge.net:/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.
Open files as root (the easy way)
I ran across a couple of tips in Linux to open a file as root without having to use a terminal. The first is a shortcut on your desktop. To make this one just right click on your desktop and then select “Create Launcher…”. When the dialog box pops up you can put in whatever you want for “Name” and “Comment” but for “Command” just put in the following command.
gksudo “gnome-open %u”
Now to open a file as root all you have to do is open the file location and drag the file to that shortcut. The system will probably ask you for your root password and then open the file as root.
A easier way is to browse to ~/.gnome2/nautilus-scripts/ and create a new file called “Open as root”. Edit the file and put
#!/bin/sh
gksudo “gnome-open $NAUTILUS_SCRIPT_SELECTED_URIS”
inside the file. Right click on the file and go to properties -> permissons then check the box that says “Allow executing file as a program”. Now all you have to do is right click on a file you want to open as root, go to scripts and click “Open as root”.
I just wanted to pass these along cause I thought they were very helpful.
Well that was stupid…easy MythTV fixes
Just a real quick tip for anyone having problems watching live TV or recording shows in MythTV. After a fairly fresh install I could not watch live TV. My screen would go black for a second and I would be kicked back to the main menu. I also was not able to record shows. The recording would show up on the schedule but nothing would happen when the time to record would actually come. So my tip is check your log files!!! They are stored in /var/log/mythtv (at least they are in ubuntu). You should have mythbackend.log*, mythwelcom.log, and mythfrontend.log* in that directory. The log files are incremented making the highest number the oldest file and the one without a number your newest file. So check the newest file first.
As for my problem I checked my frontend log first, but I didn’t see much information besides the fact that I changed skins. So I decided to check the backend. Here is what I found.
2008-11-23 10:26:22.432 TFW, Error: Opening file '/media/mythtv/recordings/1941_20081123102621.mpg'.
eno: Permission denied (13)
2008-11-23 10:26:22.436 TVRec(1) Error: RingBuffer '/media/mythtv/recordings/1941_20081123102621.mpg' not open...
2008-11-23 10:26:22.437 TVRec(1) Error: CreateLiveTVRingBuffer() failed
2008-11-23 10:26:22.438 TVRec(1) Error: Failed to create RingBuffer 1
Now this may not be too obvious to most people but take a look at “Permission denied (13)”. DOH! I forgot to give my user permissions to the directory I set up to record my shows in (as well as my live TV folder).
sudo chmod 777 /media/mythtv/*
and now I am able to watch live TV and record whatever shows I feel like.
Just thought I would save you the hassle if this happens to you.
