Open Source Technical Information: October 2011

Friday 28 October 2011

Top 11 Best Linux Distribution For 2011

,
Here are the top 11 Linux Distributions according to Distrowatch

1

Ubuntu

2

Mint

3

debian

4

fedora

5

opensuse

6

arch

7

pclinuxos

8

Puppy

9

sabayon

10

centos

11

mandriva
Linux is low cost, stable, performs well, has network friendliness, flexibility, compatability, choice, fast and easy installs, multitasking, security and best of all open source. Make sure you research your distro or try to figure out what it is you are trying to do before choosing your flavor of linux. For my laptop I run Fedora. What’s your favorite?

25 Best SSH Commands / Tricks

,
OpenSSH is a FREE version of the SSH connectivity tools that technical users of the Internet rely on. Users of telnet, rlogin, and ftp may not realize that their password is transmitted across the Internet unencrypted, but it is. OpenSSH encrypts all traffic (including passwords) to effectively eliminate eavesdropping, connection hijacking, and other attacks.  The encryption that OpenSSH provides has been strong enough to earn the trust of Trend Micro and other providers of cloud computing.Additionally, OpenSSH provides secure tunneling capabilities and several authentication methods, and supports all SSH protocol versions.


SSH is an awesome powerful tool, there are unlimited possibility when it comes to SSH, heres the top Voted SSH commands

1) Copy ssh keys to user@host to enable password-less ssh logins.

ssh-copy-id user@host
To generate the keys use the command ssh-keygen


2) Start a tunnel from some machine’s port 80 to your local post 2001

ssh -N -L2001:localhost:80 somemachine
Now you can acces the website by going to http://localhost:2001/


3) Output your microphone to a remote computer’s speaker

dd if=/dev/dsp | ssh -c arcfour -C username@host dd of=/dev/dsp
This will output the sound from your microphone port to the ssh target computer’s speaker port. The sound quality is very bad, so you will hear a lot of hissing.


4) Compare a remote file with a local file

ssh user@host cat /path/to/remotefile | diff /path/to/localfile -
Useful for checking if there are differences between local and remote files.


5) Mount folder/filesystem through SSH

sshfs name@server:/path/to/folder /path/to/mount/point
Install SSHFS from http://fuse.sourceforge.net/sshfs.html
Will allow you to mount a folder security over a network.


6) SSH connection through host in the middle

ssh -t reachable_host ssh unreachable_host
Unreachable_host is unavailable from local network, but it’s available from reachable_host’s network. This command creates a connection to unreachable_host through “hidden” connection to reachable_host.

7) Copy from host1 to host2, through your host


ssh root@host1 “cd /somedir/tocopy/ && tar -cf – .” | ssh root@host2 “cd /samedir/tocopyto/ && tar -xf -”
Good if only you have access to host1 and host2, but they have no access to your host (so ncat won’t work) and they have no direct access to each other.


8) Run any GUI program remotely



ssh -fX @
The SSH server configuration requires:
X11Forwarding yes # this is default in Debian
And it’s convenient too:
Compression delayed

9) Create a persistent connection to a machine

ssh -MNf @
Create a persistent SSH connection to the host in the background. Combine this with settings in your ~/.ssh/config:
Host host
ControlPath ~/.ssh/master-%r@%h:%p
ControlMaster no
All the SSH connections to the machine will then go through the persisten SSH socket. This is very useful if you are using SSH to synchronize files (using rsync/sftp/cvs/svn) on a regular basis because it won’t create a new socket each time to open an ssh connection.


10) Attach screen over ssh

ssh -t remote_host screen -r
Directly attach a remote screen session (saves a useless parent bash process)


11) Port Knocking!

knock 3000 4000 5000 && ssh -p user@host && knock 5000 4000 3000
Knock on ports to open a port to a service (ssh for example) and knock again to close the port. You have to install knockd.
See example config file below.
[options]
logfile = /var/log/knockd.log
[openSSH]
sequence = 3000,4000,5000
seq_timeout = 5
command = /sbin/iptables -A INPUT -i eth0 -s %IP% -p tcp –dport 22 -j ACCEPT
tcpflags = syn
[closeSSH]
sequence = 5000,4000,3000
seq_timeout = 5
command = /sbin/iptables -D INPUT -i eth0 -s %IP% -p tcp –dport 22 -j ACCEPT
tcpflags = syn


12) Remove a line in a text file. Useful to fix

ssh-keygen -R
In this case it’s better do to use the dedicated tool


13) Run complex remote shell cmds over ssh, without escaping quotes

ssh host -l user $(
Much simpler method. More portable version: ssh host -l user “`cat cmd.txt`”

14) Copy a MySQL Database to a new Server via SSH with one command

mysqldump –add-drop-table –extended-insert –force –log-error=error.log -uUSER -pPASS OLD_DB_NAME | ssh -C user@newhost “mysql -uUSER -pPASS NEW_DB_NAME”
Dumps a MySQL database over a compressed SSH tunnel and uses it as input to mysql – i think that is the fastest and best way to migrate a DB to a new server!

15) Remove a line in a text file. Useful to fix “ssh host key change” warnings

sed -i 8d ~/.ssh/known_hosts

16) Copy your ssh public key to a server from a machine that doesn’t have ssh-copy-id

cat ~/.ssh/id_rsa.pub | ssh user@machine “mkdir ~/.ssh; cat >> ~/.ssh/authorized_keys”
If you use Mac OS X or some other *nix variant that doesn’t come with ssh-copy-id, this one-liner will allow you to add your public key to a remote machine so you can subsequently ssh to that machine without a password.

17) Live ssh network throughput test

yes | pv | ssh $host “cat > /dev/null”
connects to host via ssh and displays the live transfer speed, directing all transferred data to /dev/null
needs pv installed
Debian: ‘apt-get install pv’
Fedora: ‘yum install pv’ (may need the ‘extras’ repository enabled)

18) How to establish a remote Gnu screen session that you can re-connect to

ssh -t user@some.domain.com /usr/bin/screen -xRR
Long before tabbed terminals existed, people have been using Gnu screen to open many shells in a single text terminal. Combined with ssh, it gives you the ability to have many open shells with a single remote connection using the above options. If you detach with “Ctrl-a d” or if the ssh session is accidentally terminated, all processes running in your remote shells remain undisturbed, ready for you to reconnect. Other useful screen commands are “Ctrl-a c” (open new shell) and “Ctrl-a a” (alternate between shells). Read this quick reference for more screen commands: http://aperiodic.net/screen/quick_reference

19) Resume scp of a big file

rsync –partial –progress –rsh=ssh $file_source $user@$host:$destination_file
It can resume a failed secure copy ( usefull when you transfer big files like db dumps through vpn ) using rsync.
It requires rsync installed in both hosts.
rsync –partial –progress –rsh=ssh $file_source $user@$host:$destination_file local -> remote
or
rsync –partial –progress –rsh=ssh $user@$host:$remote_file $destination_file remote -> local

20) Analyze traffic remotely over ssh w/ wireshark

ssh root@server.com ‘tshark -f “port !22″ -w -’ | wireshark -k -i -
This captures traffic on a remote machine with tshark, sends the raw pcap data over the ssh link, and displays it in wireshark. Hitting ctrl+C will stop the capture and unfortunately close your wireshark window. This can be worked-around by passing -c # to tshark to only capture a certain # of packets, or redirecting the data through a named pipe rather than piping directly from ssh to wireshark. I recommend filtering as much as you can in the tshark command to conserve bandwidth. tshark can be replaced with tcpdump thusly:
ssh root@example.com tcpdump -w – ‘port !22′ | wireshark -k -i -

21) Have an ssh session open forever

autossh -M50000 -t server.example.com ‘screen -raAd mysession’
Open a ssh session opened forever, great on laptops losing Internet connectivity when switching WIFI spots.

22) Harder, Faster, Stronger SSH clients

ssh -4 -C -c blowfish-cbc
We force IPv4, compress the stream, specify the cypher stream to be Blowfish. I suppose you could use aes256-ctr as well for cypher spec. I’m of course leaving out things like master control sessions and such as that may not be available on your shell although that would speed things up as well.

23) Throttle bandwidth with cstream

tar -cj /backup | cstream -t 777k | ssh host ‘tar -xj -C /backup’
this bzips a folder and transfers it over the network to “host” at 777k bit/s.
cstream can do a lot more, have a look http://www.cons.org/cracauer/cstream.html#usage
for example:
echo w00t, i’m 733+ | cstream -b1 -t2

24) Transfer SSH public key to another machine in one step

ssh-keygen; ssh-copy-id user@host; ssh user@host
This command sequence allows simple setup of (gasp!) password-less SSH logins. Be careful, as if you already have an SSH keypair in your ~/.ssh directory on the local machine, there is a possibility ssh-keygen may overwrite them. ssh-copy-id copies the public key to the remote host and appends it to the remote account’s ~/.ssh/authorized_keys file. When trying ssh, if you used no passphrase for your key, the remote shell appears soon after invoking ssh user@host.

25) Copy stdin to your X11 buffer

ssh user@host cat /path/to/some/file | xclip
Have you ever had to scp a file to your work machine in order to copy its contents to a mail? xclip can help you with that. It copies its stdin to the X11 buffer, so all you have to do is middle-click to paste the content of that looong file :)

Have Fun
Please comment if you have any other good SSH Commands OR Tricks.

Can I run Fedora on a Mac?

,
Yes, you can!
If you have a Core Duo Intel Mac, you want the i686 version of Fedora. If you have a Core 2 Duo or later Intel Mac, you want the x86_64 version of Fedora. (See the question about getting Fedora.) Note that some things may not yet work perfectly on Intel Macs. mactel-linux.org is a good site for information about running Fedora (or any Linux) on a Mactel machine.
If you have a G3, G4, or G5 Mac, there is no longer an installation disc available for your machine for Fedora 13/14/15.

How do I play MP3s in Fedora?

,
To play MP3s in Fedora, you have to install a different package depending on which Fedora MP3 player you want to use. If you're not sure which one to pick, Rhythmbox is the standard. It's in the "Applications" menu, under "Sound & Video" -- it's called "Rhythmbox Music Player." It looks kind of like iTunes when you run it.
Here's how to install the correct MP3 plugin:
  1. Make sure that you're using my yum configuration from the installing software question.
  2. Open a Terminal.
  3. Become root:
    su -
  4. Now, install the correct plugin depending on which MP3 player you want to use:
    • For Rhythmbox or Totem:
      yum install gstreamer-plugins-ugly
    • For Audacious (which is like XMMS or Winamp):
      yum install audacious-plugins-freeworld-mp3
Now you should be able to play MP3s in your favorite Fedora MP3 player!
INFO NOTE: For home users in any country (even the USA), there is no legal problem with MP3 players, so you are not doing anything illegal by enabling MP3 support in Fedora. However, if you are in the USA and you want to encode MP3s or use them in a commercial setting, you may be required to pay patent royalties.

How do I play DVDs in Fedora?

,
Easy! You just have to install some additional packages for Totem, the Movie Player:
  1. Make sure that you're using my yum configuration from the installing software question.
  2. Open a Terminal.
  3. Become root:
    su -
  4. Install the software that Totem needs in order to play DVDs correctly:
    yum install libdvdread libdvdcss libdvdnav gstreamer-plugins-ugly gstreamer-plugins-bad
And now you can play DVDs! You can find Totem in the "Applications" menu, under "Sound and Video." It's just called "Movie Player." Sometimes it will say that it can't play a DVD, but it will usually work if you close Totem, then insert the DVD into your drive, then wait for a popup to ask you what you want to do, and then click "Open."

Want to run Window's applicatoin on fedora? How do I install Wine?

,
Wine is a way of running some Windows programs on Linux. It's available using yum:
  1. Open a Terminal.
  2. Become root:
    su -
  3. Install wine:
    yum install wine

How do I edit the menus in the panel?

,
First you have to install the menu editor:
  1. Open a Terminal.
  2. Become root:
    su -
  3. Install the menu editor:
    yum install alacarte
Now you can go to the System menu, then "Preferences", and click on "Main Menu" to edit the menu.
For KDE users, there is a program called kmenuedit that you can run to edit the menu.

How do I read my NTFS (Windows NT/2000/XP/2003) drive in Fedora?

,
Well, now, that's an easy one! You just have to install the ntfs-3g program!
  1. Open a Terminal.
  2. Become root:
    su -
  3. Type:
    yum install ntfs-3g
Now you can read and write to your NTFS drives!
For information on how to use your NTFS drive, you can read the NTFS FAQ. (You don't need to worry about /proc/filesystems like it says there, though.)

Where can I get drivers for my hardware for Fedora?

,
Most drivers come with Fedora. However, if your driver doesn't come with Fedora, you can see what drivers are available for automatic download:
  1. Make sure that you're using my yum configuration from the installing software question.
  2. Open a Terminal.
  3. Become root:
    su -
  4. Run the following command:
    yum list akmod-\* \*-drv\* kmod-\* dkms-\*
If you don't find what you need this way, try Googling for:
Fedora NameOfHardware
or:
Linux NameOfHardware
Where NameOfHardware is the normal name of your hardware. If it has more than one name, keep trying different ones until you get a result.

Can I install the standard Windows fonts on Fedora?

,
Yes, there's also a very easy way to install all of the common Windows fonts on Linux. You don't usually have to do this on Fedora (because it comes with fonts called the "Liberation" fonts that are the same exact size as the Windows fonts), but if you want to do it, here's how:
  1. Install the chkfontpath package from ATrpms. (Click on either the i686 or x86_64 package, depending on whether you have a 32-bit or 64-bit machine.)
  2. Open a Terminal.
  3. Become root:
    su -
  4. Install some packages you'll need for the following steps:
    yum install rpm-build cabextract ttmkfdir wget
  5. Download the MS Core Fonts Smart Package File:
    wget http://corefonts.sourceforge.net/msttcorefonts-2.0-1.spec
  6. Build the Core Fonts package:
    rpmbuild -ba msttcorefonts-2.0-1.spec
  7. Install the Core Fonts package:
    yum install --nogpgcheck /root/rpmbuild/RPMS/noarch/msttcorefonts-2.0-1.noarch.rpm
(Thanks to David A. Wheeler and others for convincing me to add the MS Core Fonts instructions. Thanks to byro for pointing out the URL to the 2.0 package!)

Can I use MSN Messenger/AIM/ICQ/Yahoo instant messaging in Fedora?

,
Yes! By default, Fedora comes with a simple instant messaging program called Empathy, which supports MSN Messenger, ICQ, AIM, Yahoo! Messenger, and Google Talk, and many other protocols, all at the same time.
To start Empathy, click on the Applications menu, go to "Internet," and choose "Empathy IM Client."
If you don't like Empathy, you can use Pidgin, another Instant Messenger program for Linux. To install Pidgin:
  1. Open a Terminal.
  2. Become root:
    su -
  3. Install Pidgin:
    yum install pidgin
Pidgin will then be available in the Applications menu, under "Internet", as "Pidgin Instant Messenger".

How can I see PDF files inside my browser?

,
Just install mozplugger and xpdf:
  1. Open a Terminal.
  2. Become root:
    su -
  3. Install mozplugger:
    yum install mozplugger xpdf
This also enables Firefox to open lots of other types of files, like movies, audio, Word documents, etc.

How do I install a working Java plugin for my web browser?

,
Fedora includes an open-source version of Java 6, and nearly every Java applet will run if you simply install the Java plugin that comes with Fedora:
  1. Open a Terminal.
  2. Become root:
    su -
  3. Install the plugin:
    yum install java-1.6.0-openjdk-plugin

How do I install software in Fedora? (How to use yum or an RPM)

,
Fedora has thousands of pieces of software that can be downloaded and automatically installed from the Internet.

Configuring Package Installation

Many of the packages I mention in the FAQ are only available from rpmfusion. To configure your system so that you can install packages from rpmfusion, follow these instructions:
  1. Open a Terminal.
  2. Become root:
    su -
  3. Run the following command:

Using the GUI to Install/Update Software

If you have graphical access to your desktop, you can use the graphical tools to install software. Go to the System menu, choose "Administration", and then click on "Add/Remove Software".
Fedora will automatically let you know when updates are available for your software.

Installing Software From the Command Line

Often people want to use install or update software using the command line. For this you use a program called "yum". First become root, and then you can use the following commands:
  • To see a list of available software:
    yum list available
  • To install some software, you type:
    yum install packagename
  • To update some software, you type:
    yum update packagename
    If you leave out "packagename" yum will update all your software.
  • To see what updates are available, you can do:
    yum check-update
  • To search for a package, you can do:
    yum search word
For more info about yum, see the yum project page. (Thanks to Ron Kuris for this tip.)

Installing Local RPMs

To install an RPM file that you downloaded outside of yum, open up a terminal, and as root do:
rpm -Uvh filename.rpm
If you have Internet access, you can also install local files by doing:
yum --nogpgcheck install filename.rpm
Which is handy because it will automatically download and install any dependencies that that RPM has.

Where can I get software for Fedora?

,
The best way to get software is to use the normal software installation tools that come with Fedora, which will download and install things automatically for you.
Otherwise, to search for software packages, you can use rpm.pbone.net.

I can't access my Windows network shares anymore! People tell me to use the smbmount command, but it doesn't work!

,
Modern versions of Linux use a type of Windows file sharing called "The Common Internet File System" (CIFS). Instead of using "smbmount", try:
mount -t cifs //1.2.3.4/share /mnt/somedirectory
For more information about this, in a terminal you can do:
man mount.cifs
Note that CIFS can't resolve Windows computer names, so you're better off using their IP addresses.

The installer's media check says all my CDs are bad!

,
There is a bug in the kernel which causes the media check to say some CDs are bad when they are not, on some systems. To do a successful media check, do the following:
  1. At the installer prompt, type:
    linux mediacheck ide=nodma
  2. Run the media check on your CDs/DVD.
  3. Reboot, and run the installer normally.
Note that sometimes mediacheck will report that only some CDs are bad, but this will still fix that problem. (Thanks to Tony Nelson for reminding me of that!)

How do I enable 3D support for my nVidia graphics card in Fedora?

,
There are now nVidia driver RPMs provided by rpmfusion.org that are designed especially for Fedora. Here's how to install them:
  1. Make sure that you're using my yum configuration from the installing software question.
  2. Open a Terminal.
  3. Become root:
    su -
  4. Install the driver:
    yum install kmod-nvidia
  5. Rebuild your kernel configuration (otherwise it may try to load a conflicting driver during boot):
    new-kernel-pkg --mkinitrd --dracut --update $(rpm -q --queryformat="%{version}-%{release}.%{arch}\n" kernel | tail -n 1)
  6. Reboot your machine:
    reboot
And now you should have working 3D with your nVidia card!
Note that if you have an older card, you may need to install kmod-nvidia-173xx or kmod-nvidia-96xx. There is a list on the nVidia site that says which cards are supported by which driver.
If you need support for the nVidia drivers, check out the nV News "NVIDIA Linux Forum". (Thanks to Exile in Paradise for this tip.)

How do I enable 3D support for my ATI Radeon card in Fedora?

,
RPM Fusion provides ATI driver RPMs that are designed especially for Fedora.
NOTE: If you have nVidia drivers installed, you must un-install them before installing these ATI drivers.
Here's how to install them:
  1. Make sure that you're using my yum configuration from the installing software question.
  2. Open a Terminal.
  3. Become root:
    su -
  4. Install the driver:
    yum install kmod-catalyst
  5. Shut down X:
    init 3
  6. Log in as root.
  7. Enable the driver:
    catalyst-config-display enable
  8. Rebuild your kernel configuration (otherwise it may try to load a conflicting driver during boot) and add some new kernel arguments to work around conflicts between the Catalyst driver and Fedora:
    new-kernel-pkg --kernel-args=nomodeset --mkinitrd --dracut --update $(rpm -q --queryformat="%{version}-%{release}.%{arch}\n" kernel | tail -n 1)
  9. Reboot your machine:
    reboot
If you have any trouble with the RPM Fusion RPMs, please report a bug to the RPM Fusion Bugzilla.

I get a NOKEY warning from RPM, or I get a gpg signature error when using yum!

,
The NOKEY warning is not really a problem. It won't prevent you from doing anything. (The yum error, though, will usually prevent you from installing software.) 

If you'd like to resolve it, do the following command to get the correct key for the site you're downloading from:
You must be root to do any of this.
  • Red Hat and Fedora: 
    rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY*

  • rpm.livna.org: 
    rpm --import http://rpm.livna.org/RPM-LIVNA-GPG-KEY

  • FreshRPMs:
    rpm --import http://freshrpms.net/RPM-GPG-KEY-freshrpms

  • DAG:
    rpm --import http://dag.wieers.com/packages/RPM-GPG-KEY.dag.txt

  • ATrpms:
    rpm --import http://atrpms.net/RPM-GPG-KEY.atrpms

  • NewRPMs:
    rpm --import http://newrpms.sunsite.dk/gpg-pubkey-newrpms.txt

  • Dries (RPMForge):
    rpm --import http://apt.sw.be/dries/RPM-GPG-KEY.dries.txt

  • JPackage:
    rpm --import http://www.jpackage.org/jpackage.asc

  • kde-redhat:
    rpm --import http://kde-redhat.sourceforge.net/gpg-pubkey-ff6382fa-3e1ab2ca

  • PlanetCCRMA:
    rpm --import http://ccrma.stanford.edu/planetccrma/RPM-GPG-KEY.planetccrma.txt
NOTE: If you install my yum configuration, most of these keys are installed for you automatically.

How can I install MS Windows fonts on Fedora 15?

,

This is slightly modified from the instructions found here (and I haven't even checked if they work):
  1. Install the chkfontpath package from ATrpms (Click on either the i686 or x86_64 package, depending on whether you have a 32-bit or 64-bit machine).
  2. As root, install some packages you'll need for the following steps:
    yum install rpm-build cabextract ttmkfdir wget
    
    
  3. Download the MS Core Fonts Smart Package File:
    wget http://corefonts.sourceforge.net/msttcorefonts-2.0-1.spec
    
    
  4. Build the Core Fonts package:
    rpmbuild -ba msttcorefonts-2.0-1.spec
    
    
  5. Install the Core Fonts package:
    yum install --nogpgcheck /root/rpmbuild/RPMS/noarch/msttcorefonts-2.0-1.noarch.rpm

Download latest Linux wireless drivers

,

Download latest Linux wireless drivers

You can now download a package which lets you compile and install the latest advances on the Linux 802.11 and Bluetooth subsystem and get some of our latest drivers without having to recompile your entire kernel. This package adds mac80211, mac80211 drivers, any new FullMAC driver which has had fairly recent updates, and as of the 2.6.33-rc series it also started backporting the Bluetooth subsystem and providing updates to the entire Bluetooth subsystem as well as the drivers on it.

Old kernel support

compat-wireless aims to always support kernel compatibility down to the last supported 2.6 stable kernel release as noted on kernel.org. Today that is the 2.6.24 kernel. Additional kernel compatibility may be done but it should not be something that is expected. Old kernels do not get updates so it is highly recommended you upgrade to at least the latest stable kernel.
compat-wireless is shipped as a bundle for both 802.11 and bluetooth along with their respective drivers. It is however possible for only one specific driver to be compiled along with its requirements. In those cases kernel compatibility may be supported down to older kernels. There used to be a compat-wireless-old, but that is old and should only be used as a reference for curious developers.

Compat-wireless release types

We have two types of compat-wireless releases:
The linux-next releases are based on bleeding edge code which will likely end up being part of the next kernel release. linux-2.6-allstable compat-wireless releases are made based on each new stable kernel release made as well as each new stable RC kernel release.
This page is dedicated to always follow the bleeding edge releases based on linux-next. Refer to the linux-2.6-allstable compat-wireless releases page for more information about those.

Requirements for bleeding edge

You need two things:
  • A Kernel >= 2.6.24
  • Your kernel headers installed
Please be very sure you have your kernel headers installed before reporting any sort of build issues with this package. This usually will mean having this symlink point to a valid directory with kernel headers in it:
/lib/modules/`uname -r`/build
The exception to this is if you are building the package targeting a kernel you are not running. Users doing this should read the Building for external kernels section.
Additionally, the kernel you're building for needs a valid ".config" file, if it isn't present compat will assume you have PCI, USB and PCMCIA built into your kernel and if not, fail building.
We recommend these the following userspace applications to be installed:

Linux wireless version table

The following is the latest release versions for code taken from linux-next.git and on compat-wireless.git. This is updated automatically every day. The version represents the git-describe output.
linux-next.git: <>
compat-wireless.git: <>

Where to download bleeding edge

You can get bleeding edge compat-wireless here:
This package is updated daily. It reflects the latest on linux-next.git tree.

Directly downloading the tarball

We have enabled anti-hotlinking to the compat-wireless-2.6.tar.bz2 tarball. This ensures users directed to this tarball from random tutorials online will hopefully read this page. Anti-hotlinking prevents users from accessing the tarball directly before seeing this page. In summary, you cannot directly download (for example using wget) this tarball before having viewed this introductory page. If you try to do so you will be redirected here. You can, however, directly download a dated version of the tarball, for example compat-wireless-2008-03-25.tar.bz2.
You can find the latest dated tarball in the compat-wireless-2.6 download directory.

Archive of compat-wireless-2.6 tarballs

linuxwireless.org only hosts the latest dated compat-wireless-2.6 tarball but if you would like an older release please check the compat-wireless-2.6 archive, which is hosted by Orbit.

Selecting your driver

Extract:
Extract the content of the package:
tar jxvf compat-wireless-$(date -I).tar.bz2
If you know what driver you want you can use driver-select:
./scripts/driver-select
Selecting your driver can reduce the amount of time to compile compat-wireless. It may also enable kernel compatibility down to older kernels. If you want to restore compat-wireless to enable all drivers again you can use:
./scripts/driver-select restore
If you do not see your driver in the supported list it means care has not been taken to ensure it works with driver-select and you must just build compat-wireless as a whole.

Building and installing

Build:
Build the latest Linux wireless subsystem:
cd compat-wireless-$(date -I)
make

Install:
We use the updates/ directory so your distribution's drivers are left intact. By default depmod will search this directory first, but if you find that it does not then check that your depmod.conf file lists the search order correctly with updates appearing first (before built-in).
sudo make install

Uninstall:
This nukes our changes to updates/ so you can go back to using your distribution's supported drivers.
sudo make uninstall

Unload:
Since you might be replacing your old mac80211 and bluetooth drivers you should first try to unload all existing mac80211 and related drivers. Note also that broadcom, zydas, and atheros devices have old legacy drivers which you need to be sure are removed first. We provide a mechanism to unload all old and legacy drivers first so you should run to be sure:
sudo make unload

Load:
Before loading modules you must first unload your old wireless subsystem modules. Read above how to do this. If you know what module you need you can simply load the module using modprobe. If you simply are not sure you can use, just reboot the box.

Drivers

We tend to carry all new 802.11 drivers or any drivers worth getting updates for. For a list of all current Linux 802.11 drivers see our 802.11 Drivers page.

Known issues

If MadWifi is present the build system will detect this and disable it. It does this by simply renaming ath_pci.ko to ath_pci.ko.ignore. This lets us disable the MadWifi driver without blacklisting it which could cause issues with users later. If you would like to enable MadWifi at a later time and disable ath5k you can run:
sudo athload madwifi
To revert back to ath5k you can run:
sudo athload ath5k

Why was this work done?

It was done for users or developers stuck on older kernels that want to help test or patch wireless work. Additionally if you're on a recent kernel this lets you get the latest and greatest wireless-2.6 git work without much effort. This may mean new drivers for some users. Last but not least we hope this will encourage vendors and developers to post patches upstream first rather than forking or maintaining their own code with their own patches for their own drivers.

Firmware

If your driver needs firmware please be sure to check the driver page for that driver.

What's the difference between compat-wireless-2.6 and John Linville's tree?

This package is based on linux-next.git. John sends 802.11 updates to the linux-next.git tree based on wireless-next-2.6.git . This package then just provides the latest wireless driver updates with some compatibility work on top.

Linux distributions packaging compat-wireless

There are a few Linux distributions using or packaging compat-wireless. Here we document a bit of that information. If you know of more please expand this section.

Getting compat-wireless on Ubuntu

With Ubuntu you have the option of either installing compat-wireless yourself or of installing the package that provides it built by the Ubuntu kernel team. The Ubuntu package that carries compat-wireless is called linux-backport-modules and it has more backported modules than just your wireless subsystem. Its updated whenever major updates are pushed out into the wireless-testing git tree.
 
# For Ubuntu 8.10 Intrepid users:
sudo apt-get install linux-backports-modules-intrepid

# For Ubuntu 9.04 Jaunty users:
sudo apt-get install linux-backports-modules-jaunty

# For Ubuntu 9.10 Karmic users:
sudo apt-get install linux-backports-modules-karmic

# For Ubuntu 10.04 Lucid users (one of the following depending on the installed kernel. 
Most user should choose generic): 
 
sudo apt-get install linux-backports-modules-wireless-lucid-generic
sudo apt-get install linux-backports-modules-wireless-lucid-generic-pae
sudo apt-get install linux-backports-modules-wireless-lucid-preempt
sudo apt-get install linux-backports-modules-wireless-lucid-server

# For Ubuntu 10.10 Maverick users (one of the following depending on the installed kernel.
 Most user should choose generic): 
 
sudo apt-get install linux-backports-modules-compat-wireless-2.6.36-maverick-generic
sudo apt-get install linux-backports-modules-compat-wireless-2.6.36-maverick-generic-pae
sudo apt-get install linux-backports-modules-compat-wireless-2.6.36-maverick-server

Please note that if you are installing linux-backports-modules-karmic and you later decide to install compat-wireless by building it by yourself you are highly encouraged you first remove linux-backports-modules-karmic first otherwise you can run into module dependency conflicts.

Getting compat-wireless on Fedora

This is documented onsgruszka's compat-wireless page

Getting compat-wireless on ChromeOS

ChromeOS integrates releases of compat-wireless into its main releases.

Building for external kernels

If you have a kernel you do not have installed but yet want to build the compat-wireless-2.6 drivers for it you can use this syntax:
make KLIB=/home/mcgrof/kernels/linux-2.6.27.22 \
   KLIB_BUILD=/home/mcgrof/kernels/linux-2.6.27.22

Bugs

If you've found a bug please report it to our linux-wireless mailing list:
linux-wireless@vger.kernel.org
Report the bug because you are working with the latest and greatest. If your bug is compatibility-related then we should still try to fix it within the compatibility layer.

ChangeLog


linux-next ChangeLog

See the wireless-testing ChangeLog to see the list of latest changes to all 802.11 drivers, the 802.11 core and Blueooth. Since this package is based on the linux-next.git latest means patches which John has accepted a couple of days ago.

compat-wireless ChangeLog

See the compat-wireless-2.6 ChangeLog to view changes made necessary in order to keep advancing this package.

License

This work is a subset of the Linux kernel as such we keep the kernel's Copyright practice. Some files have their own copyright and in those cases the license is mentioned in the file. All additional work made to building this package is licensed under the GPLv2.

Hacking compat-wireless

If you'd like to hack on compat-wireless of make your own releases refer to the hacking compat-wireless page.

Administrative

The way compat-wireless releases are made, where they are kept are detailed in the compat-wireless admin page

Linux Wireless drivers

,

Existing Linux Wireless drivers


We currently have a fair number of working drivers that cover most of the available WNICs on the market. However, most don't implement all possible features and many have issues. Hardware by companies not providing complete specifications, free firmware and drivers can be more problematic to support. The switching of chipsets by manufacturers without changing model numbers also makes this list less useful to those purchasing new hardware. Except for a handful of WNICs with free software drivers and free firmware, like e.g. the Penguin 802.11N, most available wireless hardware can not be exhausted when used with Linux. Below is an alphabetically sorted list of existent Linux drivers and their current capabilities.
See also:
NOTE: All drivers can of course run in station mode, but only a few drivers support the other available wireless modes! Support of cfg80211 also offers benefits.
Driver Manufacturer cfg80211 AP IBSS mesh monitor PHY modes Buses
adm8211 ADMtek/Infineon yes no no no ? B PCI
airo Aironet/Cisco no ? ? ? ? B PCI / PCMCIA
at76c50x-usb Atmel yes no no no no B USB
ath5k Atheros yes yes yes yes yes A/B/G PCI / PCI-E / PCMCIA
ath6kl Atheros yes no yes no no A/B/G/N SDIO
ath9k Atheros yes yes yes yes yes A/B/G/N PCI / PCI-E / AHB / PCMCIA
ath9k_htc Atheros yes yes yes no yes B/G/N USB
atmel Atmel no ? ? ? ? B PCI / PCMCIA
b43 Broadcom yes yes yes yes yes A(2)/B/G SSB/PCI/PCI-E/PCMCIA
b43legacy Broadcom yes yes yes yes yes A(2)/B/G PCI/SSB
brcmsmac Broadcom yes no no no no A(1)/B/G/N PCI/AXI
brcmfmac Broadcom yes no no no no A(1)/B/G/N SDIO
carl9170 ZyDAS/Atheros yes yes yes no yes A(1)/B/G/N USB
hostap Intersil/Conexant no ? ? ? ? B PCI / PCMCIA
ipw2100 Intel no no yes no no B PCI
ipw2200 Intel no no (3) yes no no A/B/G PCI
iwl3945 Intel yes no yes no no A/B/G PCI-E
iwlagn Intel yes no yes no no A/B/G/N PCI-E
iwmc3200wifi Intel yes no yes no no A/G SDIO
libertas Marvell no no yes yes (4) no B/G USB / PCMCIA / SDIO / GSPI
libertas_tf Marvell yes yes no yes ? B/G USB
mac80211_hwsim Jouni yes yes yes no yes A/B/G/N NONE!
mwifiex Marvell yes ? ? ? ? A/B/G/N SDIO
mwl8k Marvell yes yes ? ? yes A/B/G/N PCI
orinoco Agere/Intersil/Symbol yes no yes no yes B PCI / PCMCIA / USB
p54pci Intersil/Conexant yes yes yes yes yes A(1)/B/G PCI / PCMCIA
p54spi Conexant/ST-NXP yes yes yes yes yes A(1)/B/G SPI
p54usb Intersil/Conexant yes yes yes yes yes A(1)/B/G USB
*prism2_usb Intersil/Conexant no ? ? ? ? B USB
ray_cs Raytheon no ? ? ? ? pre802.11 PCMCIA
rndis_wlan Broadcom yes no yes no no B/G USB
rt61pci Ralink yes yes yes no yes A(1)/B/G PCI
rt73usb Ralink yes yes yes no yes A(1)/B/G USB
rt2400pci Ralink yes yes yes no yes B PCI
rt2500pci Ralink yes yes yes no yes A(1)/B/G PCI
rt2500usb Ralink yes yes yes no yes A(1)/B/G USB
rt2800pci Ralink yes yes ? ? yes A(1)/B/G/N PCI
rt2800usb Ralink yes ? ? ? yes A(1)/B/G/N USB
rtl8180 Realtek yes no no no ? B/G PCI
rtl8187 Realtek yes no no no yes B/G USB
rtl8192ce Realtek yes ? ? ? ? B/G/N PCI-E
rtl8192de Realtek yes ? ? ? ? B/G/N PCI-E
rtl8192cu Realtek yes ? ? ? ? B/G/N USB
rtl8192se Realtek yes ? ? ? ? B/G/N PCI-E
*r8187se Realtek yes no no no ? B/G PCI-E
*r8192u_usb Realtek no ? ? ? ? B/G/N USB
*r8712u Realtek no ? ? ? ? B/G/N USB
*vt6655 VIA no ? ? ? ? A/B/G PCI
*vt6656 VIA no ? ? ? ? A/B/G USB
*winbond Winbond yes ? ? ? ? B USB
wl1251 Texas Instruments yes no yes ? yes B/G SPI / SDIO
wl1271 Texas Instruments yes yes yes no no A(1)/B/G/N SPI / SDIO
wl3501_cs Z-Com no ? ? ? ? pre802.11 PCMCIA
*wlags49_h2 Lucent/Agere no ? ? ? ? B/G PCI/PCMCIA
zd1201 ZyDAS/Atheros no ? ? ? ? B USB
zd1211rw ZyDAS/Atheros yes yes yes yes yes A(2)/B/G USB

Note: * staging drivers

Out of the tree drivers(Unsupported)


Driver Manufacturer cfg80211 AP IBSS mesh monitor PHY modes Buses
acx1xx Texas Instruments yes ? ? no ? B PCI / PCMCIA / USB
agnx Airgo/Qualcom yes ? ? ? ? A/B/G PCI
ar5523 Atheros ? ? ? ? ? A(2)/B/G USB
ar6k Atheros ? ? ? ? ? B/G ?
poldhu NWN no ? ? ? ? B PCMCIA

Notes:
  1. 802.11a capabilities depend on the actual radio chip used.
  2. 802.11a devices exist, but currently can't be used with this driver, A/B/G devices will work in B/G mode only.
  3. There is support with a special, out-of-tree driver and special firmware, see http://sf.net/projects/ipw2200-ap.
  4. Slightly different mesh implementation than mac80211's, in firmware.

Abandoned/Deprecated Drivers(Unsupported)


Driver
Manufacturer
AP
PHY modes
BUS
Replaced by

ZyDAS/Atheros
yes
no
yes
no
yes
A(1)/B/G/N
USB

Aironet/Cisco
no
?
?
?
?
pre802.11
ISA
-

Atmel
no
no
no
no
no
B
USB

Netwave/Xircom
no
?
?
?
?
pre802.11
PCMCIA
-

ZyDAS/Atheros
no
?
no
no
no
A/B/G/N
USB

Intersil/Conexant
no
?
?
?
?
A/B/G
PCI / PCMCIA

ST/Nokia
yes
no
no
no
no
B/G
SPI

Lucent
no
?
?
?
?
pre802.11
ISA / PCMCIA
-

Deal of the Day

Advertisement here

Advertisement here