Copying your ssh key

Since I’m frequently trying out new OSes courtesy of VirtualBox, my ssh key changes a fair bit. So I keep forgetting the xclip command, and I got tired of Google-ing “git xclip” so I’ve decided to repost snippets of this article here:

$ sudo apt-get install xclip
$ xclip -sel clip < ~/.ssh/id_rsa.pub

Now use Ctrl+V to paste the (secret) key into your Git hosting provider; e.g. the very excellent Github.

Advertisements

Debian-based distro adventures

Since my previous post, I’ve used:

I’ve compared MEPIS 8 and Ubuntu 9.04, in what was called an unfair comparison by some. I think some of the commenters even indicated that Ubuntu 9.04 would’ve come up tops, but I begged (and still do) to differ.

Since then, I’ve used Mint 7 and Kubuntu 8.04, which one may realize are using GNOME 2 and KDE 3 as well. So I guess a more appropriate comparison would’ve been:

  • MEPIS 8 versus Kubuntu 8.04;
  • Ubuntu 9.04 versus Linux Mint 7.

All of packages I use (e.g. php-pear, imagemagick, mysql-server) have the same names across the four distributions (but that’s probably due to Debian).

All four distributions work fine w/ Oracle Express Edition, which is a great way to try out Oracle database if you don’t happen to work for a large corporation that uses its (probably too-)expensive licenses.

I must say that it wasn’t so much the particular distribution, source distribution or version number that affected the speed of the interface, but rather, the window manager.

GNOME 2 just seems… slow. KDE 3 is well… snappy.

To me, there is no discernable difference between MEPIS and Kubuntu — both use KDE 3, except perhaps Kubuntu uses Adept whilst MEPIS sticks to good old Synaptic. Both are great applications nonetheless.

I’ll gripe about the loss of Dropbox, which is available both Ubuntu and Mint due to GNOME. Apparently there is command-line instructions available. But I digress.

On the upside, I can’t seem to (easily) setup a network printer in either MEPIS or Kubuntu. I followed the instructions on the Ubuntu website, and voila, I could print. Likewise for Mint, which is basically Ubuntu nicely themed. Or maybe I’m just scratching the surface.

Kdesvn and Meld are almost interchangeable, unless you want to view svn logs of course (use the former).

So there you have it. If you’ve got a high-performance, dual- (or quad-) core laptop, Ubuntu or Mint will do fine. But if you’ve got a 2- to 3- year old laptop, consider Kubuntu 8.04 or MEPIS 8. Unfortunately, I can’t access mepis.org anymore — the site is down, why? — and Canonical maintains fast servers, so I’ll be using Kubuntu for the forseeable future.

Comparing MEPIS 8 and Ubuntu 9.04

This post has been updated due to new information regarding Ubuntu 9.04.

I first tweeted about Ubutu 9.04 a week ago. Now I know I’m not exactly comparing apples with apples, since MEPIS 8 is based on Debian 5.0 and uses KDE 3.5, whilst Ubuntu 9.04 uses GNOME 2. I might be better off evaluating Kubuntu, the 9.04 release uses KDE 4, which I’d used previously, and disliked due to its (apparent) gradual reduction in speed.

But back to Ubuntu versus MEPIS. Since 10th June, I’ve been using it as a web developer machine on a Compaq nc8230. This machine is better-speced that the IBM R52 I use for MEPIS, so I’m giving Ubuntu the benefit of faster machine here. We’ll see if that pans out in Ubuntu’s favour later on.

Package Management

I develop in PHP, so I use Apache, MySQL and Oracle (remote server) on a daily basis. From my point of view as a developer, all of the .deb packages I use have the same name as in MEPIS. Synaptic, used in both MEPIS and Ubuntu, handles packages very well, so it is a tie here.

MEPIS 1, Ubuntu 1.

Applications

For applications however, I still felt that, overall KDE’s were more suitable for me, even though I was able to find GNOME-based replacements for the applications I used in MEPIS:

  • Kate to Gedit. Kate can syntax highlight my .ctp files, while Gedit has no such configuration option. Kate has sessions so I can quickly switch between projects, Gedit does not.
  • Konsole to Terminal. Konsole remembers my tabs, Terminal does not.
  • Katapult to Do. I prefer the default Alt+Space shortcut for Katapult, Do does it like Win+Space, because Alt+Space is used by GNOME. I also prefer if a calculator is built into Do, so I press Win+Space+32*5 and I get the result (160) onscreen.
  • Kdesvn,Kdiff3 Kompare to Meld. Meld is MUCH better than either of the 3 applications, as I can do 3-way file/directory comparison easily. It can even open a Subversion-ed directory and handle it correctly)
  • No Dropbox client in MEPIS, versus official Dropbox client in Ubuntu. Dropbox works very well, as it is the official release from the Dropbox guys. I’m still waiting (hoping) for a KDE-based one, but maybe they are reluctant to write one in KDE 3.5, then later rewrite for KDE4?

MEPIS 1, Ubuntu 0.5 (due to Meld, Dropbox).

Speed/Stability

I feel that Ubuntu 9.04 has some way to go, as I’d to POWER OFF the laptop as Ubuntu does the dreaded “window goes dark” thing, and I see/hear alot of hard drive activity, and then I have to (painfully) switch to Terminal, and then type killall <process>. Usually, the culprit is Firefox 3.0.11.

Previously I’d written about how unstable 9.04 was. After some reading on the forums, I figured it might be a graphics issue. Setting System -> Preferences -> Appearance -> Visual Effects to “None”, seem to have resolved my stability problems. How strange, yet comforting. Ubuntu is now as stable as MEPIS (or probably most Linux distros, anyways) is.

MEPIS 8, on the IBM R52, meanwhile is fast and stable, albeit with less special effects. I must admit, I was wowed by the special effects, but not at the expense of speed, and particularly stability.

MEPIS 1, Ubuntu 0. MEPIS 1, Ubuntu 1.

Conclusion

I’ve no issues with Synaptic, as it is used to manage packages in both MEPIS and Ubuntu.

I loved to use Dropbox and Meld in Ubuntu, so much that I was probably willing to accept the differences between kate/gedit, konsole/terminal, katapult/do. What was frustrating to me was to develop halfway, and then have to wait for the system to return control of the UI to me, and if not reboot.

The overall score is MEPIS 3, Ubuntu 1.5. This scoreline is obviously subjective, but you’ve heard all the good things about Ubuntu, have a slow(er) laptop, please do consider MEPIS. The overall score is MEPIS 3, Ubuntu 2.5. I still prefer KDE 3’s apps, but it wouldn’t be a huge leap to jump to Ubuntu’s GNOME Desktop, or for users that still prefer KDE, Kubuntu 8.04 (KDE 3.x) or Kubuntu 9.04 (KDE 4.x).

Both MEPIS and Ubuntu support audio/wireless networking flawlessly, unlike (cough, cough) Debian. At this point, I really don’t see the benefits of using Ubuntu (mostly due to its speed/stability issues) over MEPIS, so yeah, I’m a fan.

References

Debian, MEPIS and Ubuntu from en.wikipedia.org

MEPIS 8 and Fujitsu Lifebook S7110

I previously wrote that MEPIS worked (sound, wired networking, wireless networking) out of the box for my IBM R52. FYI, the wireless card is the Intel PRO/Wireless 2200BG. I’d also previously detailed instructions on Debian “Etch”. What I didn’t state was that I would encounter issues where wlassistant would report that it was unable to get an IP address (via DHCP) whilst attempting to connect to a standard WEP router. However if I left wlassistant switched on for awhile, it would (mysteriously) work later on. I got fedup, and mostly used a wired connection thereafter.

I’m pleased to note that there are no such issues for my Fujitsu Lifebook S7110, which uses the Intel PRO/Wireless 3945ABG:

lspci -nn | grep 3945
05:00.0 Network controller [0280]: Intel Corporation PRO/Wireless 3945ABG [Golan] Network Connection [8086:4222] (rev 02)

When I booted up via the LiveCD, I feared the worst, as it was unable to connect to the (same) router. But go ahead and install nonetheless. On the first boot after install, I configured the network, to no avail. I rebooted however, and it worked fine. I’m still not sure what’s going on here, but it’s certainly a pleasant surprise.

For a time I feared that my laptop would reach it’s end of useful life before I found a distro as excellent as MEPIS, but that’s all in the past now.

:)

Oracle and PHP5 in Debian-like systems

This post helped me install Oracle XE on my developer machine successfully! It worked for my Debian Lenny system previously, and I’ve personally verified it to work with MEPIS 8.0, Ubuntu 9.04 and Linux Mint 7, Linux Mint 8 and Xubuntu 10.04.

1. Oracle Express Edition (XE)

This step is optional if you already have an Oracle server to use, but in my experience, it’s far better to have one setup locally.

Add the following repository to your apt sources:

deb http://oss.oracle.com/debian unstable main non-free

Install Oracle XE:

wget http://oss.oracle.com/el4/RPM-GPG-KEY-oracle -O- | sudo apt-key add -
sudo apt-get update
sudo apt-get install oracle-xe-universal

It’s a pretty big download (~260 MB). The installation, like most in Debian systems, is a breeze. When the installer completes there is one extra step:

sudo /etc/init.d/oracle-xe configure

You’ll be asked to create a system/sys (administrative user) password, and whether or not to start Oracle on boot.

2. Oracle Instant Client

You can skip this step if Step 1 was completed. The Instant Client is required if Oracle XE is unavailable.

Downloaded the RPMs from here. You’ll need the basic, devel packages for Linux. Once the download is complete, use alien to convert .rpm into .deb. I also converted it to deb using alien (which you may not have, but can install using ‘sudo apt-get install alien’, and then installed:

# If you have alien, skip the following line
sudo apt-get install alien

# Converting and installing RPMs
sudo alien oracle*.rpm
sudo dpkg -i oracle*.deb

3. oci8 Static Object (SO)

This step is required for Oracle/PHP to play nice.

# If php-pear, php5-dev are installed, skip the following line
sudo apt-get install php-pear php5-dev

# Compling the oci8 static object (SO)
sudo pecl install oci8

At some point during this process, you’ll be prompted to input $ORACLE_HOME. If you used Step 1, input “/usr/lib/oracle/xe/app/oracle/product/10.2.0/server”. If you used Step 2, input “instantclient,/usr/lib/oracle/11.2/client/lib”. The compilation takes awhile.

4. Loading oci8.so

Save a new file as /etc/php5/conf.d/oci8.ini. Add the text “extension=oci8.so”, so that it becomes available everywhere.

5. Restart Apache

sudo /etc/init.d/apache2 restart

SimplyMEPIS 8.0

My slow laptop is now running on SimplyMEPIS 8.0. Surprisingly, it doesn’t feel that slow anymore. Maybe it was an OS issue, but I digress.

The install process was a breeze. I used mepis-network to setup wireless access, gparted to partition the hard disk into two partitions of 8GB (root) and 2GB (swap) each, and then it installed by itself. Later, it setup grub for me so that if I wanted to boot into Windows, it would comply. But I won’t of course. When I boot into MEPIS for the first time, I wanted to setup wireless again, since the install was a Live CD. But I didn’t even need to perform that step! The network settings that I added during the Live CD boot had been saved! Voila!

IMO networking, particularly wireless networking has to improve significantly, even Lenny. I wish it would just work, rather than having to jump through hoops, and even then, not work particularly well.

Up till now, I cannot connect to my home wireless router. Before Lenny was released, there was a tool called “wlassistant” that worked occasionally. But now it’s gone, and all of the other tools (kwifi-radar, wireless-tools) do not work. And it’s not a router issue, because my other Windows laptops connect easily.

I’ll try to set this up as a development machine; if things go well I just might switch my (primary) laptop to MEPIS.

Back to KDE 3.5.1

Two nights ago I reverted to KDE 3.5.1, as the UI was getting less and less responsive.

Krunner, Kate, Kdesvn for some reason felt slower than when I first installed KDE 4.1. There was also a silly issue with Kate (my primary text editor) which didn’t help.

Maybe it was the hardware, as my laptop was bought in Aug 2006, I’m not sure. But now I know why Lenny was released with KDE 3.x.y, it just feels more… complete.