Two DHCP addresses on external interface
Hello,
I have a strange question, right now I have a firewall box at home and
behind it is my web, mail and FTP server.
Plus the rest of my computers and my wife's PC.
I got a PS2 for Christmas ... I know I will never grow up really :)
So I want to play online but it uses strange ports and they do not seem to be listed anywhere. Plus I can not host any games if I am behind a firewall unless I forward connections on ports about 1024 to the PS2 IP which could break FTP and other things.
So my ISP provides a second IP free of charge :0 so I have them provide me with one. So now I can plug two PC's into a HUB and the cable modem into the HUB and each PC gets it's own IP via DHCP.
I would like to have my firewall get both IP's then I would be able to have some control as to what packets go to and from the PC also I can do some bandwidth monitoring.
I have used virtual IP's on linux boxes before with no problems but can I have a box get both IP's via DHCP ???
Right now it gets one:/sbin/dhcpcd -t 60 -h CO -d eth0
I tried to get a second one by:/sbin/dhcpcd -t 60 -h CO -d eth0:1
But it did not work :(
.. any ideas ??? do I need to fact another MAC address ???? now I am thinking
Signature · 6 lines
Hand over the Slackware CD's and back AWAY from the computer, your geek rights have been revoked !!! Michael Gale Slackware user :) Bluesuperman.com
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 :)
Michael.
Quoted 48 lines · On Sun, 28 Dec 2003 17:07:33 -0700 Michael Gale <[email protected]>…
Hello,
I have a strange question, right now I have a firewall box at home and
behind it is my web, mail and FTP server.Plus the rest of my computers and my wife's PC.
I got a PS2 for Christmas ... I know I will never grow up really :)
So I want to play online but it uses strange ports and they do not seem to be listed anywhere. Plus I can not host any games if I am behind a firewall unless I forward connections on ports about 1024 to the PS2 IP which could break FTP and other things.
So my ISP provides a second IP free of charge :0 so I have them provide me with one. So now I can plug two PC's into a HUB and the cable modem into the HUB and each PC gets it's own IP via DHCP.
I would like to have my firewall get both IP's then I would be able to
have some control as to what packets go to and from the PC also I can do some bandwidth monitoring.
I have used virtual IP's on linux boxes before with no problems but can I have a box get both IP's via DHCP ???
Right now it gets one:
/sbin/dhcpcd-t 60 -h CO -d eth0I tried to get a second one by:
/sbin/dhcpcd-t 60 -h CO -d eth0:1But it did not work :(
.. any ideas ??? do I need to fact another MAC address ???? now I am thinking
Signature · 6 lines
Hand over the Slackware CD's and back AWAY from the computer, your geek rights have been revoked !!! Michael Gale Slackware user :) Bluesuperman.com
Signature · 6 lines
Hand over the Slackware CD's and back AWAY from the computer, your geek rights have been revoked !!! Michael Gale Slackware user :) Bluesuperman.com
Quoted 11 lines · Michael Gale
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--
Quoted 4 lines
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.
Signature · 7 lines
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.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.
Quoted 58 lines · On Mon, 29 Dec 2003 01:31:57 +0000 Antony Stone <[email protected]>…
Quoted 13 lines · Michael Gale
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--Quoted 4 lines
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.
Signature · 10 lines
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.
Signature · 6 lines
Hand over the Slackware CD's and back AWAY from the computer, your geek rights have been revoked !!! Michael Gale Slackware user :) Bluesuperman.com