Asterisk and X [was: Re: [Asterisk-Users] zaptel PRI drivers]

Tom tom at technerve.com
Mon Mar 21 08:57:14 MST 2005


Quoting Tzafrir Cohen <tzafrir at cohens.org.il>:

> On Sun, Mar 20, 2005 at 11:12:22PM -0700, Tom wrote:
> >
> > I have a quick question.
> > I know that running X on an asterisk server is not officially "supported",
>
> Generally it shouldn't cause "errors", but will probably degregate
> performance, as an X server is probably as close as Asterisk is to the
> hardware and optimized just as well for minimal latency.
>
We experience the exact opposite, even when we are getting these HDLC errors we
never have experienced call quality issues.  I would be willing to ignore the
errors, but our provider doesn't see it that way as their techs get pages
constantly about them.
> > however, I've never had any trouble with it until now (8 months, using
> wctdm
> > cards with fxo and fxs ports, IAX trunks, SIP phones, everything except a
> PRI
> > card).  Now I just installed my first asterisk box that terminates a PRI,
> and
> > bam, HDLC errors up the wazoo if X is running, if its not, everything is
> fine,
> > I assume this is because the timing parameters for the PRI are so much more
> > strick.
>
> Why do you need the X server running at all?
>
> Is Asterisk running as root? With real-time priority? (-p)
>
> What distro do you use, BTW?
>
This is running on Fedora Core 3, and yes asterisk is running as root with -p
I get PRI HDLC errors whenever X is enabled.
> >
> > I don't mind if X is a little less responsive (even alot less
> > responsive), but I would really like to be able to run X on a server
> > with a PRI.  Is there any way to reduce X11's priority so that it
> > doesn't interfere with the zaptel driver for the PRI... I've tried
> > renicing X as far down as I can and renicing Asterisk up as far as I
> > can, however I fear this won't ever fix the problem since I think the
> > actual kernel module that is running the pri card needs to get higher
> > priority (ie, the kernel itself needs higher priority).
> >
>
> What exactly do you run on X? Is the CPU very busy? try a light
> interface such as icewm, windowmaker or fluxbox with a theme that uses
> no gradients and no special effects.
>
> If your display has a little resolution, try something like matchbox.
>
The CPU is never very busy as I stated in my original post ~3% average usage

> > Is there any
> > way to do this?  Am I correct in my analysis?  I really don't
> > understand why on a system
> > that averages less than 3% CPU usage with X running, why it can't handle
> the
> > PRI.  I know for whatever reason X always gets a really high priority
> (although
> > top doesn't show X getting any special treatment its PR 15 NICE 0 by
> default,
> > lower than most other processes on the system).
> >
> > Another idea is that right now the system is only a single proc, but it is
> dual
> > proc capable.  Would this somehow help if we added the second proc?  My
> > thinking is it won't because it's a kernel module we are dealing with, and
> > because of that I can't control the affinity of the driver (I was thinking
> at
> > one point put X11 on 1 proc and Asterisk on the second, but it's not
> Asterisk
> > that has the problem I don't think.)
> >
> > My final idea is that currently the system has an onboard 8mb ati graphic
> card
> > that leaves almost all actual graphics processing to the CPU, could adding
> a
> > better graphics card possibly help X use less cpu and not get in the way so
> > much?
> >
> > Anyway, I know this isn't a supported setup, so if thats your answer don't
> > bother replying, I'm know this will be a kludge/hack to get working (if I
> can
> > get it working at all).  I'm just trying to do something that will be
> > convienient for me and my users, there are other systems running on the
> server
> > that I don't want to manage through the CLI, and the users don't know how
> to
> > manage through the CLI, and there is no web management for them.
>
> You want to run a full desktop just be able to manage the Asterisk box?
> That's what ssh is for.
>
> Xorcom Rapid added a menu application for managing the box for those who
> don't know the command to type. If you have an X server on your
> workstation you can run X programs on your local X server. There should
> be no need for a local X server on the Asterisk box.
>
This is not to manage asterisk.  Asterisk has plenty of web based admin suites,
none of which are installed, as I generally like working on the CLI, and manage
asterisk that way just fine.  However, we have a couple of very large in-house
apps that run on X to manage some other things (in-house proprietary stuff). 
That is the primary function of this box, and we added * to this box after the
fact with a couple wctdm cards, it worked very well but we just upgraded our
pstn interface from old analog lines to a PRI, so we needed to upgrade the
asterisk box as well...
> >
> > Does anyone have success running X on an asterisk box that terminates a
> PRI?
> > If so what hardware (video card, cpu, ram, mobo, etc)?
> >
> > Thanks as I know this setup isn't supported, and I'm probably asking alot,
> don't
> > think I'm just relying on the list for bizarre things, I've been trying
> various
> > ways of doing this for the last 3 weeks, I can successfully run a vnc
> server on
> > the box (without X running) and everything works, so for whatever reason it
> is
> > getting a lower priority or something.  I really need to run GDM though as
> > managing VNC passwords/usernames/desktop settings is quite cumbersome and
> if we
> > can just get GDM running, we can use our ldap authentication server for
> logins
> > to this box (which is what we were doing previously when we didn't have a
> PRI
> > terminated on this box).
>
> VNC is a protocol for remotely controling a desktop. There are several
> ways of working with GDM. One useful way is to run a local XVnc server.
> This requires no GDM at all, unless you want a separate user and
> separate desktop for each real user (and waste tons of memory on that).
This is exactly what I want, because memory is cheap compared to my time fixing
permissions/forgotten passwords/etc that will happen if we can't manage these
passwords in LDAP.  The box has 4GB, it never uses more than 1.5GB, and a lack
of memory is not the problem.
>
> Still, why waste all of those resources of your * box?

This box never was primarily an * box, it is a server that people have used VNC
from windows desktops to run a couple of apps that are X11 only that we need in
house.  We just have been trying to get off of our old PBX, and onto * as our
primary system, and it's been working fine with the wctdm haven't seen any
degredation of voice quality, call quality, anything previous to this.  We run
the GDM system so that users can sign on with their same username/password, and
they get their same groups/restrictions etc all through LDAP, this has been
working for 2 years now.  We don't want to set up 45 user accounts locally on
the box, set up separate passwords, have the users manually keep those
passwords in sync, and then have separate passwords (again!) for vnc, which is
what we have to do if we can't get GDM/xdm/kdm and XDMCP to work.  There are
never more than 3-5 people logged in at once, and as I said previously this was
all working just fine with wctdm cards, its just the wcte110p that has issues,
and those are that it can't keep the timing right (according to our provider)
when X is enabled.  Our provider and our asterisk box get flooded with HDLC
Abort(6) errors.  We don't want to have to spend an extra 3 grand for another
server just to take up more space when we have this box that is sitting here
idle 99% of the time, and as it has worked spectacularly well with the wctdm
cards, I don't see why it can't with the wcte110p/PRI.
Tom Christensen
>
> --
> Tzafrir Cohen         | New signature for new address and  |  VIM is
> http://tzafrir.org.il | new homepage                       | a Mutt's
> tzafrir at cohens.org.il |                                    |  best
> ICQ# 16849755         | Space reserved for other protocols | friend
> _______________________________________________
> Asterisk-Users mailing list
> Asterisk-Users at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-users
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users
>






More information about the asterisk-users mailing list