Networking Forums

Networking Forums > Computer Networking > Linux Networking > dhcpcd

Reply
 
 
Matthew Paterson
Guest
Posts: n/a

 
      10-29-2003, 04:12 PM
Hi

How am I able to get dhcpcd to start automatically every time I boot? As
it is just now I have to type 'dhcpcd' as root to get access to the net
through my adsl router.

Is it something to do with '/etc/dhcp*' files?

Thanks

--
Matt

Fear of a flat planet
 
Reply With Quote
 
 
 
 
Bit Twister
Guest
Posts: n/a

 
      10-29-2003, 04:20 PM
On Wed, 29 Oct 2003 17:12:52 +0000, Matthew Paterson wrote:
> Hi
>
> How am I able to get dhcpcd to start automatically every time I boot? As
> it is just now I have to type 'dhcpcd' as root to get access to the net
> through my adsl router.
>
> Is it something to do with '/etc/dhcp*' files?


For me on Mandrake distro's I set BOOTPROTO=dhcp in
/etc/sysconfig/network-scripts/ifcfg-eth0

Please read
http://www.catb.org/~esr/faqs/smart-questions.html

It always helps if you provide some basic system information and what
you are having problems with when you post questions to the
news groups.

That info helps us to provide better examples/responses.

Which window manager/desktop environment,
they have different icons and file access locations.

There are several "linuxes": Red Hat, Slackware, SuSE, Debian, Mandrake,
Caldera, Corel, Yellow Lab, Black Lab, WinLinux, PhatLinux, Linux On A
Floppy, slinux, Trinux, Peanut and
(Rock, Armed, Stampede, Tiny. Power, Coyote) Linux, to name a few.

Always provide what distro and release level you are using
when you post questions (Redhat 6.1, Suse 5.0, Mandrake 8.2,...).

Different distros have different commands, files, and links to files,
pacakges and package/software managers.
Even happens between release levels of the same distribution.

Internet connection problem (ISP, cable, adsl, PPPoE, LAN, dialup, eth0. USB..)

If dhcp, which client (pump, dhcpcd, dhclient,...)


Example: Using RH 7.3, kde, pump though a cable modem on RR in Fortworth Tx.
ipchains Tinyfirewall is disabled. Still cannot get a lease.

 
Reply With Quote
 
Matthew Paterson
Guest
Posts: n/a

 
      10-29-2003, 04:53 PM
On Wed, 29 Oct 2003 17:20:48 +0000, Bit Twister wrote:

> For me on Mandrake distro's I set BOOTPROTO=dhcp in
> /etc/sysconfig/network-scripts/ifcfg-eth0


As youve mentioned due to different systems, I dont have this.

Im running :
Slackware Linux 8.1
linux-2.4.20 kernel.
DHCP Client Daemon v.1.3.22-pl1
Gnome 1.4
connection through eth0 to Force9 in the UK

> Please read
> http://www.catb.org/~esr/faqs/smart-questions.html


Thanks for the info.

--
Matt

Fear of a flat planet
 
Reply With Quote
 
Lew Pitcher
Guest
Posts: n/a

 
      10-29-2003, 05:42 PM
Matthew Paterson wrote:

> On Wed, 29 Oct 2003 17:20:48 +0000, Bit Twister wrote:
>
>
>>For me on Mandrake distro's I set BOOTPROTO=dhcp in
>>/etc/sysconfig/network-scripts/ifcfg-eth0

>
>
> As youve mentioned due to different systems, I dont have this.
>
> Im running :
> Slackware Linux 8.1
> linux-2.4.20 kernel.
> DHCP Client Daemon v.1.3.22-pl1
> Gnome 1.4
> connection through eth0 to Force9 in the UK


I can't remember if Slackware 8.1 had this, or if PV introduced it in
Slackware 9.0, but look at /etc/rc.d/rc.inet1 for this sort of code (close
to the top)

# You shouldn't need to edit anything below here.

# Set up the loopback interface:
/sbin/ifconfig lo 127.0.0.1
/sbin/route add -net 127.0.0.0 netmask 255.0.0.0 lo

# Set up the eth0 interface:
if [ "$USE_DHCP" = "yes" ]; then # use DHCP to set everything up:
echo "Attempting to configure eth0 by contacting a DHCP server..."
# Add the -h option to the DHCP hostname:
if [ ! "$DHCP_HOSTNAME" = "" ]; then
DHCP_HOSTNAME="-h $DHCP_HOSTNAME"
fi
/sbin/dhcpcd -t 10 ${DHCP_HOSTNAME} -d eth0

et cetera

If the above "if" statements are in your rc.inet1, then you just have to set
the line
USE_DHCP=yes
at the top of rc.inet1, and you'll get dhcpcd starting on eth0

If Slackware 8.1 /didn't/ come with script, go to your favourite Slackware
download site, and grab the tcpip-0.17-i386-16.tgz package. pkunzip it
(/don't/ upgradepkg or installpkg it), and extract out the rc.inet1 script.
From there, you should be able to cut'n'paste the dhcpcd startup into
/your/ rc.inet1 script





--

Lew Pitcher, IT Consultant, Application Architecture
Enterprise Technology Solutions, TD Bank Financial Group

(Opinions expressed here are my own, not my employer's)

 
Reply With Quote
 
Mark Cudworth
Guest
Posts: n/a

 
      10-29-2003, 06:19 PM
Matthew Paterson <(E-Mail Removed)> writes:
>
>Im running :
>Slackware Linux 8.1
>linux-2.4.20 kernel.
>DHCP Client Daemon v.1.3.22-pl1
>Gnome 1.4
>connection through eth0 to Force9 in the UK


You can edit /etc/rc.d/rc.inet1 manually, or you can just run "netconfig"
to reconfigure your network and select DHCP on the appropriate screen.

--
Mark Cudworth
 
Reply With Quote
 
Matthew Paterson
Guest
Posts: n/a

 
      10-29-2003, 07:20 PM
On Wed, 29 Oct 2003 19:19:11 +0000, Mark Cudworth wrote:

> You can edit /etc/rc.d/rc.inet1 manually, or you can just run
> "netconfig" to reconfigure your network and select DHCP on the
> appropriate screen.


Hi, that has worked. Thanks to Lew as well for the info on the correct
file to edit.

--
Matt

Fear of a flat planet
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

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 Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
dhcpcd - dns only Paulo da Silva Linux Networking 4 12-09-2010 08:42 PM
dhcpcd and name resolution tom Linux Networking 1 04-19-2004 09:56 PM
dhcpcd can't get an IP George Bell Linux Networking 1 12-19-2003 01:08 PM
Re: DNS update from dhcpcd Villy Kruse Linux Networking 0 07-02-2003 08:15 AM
Re: DNS update from dhcpcd Nathan Higgins Linux Networking 4 07-01-2003 11:19 PM



1 2 3 4 5 6 7 8 9 10 11