[asterisk-users] asterisk on mini-itx
Gordon Henderson
gordon+asterisk at drogon.net
Sun Mar 11 02:36:14 MST 2007
On Sat, 10 Mar 2007, Mail Lists wrote:
> On 3/10/07, Gordon Henderson <gordon+asterisk at drogon.net> wrote:
>>
>> On Sat, 10 Mar 2007, Mail Lists wrote:
>>
>> > I've had a look around and I think I have settled on one of the VIA EPIA
>> > fanless boards. Does anyone have any experience with these running
>> asterisk
>> > as far as performance and reliability is concerned? Has anyone run
>> asterisk
>> > with any compressed codecs on this setup?
>>
>> I've built several systems based on this motherboard (the 1GHz fanless
>> one) Compressed codecs are fine - as long as you aren't transcoding ;-) I
>> figured I could push 30 non transcoded calls through one, but I've never
>> had the ability to fully test it out. The max. I had going on one system
>> was 20 calls.
>
>
> I probably will be doing transcoding .... phone(ulaw)->PBX(gsm)->VTSP
> At least in some circumstances.
Proper performance teting is always been something on my to-do list. Sipp
is probably the way to do it, but as my intended audiance for these
systems has always been no more than a dozen-15 extensions, and everyone
using G711 (occasionally g726 for an IAX trunk) then it's been a low
concern. (I have just been asked to investigate a system for 10,000 users
though, so I fear it may become a concern soon!!!)
> Boot it off flash and have it load an initrd.gz into RAM. Everything will
>> run entirely from RAM - no writes to the flash at all! I can get
>> everything inside a 48MB flash drive, but I use 64MB ones which gives me
>> space to store configs, etc.. (of-course, I make it sound so simple ;-)
>> but I'd already worked this out some years back for a diskless router
>> project)
>
> I'm guessing you don't have any sort of graphical UI? I was hoping to run
> freepbx in
> some way - probably have the mysql database stuff stored somewhere else..
In the 64MB flash devices I use, I can squeeze in a fairly full featured
Linux system (and I've not even bothered with uClib or busybox yet)
including apache and php. I don't use mysql, and I removed PERL. My web
based GUI stores everything in flat text files, and generates the relevant
/etc/asterisk files from these text files. It's very fast and without
MySQL is one less thing to go wrong. (And I suspect my aplication is
actually lot faster than going through a MySQL layer too!) I did test the
speed of this by generating config files with 1000 users and there wasn't
an issue handling it. (other than having a list of 1000 names on screen
which wasn't helpful!)
My old routers have 32MB flash devices with all the above apart from
Asterisk. (Although I'm just about to build a new pair with 64MB devices
as I have stock of them)
>> I keep voicemail on a 2nd flash IDE device mounted as ext2 (not 3 as ext3
>> writes regularly!) and force the fsck at boot time if it's dirty - I'd
>> rather lose all voicemail than have it dump itself into single user mode
>> waiting for keyboard input... (your thoughts here might be different :)
>
> Have you ever burnt out a flash drive from voicemail usage alone?
Not yet! Last time I bought a batch, I had a choice of fast devices with
1,000,000 write cycles or slower ones with 5 million. I went with the
slower ones, as speed isn't an issue here. I suspect the manufacturers are
very conservative in their numbers too, and AIUI modern devices
dynamically move blocks about to make sure one block doesn't get written
many times. (write wear levelling or something I think they call it)
3 or 4 years ago I saw a microtik router box that had a live ext3
filesystem on a flash device (VIA 533MHz processor) - I wonder how long
those lasted... (it wouldn't surprise me if there were some of those early
ones still running)
>> Also, I would really like to run this as a router/firewall appliance as
>> well
>> > so that that the box can sit on a public IP if the client only has one.
>> For
>> > this reason I kind of have my heart set on openbsd. The routing and
>> firewall
>> > utilities on openbsd are very simple to configure and easy to use. Does
>> > anyone know what limitations asterisk might have on openbsd (besides
>> lack of
>> > zaptel.. ) ? I have run asterisk 1.2.? on openbsd before and found it
>> worked
>> > pretty well.
>>
>> I run similar motherboards as routers, booting off flash too. Also running
>> Linux, but then I find the Linux firewall an easy thing to work with for
>> most simple cases.
>>
>> Watch your interrupts - especially if you're plugging in a 2nd Ethernet
>> card and a TDM card. The VIA motherboard which has 2 Ethernet ports has a
>> processor with only 64MB of cache ram. The ones I'm using have 128KB
>> cache.
>
> I don't think TDM is even a consideration - at least not right now. Do the
> boards you use have
> 2 PCI slots??
No. This is the board I'm using:
http://www.icp-epia.co.uk/index.php?act=viewProd&productId=90
Single PCI slot.
There is a 2-slot riser card which some of the wall-mount boxes provide,
but my fear would be that it forces it to share the same interrupt line on
bloth slots. I have issues with these boxes with the USB hardware which
seems to share the same IRQ as the TDM card (so I turn off USB at the BIOS
level and don't compile it inth the kernel)
> Drop me an email and I'll send you a simple shell script to setup a basic
>> firewall, do nat, etc.
>>
>> I'd probably not recomend running the router/firewall on the same box as
>> asterisk though...
>
> That'd be great thanks!
I'll send it in a separate email - I'm sure this list isn't the real
place for it:)
> Why would you not do that? security? resources? Single point of failure?
Maybe I'm just getting old and more conservative (or boring ;-) I used to
think that Linux was great, it can do anything and everything swiss army
knife style, and I did build multi-function boxes with lots of
applications on-board - eg. small office systems that would do email,
intranet, dns, dhcp, firewall, squid, etc. but these days I'm more of the
opinion that it's better to get one box to do a task, and make it do that
task really well, then they can be built out of smaller parts and
hopefully have a lesser impact on the business as a whole if they were to
fail. Have a look at this:
http://catb.org/~esr/writings/taoup/html/ch01s06.html
You just need to read the 1st page. I've been dabbling with Unix for 26
years now and have sort of come full-circle (according to the writings on
that page!) See: http://www.drogon.net/ps.txt for a full list of what runs
on my asterisk boxes.
My servers don't run anything more than they need to and don't have
packages loaded that they don't need. I could rant on all day about the
bloat I see in modern RH/Fedora/SuSe, even my favourite Debian systems,
but this isn't the place ...
> Thanks a lot for all your advice - its nice to know that this sort of setup
> is working for people. Up till now I've only run asterisk on IBM eservers
> with redundant everything - which works well - but for most small-medium
> size clients it's definitely overkill and not very elegant.
Indeed. A lot of my clients are startups (without Porsches in the car
park!), or existing businesses who take a very conservative approach to
spending money, so I take time to choose hardware that I reckon is not
going to cause me problems and make it as efficient as possible, and for
me that's anything from a 1GHz asterisk box, to a 6TB datastore.
Cheers,
Gordon
More information about the asterisk-users
mailing list