LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Password
Solaris / OpenSolaris This forum is for the discussion of Solaris and OpenSolaris.
General Sun, SunOS and Sparc related questions also go here.

Notices

Reply
 
LinkBack Search this Thread
Old 04-21-2004, 10:09 AM   #1
davepal
LQ Newbie
 
Registered: Mar 2004
Location: Charlotte
Posts: 17

Rep: Reputation: 0
DHCP to static IP in Solaris ???


Morning all,

I currently have DHCP running on my Solaris 9 box. I realized that I need static IP for an application that I plan to run on the network. How do I revert back ?

Any suggestions ?

Thanks
Dave
 
Old 04-21-2004, 03:55 PM   #2
trickykid
Guru
 
Registered: Jan 2001
Posts: 24,133

Rep: Reputation: 194Reputation: 194
The easiest way is to do this:

As root

sys-unconfig

it will reboot and ask you to re-enter networking information.

There you can tell it to use a static and not DHCP, etc.
 
Old 04-21-2004, 08:26 PM   #3
TanGU
LQ Newbie
 
Registered: Apr 2004
Posts: 7

Rep: Reputation: 0
Re: DHCP to static IP in Solaris ???

Quote:
Originally posted by davepal
Morning all,

I currently have DHCP running on my Solaris 9 box. I realized that I need static IP for an application that I plan to run on the network. How do I revert back ?

Any suggestions ?

Thanks
Dave
Personnaly, i did have the same problem, i just did a :

ifconfig hme0 plumb (do a ifconfig -a to see if it is hme0 or anything else)
ifconfig hme0 192.168.1.2 netmasks 255.255.255.0 up (replace the 192 by your own ip)
echo "192.168.1.100" > /etc/defaultrouter (your router)
echo "192.168.1.0 255.255.255.0" > /etc/netmasks

edit /etc/nsswitch.conf and check if you have the word "dns" after the line "host:"

Remove the file: /etc/dhcp.hme0

everything should be okay when you'll reboot, you can put your IP and host in /etc/hosts and your hostname in: /etc/hostname.hme0
 
Old 04-22-2004, 05:05 AM   #4
FragInHell
Member
 
Registered: Sep 2003
Location: Sydney Australia
Distribution: Redhat, Centos, Ubuntu
Posts: 282

Rep: Reputation: 45
if you have access to the DHCP server, you could assign that machine a permanent IP, it bind its to the machine using the mac address.
 
Old 04-24-2004, 08:07 PM   #5
paulsm4
Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
In contemporary (Solaris 8/Solaris 9) days, "sys-unconfig" is the correct answer ;-)
 
Old 04-26-2004, 09:23 AM   #6
nonamenobody
Member
 
Registered: Oct 2002
Posts: 138

Rep: Reputation: 22
>> In contemporary (Solaris 8/Solaris 9) days, "sys-unconfig" is the correct answer ;-)

I recently installed Solaris 9 and none of the howtos I found mentioned "sys-unconfig". I will have to try it some time.
 
Old 04-26-2004, 11:15 AM   #7
paulsm4
Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
One caveat - "sys_unconfig" isn't available on diskless clients
 
Old 04-30-2004, 11:06 AM   #8
davepal
LQ Newbie
 
Registered: Mar 2004
Location: Charlotte
Posts: 17

Original Poster
Rep: Reputation: 0
Thanks everybody for their replies.

I knew sys-unconfig works, even Redhat has sys-unconfig. But I prefer knowing files that get affected. So special thanks to TanGU and FragInHell.

Thanks again,
Dave
 
  


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
From DHCP to static IP. dave`2005 Slackware 3 08-22-2005 09:12 AM
Using DHCP with a static IP ninmonkeys Linux - Networking 9 11-30-2004 07:32 AM
FC2 Overriding static if in favor of dhcp system set for static pkraus109 Linux - Networking 8 09-21-2004 11:13 AM
DHCP to static IP ?? davepal Linux - Networking 1 04-21-2004 09:34 AM
DHCP or Static Culbert Linux - Networking 1 03-14-2003 07:42 PM


All times are GMT -5. The time now is 01:07 AM.

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 Google+: linuxquestions
Open Source Consulting | Domain Registration