Q:

Trouble setting up a DD-WRT router with a DSL gateway

Our office is fairly small. We previously had a 2wire gateway that came when we ordered our DSL connection. I recently decided to upgrade to a router that could support DD-WRT since the 2wire was very lacking in features. I purchased a new router and a new modem (which is actually a DSL modem with 1 port router). I got DD-WRT flashed onto the router successfully, and configured the gateway to work with our ISP (and I confirmed that it is working by connecting it to a single computer and checking out the internet). Additionally, I disabled the modem's DHCP server since I intend for DD-WRT to cover that.
Now, my goal here is to have the DD-WRT router between the gateway and the switch (all servers and workstations are connected to the switch, the gateway is connected to the router's WAN port) where it can act as firewall in addition to everything else. The modem came with a default IP of 192.168.0.1, which is outside my network, so I changed it to 192.168.1.254 (the DD-WRT router is 192.168.1.253). On the initial setup page of DD-WRT, I plugged in a gateway IP of 192.168.1.254.
After doing this and restarting all required equipment, no machines have internet access. They can ping both the router and the gateway successfully. I tried everything I could think of. I noticed that the router is handing out it's own IP of 192.168.1.253 as the gateway address. If I set up a workstation to use a static IP and set the gateway IP to 192.168.1.254, the machine gets internet access, but I don't think that is what I want since I believe that bypasses the router's firewall and such.
What am I doing wrong? I'm not the most knowledgeable networking guy around, I have a feeling I'm missing something really obvious here.

A:

You want to put the router between your gateway and the switch as mentioned. In this typical setup, all traffic between the internet and your local network runs through the router and gateway, which allows you to control the traffic using either device.
internets---------[gateway]---------[router]------[switch]---local network
              192.168.0.1 (lan)   192.168.1.253              192.168.1.XXX
              XXX.XXX.X.X (public)

Your second setup could allow all connections through the gateway, but this would mean that you would not be able to force control traffic from your router and your router would just be a DHCP server.
internets---------[gateway]---------[switch]------[router]
             192.168.1.254 (lan)       |       192.168.1.253
             XXX.XXX.X.XXX (public)    |
                                       +---local network
                                           192.168.1.XXX

There is a third possible setup and one that I actually use at my place. In this mode, the DSL modem only acts in a pass-thru/bridge manner (like a dumb modem). We use PPPoE for DSL connections and DD-WRT supports it. As a result of this setup, the Internet connection interface is actually on the router instead of the gateway, which allows further control over the traffic.
internets------bridge---------[router]---------[switch]---local network
               (modem)     192.168.1.254 (lan)              192.168.1.XXX
                           XXX.XXX.X.XXX (public ip)

