The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Advanced & Expert Users
.
google unix.com



UNIX for Advanced & Expert Users Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Dhcp rkap SUN Solaris 1 08-03-2005 01:24 PM
Dhcp NJay UNIX for Dummies Questions & Answers 2 06-29-2004 08:37 AM
DHCP and DNS meyersp IP Networking 3 11-21-2003 05:02 PM
Dhcp aojmoj UNIX for Dummies Questions & Answers 6 09-23-2002 01:03 PM
Dhcp jdevarie IP Networking 1 07-11-2001 12:29 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 07-30-2003
alex blanco alex blanco is offline
Registered User
  
 

Join Date: Jun 2001
Location: Mexico city
Posts: 36
Angry Dhcp

Hi you all. I'm trying to enable DHCP in a Sun Utra 5 runing Solaris 8 but during the boot process it sends me the message : "Device not in appropiate status"

Do anyone have enabled DHCP on solaris 8?
Any Procedure?

The DHCP server is an NT I guess.
  #2 (permalink)  
Old 07-31-2003
RTM's Avatar
RTM RTM is offline Forum Advisor  
Hog Hunter
  
 

Join Date: Apr 2002
Location: On my motorcycle
Posts: 3,039
The procedure as found on SunSolve:
Quote:
************************************************************************
DHCP Client Setup
************************************************************************

1. Create two empty file /etc/hostname.xxx and /etc/dhcp.xxx for each
interface, where xxx is interface name, like le0, hme0. For more
than one interfaces you can create both files for each interface.
In this example I am creating le0 and le0:1 (virtual interface).

client# touch /etc/hostname.le0 /etc/hostname.le0:1
client# touch /etc/dhcp.le0 /etc/dhcp.le0:1

client#ls -l /etc/*.le*
-rw-r--r-- 1 root root 9 Mar 18 1997 /etc/hostname.le0
-rw-r--r-- 1 root other 11 Oct 23 11:33 /etc/hostname.le0:1

client# ls -l /etc/dhcp.*
-rw-r--r-- 1 root root 0 Oct 24 09:11 /etc/dhcp.le0
-rw-r--r-- 1 root other 0 Oct 27 09:11 /etc/dhcp.le0:1
client-1#

2. After creating these files you can setup you can reboot the machine
or you can use ifconfig command to configure the interface.

client# ifconfig le0 dhcp start
client#
client-1# ifconfig -a

lo0: flags=849<UP,LOOPBACK,RUNNING,MULTICAST> mtu 8232
inet 127.0.0.1 netmask ff000000
le0: flags=4843<UP,BROADCAST,RUNNING,MULTICAST,DHCP> mtu 1500
inet 129.145.71.1 netmask ffffff00 broadcast 129.145.71.255
ether 8:0:20:7d:5f:a2
client-1# ifconfig le0:1 dhcp start
client-1# ifconfig -a

lo0: flags=849<UP,LOOPBACK,RUNNING,MULTICAST> mtu 8232
inet 127.0.0.1 netmask ff000000
le0: flags=4843<UP,BROADCAST,RUNNING,MULTICAST,DHCP> mtu 1500
inet 129.145.71.1 netmask ffffff00 broadcast 129.145.71.255
ether 8:0:20:7d:5f:a2
le0:1: flags=4843<UP,BROADCAST,RUNNING,MULTICAST,DHCP> mtu 1500
inet 129.145.71.2 netmask ffffff00 broadcast 129.145.71.255

3. Release an interface.

client-1# ifconfig le0:1 dhcp release
client-1# ifconfig -a

lo0: flags=849<UP,LOOPBACK,RUNNING,MULTICAST> mtu 8232
inet 127.0.0.1 netmask ff000000
le0: flags=4843<UP,BROADCAST,RUNNING,MULTICAST,DHCP> mtu 1500
inet 129.145.71.1 netmask ffffff00 broadcast 129.145.71.255
ether 8:0:20:7d:5f:a2
le0:1: flags=842<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 0.0.0.0 netmask 0
you can bring that interface back up again as:

client-1# ifconfig le0:1 dhcp start

To get status on any dhcp interface:

client-1# ifconfig le0 dhcp status

Interface Status Sent Received Rejects
le0 BOUND 1 1 0
(Began,expires,Renew) =(10/28/1997 22:05,10/30/1997 10:05, 10/29/1997 16:05)

There are other commands with ifconfig command that you can use:

/usr/sbin/ifconfig interface { auto-dhcp | dhcp }
[ primary ] [ wait seconds ]
drop | extend | ping | release | start | status


Also refer to ifconfig man pages.

client-1#
client-1# cat /etc/hosts
129.145.71.1 client-1 # Added by DHCP
client-1#
client-1#
client-1# cat /etc/nsswitch.conf
#
# /etc/nsswitch.files:
#
# An example file that could be copied over to /etc/nsswitch.conf; it
# does not use any naming service.
#
# "hosts:" and "services:" in this file are used only if the
# /etc/netconfig file has a "-" for nametoaddr_libs of "inet" transports.

passwd: files
group: files
#hosts: files # Commented out by DHCP
#hosts: files # Added by DHCP # Commented out by DHCP
hosts: files # Added by DHCP dns # Added by DHCP
networks: files
protocols: files
rpc: files
ethers: files
netmasks: files
bootparams: files
publickey: files
# At present there isn't a 'files' backend for netgroup; the system will
# figure it out pretty quickly, and won't use netgroups at all.
netgroup: files
automount: files
aliases: files
services: files
sendmailvars: files
#

I have used this to set up Ultra 10 systems in the past with no problems.

You might also want to look at Solaris DHCP Admin guide
  #3 (permalink)  
Old 08-04-2003
pressy's Avatar
pressy pressy is offline Forum Staff  
solaris cultist
  
 

Join Date: Aug 2003
Location: Vienna / Austria (Europe) [EARTH]
Posts: 726
Setting up a DHCP client on Solaris
Introduction :
If you are trying to set up DHCP on a Solaris box, this could be just what you're looking for! For example, if you're trying to get your Sun workstation (or PC running Solaris x86) to talk to your cable modem, but your hostname gets set to "unknown", this document will tell you how to get round that.

Throughout this page, I'll assume that you're using le0 for your DHCP connection. Substitute hme0 (or whatever interface you do use) in the examples below.

Setting up a DHCP client
There are two ways of using DHCP:

DHCP has limited control
DHCP has full control

The first case may be where you want to set your own /etc/resolv.conf and so on, with a minimum of hassle.

The second case would be the normal situation, especially if your cable modem provider has a habit of changing DNS name server IP addresses on you (like mine does!), so I'll concentrate on that here. You'll need to change the DEFAULT_ADDR and INTERFACE variables as required.

The first thing to do is to create an empty /etc/hostname.le0; I use touch:

# touch /etc/hostname.le0
Another way of creating the file is to simply say:
# > /etc/hostname.le0
The latter method will work even if /etc/hostname.le0 already exists on your system. Creating this file ensures that the interface gets plumbed, ready for the DHCP software to do its stuff.
Next, you create /etc/dhcp.le0. This file can be empty if you want to accept the defaults, but may also contain one or both of these directives:

wait time, and
primary

By default, ifconfig will wait 30 seconds for the DHCP server to respond (after which time, the boot will continue, while the interface gets configured in the background). Specifying the wait directive tells ifconfig not to return until the DHCP has responded. time can be set to the special value of forever, with obvious meaning. I use a time value of 300, which seems to be long enough for my cable provider.

The primary directive indicates to ifconfig that the current interface is the primary one, if you have more than one interface under DHCP control. If you only have one interface under DHCP control, then it is automatically the primary one, so primary is redundant (although it's permissible).

With these files in place, subsequent reboots will place le0 under DHCP control: you're ready to play!

Actually, there's one snag: most (if not all) cable modem DHCP servers don't provide you with a hostname (even if they did, odds are it won't be one you want anyway!). This wouldn't be a problem, except that the boot scripts (/etc/init.d/rootusr in particular) try to be clever, and set your hostname to "unknown" in this case, which is not at all useful!

The trick is to change your hostname back to the right one, preferably without changing any of the supplied start up scripts, which are liable to be being stomped on when you upgrade or install a patch. You've also got to do it early enough in the boot process, so that rpcbind, sendmail and friends don't get confused by using the wrong hostname. I put this little script in to /etc/init.d/set_hostname, with a symbolic link to it from /etc/rc2.d/S70set_hostname to solve this problem.

With these modifications in place, reboot, and you'll be using your cable modem in no time!

so long...
greetings Preßy
Sponsored Links
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 06:22 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0