25 September, 2010

How to assign an IP address in Ubuntu using command line

Computers may be assiged a static IP address or assigned one dynamically. Typically servers and institutions will use a static IP which will not change each time u get connected. Workstation will use Dynamic Host Configuration Protocol (DHCP) for IP address assignment. It is more easily to find a system if the IP address does not change and is static.


Use the Command Line:

    /sbin/ifconfig eth0 192.168.10.12 netmask 255.255.255.0 broadcast 192.168.10.255                  
 
The ifconfig command does NOT store this information permanently. Upon reboot this information is lost. Manually add the network configuration to /etc/network/interfaces  as shown in my next post .
Read rest of entry

IP Configuration in Ubuntu

Here is a howto about the configuring ip using networking related files in Ubuntu / Debian systems.

File: /etc/network/interfaces
    This file contains network interface configuration information  for the ifup and ifdown commands. This is where you configure how your system is connected to the network.

Three important Interfaces are:
        # lo: Loopback interface (it is an internal 
            networking mechanism. It is used to
            test applications...)
        # eth0: First ethernet interface card
        # wlan0: First wireless network interface


Use following command to edit the interfaces file

$ sudo gedit /etc/network/interfaces

Add one or more of the stanzas below 

    Static IP example:
    auto lo
    iface lo inet loopback

    auto eth0
    iface eth0 inet static
            address 208.88.34.106
            netmask 255.255.255.248
            broadcast 208.88.34.111
            network 208.88.34.104
            gateway 208.88.34.110
                   

    Dynamic IP (DHCP) example:
    auto lo
    iface lo inet loopback

    auto eth0
    iface eth0 inet dhcp

    auto eth1
    iface eth1 inet dhcp

    auto eth2
    iface eth2 inet dhcp

    auto ath0
    iface ath0 inet dhcp

    auto wlan0
    iface wlan0 inet dhcp
                   
    Lines  beginning with the word "auto" in the interfaces file are used to identify the physical interfaces to be brought up when ifup is run with the -a option.  (This option  is  used by the system boot scripts.)  Physical interface names should follow the word "auto" on the same line.

GUI Network Tools:

    * NetworkManager or wicd can be used as the GUI tools for the network management. Better use wicd network manager if you have to rely more upon the wireless internet than the wired ones
.
Read rest of entry

26 April, 2010

Make your keyboard blinking to represent network traffic using tleds in Ubuntu

tleds is debian based appliation that is used to indicate the netwotk traffic using your keyboard LEDs. As you know the led lights in the keyboard for indicating scroll lock, numlock have no other purpose other than just glowing to indicate this features are active. These remain off during most of the time.

So let's use these LED's to indicate the network traffic of your system. You can make them blinking when you send/recieve packets into network or internet.
This can be done by just downloading a small package called tleds.

Installing tleds


Take the terminal and type in as follows

    sudo apt-get install tleds

configuring

You have to show,  for which connection these LEDs should blink. You will issue the command ifconfig in the terminal to see the name of active connection. The commandline is
   
        sudo tleds wlan0   -- represents the wireless connection

        sudo tleds ppp0     -- represents the point to point connection (eth0,    
                                                                                 mobile broadband )

also you can issue command below for further control

        sudo tleds ppp0 -d 100
100 represents the delay between the blinking in microseconds. This delay represents the blinking speed. You can also issue command like this.  Here the default delay 200ms will be used.

That's all. Take your browser and search for something... See the lights in your keyboard blinking..
   
       
Read rest of entry

24 April, 2010

How to connect Windows XP to Ubuntu over LAN cable

                 This post is all about connecting Ubuntu and Windows system using a LAN cable for sharing data between them . . . A LAN cable is a preferable mechanism for sharing files in a good speed in the range of Mbps.

Connection requirements :
        LAN cable
        Ubuntu linux with Samba (or any other file sharing application)
        Windows machine

Connect LAN cable to both of the systems. On connecting both the Windows and Ubuntu try to connect automatically between each other.

Now follow the steps below... 

Configuring the Linux system


1.  Right click on the Network manager icon on the top sidebar. Select 
     "Edit  connections".

2.  Under the "wired" tab on the pop up Network connections window choose the
     "add" button to add a new connection.

3.  Make changes in the opened window as in figure

        # specify the connection name as u like. I call it "Ubuntu XP network"
        # Check the connect automatically box enabled
        # Click on the IPv4 settings
            * Click on the methode field and choose "Manual"
            * Click below the address feild and enter an arbitray ip say, 
               192.100.100.1                   ....you can choose it your own
            * Add 255.255.255.0 in the Netmask (no options for you, enter it as if)
        # click on the apply button to make the changes available.



4. That's all you need to do in Ubuntu machine.


Configuring the Windows system

1.  Open the Network Connections folder from Start ---> Network Connections

2.  Right click on the connection with the name "Local Area Connection" and 
     click on the properties


3.  Under the general tab select Internet Protocol(TCP/IP) and click 
     "properties"


4.  Choose 'Use the following IP address' and enter
        IP Address  :  192.100.100.3
        Subnet Mask :  255.255.255.0




5.  Press the OK button to complete the configuring.

            Thats all about configuration. Now restart the connection from the Ubuntu system using network manager (No need to pull out the cable physically)
Inorder to share a particular file from windows, right click on the file and select properties.In the properties window check the corresponding
feilds related to sharing under the "sharing" tab.

To access those files from Ubuntu system, goto Places ---> Network ---> Windows network
Read rest of entry

23 April, 2010

How to connect Airtel GPRS in Ubuntu linux

The gprs internet is a good option when you are looking for an affordable internet connection and limited budget...

You dont need to think about the wires... (coz it probably makes you weired). Here check out how airtel's gprs can be accessed in your desktop or laptop


Follow the steps to connect.


1. Connect the phone using the data cable to the computer. Choose the COM port
    mode or phone mode in your phone. In Nokia it is called 'nokia mode'


2. On selecting the phone mode the 'New Mobile Broadband wizard begins 
    automatically. If the wizard does not pops up automatically, right click on the
    network manager icon on the top of the task bar. Then choose edit connection. 
    Click on the add button. The window will appear as follows..


       


3. Select the Airtel from the list.






4. Write click on the network manager icon on the top bar and slect the 'edit 
    connections'. Select the 'Mobile Internet' tab and click on the edit button
    after selecting the Airtel from the list.




5. On the IPv4 settings tab change the dns entry as follows...
  
        DNS : 8.8.8.8,8.8.4.4


    These are public dns addresses by google and may give better performance in
    case of of speed.






6. Click on the network manager icon on the top panel and select Aircel to dial 
    the connection.


Repeat the step 6 whenever you need to connect using the same connection, after connecting the mobile phone/usb modem to the system....
Read rest of entry

How to connect Aircel GPRS in Ubuntu Linux

Older versions of the Ubuntu linux has very less support for USB modems. This was the major problem that prevents you from connecting the mobile broadband internet facility provided by means of gprs.Linux versions were back in automatically detecting the USB modems in the mobile phones… But the new 9.04 version of Ubuntu linux (some previous versions also ) comes up with many facilities to overcome this problems…

Let me get into the matter… Here i am sharing my experiences when i tried to connect Aircel gprs using my Nokia 5200… the following procedures may be applicable to almost all java based phones.

Inorder to connect aircel gprs in your computer, first connect your phone to the computer through the data cable and select the nokia mode. Then the Network manager in Ubuntu will automatically detect the presence of phone. It will automatically starts a Mobile broadband configuration wizard…

Go through the pictures to get the step by step procedure..



One of the problems that I faced while the connection process is the list of mobile broadband ISPs provided did not contain Aircel. No problem!!! select the Airtel from the list, so that u can edit the connection later. Also the number that we have to dial in Aircel and Airtel are almost the same.


After the wizard completes right click on the network manager icon on the top panel and perform as shown in the pictures below..

Select the ‘edit connections'



Choose the Mobile broadband tab and select the ‘Airtel’ and click on the edit button



Change the following ….

Connection name : Aircel

Number : *99#

APN  : aircelgprs      (in lower case)

Leave the remaining spaces untouched and click ‘apply’

Click on the IPv4 Settings tab and enter the value in the DNS field as in figure.

      8.8.8.8, 8.8.4.4  

Each are primary and secondary dns addresses respectively seperated by the a comma. Please  remember we have started from configuration of airtel. So the dns addresses are also belonging to airtel. Here in this step we replace this with google's  public dns. Read more about dns on 
http://1024bitez.blogspot.com/2010/04/something-about-domain-name-servers.html



 
Click on the network manager icon on the top panel and select Aircel to dial the connection.


Then the icon of the Network manager will show that the connection is active soon. If you put your mouse over the icon u get a pop up  ” Mobile broadband connection ‘Aircel’ active”


That's all about the connecting Aircel in the Ubuntu linux, enjoy the power of mobile internet.

Read rest of entry
 

Terminal Diary | techblog Copyright © 2009 Gadget Blog is Designed by jintu jacob Powered by Blogger