Was this page helpful?

Assign Static IP to Ubuntu Installation

    Table of contents
    1. 1. Overview
    2. 2. Goal
      1. 2.1. Assigning a Static IP
    3. 3. What's Next
    4. 4. Related

    Overview

    Applying a static IP to the Ubuntu install will make sure that when you shutdown and restart the server it has the same IP address.

    Goal

    After completing this tutorial you will have a static IP applied to your Ubuntu server

    Assigning a Static IP

    Login to your MindTouch server via SSH and type out the following command:

    nano /etc/network/interfaces

    After you type in the above command hit Enter and you will be presented with the following screen:

    # This file describes the network interfaces available on your system
    # and how to activate them. For more information, see interfaces(5).
    
    # The loopback network interface
    auto lo
    iface lo inet loopback
    
    # The primary network interface
    auto eth0
    allow-hotplug eth0
    iface eth0 inet dhcp

    Type out your network settings so that it matches the following format (Note: your network settings will vary then the example):

    # The loopback network interface
    auto lo
    iface lo inet loopback
    
    # The primary network interface
    auto eth0
    iface eth0 inet static
    address 192.168.1.90
    gateway 192.168.1.1
    netmask 255.255.255.0

     *Note: address is the Static IP address that you want to assign the MindTouch

    Tips:

    • Make sure you ping the static IP before you assign it to MindTouch to ensure that it isn't being used by another device
    • On XP the way to find out your network settings is go to Start->Run->type cmd and hit enter ->type ipconfig /all

    Once you have verified that your settings are accurate then exit out of the editor by hitting CTRL X on your keyboard

    You will be prompted to save the file to do so type Y

    Hit Enter at the screen below and your changes will be applied to the file

    After you have saved restart your networking by typing the following
     

    /etc/init.d/networking restart

    Once you have restarted networking type ifconfig and verify that your static IP has been assigned to one of the network connections

     

    What's Next

    Once you have a static IP assigned to can set internal or external static routes so that domains will resolve to the IP address.  

    Was this page helpful?
    Tag page
    You must login to post a comment.

    Copyright © 2011 MindTouch, Inc. Powered by