Home | Blog | Software | Reviews and Features | Forum | Help | Donate | About us
topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • December 14, 2017, 04:12 AM
  • Proudly celebrating 10 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: Tomato Custom Router Firmware question  (Read 386 times)

jcase397

  • Participant
  • Joined in 2017
  • *
  • default avatar
  • Posts: 2
    • View Profile
    • Donate to Member
Tomato Custom Router Firmware question
« on: November 20, 2017, 04:09 PM »
Hello,

I am looking at possibly building custom firmware using Tomato OS for a custom router.

I have been looking at different forums and the directions on how to compile Tomato into a .trx file, but I am still kind of lost. The router itself is a custom build, so I would imagine that I have to build from scratch.

Does anyone have any suggestions on where or how to start this?

Shades

  • Member
  • Joined in 2006
  • **
  • Posts: 2,274
    • View Profile
    • Donate to Member
Re: Tomato Custom Router Firmware question
« Reply #1 on: November 20, 2017, 10:09 PM »
Know the hardware you are using for your router, really, really well...before undertaking such a thing. With the provided instructions it won't be too big of a deal to do the compiling. But that is only half the battle. Getting the compiled result to properly talk to the hardware in your router...that is where most fail.

So be sure you know the hardware really well.

Perhaps it is smarter to have a look at a working setup of the Tomato router setup and how it is linked to that particular hardware. That can give you a lot of insight, before embarking on your custom build.

Then there is the question, why custom? From (bad) memory, Tomato is not that actively developed anymore. OpenWRT is. After cleaning up a "junkyard" of computer gear I found several old and broken TP-Link WiFi routers (TL-WR741ND). Yet I managed to get one to work again and there was a specific ROM from OpenWRT for that particular device. I tried and it worked beautifully.

However, that might give you the idea that creating such a ROM is easy. But the amount of warnings you get on that website about how easy it is to brick your device... Really, know the hardware in your router very, very well.

The router, is it just for yourself or are other people also depending on the internet connection you plan to use this custom router with? when it is the latter case, you will get a lot of crap from those people the second they think something is wrong with the connection.

On the OpenWRT site I also read the sage advise: If you think you can build something better and cheaper than the devices they build their ROMs for, you are mistaken. First, those devices contain hardware that is proven to work well (enough) together with a decent (enough) degree of reliability and for a price that you will have a very hard time trying to match.

Your custom selection of hardware must prove itself still and might be cheaper if you take a look at the component price alone. Personally, I can't be arsed to go out and try to "beat" a 15 US dollar device that is very easy to replace. and after I found out which model of device I had, the version of the factory ROM and the that it was build for the Brazilian market (yes, that can make a difference), I found the correct OpenWRT ROM, uploaded it to the device, went through the reset procedure as described on the website and now I have a fully functional Linux-based little router.

If you plan to use PC hardware to build your router, I strongly recommend to use OPNSense or pfSense instead. Much more powerful, runs of FreeBSD and you can extend its core functionalities with lots of extras that is readily available or you can create what you need yourself. Believe me, you lust for tinkering will be more than satisfied with either, especially when you like to create intricate network setups.

Don't underestimate the effect custom hardware with insufficient resources can have on your network. OPNSense and pfSense require only very little hardware resources, if you don't deviate that much from their default setup. Still, if you plan to use such a router with a lot of people, you better add more RAM and CPU quickly. A custom router that works fine for your one-person network, is very likely to fail when lots of people start using it. Another thing that people love to overlook.

Idiosynchro-nasties come into play when you build your own custom router, both in software but also with hardware and not all of them are properly documented.

Now, if you still like to play with hardware that is trusted to work and pretty good documented, you might better go for MikroTik hardware. Allows you build your own device (in a similar fashion as building with Lego blocks) and you are allowed to define a lot of your own stuff regarding networking in your equipment with their software. Best of customization with dependable hardware, which can scale up/down to your (professional) needs.

Companies here in Paraguay do use a lot of Mikrotik networking hardware. And for consumer networking gear, TP-Link is very popular (because it is dependable enough, while cheap). You don't know how many miles I had to make between computer shops throughout the whole of Asuncion (capital of Paraguay) and it suburbs, just to find 1(!) store that still had a new, but older model of an 8 port 1GBit/sec LinkSys switch.

Ath

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 3,080
    • View Profile
    • Donate to Member
Re: Tomato Custom Router Firmware question
« Reply #2 on: November 21, 2017, 01:34 AM »
I am looking at possibly building custom firmware using Tomato OS for a custom router.
You are asking strange questions: If you know how to build a custom router, why don't you know/have investigated how to build the software for it?
It seems you are working backward here.

jcase397

  • Participant
  • Joined in 2017
  • *
  • default avatar
  • Posts: 2
    • View Profile
    • Donate to Member
Re: Tomato Custom Router Firmware question
« Reply #3 on: November 21, 2017, 10:57 AM »
Shades, that was very insightful. Thank you!

So, I feel I need to be clear as to why I am asking this question.

I work for a company that buys routers from a source in Asia. This source sells the routers and builds firmware for them, but they are NOT the manufacturers of these routers as they outsource them from ANOTHER source in Asia. Part of our deal with them is that they design custom firmware for us that feature several methods of backup or constant contact. However, like I said, the routers
are custom jobs that they outsource and then sell to us. To make matters worse, the original manufacturers of these routers do not design firmware at all. We are considering building our own firmware in an attempt to cut off that lifeline, and become more independent.

This is merely an experiment to see how steep the learning curve is. Everything I am learning from the router I have gained from using telnet and firing various Linux commands at the pid's, but I'm not exactly sure what is going on. The company we buy from has obviously recycled code from other sources and it amazes our IT guys that they can build the firmware in the first place as they seem to be somewhat clueless with certain programming concepts. A good example of this is when we tried to approach them about firmware that allows the APN for the cellular network to be applied dynamically as the router dials out. I showed them a rough outline with a series of "if" statements that would evaluate whether the dialing process was successful or unsuccessful and, if successful, when to apply the proper APN. They were kind of clueless. They claimed they could not do it, when there is clearly JavaScript code in the www directory of the router that does something similar.

I'll save you the rest. Thank you for your time.
« Last Edit: November 21, 2017, 11:08 AM by jcase397 »

Ath

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 3,080
    • View Profile
    • Donate to Member
Re: Tomato Custom Router Firmware question
« Reply #4 on: November 21, 2017, 02:28 PM »
This is merely an experiment to see how steep the learning curve is.
Ah, now it makes more sense.

IMHO, you either need to acquire the needed knowledge yourself, or find a colleague/hire someone that has or can get up to speed with this.

Shades

  • Member
  • Joined in 2006
  • **
  • Posts: 2,274
    • View Profile
    • Donate to Member
Re: Tomato Custom Router Firmware question
« Reply #5 on: November 21, 2017, 06:17 PM »
These links may help you in your quest (or should I say, avoid pitfalls and mousetraps):
https://arstechnica....router-from-scratch/
http://www.linuxjour...al.com/article/10687
https://arstechnica....ild-your-own-router/

Those links should give you already an idea what to expect when you start to build your own router.