LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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
  Search this Thread
Old 06-28-2005, 11:55 AM   #1
taylortbb
LQ Newbie
 
Registered: Oct 2003
Distribution: Mandrake
Posts: 21

Rep: Reputation: 15
Exclamation Static IP Address with DHCP server control


Hello, I am attempting to configure a Linux server (Mandriva 2005LE) with a static IP address however I do not control the DHCP server for the network it will be on. What I'm looking to do is have the computer make a DHCP request and use the information it provides, except replacing the IP address the DHCP server specifies with one of my choice. The same as the "DHCP with Static IP" option in Mac OS X, if you are familiar with Macs.

I have tried adding the IPADDR speciification to /etc/sysconfig/network-scripts but that doesn't work. Using ifconfig changes my IP but I become un-accesable ver the network. The procedure is possible on our network as for we have two OS X servers working this way.
 
Old 06-28-2005, 01:43 PM   #2
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 79
I'm not sure there is a way to do this with any default network initiation scripts but all you really need to do is call:
dhclient eth0
ifconfig eth0 ip.addr.goes.here

You may also need to supply the correct netmask in the ifconfig command. Make sure that the IP address you use is outwith the dhcp range though.
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I disable DHCP now I am using static address? rosco136 Linux - Networking 4 08-01-2005 02:53 AM
I want static IP, but have to use DHCP (preffered/desired address) homa2001 Linux - Networking 13 02-10-2005 01:47 AM
Eth0 set up for Static, obtaining DHCP address?! IndustrialGeek Linux - Networking 2 01-03-2005 12:39 AM
computer switches from static to dhcp address (automagically?) cyberpuerka Linux - Networking 1 09-03-2004 11:29 AM
Static address works but DHCP doesn't... devahl Linux - Networking 1 05-03-2004 04:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:31 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration