LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
LinkBack Search this Thread
Old 02-24-2009, 10:07 AM   #1
Russ
LQ Newbie
 
Registered: Dec 2004
Posts: 19

Rep: Reputation: 0
Static IP address in Ubuntu


I am running the desktop version of U8.10 for a server of sorts. I need it to have a static IP and not under the control of Networking. This is so I can use vsftp, ssh and tftp. Any input would be helpful. Thanks in advance.

Russ
 
Old 02-25-2009, 03:02 AM   #2
frieza
Senior Member
 
Registered: Feb 2002
Location: harvard, il
Distribution: Ubuntu 11.4,DD-WRT micro plus ssh,lfs-6.6,Fedora 15,Fedora 16
Posts: 2,612

Rep: Reputation: 228Reputation: 228Reputation: 228
you would need to edit the file /etc/network/interfaces
an example would be as follows
Code:
# 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 eth0
iface lo inet loopback

# The primary network interface
iface eth0 inet static
	address 192.168.1.21
	netmask 255.255.255.0
	broadcast 192.168.1.255
	network 192.168.1.0
	gateway 192.168.1.1

Last edited by frieza; 02-25-2009 at 03:03 AM.
 
Old 02-28-2009, 09:41 PM   #3
Russ
LQ Newbie
 
Registered: Dec 2004
Posts: 19

Original Poster
Rep: Reputation: 0
That worked, thank you. I just have to remember to re-select "wired network" after every re-boot.

Thanks again,

Russ
 
Old 03-01-2009, 07:27 AM   #4
tredegar
Guru
 
Registered: May 2003
Location: London, UK
Distribution: Ubuntu 10.04, mostly
Posts: 5,995

Rep: Reputation: 354Reputation: 354Reputation: 354Reputation: 354
Quote:
I just have to remember to re-select "wired network" after every re-boot.
If you add the line
Code:
auto eth0
to the interfaces file, it'll be brought up at boot.
See man interfaces for the full story
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Set IP address to static from DHCP assigned address jborn Linux - Networking 4 02-02-2007 08:38 PM
[SOLVED] Converting static IP-address to dynamic IP-address Blue_Ice Linux - Networking 3 07-20-2006 03:35 AM
Static IP address mikz Slackware 4 11-28-2005 04:30 PM
Getting static IP address etc. chapzilla Linux - Newbie 2 06-16-2003 11:40 AM
Static IP Address bytebrowser Linux - Networking 14 06-16-2003 06:36 AM


All times are GMT -5. The time now is 01:22 PM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration