THESE FORUMS NOW CLOSED (read only)

Fun Stuff => CLIKC => Topic started by: Statik on 25 Nov 2008, 19:52

Title: Convert old computer to linux router/NAS
Post by: Statik on 25 Nov 2008, 19:52
So, as the subject states, My goal is to turn an older computer I have at the house into a router AND network storage.

Yes I know I could accomplish the same thing with a router and one of the HDDs made for such a thing, but I would rather have the experience doing it myself.    Apparently that wasn't very clear initially.


My questions (for all intents and purposes consider me computer savvy, but new to linux):

I suppose, first off, is building a box with a bunch of NICs in it a good idea?  IIRC, I saw in a thread where someone asked something similar to what Im asking, they recommended two NICs and a switch, but I would rather make the box self contained (as having a box + switch would kind of defeat the purpose of building it in the first place).

I have googled this and come back with many guides on how to do one or the other, but not specifically one for both (I could be looking in the wrong places).  Some of the things I have read are for custom distros of linux with samba as an addon.  I also found someone pointing to eBox for accomplishing this.  Does anyone have any experience with any of these (or others) and have recommendations towards which distro to use?  (I'm not particularly concerned if doesnt have a GUI) .

Basically, can anyone point me to a guide and/or distro they have used for this purpose. 

Also, I don't think its possible, and not really a concern either way, but is it even possible to make a router box with wireless capabilities?  It doesn't seem like it would be possible (or at the very least, practical), given the limitations of PCI/X.
Title: Re: Convert old computer to linux router/NAS
Post by: clockworkjames on 26 Nov 2008, 03:28
One thing I am going to just throw out there is as far as power consumption goes, even a really dumb old computer will have a stupidly high power draw compared to a router and it will be noisier.

If you are going with it long term I would suggest you think heavily about spending a buck a day to power your router.
Title: Re: Convert old computer to linux router/NAS
Post by: bicostp on 28 Nov 2008, 08:37
Don't bother.

You can run 2 NICs and make a firewall, but it really won't be any better than a $50 off-the-shelf Netgear from Circuit City. (If you really want a high end router, you can probably pick up a used Cisco off eBay.) Running multiple NICs to make an Ethernet switch is ludicrous; you can get one of those for $20 and it will work faster and more reliably. And, as clockworkjames said, the power draw is going to be really high.

If you need more storage and want it accessible to multiple computers, either add hard drives to your main PC and share them over the network (Windows File Sharing or FTP), or put them in removable enclosures. You could do a DIY NAS box if you want (it's really simple once you get the server set up), but it's not something you'll want going 24/7.
Title: Re: Convert old computer to linux router/NAS
Post by: clockworkjames on 28 Nov 2008, 15:19
Another thing is if you want to just make another device connect to the internet, put another NIC in your current PC and bridge it so they share the connection. Otherwise buy a router since it is the best option for many reasons.
Title: Re: Convert old computer to linux router/NAS
Post by: Statik on 29 Nov 2008, 14:54
I clarified my post a bit.

Yes, I am fully aware of the power draw, I am fully aware of routers and switches (I actually already own one). 

Please read the post before commenting.
Title: Re: Convert old computer to linux router/NAS
Post by: clockworkjames on 29 Nov 2008, 17:05
Oh, let me clarify my post,

Quote
first off, is building a box with a bunch of NICs in it a good idea?

 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
 ||
\||/
 \ /
  v
NO.
Title: Re: Convert old computer to linux router/NAS
Post by: Melodic on 29 Nov 2008, 17:10
To be honest, I was expecting the OP to edit that after he realized his mistake. Oops.
Title: Re: Convert old computer to linux router/NAS
Post by: Statik on 29 Nov 2008, 22:42
Ugh... You STILL missed the point.  And somehow STILL managed to miss the actual question. 

For the record, I dont care about power, I dont want to bridge the connection.  (Yes, I am aware that I would be bridging the connection off of one pc to multiple others).

I don't plan on having it run 24/7 (I may in the future, but thats if I actually turn it into a server)

As stated in the original post, I wanted to know the difference between using a bunch of NICs and using 2 NICs + a switch.  Using 2 NICs + switch seems to defeat the entire point of making a linux router (at least for me).  I have found multiple threads of people talking about having 3 or 4 NICs in a linux box being used as a router / server / whatever.

And Melodic, I don't really see what mistake I made.  It's entirely feasible to run more than 2 NICs in a single linux box.

I am simply looking for opinions on distro to use, if anyone knows of a guide to set up a combined router / NAS (and maybe print server).  As all I seem to find are one or the other.


Title: Re: Convert old computer to linux router/NAS
Post by: bicostp on 30 Nov 2008, 11:48
You're not going between multiple subnets, therefore you don't need an internal LAN router. You only need one to connect to your ISP's WAN, and your DSL or cable modem does that job.

2 NICs plus a switch is what you want.
Title: Re: Convert old computer to linux router/NAS
Post by: dennis on 01 Dec 2008, 11:59
Oh, let me clarify my post,

Quote
first off, is building a box with a bunch of NICs in it a good idea?

NO.
Not helpful. Also, putting multiple NICs in a Unix/Linux box is really no problem.

I used to run a router/firewall on an old Pentium Pro with 2 3COM NICs for years, and had no problem with it.

I used a distro from the Linux Router Project, but that was way back in 2001 or so. It's been subsumed into the LEAF project (http://leaf.sourceforge.net/) which should serve your purpose.

I believe they've updated it with online storage, and it can route wireless over certain wireless NICs.
Title: Re: Convert old computer to linux router/NAS
Post by: Statik on 01 Dec 2008, 12:19
Yeah, I just found LEAF the other day.  It's not a hugely pressing project for me (making the DIY router/NAS) as finishing finals takes precedent at the moment, I was just looking for some opinions as to the way to go about it.  And as I have multiple older computers laying around, it seemed like it would be an interesting project to try.

I have yet to understand the need for making every god damn thing wireless when it comes to computers.  You could argue that laptops and cellphones are better for having such features, and I wouldn't disagree, but I have yet to see a practical reason to have a home network of DESKTOPS linked wirelessly.  (Yes, it gets rid of cables, which could be a benefit, but wireless has a habit of being unreliable, so the downsides outweigh the upsides IMO)  That being said, based on your comment, I'm guessing that you COULD make a linux box into a wireless router?  And have it broadcast via a wireless NIC?  Id be curious to know if it could/would have the same range as a traditional router with wireless capabilities.  I can't really see why this wouldn't work, except for the fact that I don't know if wireless NICs are set up (or can be set up) to broadcast to / recieve from multiple sources?
Title: Re: Convert old computer to linux router/NAS
Post by: ackblom12 on 01 Dec 2008, 12:55
The point is really that Wireless has a lot of work that needs to be done, and the only way that's gonna happen is to get it into the mass market and give companies reasons to give a shit if it's reliable. My desktop I'd prefer to stick to being wired just because of the ridiculus amount of torrentings I do, but for most cases, I'd much much prefer my equipment to be wireless. Hell, if it wasn't for the shitty price of the 360's wireless adapter I'd definitely have that wireless because wires are just that much of a pain in the ass.
Title: Re: Convert old computer to linux router/NAS
Post by: supersheep on 01 Dec 2008, 13:07
Wireless is also useful; if you live somewhere that isn't wired for networks, or especially if you live in rented accommodation. Running CAT5 up the stairs to my housemate's room is a bit of a pain when we can't tack it to the walls or drill holes to avoid doors.
Title: Re: Convert old computer to linux router/NAS
Post by: ackblom12 on 01 Dec 2008, 13:29
God yes, I have 5 computers on my network and I'd kill for a decent reliable wireless network. Also, honestly, wireless isn't terribly unreliable anymore. The main issue is that if anything does go wrong it's a ridiculous pain in the ass trying to find out what the hell happened. Also, in the case of torrents and massive file transfers, it's just nowhere near as fast. For online gaming even, the speed doesn't make a difference as long as you have G or N, which most do now, unless you've got something else wrong with the connection.

Also, for those who aren't familiar with sites like Newegg, CAT5 cable is expensive as fuck. I mean, some poeple actually pay Wal-Mart and Best Buy prices for cable. Silly I know.
Title: Re: Convert old computer to linux router/NAS
Post by: dennis on 01 Dec 2008, 13:40
Yeah, I just found LEAF the other day.  It's not a hugely pressing project for me (making the DIY router/NAS) as finishing finals takes precedent at the moment, I was just looking for some opinions as to the way to go about it.  And as I have multiple older computers laying around, it seemed like it would be an interesting project to try.

I have yet to understand the need for making every god damn thing wireless when it comes to computers.  You could argue that laptops and cellphones are better for having such features, and I wouldn't disagree, but I have yet to see a practical reason to have a home network of DESKTOPS linked wirelessly.  (Yes, it gets rid of cables, which could be a benefit, but wireless has a habit of being unreliable, so the downsides outweigh the upsides IMO)  That being said, based on your comment, I'm guessing that you COULD make a linux box into a wireless router?  And have it broadcast via a wireless NIC?  Id be curious to know if it could/would have the same range as a traditional router with wireless capabilities.  I can't really see why this wouldn't work, except for the fact that I don't know if wireless NICs are set up (or can be set up) to broadcast to / recieve from multiple sources?
LEAF is pretty much painless as long as your NIC cards have good Linux drivers. It looks like the Bering distro is closest to what I was using back in the day (Dachstein). What's nice about building a multi-NIC computer into a router rather than using a consumer standalone router is that you can integrate various file and web servers and you can have advanced routing and QOS cheaply and easily. Also, it's just a fun project.

As for wireless, only a small range of card chipsets are supported by Linux for use as access points, but you should be able to set up a peer-to-peer network pretty easily. This isn't something I've done personally, though.
Title: Re: Convert old computer to linux router/NAS
Post by: Statik on 01 Dec 2008, 14:45

Also, for those who aren't familiar with sites like Newegg, CAT5 cable is expensive as fuck. I mean, some poeple actually pay Wal-Mart and Best Buy prices for cable. Silly I know.

And monoprice is even cheaper than Newegg.  75ft cat5 for less than $10.  And comes in a lot of pretty colors.

Id assume the cards that are capable of being used as a wireless access point are the ones specifically capable of handling multiple connections.

I'll probably just pick up a stack of linksys (cisco) NICs, as they are like $10 at the best buy near me.
Title: Re: Convert old computer to linux router/NAS
Post by: ackblom12 on 01 Dec 2008, 22:06
Yes, but when you start getting into the price differences between places like Newegg and Monoprice, is where I stop caring that much and preference of companies starts taking over. The point I was trying to make is that most people with internet connections seem to think that paying $30 for 25ft of network cable is the best they can do and part of the huge draw of it for the average consumer.
Title: Re: Convert old computer to linux router/NAS
Post by: Statik on 03 Dec 2008, 08:27
Oh, trust me, I know.  I worked for best buy for 4 and a half years, and circuit city another 1 and a half.  I worked in the warehouse (shipping/receiving) for both, and I got to see the cost on everything.  The problem is, thats where stores such as best buy and such make their money.  They make little to nothing (sometimes even losing money) on laptops and desktops, so cables and service plans are where they recoup their costs.  Cable markup of 600-700% is the norm.  And don't even get me started on Geek Squad markup.