Archive

Archive for March, 2007

Creating Shortcuts With User Aliases

March 30th, 2007 Christer Edwards 11 comments

Do you have a set of commands that you find you repeat over and over in your daily use? Things like connecting to servers over ssh, rsyncing data launching apps with a slew of argumets. You know what I mean. Well you can make things easier on yourself by creating alias commands for your account. Below are a few examples:

ssh user@server -p 22222 could be setup in an alias defined as ‘connectwork’

rsync -avz –progress daily/backup/file/ user@server:/remote/directory could be defined as ‘dailybackup’

By setting these longer commands as local aliases all you have to do is type the alias name, which is then connected to the command and you’ve saved yourself a load of typing. Yes, this appeals to us because we work hard but don’t want to work any harder than needed!

To create an alias you’ll want to edit your local .bashrc file. This file defines a number of shell options for your account but also can store any aliases you want to define. The default file has a few example aliases set, and all you have to do to create your own are append them to the list.  A sample entry would look like this:

alias aoeu=’setxkbmap us’ (this will switch keyboard layouts to qwerty)

alias asdf=’setxkxmap dvorak’ (this will switch keyboard layouts to dvorak)

alias updateme=’sudo aptitude update && sudo aptitude upgrade && sudo aptitude dist-upgrade && sudo aptitude autoclean’ (check for, download, install and cleanup after updates)

As you can tell from these few examples you’re able to create an alias for your user on the shell for whatever you like.  It can save you typing, help automate repetitive commands, and make your life easier.  Give it a try.

If this article has been helpful, please consider linking to it.

Categories: Linux Tags:

Enabling The Cube In Feisty’s “Desktop Effects”

March 28th, 2007 Christer Edwards 10 comments

I found something this evening in passing that I wanted to pass on to the rest of you.  It’s a small fix that will allow the Cube to function properly with the current setup of Feisty and the desktop effects.  Currently you can get the wobbly windows but no Cube.

In any event, try the tip below to get the Cube to function if you’d like to stick with Compiz (vs Beryl).

gconftool-2 --type int --set /apps/compiz/general/screen0/options/hsize 4
gconftool-2 --type int --set /apps/compiz/general/screen0/options/number_of_desktops 1

This is taken from a fix posted on a bug for the issue.  If you’d like to offer any of your experience with the problem or how you’d like to see things implemented in future releases visit bug #89786 in desktop-effects.

Categories: Compiz/Beryl Tags:

Quick Update

March 26th, 2007 Christer Edwards No comments

I know it has been a little while since I have posted any tutorials here and I apologize.  As I mentioned in my previous post I have just started a new job and need to get things on a schedule here.  In the meantime, until I’m back to a regular schedule, I have invited a couple of guest bloggers to keep things alive here.

Thank you for contributing to the blog this next week and thanks to the rest of you for your patience.

Categories: News Tags:

Some Exciting News For Me

March 19th, 2007 Christer Edwards 10 comments

I have been sitting on this news for a few days pending finalizing some details but I am happy to announce now that I will be the latest addition to the Guru Labs team!

For those of you catching this blog outside of Utah, Guru Labs is a Linux Training company.  That means, yes, I’ll be paid to teach Linux administration, security and all that fun stuff all over the country.  Needless to say I’m pretty stoked about the opportunity.. as well as a little intimidated.  Guru Labs has long been considered by myself, and I’m sure many others in the state, as the holy grail of nerd jobs.

This will also offer me the opportunity to personally meet some of the great people we’ve got in the US Teams project, and US based LoCo Teams.  You’ll hear from me if I’ll be heading to your area.

I’ll be starting there this next Monday, just as soon as I can wrap up business at my current job.

Tutorials should begin again as usual once I finish the transition.

Categories: News Tags:

How To Configure Wireless on a MacBook Using Ndiswrapper

March 18th, 2007 Christer Edwards 25 comments

As many of you saw, this past week I bought myself a new Macbook and have successfully installed Ubuntu on it via bootcamp. I plan on documenting many of the steps I took to be published this upcoming week, but first I have some great news. I have successfully configured wireless on this machine despite all the talks that it wasn’t available! If you are struggling with wireless on a Core 2 Duo Macbook you might give this a try.

First of all, you’ll need to use ndiswrapper. There is not a free solution (free as in freedom) to this *yet* but from the piles of articles, threads and bugs that I read the madwifi team is working on it. In the meantime we’ll have to use the Windows driver, which I will link to here.

Second, you’ll need to compile ndiswrapper yourself as even the Feisty package is out dated and will not support this hardware. I’ll walk through those few steps as well.

Third, if this works for you, you’ll have to share it with everyone you know because wireless is awesome, of course, and not something that one can easily live without.

Ok, now on to the good stuff.

How to setup wireless on a Macbook (Core 2 Duo) using ndiswrapper.

You’ll need the latest version of ndiswrapper available from their site. I am currently using the v1.38 release. You can find that here. (Feisty still includes the 1.30 version, which was released 2006-11-28!)

Unzip this package to a location you’ll remember. (ie; Desktop)

You’ll want to remove any previous installations or mentions of ndiswrapper. I used the following:

sudo aptitude remove –purge ndiswrapper-common ndiswrapper-utils (make sure you get any other package you’ve installed)

sudo rm -R /etc/ndiswrapper

sudo rm /etc/modprobe.d/ndiswrapper

After you’ve purged any of your previous attempts you can open a terminal and enter the directory where you unzipped the ndiswrapper-1.38 source (which, for this tutorial, will be on your Desktop)

cd ~/Desktop/ndiswrapper-1.38/

You will need the powers of compiling, which is tidily wrapped up in the build-essential package. Simply sudo aptitude install build-essential and you should have what you need for the next few steps.

make uninstall (repeat until it doesn’t find anything)

make

sudo make install

At this point your ndiswrapper version 1.38 should be installed to your system. You’re now ready to download the appropriate driver and unpack its contents. The driver I used is sourced from a Lenovo driver page but it appears to be the same hardware and it’s working so… you can get that here.

Note: if you want to verify that it is the suggested driver for your system you can run the following two commands, and verify that listing suggestion on the supported hardware page of ndiswrapper.

lspci

This is what I get in my output:

02:00.0 Network controller: Atheros Communications, Inc. Unknown device 0024 (rev 01)

You’ll then want to run

lspci -n | grep 02:00.0 (note this is grepping for the information at the beginning of the line above. alter if your information is different)

…the results you get here is the PCI-ID for that card, (mine being: 02:00.0 0280: 168c:0024 (rev 01)
). You’ll want to take the 168c:0024 section of this output and search for it at the ndiswrapper hardware list. (I know it sounds a bit complicated but give it a try, you should catch on to what you’re looking for pretty quickly)

So now that you’ve verified your card ID and downloaded the driver you can install it using the command below:

sudo ndiswrapper -i NET5416.INF

This should give you some output.. and then to verify that the system is happy with that driver:

sudo ndiswrapper -l

Hopefully you see the same thing I did:

net5416 : driver installed
device (168C:0024) present

If this is the case (and notice the device number matches the lspci -n information above, something I had trouble with in previous attempts) you can load the ndiswrapper module and you should be ready to rock.

sudo modprobe ndiswrapper

Take a look to see if the device was created using something like:

iwconfig or check network-manager to see if you’ve got a wireless device listed now.

…and to have it auto-load at each boot

sudo ndiswrapper -m

At this point set up your wireless card information, pull out that leash of a LAN cable and jump for joy! Yeah, it’s ok to dance around the room a little bit if you’ve been fighting this for a while.

If it doesn’t work for you feel free to drop me and email and we’ll see if we can’t get something figured out. Good luck!

Categories: News Tags:

Ubuntu on a Macbook

March 15th, 2007 Christer Edwards 19 comments

I am now the owner of an Apple Macbook and I have spent the course of the day getting Ubuntu installed on it (under Bootcamp).  I will have some tutorials ready by the weekend for any of you that have wanted to try or are tempted to get a Macbook.  So far I am still having trouble with one thing though, and if any of you current owners can offer me some tips I sure would appreciate it.

My problem so far is that wireless doesn’t work for me.  I have tried three sources for a driver over ndiswrapper and none of them seem to work yet.  Two of them will show driver present, hardware present and one of them gives me the best result with a kernel panic (yes, that is sarcasm).

Has anyone been able to get wireless working on a macbook, core 2 duo with the 168c:0024 PCI-ID?

Other than that things are coming along well.  Again, look for a tutorial on getting Ubuntu Feisty running on a MacBook via bootcamp within a few days… assuming I can get this wireless going.

Categories: News Tags:

How To Burn an .ISO image in 3-Clicks (CD or DVD)

March 15th, 2007 Christer Edwards 34 comments

I was working on a project the other day with a friend and he was having some trouble burning an .iso image of one of the Ubuntu 7.04 Herd releases. He asked me about installing gnomebaker or K3B for burning the image. While I have used both of those programs I found that a disk image can be burned very easily directly from the the file location. Here are a few steps to burning a disk image in three clicks.

  1. First, you’ll need to have a .iso image available for burning. This could be located on your desktop, home folder or I’ve even burned an image using this method over on NFS connection. You’ll also need a blank CD or DVD in the drive.
  2. Once you’ve selected your disk image you can right-click the .iso file and select “Write to disk…” (two clicks)
  3. This will open a dialog box letting you verify the disk type, size and burn speed. If all is correct (which it normally is) you can click Burn. Sit back and relax. Your disk will be finished in just a few minutes. (one click)

Done. When finished it’ll ask if you’d like to Eject, Burn Another Copy or if you’re just Done. So very easy.

I find this method much faster and a little more intuitive than the other cd / dvd burning applications. Not to say they aren’t great apps, but if you’re just burning a simple disk image this should be a bit faster. I’ve also had far fewer coasters using this method than I have with the others.

Categories: GNOME Tags: ,

How To Setup OpenDNS On Ubuntu

March 14th, 2007 Christer Edwards 8 comments

I had heard about OpenDNS a while ago but for some reason never looked much into it. A magazine article tonight reminded me about OpenDNS so I thought I’d take a look. Well, I’m happy that I did so far. I thought I would outline a few steps for you to get OpenDNS setup on your machine.

First, what is OpenDNS?

OpenDNS is a better DNS, free to all. OpenDNS uses its distributed network of DNS servers to speed up your Internet experience, increase reliability, improve security and make DNS smarter for users all over the world.

Basically you can stop using your ISPs DNS, which can often be slower or unreliable, and use this instead. Here is how to set it up on an Ubuntu machine. You can see the Ubuntu setup instructions on the OpenDNS site if you’d like more information.

sudo cp /etc/resolv.conf /etc/resolv.conf.auto

sudo gedit /etc/dhcp3/dhclient.conf

Look for the below line, which will be commented, and match this setting.

# append the following line to the document
prepend domain-name-servers 208.67.222.222,208.67.220.220;

Once your entry matches this you will want to save the file and restart networking using a command such as the one below.

sudo ifdown eth0 && sudo ifup eth0

You can then visit this address to verify that you’re using the new OpenDNS service.

http://welcome.opendns.com

Categories: Internet Tags: ,

Squashing A Few Myths About Mono Development

March 13th, 2007 Christer Edwards 20 comments

During my switch to KDE for a week I saw a few comments about others leaving gnome based on the seeming trend toward mono development. I have seen this in other places as well and I thought I would try to offer some information on what the mono framework really is about. I share some of the same reservations that many of you have about Microsoft, its tools and so-called “Intellectual Property“. I was interested enough that I thought I should do some research. Well here is what I found out about mono.

What Is Mono?

Mono provides the necessary software to develop and run .NET client and server applications on Linux, Solaris, Mac OS X, Windows, and Unix. Sponsored by Novell (http://www.novell.com), the Mono open source project has an active and enthusiastic contributing community and is positioned to become the leading choice for development of Linux applications. - Mono Project Website

Did I really just say .NET? Back the truck up there pal! I don’t want to develop for Microsoft! Well you’re not. .NET is a public development framework that was initially contributed to by Microsoft but does fall under their control, licensing, etc. From the Mono website:

The Mono Project is an open development initiative sponsored by Novell to develop an open source, UNIX version of the Microsoft .NET development platform. Its objective is to enable UNIX developers to build and deploy cross-platform .NET Applications. The project implements various technologies developed by Microsoft that have now been submitted to the ECMA for standardization.

The ".NET Initiative" is a somewhat nebulous company-wide effort by Microsoft, one part of which is a cross-platform development framework. Mono is an implementation of the development framework, but not an implementation of anything else related to the .NET Initiative, such as Passport or software-as-a-service.

Ok. I’ll translate. This didn’t really clear a lot up for me at first either. It gets better, I promise. From what I understand Microsoft put together a development framework that allowed coders to write programs in the language of their choice. In other words, you and I could work side by side on a program while I use python and you used C#. .NET, in its original implementation, allowed for this and was then submitted to the ECMA for standardization. So, Microsoft isn’t even really in charge of this system anymore although they’ve expanded it to their Passport and software-as-a-service models. These two things, and Microsofts usage of this development framework are really disconnected from Mono.

The only thing .NET, Microsofts original framework, and Mono have in common are the idea. A central cross-platform development framework.. and one is based on the other, although not dependent on the other.

Now, from what I’ve read and understand, there really are quite a few benefits of writing in Mono that should really appeal to us as a software community. Not only in developing better software but also in being able to spread our software to those not yet ready to use Linux or Ubuntu.

As mentioned above Mono allows you to write an application in a list of languages so you can use the language of your choice. You don’t need to learn something new in order to use it. Some of the languages currently supported in Mono are:

C#

Java

Boo

Nemerle

Visual Basic.NET

Python

Javascript

Oberon

PHP

Object Pascal

Cross Platform Compatibility is the second, and I think more important reason why Mono development can benefit us. Considering that Mono is supported on Linux, UNIX, OSX, Solaris, BSD and Windows you can write an application within one and almost instantly port it to the next. Assuming the other platform has the mono common libraries (which are included in Ubuntu and Windows for starters) and your application doesn’t depend on any platform dependent libraries. If this is the case you just wrote an application that can be used on Linux, OSX and Windows without any additional work.

Think of the benefits to those outside our community if we could more easily share our Open Source applications with them.. and if we can sell them on Open Source applications we’ll have an easier chance of helping them understand the benefits of free software and the ideals we all embrace.

There are already some very popular applications that have been developed using Mono. You might have already used a few of them. Banshee. Tomboy. F-Spot. Beagle. Even Second Life is developed using Mono.

You might want to take a second look at what Mono is all about. I think it has some real value. Not only for us as developers but also as a community. Thoughts?

Categories: Development Tags:

Dell Is Listening – Help Make A Change

March 13th, 2007 Christer Edwards 4 comments

Based on the results of the aptly named Dell Idea Storm (which got a storm of requests for Linux pre-installed) Dell is now asking for more information on what we would like if they were to offer a Linux based installation. Please, for the love, visit this Dell Linux Survey and vote for what you would need from them. My only humble request? Vote for Ubuntu as your distro of choice!

…and if Free Software is important to you share the link with everyone you know!

Categories: Community Tags: