# Linux router with quad port server adaptor

## ronstudio

Hi all,

I am planning to build a Gentoo linux box as a router with a quad port network card like Intel I350 T4, however, may I ask

1) if a quad port card means there will be 4 devices in the system? eth0 - eth3? 

2) Could I have one port or one eth for the Wan, remaining 3 ports for internal lan network?

The reason for building a Linux router myself instead of just buying a router is because,

1) Seems like most normal customer level router having poor firmware.. like the newly released ASUS N66U or AC66U has been found the problem in firmwire and functionality not fully working due to the unstable firmware

2) I feel like the Linux router with a good Lan card could have better Wan to Lan performance, but is that true?

Could someone give me the advice regarding this? Is there anything I should pay attention to while building my own Linux router rather than just buying a router?  (like too much work just to get the routing work? or performance is equally the same so not worth the trouble?)

I know that there is some distro which specialized designed for router and having great UI.... but I would like to have the system in Gentoo which I can use for other purpose as well... Those distro looks only having the system which purely for routing and nothing else, is that the case?

Thanks~

----------

## Mad Merlin

1) Yes.

2a) Yes.

2b) Generally, yes, although it depends on what hardware you use (a Pentium 60 you have laying around in your closet will not be faster than a modern consumer grade router).

----------

## Jaglover

Three ports on same subnet needs co-operating switch. Unless you just wire these three ports to three separate boxes.

----------

## ronstudio

Thanks a lot for the help, this has cleared my concern now.

I am currently using a consumer router + D-Link 8 ports switch, however, the performance of the D-Link switch is very poor in performance. It is a gigabit switch, but the max internal transfer speed is only 694mb when I used the ipserf to test it.

So I am planning to have the 4 port network card, having 1 port for Wan and remaining 3 ports connecting to the other 3 PC directly.

Thanks~

----------

## mtfj

I am running ASUS E45M1-M PRO w/two Intel GbE NICs + 8GB RAM for my gentoo home router w/200Mbps fibre optical line.

>2) I feel like the Linux router with a good Lan card could have better Wan to Lan performance, but is that true?

Based on my experience (when I was running a uploader site), a single connection bandwidth of consumer router and linux router ain't much different.

You see a big performance difference when thousands of simultaneous connections are coming in. A consumer router CPU just can't handle

that many connections. A conventional PC CPU can, but you have to pay a slightly higher electricity bill for that performance.

----------

## ronstudio

Hi mtfj,

Thanks a lot for sharing your view. I'm thinking to try running those VMWare for the PC to have those distro which specifically designed for running as router, however, how much Ram would I need in this case??

The PC was running Q6600, ASUS P5Q-PRO, 2GB DDR2 ram, the problem is it's a bit difficult to get DDR2 these days. DDR3 is much cheaper and common these days, but I am not willing to upgrade it just for this purpose -_-

May I ask usually how much ram had been used generally for your case as home router?

----------

## NeddySeagoon

ronstudio,

I am doing something similar.

I have an HP microserver with a four port network card, for eth0 ... eth4 in total.  Only four ports are used.

They are passed to a Virtual Machine router that runs Shorewall.

The four ports are used for

1.  Internet

2.  Wireless Access Point

3.  Servers (more Virtual Machines)

4.  Protected Wired network

This avoids wardrivers getting access to my wireless and onto the wired network, since wireless is not permitted to connect to wired.

----------

## mtfj

My first linux router was Intel Coppermine with 512MB RAM and that was more than enough using a linux distribution not Gentoo.

My current one has, as I said, 8GB. That is way too much, but DDR3 is dirt cheap now. I just went ahead and bought x2 4GB DDR3 RAM.

Memory usage is like this.

```
Mem:   7780096k total,   748140k used,  7031956k free,   387680k buffers
```

Approx. 730MB? So if you have 1GB memory that is more than enough.

I am running, dibbler, dnsmasq, ebtables, fancontrol, ip6tables, iptables, lm_sensors, ntpd, pptpd,radvd,rsyncd,snmpd,sshd,syslog-ng, vixie-corn and other system services.

I am not sure how much RAM do you need to run a host OS + a guest OS. Why do you need to use VMWare for this?

Can you install Gentoo on the bare metal?

and my concern is you are sure about running Q6600 as router for 24/7? It's not very power efficient CPU, thou.

 *ronstudio wrote:*   

> Hi mtfj,
> 
> Thanks a lot for sharing your view. I'm thinking to try running those VMWare for the PC to have those distro which specifically designed for running as router, however, how much Ram would I need in this case??
> 
> The PC was running Q6600, ASUS P5Q-PRO, 2GB DDR2 ram, the problem is it's a bit difficult to get DDR2 these days. DDR3 is much cheaper and common these days, but I am not willing to upgrade it just for this purpose -_-
> ...

 

regards,

----------

## ronstudio

Yes, Q6600 is definitely not a energy efficient CPU, but it's an old computer which I have no alternative use... 

Today I have gone to buy a cheap Intel CT desktop 1 port lan card as a cheap alternative at the moment(1 lan card + on board lan), to have a try and learn how it works first.

For VMWare, just I have read some comment and suggestion that it would be a good idea to have 1 system for 1 dedicated service for security reason. Thinking this sound makes sense and maybe a good idea to try.

Neddy, Thanks a lot for sharing your configuration~~  =)

----------

## ronstudio

Hi,

may I ask further ask if there is any possible way to buy the quad port full height plate?? I have found a very good value second hand I340 T4, but it is currently in low profile and the seller does not have full height plpate for quad port.. >_<

I tried to search for that in ebay, but doesn't know the correct keyword for that...

----------

