Wired ethernet not getting detected in Ubuntu

Recently I installed Ubuntu on my Desktop. But I met with a difficulty after the installation, my ethernet card is not getting detected.

I searched the repositories and I didn’t get far with that.

Then I searched this in Ubuntu forums, and found a thread similar to my issue.

A solution mentioned there was to install compat-wireless package and enable the module in the kernel.

I downloaded the package from http://linuxwireless.org/download/ and compiled it.

sudo apt-get update
tar -xjvf compat-wireless-x.x.tar.bz2
cd compat-wireless*
scripts/driver-select atl1c
make
sudo make install
sudo modprobe atl1c

and rebooted the machine. Voila!!!!! it worked and was able to connect to the internet.