2009/11/20

Ubuntu 9.10 and dell 5100cn

We have this nice dell 5100cn laser color printer. It's big and prints fast and a lot. One of my requirements for switching to ubuntu at work was that I could print. I first tried to use default ppds like the driver for the 3100cn or the postscript driver... not all with big success.

Today I was wondering, wouldn't dell have drivers for Linux (read ppds). They must have them cause they sell laptops with ubuntu on. Looking on the website I only found and rpm for redhat 4. Being a small package I decided to download it.

Next step was looking into the package. Using the archive manager in ubuntu i found under /usr/share/cups/model/Dell/ a custom ppd. Joy joy. I placed the ppd under /etc/cups/ . Next I went to my printer settings in gnome and added a new printer. I ofcourse selected custom ppd in the wizard and voila it was installed. Printing at first was not a success. It seems that the driver by default selects the format for printing on envelopes. Changing it to A4 as the default media size in printer options (right click the printer > properties > printer options ) solved the problem.

Btw i extracted the PPD and uploaded here. Use Save as ;)

2009/11/19

Top 5 applications I use on Ubuntu

The first application seems silly but frankly I don't get why Ubuntu changed their policy. Pidgin is oh my god the easiest messenger client out there. It has support for MSN/ICQ/facebook/Bonjour and all the other protocols I don't use. I didn't even try out empathy cause I used to use Pidgin on XP and I liked it .. so why change a winning team?
$ sudo apt-get install pidgin

Launching applications via menu's is easy but sometimes very slow (clicking,scrolling,etc..). If you like cli like I do, you end up entering application_name & in a terminal to quickly launch apps. A nicer way to launch applications is gnome-do. You launch it by using a shortcut and then you start typing the application you want to launch. If you type in pidg (assuming you have pidgin installed ;)), it already starts suggesting to launch pidgin if you push the enter key. But wait there is more. It integrates with firefox, pidgin and others.. This means if I make a bookmark for google maps and I call it google maps, I can just type in google maps in gnome-do and it will launch the bookmark in firefox. Small but must have app
$ sudo apt-get install gnome-do

Where the hell did the service dialog go in Ubuntu 9.10? For some reason, it was removed from the system > admin menu. Granted I always use the terminal to restart apps and the new "service [servicename] [start|stop|restart]" is quite nice in 9.10 (thank you redhat for the idea btw), but for newer people this is quite complex. This is why when I gave my Ubuntu for windows administrators workshop I was quite suprised that it was gone. Luckily there is a replacement on the market called BootUp Manager. If you want to do everything in GUI, you can use this
$ sudo apt-get install bum

Compiz fusion (aka Desktop effects) is nowadays installed by default on Ubuntu. Only there is no nice way to manage it. If you want to enable that fancy rotating cube and the wobbly windows you need something to configure Compiz fusion. Enter compizconfig-settings-manager. To be honest I have compiz disabled all the time cause it consumes batteries like vampires drink human blood. But when the random dude-linux-is-for-geeks guy shows up, I can not stop myself from showing the famous cube. You want to know how deep the compiz fusion rabbit hole goes...
$ sudo apt-get install compizconfig-settings-manager

I never read a lot of blogs. Mainly cause I hate browsing every site to check if there is something new on there. So I discovered RSS feeds. Yes I know they exists for ages but I never found the time to find a good reader on windows. That is why I love synaptic. When you are using it, you feel like a nerd in the mediamarket software shop. This is how I discovered liferea. A nice, clean and simple rss reader
$ sudo apt-get install liferea

Yeah I know I said top 5 and this is 6 but who gives a damn ;). Making screenshot is always a hell but so useful for writing doc. Nothing says more than a picture does. Meet Shutter. A screen shot tools that uses profiles and allows you to easily take screenshots of parts of windows.
$ sudo apt-get install shutter

Ok maybe one more. This one is a bit more complex to install but it is worth it. I don't want to switch back to windows but some apps are impossible to run on Linux. I'm a SE and sometimes I need the VMware vi client. Exchange well, it only works good with Outlook (no offense Evolution). This is why I use virtualbox. A free product from SUN. Granted I love VMware but I must say Workstation 6.5.3 for Linux = crap. It's hard to install and hogs up my system. This is why i sadly choose for virtualbox. Installing it is a bit harder then sudo apt-get. You can find more on http://www.virtualbox.org/wiki/Linux_Downloads . Don't download the debian package but scroll down and find out how to do it the proper way, adding the repository. This will give you the advantage of automatic updates.

Ubuntu 9.10 and mobistar stick

So recently I changed from Windows XP to Ubuntu 9.10 on my work laptop. I was already using it on my home laptop which has a lot less of possible hardware/software requirements.

First of all, lets start with the good news. I have a Lenovo T61. Under xp it was performing badly so that is on of the reasons I decided to change to Ubuntu. Installation was a piece of cake. It went smooth, 6 answer setup and it installs. Hardware support was amazing except for my Mobistar usb stick...

When plugging it in I get this HUAWEI Mass Storage kind of message in my dmesg. Seems ok except that it is a composit device (more then one device on the same usb port). Ubuntu ofcourse recognize the wrong device (the mass storage device part). Luckily I found this guy on the internet who had the same problem:
http://blog.simple2web.ie/?p=363

So ok I tried it out and it works ! Great ! Well what was not so great is that I always have to run usb_modeswitch manually. This seems no biggy but it can get annoying if you need to plug in and plug out your device frequently. So here is my solution and my added value.

Ubuntu has something called udev. Udev is a service that dynamically detects devices and can run scripts when it sees certain devices. So I made my own script:
/usr/local/share/mobistar.sh
which has
#!/bin/bash
/usr/sbin/usb_modeswitch

Now that wasn't so hard was it. Now how can we make udev execute this script. First of all you need a rule script. I created :
/etc/udev/rules.d/10-mobistartusbswitch.rules
which contains
BUS=="usb", SYSFS{idProduct}=="12d1", SYSFS{idVendor}=="1001",
ACTION=="add", RUN+="/usr/local/share/mobistar.sh"

Doesn't seem to complicated except for the idproduct and idvendor numbers. I found these by executing lsusb. This gives something like :
Bus 001 Device 030: ID 12d1:1001 Huawei Technologies Co., Ltd. E620 USB Modem

After I created the rule, I restarted udev by doing
sudo service udev stop
sudo service udev start

That was it! Plugging and deplugging works as a charm now!