Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.os.linux.networking > #1235
| From | Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> |
|---|---|
| Newsgroups | comp.os.linux.networking |
| Subject | Re: Is this a bridging scenario? |
| Date | 2012-04-08 14:20 +0200 |
| Organization | Plouf ! |
| Message-ID | <jlrvq6$2muf$1@saria.nerim.net> (permalink) |
| References | <b5b53ca6-9141-4105-b701-4b8935268f02@vy8g2000pbc.googlegroups.com> <jkmhbp$em6$1@dont-email.me> <2f8acba3-b55f-42c3-b7ff-c7de7bf22649@qg3g2000pbc.googlegroups.com> |
Al a écrit : > > Sorry for the belated reply. Ok I understand that it is routing, and I > will need to set a static IP on the interfaces. As I wrote, it can be either routing or bridging. Let's go for routing. > Lets say on the PC we have > > wlan0 192.168.1.120 > eth0 192.168.2.121 (I think eth0 needs to be a diff subnet right?) Correct. > and on the camera which connects to eth0: > > cam1 192.168.2.122 Fine. > I then need a routing "rule" ? No. But in order for the camera to be able to connect to the internet, you need to set the Linux box (192.168.2.121) as the default gateway on the camera and set up the Linux box as an IP router (sysctl net.ipv4.ip_forward=1). Also you will need to either : - create a static route on the router to the camera subnet (192.168.2.0/24) with the Linux box (192.168.1.120) as the gateway. - or set up masquerading on the Linux box (iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE). > and how would I port forward so I can access the camera directly from > the inet? If the router has a static route to the camera subnet, then it should be possible to create a port forwarding rule directly to the camera (192.168.2.122) on it. Otherwise you need to create a port forwarding rule to the Linux box (192.168.1.120) on the router and create a similar port forwarding rule to the camera on the Linux box : iptables -t nat -A PREROUTING -i wlan0 -d 192.168.1.120 -p tcp --dport 80 -j DNAT --to 192.168.2.122 (change with whatever port the camera is using) > how would I port forward so I can access the linux box from the net? See above. This is router-dependent.
Back to comp.os.linux.networking | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-03-24 15:55 -0700
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-03-24 15:57 -0700
Re: Is this a bridging scenario? Aragorn <stryder@telenet.be.invalid> - 2012-03-25 09:26 +0200
Re: Is this a bridging scenario? Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-03-25 10:56 +0200
Re: Is this a bridging scenario? Aragorn <stryder@telenet.be.invalid> - 2012-03-25 12:19 +0200
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-04-08 05:00 -0700
Re: Is this a bridging scenario? Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-08 14:20 +0200
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-04-08 06:10 -0700
Re: Is this a bridging scenario? Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-08 16:28 +0200
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-04-08 12:39 -0700
Re: Is this a bridging scenario? Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-08 22:32 +0200
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-04-09 08:28 -0700
Re: Is this a bridging scenario? Scott Hemphill <hemphill@hemphills.net> - 2012-04-09 12:41 -0400
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-04-09 11:52 -0700
Re: Is this a bridging scenario? Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-09 21:09 +0200
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-04-10 01:56 -0700
Re: Is this a bridging scenario? Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-10 20:30 +0200
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-04-10 16:30 -0700
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-04-10 19:23 -0700
Re: Is this a bridging scenario? Al <bigal.nz@gmail.com> - 2012-04-10 22:54 -0700
Re: Is this a bridging scenario? Pascal Hambourg <boite-a-spam@plouf.fr.eu.org> - 2012-04-11 09:33 +0200
Re: Is this a bridging scenario? Scott Hemphill <hemphill@hemphills.net> - 2012-04-09 18:19 -0400
csiph-web