Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a Wifi router doing DHCP and NAT, connected to another router, which in turn is connected to the internet.

The main router (LAN IP: 192.168.1.1) distributes addresses in the 192.168.1.* range, while the Wifi router (WAN IP: 192.168.1.190, LAN IP: 192.168.2.1) distributes addresses in the 192.168.2.* range. The reason for the separation of these two network segments is that there is a NAS behind the wifi router, with heavy amounts of data being constantly exchanged between wifi clients and the NAS.

Most of the time, only Wifi clients need to access the NAS, and everything works very well. In some cases, though, accessing the NAT from a wired client connected to the main router is needed.

I'm searching for a way to allow clients connected to the main router to access the NAS behind the Wifi router.

Setting up a specific route on the main router (192.168.2.0, mask 255.255.255.0, routing to 192.168.1.190) only works if I disable NAT on the router, which in turns decreases the performance of transmissions over Wifi.

Could port forwarding work? Which ports would I need to forward? How would I do that?

Thanks for your help!

EDIT

I've set up port forwarding on my router, and now accessing \\192.168.2.1\ in Windows Explorer doesn't return "Not found". Instead, it simply shows a blank listing (no files or folders appear). What might I have done wrong?

EDIT 2

Some more details: I'm running Windows 7 Home Edition, and Debian Squeeze. The NAS uses the SMB protocol. Trying to access it from debian (via smbclient -L) yields an empty listing.

share|improve this question
    
Why don't you just have it all on the same subnet? It's not as if the traffic over the wifi router will impede the traffic on the wired router, or vice versa, since it's all switched. –  Orihara Jan 22 '12 at 23:48
    
Port forwarding would probably work, if set up on the wifi router. Use whichever port(s) your NAS uses, then the wifi router behaves as a NAS for outside clients. –  jpaugh Jan 23 '12 at 4:26
    
@jpaugh: I've edited my question to reflect my most recent discoveries. For some reason no files get listed when I access `\\192.168.2.1` in Explorer. –  Clément Jan 23 '12 at 11:13
1  
Even if you get access to your NAS to work properly, that doesn't necessarily mean you can access it from Explorer---but I'm assuming that works inside your wifi. What protocol does your NAS use to talk to other computers? Which operating system exactly are you using? Which version? –  jpaugh Jan 23 '12 at 11:28
1  
Assuming your network topology has the Win 7 box and internet hooked up to the 1.x router, and the NAS box is hooked to the 2.x router, accessing 192.168.2.1 shouldn't give you anything. You need to hit the WAN IP. –  Orihara Jan 24 '12 at 20:47

1 Answer 1

up vote 0 down vote accepted

Listing in Explorer doesn't work, but mounting it does. The ports to forward are 135, 137, 138, 139, and 445.

Hope this helps!

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.