Spreadfirefox Affiliate Button
Custom Search
Showing posts with label Networking. Show all posts
Showing posts with label Networking. Show all posts

Monday, February 23, 2009

The Ultimate Linux Network Reference Guide for Newbies

The previous article I wrote was The Ultimate Linux Network Reference Guide for Newbies and many of our readers seem to have liked it. We received many feedbacks on how useful it was specially for the users that are new to the Unix/Linux scene. For this reason, to further spread the knowledge, We’ve put together another guide called The Ultimate Linux Network Reference Guide for Newbies.

The reference should be an easy read and printer friendly. So if you’re just starting out on that Unix admin job or just trying to get around your own Linux install, this guide is for you. Unfortunately as with the first article, I was not able to fit this one into the blog template so I’ve created a separate html file. Please read full article here.

Tuesday, February 17, 2009

Ubuntu Networking Configuration Using Command Line

The basics for any network based on *nix hosts is the Transport Control Protocol/ Internet Protocol (TCP/IP) combination of three protocols. This combination consists of the Internet Protocol (IP),Transport Control Protocol (TCP), and Universal Datagram Protocol (UDP).

By Default most of the users configure their network card during the installation of Ubuntu. You can however, use the ifconfig command at the shell prompt or Ubuntu’s graphical network configuration tools, such as network-admin, to edit your system’s network device information or to add or remove network devices on your system

Configure Network Interface Using Command-Line

You can configure a network interface from the command line using the networking utilities. You configure your network client hosts with the command line by using commands to change your current settings or by editing a number of system files.

Configuring DHCP address for your network card

If you want to configure DHCP address you need to edit the /etc/network/interfaces and you need to enter the following lines replace eth0 with your network interface card

sudo vi /etc/network/interfaces

# The primary network interface - use DHCP to find our address
auto eth0
iface eth0 inet dhcp

Configuring Static IP address for your network card

If you want to configure Static IP address you need to edit the /etc/network/interfaces and you need to enter the following lines replace eth0 with your network interface card

sudo vi /etc/network/interfaces

# The primary network interface
auto eth0
iface eth0 inet static
address 192.168.3.90
gateway 192.168.3.1
netmask 255.255.255.0
network 192.168.3.0
broadcast 192.168.3.255

After entering all the details you need to restart networking services using the following command

sudo /etc/init.d/networking restart

Setting up Second IP address or Virtual IP address in Ubuntu

If you are a server system administrator or normal user some time you need to assign a second ipaddress to your Ubuntu machine.For this you need to edit the /etc/network/interfaces file and you need to add the following syntax.Below one is the only example you need to chnage according to your ip address settings

sudo vi /etc/network/interfaces

auto eth0:1
iface eth0:1 inet static
address 192.168.1.60
netmask 255.255.255.0
network x.x.x.x
broadcast x.x.x.x
gateway x.x.x.x

You need to enter all the details like address,netmask,network,broadcast and gateways values after entering all the values save this file and you need to restart networking services in debian using the following command to take effect of our new ipaddress.

After entering all the details you need to restart networking services using the following command

sudo /etc/init.d/networking restart

Setting your ubuntu stytem hostname

Setting up your hostname upon a ubuntu installation is very straightforward. You can directly query, or set, the hostname with the hostname command.

As an user you can see your current hostname with

sudo /bin/hostname

Example

To set the hostname directly you can become root and run

sudo /bin/hostname newname

When your system boots it will automatically read the hostname from the file /etc/hostname

If you want to know more about how to setup host name check here

Setting up DNS

When it comes to DNS setup Ubuntu doesn’t differ from other distributions. You can add hostname and IP addresses to the file /etc/hosts for static lookups.

To cause your machine to consult with a particular server for name lookups you simply add their addresses to /etc/resolv.conf.

For example a machine which should perform lookups from the DNS server at IP address 192.168.3.2 would have a resolv.conf file looking like this

sudo vi /etc/resolv.conf

enter the following details

search test.com
nameserver 192.168.3.2

Taken from : http://www.ubuntugeek.com

Sunday, February 15, 2009

VirtualBox Host-Guest Interface Networking (Generic)

This way is a bit harder, but it allows you to see the VirtualMachine as a "real" computer on your local network.

1. Create a new bridge with this command:
# brctl addbr br0

2. If you are not using DHCP, run ifconfig and note down the network configuration of your existing network interface (e.g. eth0), which we will need to copy to the bridge in a minute.

(Note: You will need this settings so make sure you don't lose them!!!)

3. Switch your physical network adapter to "promiscuous" mode so that it will accept Ethernet frames for MAC addresses other than its own (replace eth0 with your network interface):

# ifconfig eth0 0.0.0.0 promisc

(Note: You will lose network connectivity on eth0 at this point.)

4. Add your network adapter to the bridge:

# brctl addif br0 eth0

5. Transfer the network configuration previously used with your physical ethernet adapter to the new bridge. If you are using DHCP, this should work:

# dhclient br0

Note:

Use "dhcpcd -t 30 -h yourhostname br0 &" instead of the above

Otherwise, run ifconfig br0 x.x.x.x netmask x.x.x.x and use the values that you noted down previously.

6. To create a permanent host interface called vbox0 (all host interfaces created in this way must be called vbox followed by a number) and add it to the network bridge created above, use the following command:

VBoxAddIF vbox0 vboxuser br0

Replace vboxuser with the name of the user who is supposed to be able to use the new interface.

(Note: VboxAddIF is located in /opt/VirtualBox-VERSION OF VIRTUALBOX/VBoxAddIF)

Alternatively, you can setup VirtualBox networking through your /etc/rc.conf to enable a bridged connection.

Friday, February 13, 2009

WICD Network Manager

Wicd is an open source wired and wireless network manager for Linux which aims to provide a simple interface to connect to networks with a wide variety of settings.

Some of Wicd's features include:

  1. No Gnome dependencies (although it does require GTK), so it is easy to use in XFCE, Fluxbox, Openbox, Enlightenment, etc.
  2. Ability to connect to wired and wireless networks
  3. Profiles for each wireless network and wired network
  4. Many encryption schemes, some of which include WEP/WPA/WPA2
  5. Remains compatible with wireless-tools
  6. Tray icon showing network activity and signal strength

If you are using Ubuntu Jaunty (not currently released), Wicd is in the universe repository.

Installing Wicd in Ubuntu is very simple. You just have to add the Wicd repository to the Ubuntu package manager. To open the package manager in Gnome, go to Administration > Synaptic Package Manager. When it appears, go to Settings > Repositories > Third Party Software > Add..., and enter the following line:

deb http://apt.wicd.net hardy extras
where gutsy is your version of Ubuntu in lowercase (dapper, edgy, feisty, gutsy, hardy, intrepid). You'll also need to add the key used for signing Wicd by running the following command in a terminal:
wget -q http://apt.wicd.net/wicd.gpg -O- | sudo apt-key add -
Now, click Reload, and wait while the package lists are downloaded. Now, search for "Wicd", and right click on it. Select Install, then press Apply, and Wicd will automatically be downloaded and installed for you. This will also keep you automatically up to date with the latest and greatest version of Wicd. Please note that this will remove network-manager, which is the default GNOME network manager and may cause loss of network connection temporarily.

TROUBLESHOOTING

If Wicd fails to connect after you install it, make sure that the only entry in your /etc/network/interfaces file is
auto lo
iface lo inet loopback
You can change the contents of this file by pressing alt + f2, then typing
gksudo gedit /etc/network/interfaces
if you are using Gnome, or replace gedit with kate if you are using KDE. This will allow you to view and edit the /etc/network/interfaces.You can ignore lines that start with #.

STARTTING WICD

If you are using a desktop environment without a notification area, you can run the Wicd GUI by running

wicd-client -n
If you are using a desktop environment with a notification area, you can start the tray icon by running
wicd-client
If you are using a desktop environment such as GNOME or KDE, you can start the Wicd GUI by opening the Application

Friday, January 30, 2009

Wifi WEP Cracking Using Intel PRO/Wireless 3945ABG

Crack WEP with Intel PRO/Wireless 3945ABG is a task that can employ you for a long time. The Intel PRO/Wireless 3945ABG network adapter driver that comes from the manufacturer does not provide packet injection and network monitoring capabilities which are needed to crack WEP, and therefore before you attempt WEP cracking efforts, you have to update your driver first which can be a daunting task.