netfilter.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michael Gale <michael@bluesuperman.com>
To: netfilter@lists.netfilter.org
Subject: Re: Two DHCP addresses on external interface
Date: Thu, 1 Jan 2004 14:28:00 -0700	[thread overview]
Message-ID: <20040101142800.0ac045d2.michael@bluesuperman.com> (raw)
In-Reply-To: <200312290131.57181.Antony@Soft-Solutions.co.uk>


Ok ... here is the scoop ....

Originally I ran /sbin/dhcpcd -R -N -t 60 -h CO -d eth0

on my external interface to get a IP via DHCP from my ISP.

Now I want to run my PS2 behind the firewall and want the PS2 rules to
not be part of the standard firewall set.

So I get the MAC address of my PS2 and ran:
/sbin/dhcpcd -R -N -t 60 -h CO -I MAC-of-PS2 -d eth0:1

The out put was:
dhcpcd: MAC address = EXT NIC MAC 

but then BAM !!

dhcpcd: your IP address = Second IP via DHCP

So now if I run ifconfig I see

eth0 IP
eth0:1 second IP

Michael.


On Mon, 29 Dec 2003 01:31:57 +0000
Antony Stone <Antony@Soft-Solutions.co.uk> wrote:

> On Monday 29 December 2003 12:26 am, Michael Gale wrote:
> 
> > Hello,
> >
> > 	I think I have the answer, first I will find out the MAC address
> > 	of my
> > PS2 (packet sniffer) and then use dhcpcd w/ -I:
> > --snip-- man dhcpcd
> > -I <ClientID>
> >               Specifies the client identifier string.  dhcpcd uses
> >               the
> > default client identifier (MAC address of              the network
> > interface) if it is not specified.
> > --snip--
> >
> > I will specify the MAC of my PS2 ... then I can DNAT the traffic
> > back and forth to and from the PS2 :)
> >
> > Oh ... I think it will work :)
> 
> I'm not so sure - sorry.
> 
> The option you have found sends a client ID to the DHCP server, and if
> you don't specify the ID you want, it uses the MAC address.   However,
> I don't think that sending a different MAC address will give you the
> second DHCP client lease, because you can specify anything you like
> for the client ID (hostname is common), and you don't have to specify
> one at all, yet you still get a lease.
> 
> I wonder if maybe you have to do something unpleasant like acquire a
> lease, rename the /etc/dhcpc/dhcpcd-eth0.* files, and acquire another
> one, this time faking the MAC address (but I'm not sure how...)?
> 
> Another horrible suggestion is to put another ethernet card in your
> firewall, plug it into the hub alongside your existing external
> interface, then acquire leases on both eth0 and eth1 (which just
> happen to be connected to each other through the hub).   Normally I
> would say to people "No! Don't have two interfaces on the same subnet,
> and don't connect two interfaces to the same hub" but in this case it
> might be a workable solution?
> 
> Regards,
> 
> Antony.
> 
> -- 
> A: Because it messes up the order in which people normally read text.
> Q: Why is top-posting such a bad thing?
> A: Top-posting.
> Q: What is the most annoying thing on usenet and in e-mail?
> 
>                                                      Please reply to
>                                                      the list;
>                                                            please
>                                                            don't CC
>                                                            me.
> 
> 


-- 
Hand over the Slackware CD's and back AWAY from the computer, your geek
rights have been revoked !!!

Michael Gale
Slackware user :)
Bluesuperman.com 


      reply	other threads:[~2004-01-01 21:28 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-12-29  0:07 Two DHCP addresses on external interface Michael Gale
2003-12-29  0:26 ` Michael Gale
2003-12-29  1:31   ` Antony Stone
2004-01-01 21:28     ` Michael Gale [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040101142800.0ac045d2.michael@bluesuperman.com \
    --to=michael@bluesuperman.com \
    --cc=netfilter@lists.netfilter.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).