Friday, 24 October 2008

How to Configure WiFi and Webcam in a Dell Inspiron 1525 for Hardy

A fresh install from the Ubuntu disk does not include the wifi and webcam drivers by default, so you have to install them manually. If you can connect to the internet by ethernet (wire) from your laptop then do so.



If you can connect by ethernet

Go to System -> Administration -> Software Sources -> Updates tab.

Check the box saying "Unsupported updates (hardy-backports)" and close the window.

Open a terminal window and type

sudo apt-get update

and then

sudo apt-get install linux-backports-modules-hardy

This is a meta-package that will install the relevant modules for your kernel version and keep them up to date whenever you install a new kernel version. After a reboot your WiFi and/or webcam should work now, and hopefully bluetooth but I'm not sure whether these modules will enable bluetooth or not.

If you cannot connect by ethernet

Go to the following page and download the file for your processor (AMD or Intel) to a removable storage device (eg. Pen drive). The file you want to download is under the header "Download linux-backports..." from here

Put the pen drive into your laptop and double click to run the .deb file you downloaded from that page. Install the package (you'll need to use your sudo password).

After that, a reboot should have your wireless and webcam running (if you have a webcam). However, you should now do all of the tasks listed under "If you can connect by ethernet" before any new updates. This is because kernel modules are kernel version dependent, and you need the meta package to ensure your kernel module is kept up to date with any new kernel versions.

Sound

Sound should be working with the default Ubuntu install on an Inspiron 1525, but with some limits, namely Pulseaudio won't work with all programs installed on your computer so you might be limited to only one application being able to produce sound at a time.

For a simple solution, just open Synaptic, search for "Pulseaudio" and install all the packages it lists.

You may not need to, but it may be best to reboot after installing these pulseaudio packages, to ensure the server and your desktop environment loads all of these new packages and uses them.

Read More......

Sunday, 19 October 2008

How to Setup Broadcom Wireless BCM4312 (rev 02)for Ubuntu Hardy

Step 1 (run in terminal)

echo 'blacklist bcm43xx' | sudo tee -a /etc/modprobe.d/blacklist

sudo apt-get install ndiswrapper-utils-1.9


mkdir ~/bcm43xx; cd ~/bcm43xx

For Step 2, You can check your Broadcom wireless version with this command in terminal : "lspci | grep Broadcom\ Corporation",if your wireless device is different from BCM4312 (rev 02), please refer here for this step and you can continue again with step 3 onwards:

Step 2 (run in terminal)

sudo apt-get install cabextract

wget ftp://ftp.compaq.com/pub/softpaq/sp34001-34500/sp34152.exe

cabextract sp34152.exe

Step 3 (run in terminal)

sudo ndiswrapper -i bcmwl5.inf

ndiswrapper -l

sudo depmod -a

sudo modprobe ndiswrapper

sudo cp /etc/network/interfaces /etc/network/interfaces.orig

echo -e 'auto lo\niface lo inet loopback\n' | sudo tee /etc/network/interfaces

sudo ndiswrapper -m

echo 'ndiswrapper' | sudo tee -a /etc/modules

echo 'ENABLED=0' | sudo tee -a /etc/default/wpasupplicant

Step 4 (run in terminal)

sudo aptitude remove b43-fwcutter

Step 5 (run in terminal)

sudo gedit /etc/init.d/wirelessfix.sh

Step 6

Paste the followings in the opened file(wirelessfix.sh)and make sure you save it before continuing Step 7

#!/bin/bash
modprobe -r b44
modprobe -r b43
modprobe -r b43legacy
modprobe -r ssb
modprobe -r ndiswrapper
modprobe ndiswrapper
modprobe b44

Step 7 (run in terminal)

Run this :

cd /etc/init.d/ && sudo chmod 755 wirelessfix.sh

Step 8 (run in terminal)

finally run this:

sudo update-rc.d wirelessfix.sh defaults

Step 9

Restart your machine and that's it.

Read More......

Some tips for correcting UUIDs in Ubuntu

a UUID is a rather long identifier for a disk partition. Every disk partition has its own unique UUID. In Ubuntu, the UUID for partitions must be correctly specified in two files: /boot/grub/menu.lst and /etc/fstab. Sometimes errors occur during boot up eg after partition changes or formatting cause changes to the UUID. Correction is often simply a matter of editing files to reflect the correct UUID designations.



First... Files which may need to be edited include /boot/grub/menu.lst and /etc/fstab. It's a good idea to back up these important files first

sudo cp /etc/fstab /etc/fstab.bk1

sudo cp /boot/grub/menu.lst /boot/grub/menu.lst.bk1

To find out the UUID for each partition, in a terminal type:

sudo blkid

This will show the current UUID and the device designation for each drive recognised by the BIOS. The partition does not need to be mounted - it will appear here in any case.

To list all partitions on all drives:

sudo fdisk -l

This will show the partition information for each drive, and each partition. You can recognise which partition is which on the basis of its size, format and the drive designation. Once again, the partition does not need to be mounted; all partitions will be listed irrespective. The 'fdisk' command does not show the UUID of partitions but we already have that from the 'sudo blkid' command.

To find out where partitions are mounted now:

mount

To show/edit default mount points:

cat /etc/fstab

sudo gedit /etc/fstab

This will show where partitions are mounted during boot. You may wish to use a text editor other than gedit of course (eg kate, mousepad, vi, nano, mcedit etc). The UUID or device name shown in the relevant line in fstab must correlate with the partition information given by 'fdisk' and 'blkid'.

To show/edit where Grub is directing the boot process:

cat /boot/grub/menu.lst

sudo gedit /boot/grub/menu.lst

Towards the end of the menu.lst file you will see entries correlating to those you see in Ubuntu's start up or boot menu, (which only appears if enabled). The UUID for the respective partition, which appears in /boot/grub/menu.lst, must be that shown by 'sudo blkid'.

Note: Drive and partition numbering in Grub language starts at 0, whereas the numbering for the Ubuntu operating system starts at "a" or 1. Thus "root (hd0,0)" would be Grub's reference to the first partition on the first drive, ie device "/dev/sda1". Likewise for example "root (hd1,2)" would refer to "/dev/sdb3".

Some examples from laptop:

Extract from output of 'sudo blkid':

/dev/sda1: UUID="73d8bfea-01e8-4f65-8efe-99265ce849db" TYPE="ext2"
/dev/mmcblk0p1: UUID="24672713-fb81-47f5-8190-f8f88529ac44" TYPE="ext2"
/dev/sdb1: LABEL="LaCie" UUID="6853-5BA9" TYPE="vfat"
/dev/sdb2: UUID="c85eeef7-1599-4be8-a5b8-9d3f673db526" TYPE="ext2"

Shows me the UUID and format type for the partitions on several disks on my laptop.

Extract from output of 'sudo fdisk -l':

Disk /dev/sda: 8069 MB, 8069677056 bytes
255 heads, 63 sectors/track, 981 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x000a34c8

Device Boot Start End Blocks Id System
/dev/sda1 * 1 981 7879851 83 Linux

(Other lines deleted for brevity)

Shows me the size and format information for my partitions .

Extract from output of 'mount':

/dev/sda1 on / type ext2 (rw,noatime,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
/sys on /sys type sysfs (rw,noexec,nosuid,nodev)
varrun on /var/run type tmpfs (rw,noexec,nosuid,nodev,mode=0755)
varlock on /var/lock type tmpfs (rw,noexec,nosuid,nodev,mode=1777)
udev on /dev type tmpfs (rw,mode=0755)
devshm on /dev/shm type tmpfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
lrm on /lib/modules/2.6.24-19-generic/volatile type tmpfs (rw)
/dev/mmcblk0p1 on /home type ext2 (rw,noatime)
/dev/sdb1 on /media/sdb1 type vfat (rw,noexec,nosuid,nodev,dmask=0000,fmask=1111,uid=1000,gid=1000)
securityfs on /sys/kernel/security type securityfs (rw)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)

(Other lines deleted for brevity)

Shows (amongst other things) that my partition /dev/sda1 is mounted on the root file system "/" and that my /dev/mmcblk0p1is mounted on "/home".

Extract from output of 'cat /boot/grub/menu.lst':

(Lots of lines deleted for brevity)
title Ubuntu 8.04.1, kernel 2.6.24-19-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-19-generic root=UUID=73d8bfea-01e8-4f65-8efe-99265ce849db ro quiet
initrd /boot/initrd.img-2.6.24-19-generic
quiet

title Ubuntu 8.04.1, kernel 2.6.24-19-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-19-generic root=UUID=73d8bfea-01e8-4f65-8efe-99265ce849db ro single
initrd /boot/initrd.img-2.6.24-19-generic

title Ubuntu 8.04.1, memtest86+
root (hd0,0)
kernel /boot/memtest86+.bin
quiet
(Other lines deleted for brevity)

Here:

* 'title' is the relevant line as displayed in the Grub menu
* 'root' is the partition where grub will look for the boot files (and remember (hd0,0) refers to /dev/sda1)
* 'kernel' is the path where grub will look for the kernel file
* 'initrd' is the path where grub will look for the file system image file

Read More......

Saturday, 11 October 2008

Howto get the rt2870 Wifi 802.11abgn chipset to work with Intrepid Ibex

Install build-essential (This may not be needed so try the next steps without build-essential first).


sudo apt-get install build-essential

Create a directory in for example your home directory to keep all the files.

cd ~/

mkdir rt2870

cd rt2870

Now retrieve the driver

wget http://www.ralinktech.com.tw/data/drivers/2008_0925_RT2870_Linux_STA_v1.4.0.0.tar.bz2

Extract the compressed driver directory and files.

tar xvfj 2008_0925_RT2870_Linux_STA_v1.4.0.0.tar.bz2

Enter the directory and edit the config.mk file so that the driver will support NetworkManager

nano os/linux/config.mk

Change the following part

# Support Wpa_Supplicant

HAS_WPA_SUPPLICANT=n

# Support Native WpaSupplicant for Network Magang

HAS_NATIVE_WPA_SUPPLICANT_SUPPORT=n

to this

# Support Wpa_Supplicant

HAS_WPA_SUPPLICANT=y

# Support Native WpaSupplicant for Network Maganger

HAS_NATIVE_WPA_SUPPLICANT_SUPPORT=y

Compile and install.

sudo make

sudo make install

Edit the Ralink settings file to your liking.

sudo nano /etc/Wireless/RT2870STA/RT2870STA.dat

This is what mine looks like without the passwords and accesspoint.

#The word of "Default" must not be removed

Default

CountryRegion=5

CountryRegionABand=7

CountryCode=SE

ChannelGeography=1

SSID=*REMOVED*

NetworkType=Infra

WirelessMode=5

Channel=1

BeaconPeriod=100

TxPower=100

BGProtection=0

TxPreamble=0

RTSThreshold=2347

FragThreshold=2346

TxBurst=1

PktAggregate=0

WmmCapable=1

AckPolicy=0;0;0;0

AuthMode=WPA

EncrypType=TKIP

WPAPSK=*REMOVED*

DefaultKeyID=1

Key1Type=0

Key1Str=

Key2Type=0

Key2Str=

Key3Type=0

Key3Str=

Key4Type=0

Key4Str=

PSMode=CAM

FastRoaming=0

RoamThreshold=70

APSDCapable=0

APSDAC=0;0;0;0

HT_RDG=1

HT_EXTCHA=0

HT_OpMode=1

HT_MpduDensity=4

HT_BW=1

HT_BADecline=0

HT_AutoBA=1

HT_BADecline=0

HT_AMSDU=1

HT_BAWinSize=64

HT_GI=1

HT_MCS=33

HT_MIMOPSMode=3

IEEE80211H=0

TGnWifiTest=0

WirelessEvent=0

I think the important part of my changes is this.

AuthMode=WPA

This was what I had to change to make the driver work with NetworkManager.

Now make the driver load at bootup

sudo nano /etc/modules

and add this line to the the file.

alias ra0 rt2870sta

My /etc/modules looks like this.

# /etc/modules: kernel modules to load at boot time.

#

# This file contains the names of kernel modules that should be loaded

# at boot time, one per line. Lines beginning with "#" are ignored.

fuse

lp

sbp2

#ndiswrapper

uinput

alias ra0 rt2870sta

# Added for Nero Linux device access

sg

Add an ugly fix to make the ra0 interface come up during each boot.

sudo nano /etc/init.d/rc.local

and add these lines to the end of the file

ifconfig ra0 inet up

sudo /etc/init.d/NetworkManager restart

Reboot and it should work. It did for me.

Read More......

How To Change File-Type (mimetype) Icons in Ubuntu

This how-to is based on wanting to change icons which have been downloaded from Gnome-look or some other source. As an example, I'll show how to change the icons associated with .doc and .odt files. Exactly same method applies to other file types.


(If you're using the icons supplied with Ubuntu, you'll find them in /usr/share/icons. Also, if the iconset you're modifying is based on scalable .svg icons, the procedure will differ - find the icon to change in the "scalable" folder and replace with new .svg image)

Open up a folder containing files with icons you want to change.

Right-click on an icon and select Properties

Look for the MIME type entry and make a note of it:
e.g. application/msword (for .doc file)
or application/vnd.oasis.opendocument.text (for .odt file)

Navigate to ~/.icons folder. You'll see all the custom icon sets you've installed.

Open up the icon folder you're using and you'll see that there are several folders containing the same icons at different sizes. In the Nautilus file manager, you can zoom in or out, increasing or decreasing the size of the icons displayed - these folders of icons make that possible. The size of icon vs zoom level is as follows:

400% - 128x128
200% - 96x96
150% - 72x72
100% - 48x48
67% - 32x32
50% - 24x24
33% - 16x16

(There are also icon folders 64x64 and 24x24 - not sure what they're used for!)

Make seven versions of the image you want to use in the sizes listed above and copy into each folder.

You'll have to repeat the next bit for each size:

Open folder
Look for file corresponding to mimetype entry you noted down earlier
e.g. application/msword = application-msword.png
or application/vnd.oasis.opendocument.text = application-vnd.oasis.opendocument.text.png
Delete existing file
Find the image file you copied in here earlier, right-click, Properties, Permissions tab.
Click on the "Execute" tick box and "OK"
Right-click on image file, Make link to to create a new link file.
Rename the link to replace the file you deleted.

Repeat for each icon size.


When you've finished replacing icons, delete the "icon-theme.cache" file.

Open a terminal and do:

# cd .icons

# gtk-update-icon-cache ICONSET NAME

This will re-generate the icon-theme.cache file using your new icons.

That's about it. Open up a new Nautilus window and enjoy icon nirvana

Read More......

How to install Wink (Video Tutorials Application) for 64bit - Ubuntu 8.04

Wink is a great program for creating video tutorials through the use of flash animation. You can take screen captures with Wink either on-demand or on a time-delay basis and then compile those screenshots into a swf file for use in a web page. You can also add explanation boxes, buttons and titles to your presentations. If you're looking for an easy way to create a video tutorial on how to use certain software applications or perhaps even a website then you definitely want to check out Wink. Unfortunately the wink package available in the Ubuntu repository is only available for the 32-bit architecture so this guide will walk you through installing it on the 64-bit version of Ubuntu.


First off you'll need to install the ia32-libs package if it's not already installed.

sudo apt-get install ia32-libs

The next step is to download the Wink package from here

Open your terminal and type the following:

cd /home/[YourUserName]/Desktop

dpkg-deb --extract wink_1.5.1060-3ubuntu1.2_i386.deb wink

dpkg-deb --control wink_1.5.1060-3ubuntu1.2_i386.deb wink/DEBIAN

gedit ./wink/DEBIAN/control

Find the line that begins with "Architecture:" and replace the "i386" with "all"

Architecture: all

Delete the line that begins with "Original-Maintainer: Daniel Baumann ". This step isn't mandatory but it will prevent an error from being displayed when the package is built.

Click Save and close gedit.

Type the following

gedit ./wink/usr/share/applications/wink.desktop

Find the line that begins with "Icon=" and replace "wink" with "/usr/share/pixmaps/wink.xpm". This step ensures that the correct icon will appear on your Applications > Graphics menu.

Icon=/usr/share/pixmaps/wink.xpm

Click Save and close gedit

The wink package requires that the libexpat.so.0 file be installed in your /usr/lib32 folder. The first step here is to check and see if you have that file installed. Type the following:

dir /usr/lib32/libexpat*

If you see a file named libexpat.so.0 then you can skip to step 12. Otherwise make a note of the latest version of libexpat that is installed. It's most likely going to be libexpat.so.1.5.2. Type the following: (make sure to replace the 1.5.2 with your latest version)

mkdir ./wink/usr/lib32

sudo ln -s /usr/lib32/libexpat.so.1.5.2 ./wink/usr/lib32/libexpat.so.0

Type the following to build the package.

dpkg-deb --build wink

Click on the new wink.deb package to install it or type the following. If you receive any errors during the installation you may need to install the gcc-3.3-base and libstdc++5 pacakges.

sudo dpkg -i wink.deb

Before running the program for the first time you need to make sure that all required libraries are installed. After you install the newly created package type the following:

ldd /usr/lib/wink/wink

If none of the libraries say "not found" then you should now be able to open wink from the Applications > Graphics menu.

To uninstall type the following command

sudo apt-get remove wink

Read More......

Adeona - System for tracking lost or stolen laptops in Ubuntu

Adeona is the first Open Source system for tracking the location of your lost or stolen laptop that does not rely on a proprietary, central service. This means that you can install Adeona on your laptop and go — there's no need to rely on a single third party. What's more, Adeona addresses a critical privacy goal different from existing commercial offerings. It is privacy-preserving. This means that no one besides the owner (or an agent of the owner's choosing) can use Adeona to track a laptop. Unlike other systems, users of Adeona can rest assured that no one can abuse the system in order to track where they use their laptop.


Installation Procedure

Step 1: Install the packages that Adeona needs

sudo apt-get install build-essential libssl-dev openssl traceroute cron

Step 2: Download the latest version of Adeona to your home folder

Step 3: Unzip/Untar the tar file

tar -xvf adeona-0.2.1.tar.gz

Step 4: Move to adeona directory

cd adeona/

Step 5: Run the configuration and compile

./configure

make

Step 6: Install Adeona

sudo make install

Step 7: During the install it asks you to add a line to your cron/crontab... Make sure you copy this line, then open cron/crontab

sudo crontab -e

and then paste this line as a new line at the end of your cron/crontab file and then save it.

Read More......