Question

CentOS 5.3 running Asterisk low on Ram - How to free up

Asked by: shaunwingin

Say,
Asterisk is restarting with message that out of memmory.
What services and modules can I remove to reduce mem usage. The machine has 750MB of Ram.
A basic asterisk server is needed to simly transfer calls.
How can I see how much mem each service uses?
How can I see whcih modules are actually loaded in Asterisk?
Tx

This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.

Subscribe now for full access to Experts Exchange and get

Instant Access to this Solution

  • Plus...
  • 30 Day FREE access, no risk, no obligation
  • Collaborate with the world's top tech experts
  • Unlimited access to our exclusive solution database
  • Never be left without tech help again

Subscribe Now

Asked On
2009-07-21 at 12:22:39ID24588687
Topics

CentOS

,

Linux Administration

,

Asterisk Open Source Telephony

Participating Experts
1
Points
500
Comments
33

Trusted by hundreds of thousands everyday for fast, accurate and reliable tech support.

  • "The time we save is the biggest benefit of Experts Exchange to Warner Bros. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange." Mike Kapnisakis, Warner Bros.
  • "Our team likes having a resource that is more secure than just using Google and most experts using this service really know their stuff. It's nice to look here first versus using Google." Dayna Sellner, Lockheed Martin
  • "Anytime that I've been stumped with a problem, 9 out of 10 times Experts Exchange has either the accepted solution or an open discussion of the potential solution to the problem." Kenny Red, eBay Inc.

See what Experts Exchange can do for you.

Got a question?

We've got the answer.

Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.

Screenshot of Experts Exchange Knowledgebase

Need individual assistance?

Our experts are ready to help.

If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.

Screenshot of Experts Exchange Knowledgebase

Want to learn from the best?

Read articles from industry experts.

Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.

Screenshot of an Article

Working on a long term project?

Store your work and research.

Save solutions to your questions, answers you’ve discovered through searching plus helpful articles in your personal knowledgebase for easy future access.

Screenshot of Experts Exchange Knowledgebase

Access the answers to your technology questions today.

Subscribe Now

30-day free trial. Register in 60 seconds.

What Makes Experts Exchange Unique?

Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Trusted by the world's most respected brands.

image of each brand's logo

Faithfully serving IT professionals since 1996.

Experts Exchange Logo

Try it out and discover for yourself.

Subscribe Now

30-day free trial. Register in 60 seconds.

Related Solutions

  1. ASTERISK
    HOW CAN YOU MAKE A CIRCLE USING THE FIGURE * (ASTERISK)?
  2. Centos Unistall Asterisk
    Alright being kind of new to a unix enviornment and learning how to work with a pure command line interface how would one unistall an application like asterisk from the command line. I have to admit, the years of dealing windows and dos prompts have kept me in a close ended ...
  3. Asterisk install issues CentOS
    I am getting an error during the "make" portion of an asterisk install. Here are some prerequisites, that make the issue rather frustrating, but maybe someone here can shine some light: - I have done this exact same install, two times prior today, on 2 other boxes...
  4. 2 Instances of Asterisk
    Currently: Asterisk 1.4 Goal: Asterisk 1.6 BACKGROUND: This scenario is more of a learning experience for me since I'm a junior Linux admin. We can't use virtual machines. Only 1 physical test machine. Why? They didn't really say.... Anyway, it seems that Asterisk version...

Free Tech Articles

  1. WARNING: 5 Reasons why you should NEVER fix a computer for free.
    It is in our nature to love the puzzle. We are obsessed. The lot of us. We love puzzles. We love the challenge. We thrive on finding the answer. We hate disarray. It bothers us deep in our soul. W...
  2. SCCM OSD Basic troubleshooting
    SCCM 2007 OSD is a fantastic way to deploy operating systems, however, like most things SCCM issues can sometimes be difficult to resolve due to the sheer volume of logs to sift through and the dispe...
  3. Migrate Small Business Server 2003 to Exchange 2010 and Windows 2008 R2
    This guide is intended to provide step by step instructions on how to migrate from Small Business Server 2003 to Windows 2008 R2 with Exchange 2010. For this migration to work you will need the fo...
  4. Create a Win7 Gadget
    This article shows you how to create a simple "Gadget" -- a sort of mini-application supported by Windows 7 and Vista. Gadgets can be dropped anywhere on the desktop to provide instant information, ...
  5. Outlook continually prompting for username and password
    There have been a lot of questions recently regarding Outlook prompting for a username and password whilst using Exchange 2007. There are a few reasons why this would happen and I will try to cover t...
  6. Backup Exchange 2010 Information Store using Windows Backup
    There seems to be quite a lot of confusion around the ability to backup Exchange 2010 using the built in Windows Backup feature. This stems from the omission of this feature prior to Exchange 2007 s...

Cloud Class Webinars

  1. Avoiding Bugs in Microsoft Access
    Alison Balter takes and in-depth look at avoiding bugs in Access. In this webinar you will learn about using the immediate window to debug your applications, invoking the debugger, using breakpoints to troubleshoot, stepping through code, setting the next statement to execute, ...
  2. Top 10 Best New Features in Visio 2010
    Scott Helmers gives live demonstrations of the top 10 new features in Visio 2010. This webinar will teach you how to create compelling diagrams by adding shapes to the page with a single click, linking the shapes in a diagram to data in Excel (or SQL Server, or SharePoint), ...
  3. IT Consultant Business Secrets Revealed
    Michael Munger, Experts Exchange tech pro and IT consultant, pulls back the curtain on his very successful businesses and answers question on every IT consultant and business owner should know about. He shares secrets on what he did to solve the 5 most common problems in IT, ...
  4. Disaster Recovery and Business Continuity
    Quest CTO, Mike Billon, gives an overview of the steps involved in building a dunamic disaster recovery plan. Through case studies and an examination of software/hardware tooles for monitoring and testing, you'll gain a better understandin of where you are, where you want ...
  5. Organize Your Visio Diagrams with Containers and Lists
    Scott Helmers uses cross functional flowcharts, wireframe diagrams, data graphic legends and seating charts to teach you: how to ustilize all three new structured diagram components in Visio 2010, the best practices for organizeing shapes in previous version of Visio, how to organize ...
  6. How to Us Objects, Properties, Events and Methods in Microsoft Access
    Alison Dalter gives an in-depbth look at objects, properties, events and methods in Microsoft Access. In this webinar you will learn about using the object browser, referring to objects, working with properties and methods, working with object variables, understanding the ...

Join the Community

Give a Little. Get a Lot.

Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.

Join the Community

Answers

 

by: grbladesPosted on 2009-07-22 at 01:14:11ID: 24912403

You sholdnt get messages about being out of memory because there should be at least virtual memory to be used.

Run the following commands and post the output:-
uptime
free
ps ax
cat /etc/inittab | grep initdefault

 

by: shaunwinginPosted on 2009-07-22 at 01:37:40ID: 24912519


[root@Harrow ~]# uptime
 15:33:48 up 12 min,  1 user,  load average: 3.05, 5.37, 2.96
______________________________

[root@Harrow ~]# free
             total       used       free     shared    buffers     cached
Mem:        385444     380276       5168          0        536      20604
-/+ buffers/cache:     359136      26308
Swap:       786424     533380     253044
_____________________________________________________________________
[root@Harrow ~]# ps ax
  PID TTY      STAT   TIME COMMAND
    1 ?        Ss     0:01 init [3]
    2 ?        S<     0:00 [migration/0]
    3 ?        SN     0:00 [ksoftirqd/0]
    4 ?        S<     0:00 [watchdog/0]
    5 ?        S<     0:00 [events/0]
    6 ?        S<     0:00 [khelper]
    7 ?        S<     0:00 [kthread]
   10 ?        S<     0:00 [kblockd/0]
   11 ?        S<     0:00 [kacpid]
   75 ?        S<     0:00 [cqueue/0]
   78 ?        S<     0:00 [khubd]
   80 ?        S<     0:00 [kseriod]
  142 ?        S      0:00 [pdflush]
  143 ?        S      0:00 [pdflush]
  144 ?        S<     0:02 [kswapd0]
  145 ?        S<     0:00 [aio/0]
  301 ?        S<     0:00 [kpsmoused]
  326 ?        S<     0:00 [ksnapd]
  329 ?        S<     0:00 [kjournald]
  356 ?        S<     0:00 [kauditd]
  390 ?        S<s    0:00 /sbin/udevd -d
  733 ?        S<     0:00 [kgameportd]
 1177 ?        S<     0:00 [kmpathd/0]
 1199 ?        S<     0:00 [kjournald]
 1752 ?        S<sl   0:00 auditd
 1754 ?        S<sl   0:00 /sbin/audispd
 1786 ?        Ss     0:00 syslogd -m 0
 1789 ?        Ss     0:00 klogd -x
 1823 ?        Ss     0:00 portmap
 1848 ?        Ss     0:00 rpc.statd
 1881 ?        Ss     0:00 rpc.idmapd
 1908 ?        Ss     0:00 dbus-daemon --system
 2063 ?        Ss     0:00 /usr/sbin/acpid
 2115 ?        Ss     0:00 /usr/sbin/sshd
 2131 ?        Ss     0:00 xinetd -stayalive -pidfile /var/run/xinetd.pid
 2149 ?        SLs    0:00 ntpd -u ntp:ntp -p /var/run/ntpd.pid -g
 2166 ?        Ss     0:00 /usr/sbin/vsftpd /etc/vsftpd/vsftpd.conf
 2201 ?        S      0:00 /bin/sh /usr/bin/mysqld_safe --datadir=/var/lib/mysql --socket=/var/lib/mysql/mysql.sock --log-error=/var/log/mysqld.log --pid-file
 2258 ?        Sl     0:00 /usr/libexec/mysqld --basedir=/usr --datadir=/var/lib/mysql --user=mysql --pid-file=/var/run/mysqld/mysqld.pid --skip-external-lock
 2406 ?        Ss     0:00 /usr/lib/cyrus-imapd/cyrus-master -d
 2429 ?        S      0:00 idled
 2432 ?        S      0:00 imapd
 2433 ?        S      0:00 imapd -s
 2434 ?        S      0:00 pop3d
 2435 ?        S      0:00 pop3d -s
 2436 ?        S      0:00 lmtpd
 2437 ?        S      0:00 imapd
 2440 ?        S      0:00 imapd -s
 2441 ?        S      0:00 pop3d
 2442 ?        S      0:00 pop3d -s
 2445 ?        S      0:00 imapd
 2446 ?        S      0:00 pop3d
 2447 ?        S      0:00 imapd
 2448 ?        S      0:00 pop3d
 2482 ?        Ss     0:00 /usr/libexec/postfix/master
 2485 ?        S      0:00 pickup -l -t fifo -u
 2486 ?        S      0:00 qmgr -l -t fifo -u
 2500 ?        S      0:00 imapd
 2501 ?        S      0:00 imapd
 2502 ?        S      0:00 imapd
 2503 ?        S      0:00 pop3d
 2504 ?        S      0:00 imapd
 2505 ?        S      0:00 imapd
 2506 ?        S      0:00 imapd
 2507 ?        S      0:00 pop3d
 2508 ?        Ss     0:00 /usr/sbin/httpd
 2542 ?        S      0:00 /bin/sh /usr/sbin/safe_asterisk -U asterisk -G asterisk
 2551 ?        Sl     3:15 /usr/sbin/asterisk -f -U asterisk -G asterisk -vvvg -c
 2570 ?        Ss     0:00 crond
 2586 ?        S      0:00 /usr/sbin/httpd
 2587 ?        S      0:00 /usr/sbin/httpd
 2588 ?        S      0:00 /usr/sbin/httpd
 2589 ?        S      0:00 /usr/sbin/httpd
 2590 ?        S      0:00 /usr/sbin/httpd
 2591 ?        S      0:00 /usr/sbin/httpd
 2592 ?        S      0:00 /usr/sbin/httpd
 2593 ?        S      0:00 /usr/sbin/httpd
 2594 ?        Ss     0:00 /usr/sbin/atd
 2609 ?        Ss     0:00 /usr/sbin/saslauthd -m /var/run/saslauthd -a pam
 2611 ?        S      0:00 /usr/sbin/saslauthd -m /var/run/saslauthd -a pam
 2612 ?        S      0:00 /usr/sbin/saslauthd -m /var/run/saslauthd -a pam
 2613 ?        S      0:00 /usr/sbin/saslauthd -m /var/run/saslauthd -a pam
 2614 ?        S      0:00 /usr/sbin/saslauthd -m /var/run/saslauthd -a pam
 2628 ?        Ss     0:01 hald
 2629 ?        S      0:00 hald-runner
 2639 ?        S      0:00 hald-addon-acpi: listening on acpid socket /var/run/acpid.socket
 2640 ?        S      0:00 hald-addon-keyboard: listening on /dev/input/event0
 2719 ?        S      0:00 -bash -c cd /var/www/html/panel && /var/www/html/panel/safe_opserver &
 2720 ?        S      0:00 sh /var/www/html/panel/safe_opserver
 2722 ?        S      0:01 /usr/bin/perl /var/www/html/panel/op_server.pl
 3183 ?        Ss     0:00 /usr/bin/perl /usr/libexec/webmin/miniserv.pl /etc/webmin/miniserv.conf
 3186 tty1     Ss+    0:00 /sbin/mingetty tty1
 3187 tty2     Ss+    0:00 /sbin/mingetty tty2
 3188 tty3     Ss+    0:00 /sbin/mingetty tty3
 3189 tty4     Ss+    0:00 /sbin/mingetty tty4
 3190 tty5     Ss+    0:00 /sbin/mingetty tty5
 3191 tty6     Ss+    0:00 /sbin/mingetty tty6
 3266 ?        Ss     0:00 sshd: root@pts/0
 3269 pts/0    Ss     0:00 -bash
 3304 pts/0    R+     0:00 ps ax
_________________________
[root@Harrow ~]# cat /etc/inittab | grep initdefault
#   0 - halt (Do NOT set initdefault to this)
#   6 - reboot (Do NOT set initdefault to this)
id:3:initdefault:
[root@Harrow ~]#
____________________________________
During this short time I get a screen dump :
Apr 22 15:31:44 Harrow kernel: asterisk invoked oom-killer: gfp_mask=0x201d2, order=0, oomkilladj=0
Apr 22 15:31:44 Harrow kernel:  [<c0458895>] out_of_memory+0x72/0x1a5
Apr 22 15:31:44 Harrow kernel:  [<c0459d6a>] __alloc_pages+0x216/0x297
Apr 22 15:31:44 Harrow kernel:  [<c0455a0d>] page_cache_read+0x3f/0x98
Apr 22 15:31:44 Harrow kernel:  [<c0457ec4>] filemap_nopage+0x1ce/0x312
Apr 22 15:31:44 Harrow kernel:  [<c0460c8e>] __handle_mm_fault+0x178/0x8e6
Apr 22 15:31:44 Harrow kernel:  [<c0609997>] rwsem_down_read_failed+0x128/0x143
Apr 22 15:31:44 Harrow kernel:  [<c041f9a7>] __activate_task+0x1c/0x29
Apr 22 15:31:44 Harrow kernel:  [<c060acb3>] do_page_fault+0x20a/0x4b8
Apr 22 15:31:44 Harrow kernel:  [<c060aaa9>] do_page_fault+0x0/0x4b8
Apr 22 15:31:44 Harrow kernel:  [<c0405a71>] error_code+0x39/0x40
Apr 22 15:31:44 Harrow kernel:  =======================
Apr 22 15:31:44 Harrow kernel: Mem-info:
Apr 22 15:31:46 Harrow kernel: DMA per-cpu:
Apr 22 15:31:47 Harrow kernel: cpu 0 hot: high 0, batch 1 used:0
Apr 22 15:31:47 Harrow kernel: cpu 0 cold: high 0, batch 1 used:0
Apr 22 15:31:47 Harrow kernel: DMA32 per-cpu: empty
Apr 22 15:31:47 Harrow kernel: Normal per-cpu:
Apr 22 15:31:47 Harrow kernel: cpu 0 hot: high 186, batch 31 used:44
Apr 22 15:31:47 Harrow kernel: cpu 0 cold: high 62, batch 15 used:14
Apr 22 15:31:47 Harrow kernel: HighMem per-cpu: empty
Apr 22 15:31:47 Harrow kernel: Free pages:        3916kB (0kB HighMem)
Apr 22 15:31:47 Harrow kernel: Active:34714 inactive:56615 dirty:0 writeback:0 unstable:0 free:979 slab:1877 mapped-file:946 mapped-anon:90108 pagetables:951
Apr 22 15:31:47 Harrow kernel: DMA free:1572kB min:104kB low:128kB high:156kB active:5372kB inactive:5196kB present:16384kB pages_scanned:48959 all_unreclaim$
Apr 22 15:31:47 Harrow kernel: lowmem_reserve[]: 0 0 367 367
Apr 22 15:31:47 Harrow kernel: DMA32 free:0kB min:0kB low:0kB high:0kB active:0kB inactive:0kB present:0kB pages_scanned:0 all_unreclaimable? no
Apr 22 15:31:47 Harrow kernel: lowmem_reserve[]: 0 0 367 367
Apr 22 15:31:47 Harrow kernel: Normal free:2344kB min:2400kB low:3000kB high:3600kB active:133484kB inactive:221264kB present:376768kB pages_scanned:612016 a$
Apr 22 15:31:47 Harrow kernel: lowmem_reserve[]: 0 0 0 0
Apr 22 15:31:47 Harrow kernel: HighMem free:0kB min:128kB low:128kB high:128kB active:0kB inactive:0kB present:0kB pages_scanned:0 all_unreclaimable? no
Apr 22 15:31:47 Harrow kernel: lowmem_reserve[]: 0 0 0 0
Apr 22 15:31:47 Harrow kernel: DMA: 1*4kB 0*8kB 0*16kB 1*32kB 0*64kB 0*128kB 0*256kB 1*512kB 1*1024kB 0*2048kB 0*4096kB = 1572kB
Apr 22 15:31:47 Harrow kernel: DMA32: empty
Apr 22 15:31:47 Harrow kernel: Normal: 0*4kB 1*8kB 0*16kB 3*32kB 1*64kB 1*128kB 0*256kB 0*512kB 0*1024kB 1*2048kB 0*4096kB = 2344kB
Apr 22 15:31:47 Harrow kernel: HighMem: empty
Apr 22 15:31:47 Harrow kernel: 1450 pagecache pages
Apr 22 15:31:47 Harrow kernel: Swap cache: add 199073, delete 198848, find 225/508, race 0+0
Apr 22 15:31:47 Harrow kernel: Free swap  = 0kB
Apr 22 15:31:47 Harrow kernel: Total swap = 786424kB
Apr 22 15:31:47 Harrow kernel: Free swap:            0kB
Apr 22 15:31:47 Harrow kernel: 98288 pages of RAM
Apr 22 15:31:47 Harrow kernel: 0 pages of HIGHMEM
Apr 22 15:31:47 Harrow kernel: 1943 reserved pages
Apr 22 15:31:47 Harrow kernel: 9992 pages shared
Apr 22 15:31:47 Harrow kernel: 225 pages swap cached
Apr 22 15:31:47 Harrow kernel: 0 pages dirty
Apr 22 15:31:47 Harrow kernel: 0 pages writeback
Apr 22 15:31:47 Harrow kernel: 946 pages mapped
Apr 22 15:31:47 Harrow kernel: 1877 pages slab
Apr 22 15:31:47 Harrow kernel: 951 pages pagetables
Apr 22 15:31:47 Harrow kernel: Out of memory: Killed process 2551 (asterisk).

 

by: grbladesPosted on 2009-07-22 at 02:05:35ID: 24912679

The machine appears to have 384MB not 750MB (assuming you mean 768MB) of memory.

However you are using 530MB of swap and the memory you have is being used mostly by 360MB of cache/buffers. Thats a lot.
My older asterisk system is using no swap and 240MB in buffers so something is wrong on your system somewhere.

Try using 'ps axv' as it will show the % of ram each process is using.
Also try stopping asterisk and using 'free' again to see if it is asterisk using all the memory.

 

by: shaunwinginPosted on 2009-07-22 at 03:03:01ID: 24912956

I made a mistake on the Ram. I've upgraded it now to 512MB

WITH ASTERISK
[root@Harrow ~]# free
             total       used       free     shared    buffers     cached
Mem:        515492     112552     402940          0       1804      41460
-/+ buffers/cache:      69288     446204
Swap:       786424      52212     734212

_________________________________
WITHOUT ASTERISK
# free
             total       used       free     shared    buffers     cached
Mem:        515492      63744     451748          0       1080      40628
-/+ buffers/cache:      22036     493456
Swap:       786424      52052     734372

_________________________________
  PID TTY      STAT   TIME  MAJFL   TRS   DRS   RSS %MEM COMMAND
    1 ?        Ss     0:09    328    31  2040   164  0.0 init [3]
    2 ?        S<     0:00      0     0     0     0  0.0 [migration/0]
    3 ?        RN     0:00      0     0     0     0  0.0 [ksoftirqd/0]
    4 ?        S<     0:00      0     0     0     0  0.0 [watchdog/0]
    5 ?        S<     0:00      0     0     0     0  0.0 [events/0]
    6 ?        S<     0:00      0     0     0     0  0.0 [khelper]
    7 ?        S<     0:00      0     0     0     0  0.0 [kthread]
   10 ?        S<     0:01      0     0     0     0  0.0 [kblockd/0]
   11 ?        S<     0:00      0     0     0     0  0.0 [kacpid]
   75 ?        S<     0:00      0     0     0     0  0.0 [cqueue/0]
   78 ?        S<     0:00      0     0     0     0  0.0 [khubd]
   80 ?        S<     0:00      0     0     0     0  0.0 [kseriod]
  144 ?        S<     3:21      0     0     0     0  0.0 [kswapd0]
  145 ?        S<     0:00      0     0     0     0  0.0 [aio/0]
  301 ?        S<     0:00      0     0     0     0  0.0 [kpsmoused]
  326 ?        S<     0:00      0     0     0     0  0.0 [ksnapd]
  329 ?        S<     0:10      0     0     0     0  0.0 [kjournald]
  356 ?        S<     0:00      0     0     0     0  0.0 [kauditd]
  390 ?        S<s    0:00    109    67  2088   320  0.0 /sbin/udevd -d
  934 ?        S<     0:00      0     0     0     0  0.0 [kgameportd]
 1178 ?        S<     0:00      0     0     0     0  0.0 [kmpathd/0]
 1200 ?        S<     0:00      0     0     0     0  0.0 [kjournald]
 1754 ?        S<sl   0:01    195   102 12029   276  0.0 auditd
 1756 ?        S<sl   0:02    138    68 13003   244  0.0 /sbin/audispd
 1787 ?        Ss     0:05    225    31  1692   188  0.0 syslogd -m 0
 1791 ?        Ss     0:01     54    21  1654    36  0.0 klogd -x
 1825 ?        Ss     0:00      1    30  1781     4  0.0 portmap
 1850 ?        Ss     0:00      1    43  1916     8  0.0 rpc.statd
 1883 ?        Ss     0:05    310    27  5448    60  0.0 rpc.idmapd
 1910 ?        Ss     0:00      0   340  2411     0  0.0 dbus-daemon --system
 2065 ?        Ss     0:00      0    15  1656     0  0.0 /usr/sbin/acpid
 2095 ?        Ss     0:03     68   369  6710   548  0.1 /usr/sbin/sshd
 2133 ?        Ss     0:00      0   154  2573     4  0.0 xinetd -stayalive -pidf
 2151 ?        SLs    0:00      6   458  3917  4376  0.8 ntpd -u ntp:ntp -p /var
 2168 ?        Ss     0:00      0   123  4996   172  0.0 /usr/sbin/vsftpd /etc/v
 2203 ?        S      0:00      0   691  3836   624  0.1 /bin/sh /usr/bin/mysqld
 2260 ?        Sl     1:43   5400  6397 130330 2320  0.4 /usr/libexec/mysqld --b
 2408 ?        Ss     1:20   2997    69 17194  1224  0.2 /usr/lib/cyrus-imapd/cy
 2435 ?        S      0:38    971   874 29085   140  0.0 idled
 2437 ?        S      0:00     12  1179 30272   692  0.1 imapd
 2438 ?        S      0:00     12  1179 30272   692  0.1 imapd -s
 2439 ?        S      0:00      8   906 30245   692  0.1 pop3d
 2440 ?        S      0:00      7   906 30241   692  0.1 pop3d -s
 2441 ?        S      0:00      9   986 30257   692  0.1 lmtpd
 2443 ?        S      0:00      5  1179 30272   692  0.1 imapd
 2444 ?        S      0:00      6  1179 30268   692  0.1 imapd -s
 2445 ?        S      0:00      6   906 30245   692  0.1 pop3d
 2446 ?        S      0:00      4   906 30241   692  0.1 pop3d -s
 2480 ?        Ss     0:04    223   123  6656   940  0.1 /usr/libexec/postfix/ma
 2483 ?        S      0:02    189   184  6655   856  0.1 pickup -l -t fifo -u
 2484 ?        S      0:00    156   244  6659   764  0.1 qmgr -l -t fifo -u
 2498 ?        S      0:00      0  1179 30268   692  0.1 imapd
 2499 ?        S      0:00      0  1179 30268   692  0.1 imapd
 2500 ?        S      0:00      0  1179 30268   692  0.1 imapd
 2501 ?        S      0:00      0  1179 30268   692  0.1 imapd
 2502 ?        S      0:00      0   906 30241   692  0.1 pop3d
 2503 ?        S      0:00      0   906 30241   692  0.1 pop3d
 2504 ?        S      0:00      0  1179 30268   692  0.1 imapd
 2505 ?        S      0:00      0  1179 30268   692  0.1 imapd
 2506 ?        S      0:00      0  1179 30268   692  0.1 imapd
 2507 ?        S      0:00      0  1179 30268   692  0.1 imapd
 2508 ?        S      0:00      0   906 30241   692  0.1 pop3d
 2509 ?        S      0:00      0   906 30245   692  0.1 pop3d
 2510 ?        Ss     1:06   2796   297 25230  1260  0.2 /usr/sbin/httpd
 2544 ?        S      0:00    285   691  3844   736  0.1 /bin/sh /usr/sbin/safe_
 2572 ?        Ss     0:04    175    46  5225   592  0.1 crond
 2579 ?        S      0:00      0   297 25366   316  0.0 /usr/sbin/httpd
 2580 ?        S      0:00      0   297 25366   316  0.0 /usr/sbin/httpd
 2581 ?        S      0:00      0   297 25366   316  0.0 /usr/sbin/httpd
 2582 ?        S      0:00      0   297 25366   316  0.0 /usr/sbin/httpd
 2583 ?        S      0:00      0   297 25366   316  0.0 /usr/sbin/httpd
 2591 ?        S      0:00      0   297 25366   316  0.0 /usr/sbin/httpd
 2592 ?        S      0:00      0   297 25366   316  0.0 /usr/sbin/httpd
 2593 ?        S      0:00      0   297 25366   316  0.0 /usr/sbin/httpd
 2596 ?        Ss     0:01     78    17  2234   288  0.0 /usr/sbin/atd
 2611 ?        Ss     0:00      0    78  5445   368  0.0 /usr/sbin/saslauthd -m
 2614 ?        S      0:00      0    78  5445   104  0.0 /usr/sbin/saslauthd -m
 2615 ?        S      0:00      0    78  5445    92  0.0 /usr/sbin/saslauthd -m
 2616 ?        S      0:00      0    78  5445    92  0.0 /usr/sbin/saslauthd -m
 2617 ?        S      0:00      0    78  5445    92  0.0 /usr/sbin/saslauthd -m
 2630 ?        Ss     0:42   2382   257  5146  1264  0.2 hald
 2631 ?        S      0:00      0    10  3117   416  0.0 hald-runner
 2639 ?        S      0:00      8     9  1994   528  0.1 hald-addon-acpi: listen
 2642 ?        S      0:00     33     9  1990   560  0.1 hald-addon-keyboard: li
 2720 ?        S      0:00      0   691  3840   156  0.0 -bash -c cd /var/www/ht
 2721 ?        S      0:00      0   691  3792   552  0.1 sh /var/www/html/panel/
 2723 ?        S      1:20   6089     9 12238  2896  0.5 /usr/bin/perl /var/www/
 3185 ?        Ss     0:55   2566     9 14502  1104  0.2 /usr/bin/perl /usr/libe
 3189 tty2     Ss+    0:00      0     8  1655   408  0.0 /sbin/mingetty tty2
 3190 tty3     Ss+    0:00      0     8  1651   408  0.0 /sbin/mingetty tty3
 3191 tty4     Ss+    0:00      0     8  1655   408  0.0 /sbin/mingetty tty4
 3192 tty5     Ss+    0:00      0     8  1655   408  0.0 /sbin/mingetty tty5
 3193 tty6     Ss+    0:00      0     8  1655   408  0.0 /sbin/mingetty tty6
 3542 ?        S      0:00      0     0     0     0  0.0 [pdflush]
 3888 ?        S      0:00      0     0     0     0  0.0 [pdflush]
 3906 ?        Ss     0:00     18   369  6710  2144  0.4 sshd: [accepted]
 3908 ?        Ss     0:00     15   369  9562  2840  0.5 sshd: root@pts/0
 3916 ?        Sl     0:58    102   912 310611 292320 56.7 /usr/sbin/asterisk -f
 3937 pts/0    Ss     0:00      1   691  3844  1488  0.2 -bash
 3988 tty1     Ss+    0:00      1     8  1655   476  0.0 /sbin/mingetty tty1
 3998 pts/0    R+     0:00      1    69  4134   860  0.1 ps axv

PLEASE HELP

 

by: grbladesPosted on 2009-07-22 at 03:15:12ID: 24913013

WITH ASTERISK
[root@Harrow ~]# free
             total       used       free     shared    buffers     cached
Mem:        515492     112552     402940          0       1804      41460
-/+ buffers/cache:      69288     446204
Swap:       786424      52212     734212

At that point in time you had 400MB of free memory so it should have been fine. You are using about 160MB of memory but in your previous post the machine was using over 800MB and then completely used up all the available swap space and then had problems.
Perhaps it gradually uses up memory over the course of a few minutes?

I would keep an eye on the swap usage using the 'free' command and when it gets high (over 500MB used) then use the 'ps axv' to see what is using all of it.

 

by: shaunwinginPosted on 2009-07-22 at 03:47:31ID: 24913196

Yes, its definately using up memory over time -as I rebooted to add the memory.
This is after time:
NO ASTERISK:
[root@Harrow ~]# free
             total       used       free     shared    buffers     cached
Mem:        515492     105228     410264          0       4896      76508
-/+ buffers/cache:      23824     491668
Swap:       786424      51640     734784
___________________________
ASTERISK LOADED
4121 pts/0    Sl     1:08     15   912 355919 338680 65.7 /usr/sbin/asterisk -f -vvvg -c
AND
 4121 pts/0    Sl     1:44     15   912 532715 468652 90.9 /usr/sbin/asterisk -f -vvvg -c
__________[root@Harrow ~]# free
             total       used       free     shared    buffers     cached
Mem:        515492     509608       5884          0        248      20676
-/+ buffers/cache:     488684      26808
Swap:       786424     235692     550732
___________________
WÙHAT CAN I DO?
Asterisk 1.4.24

 

by: grbladesPosted on 2009-07-22 at 03:54:23ID: 24913216

First I would upgrade asterisk to 1.4.26 as there have been 4 months and 4 releases between the version you are running and the latest.

You could also stop running op_server to see if that is the cause.

If none of those help then it may be a configuration item which is causing a problem.

 

by: shaunwinginPosted on 2009-07-22 at 04:10:51ID: 24913328

"You could also stop running op_server to see if that is the cause."
How please?

 

by: grbladesPosted on 2009-07-22 at 05:39:47ID: 24913994

That depends on how it was installed. List the startup files in /etc/init.d/. One of those should have an ovious name and can be used to start and stop it.

 

by: shaunwinginPosted on 2009-07-22 at 05:59:58ID: 24914201

Are all files below run on startup?
I can't see the obvious one.
Do I need all of these below for a basic system? What can I stop and how do I stop them?

[root@Harrow init.d]# ls
acpid        dhcrelay   krb524        multipathd  pppoe         sshd
asterisk     functions  kudzu         mysqld      psacct        syslog
atd          gpm        LCDd          netconsole  rdisc         vsftpd
auditd       haldaemon  lcdelastix    netfs       restorecond   wanrouter
capi         halt       lm_sensors    netplugd    rpcgssd       webmin
crond        httpd      lvm2-monitor  network     rpcidmapd     wpa_supplicant
cyrus-imapd  hylafax    mailman       nfs         rpcsvcgssd    xinetd
dahdi        iaxmodem   mcstrans      nfslock     saslauthd
dc_client    ip6tables  mdmonitor     ntpd        single
dc_server    iptables   mdmpd         openfire    snmpd
dhcdbd       isdn       messagebus    portmap     snmptrapd
dhcpd        killall    mISDN         postfix     spamassassin
[root@Harrow init.d]#

 

by: shaunwinginPosted on 2009-07-22 at 06:06:34ID: 24914277

[root@Harrow init.d]# service --status-all
acpid (pid 2066) is running...
asterisk (pid 6073) is running...
atd (pid 6136) is running...
auditd (pid 1755) is running...
capi not installed - No such file or directory (2)
crond (pid 6112) is running...
cyrus-master (pid 5614) is running...
### Span  1: DAHDI_DUMMY/1 "DAHDI_DUMMY/1 (source: RTC) 1" (MASTER)
dc_client is stopped
dc_server is stopped
dhcpd is stopped
dhcrelay is stopped
gpm is stopped
hald (pid 6233) is running...
httpd (pid 6133 6132 6121 6120 6119 6118 6117 6116 5987) is running...
HylaFAX client-server protocol server: hfaxd is stopped
HylaFAX queue manager process: faxq is stopped
iaxmodem is stopped
Firewall is stopped.
Firewall is stopped.
krb524d is stopped
LCDd is stopped
lcdelastixd is stopped
mailman is stopped
mcstransd is stopped
mdadm is stopped
mdmpd is stopped
dbus-daemon (pid 1911) is running...
Usage: /usr/sbin/mISDN start|stop|restart|config|scan|help
multipathd is stopped
mysqld (pid 21156) is running...
netconsole module not loaded
netplugd is stopped
Configured devices:
lo eth0 eth1 ppp0
Currently active devices:
lo eth1 eth0
rpc.mountd is stopped
nfsd is stopped
rpc.statd (pid 1851) is running...
ntpd (pid 2152) is running...
openfire is not running
portmap (pid 1826) is running...
master (pid 5843) is running...
pppoe-status: Link is down (can't read pppoe PID file /var/run/pppoe.conf-pppoe.pid.pppoe)
Process accounting is disabled.
rdisc is stopped
rpc.idmapd (pid 1884) is running...
saslauthd (pid 6193 6192 6191 6190 6172) is running...
snmpd is stopped
snmptrapd is stopped
spamd is stopped
sshd (pid 17469 2118) is running...
syslogd (pid 1789) is running...
klogd (pid 1792) is running...
vsftpd (pid 2169) is running...

Router is stopped !

webmin (pid 12558) is running
wpa_supplicant is stopped
xinetd (pid 2134) is running...

 

by: shaunwinginPosted on 2009-07-22 at 06:07:52ID: 24914293

BTW, I used the Elastix compialtion to install the system. Can you recomend an installation that gives a good basic setup of asterisk on a clean PC? I need A2 Billing installed along with it and My SQL.

 

by: grbladesPosted on 2009-07-22 at 06:40:01ID: 24914680

The op_panel must be included as part of the elastix configuration tools.
What you have running looks fine.


You could have a look at Trixbox (http://www.trixbox.org/) which is a complete installation so you dont have to install centos first etc...
The advantage is that it generally works straight away but the disadvantage is that if you want to install any different software aswell then this can be more difficult because you are not starting from a known distribution which you can easily get software packages for.

 

by: shaunwinginPosted on 2009-07-22 at 06:54:35ID: 24914860

Tx. I have a Trixbox 2.4 version. How can I upgrade it to the latest 2.6 stable version?

 

by: grbladesPosted on 2009-07-22 at 06:59:11ID: 24914904

Sorry I dont know. I dont use trixbox myself.

 

by: shaunwinginPosted on 2009-07-22 at 07:10:04ID: 24915055

No problem.What do you use if I may ask?
I'm trying to setup an Asterisk server to work as a switch and handle about 300 simultaneous calls.

 

by: grbladesPosted on 2009-07-22 at 07:21:09ID: 24915210

I have been using Linux for a long time so I tend to install asterisk from source code and configure it directly from the config files.
Its the most complex way to do it but it gives a very streamlined install and means that I can configure it to do exactly what I want and I am not limited to what can be done within a web based configuration tool.

 

by: shaunwinginPosted on 2009-07-22 at 07:47:20ID: 24915545

Tx. Do you recomend the 1.6 version for a production site yet?

 

by: grbladesPosted on 2009-07-22 at 07:59:45ID: 24915735

Have a look at http://www.asterisk.org/node/48602
I would say 1.6.0 is stable enough having been available for around 9 months.
1.6.1 may still be a little new for full commercial use.

 

by: shaunwinginPosted on 2009-07-23 at 03:26:02ID: 24923470

Thanks.
I would prefer to stay with exisiting Asterisk install and its clearly and issue of * using up Ram over time.
I wish to install the newer 1.4 version - how do I do it - whithout destroying config files? Do I remove the older version 1st?
If this doesn't help then how do I find the config issue?
Btw ps avx is G8. How can I sort by Mem usage?

 

by: grbladesPosted on 2009-07-23 at 03:48:23ID: 24923599

It should just be a case of installing the new version of asterisk. When you install it, it will just install the binaries. When doing the 1st install there is a separate command to install example configuration.

Cant remember how to sort by mem usage off hand. I am out of the office at the moment so no access to a linux machine to check. You can do 'man ps' to bring up the manual page for using the command.

 

by: shaunwinginPosted on 2009-07-23 at 03:55:14ID: 24923642

Tx. Please have a look when you can as I tried using the man pages - but couldn't understand how to sort by %mem column. it was something like -o= but -o=%mem didn't help.

 

by: grbladesPosted on 2009-07-23 at 10:42:46ID: 24927911

This is the best I could come up with. The 'k' specifies the sorting order but you have far fewer options which you can sort on so you have to sort by the virtual memory size which is not quite the same thing.

ps axvk vsz

 

by: shaunwinginPosted on 2009-07-23 at 11:33:56ID: 24928508

Tx very much this helps a lot .I'm planning to start from scratch with Trix Box as I've hit a snag with drive space when compiling asterisk - with a NO DRIVE SPACE ERROR.

df
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
                       8824112   8809452         0 100% /
/dev/hdc1               101086     18827     77040  20% /boot
tmpfs                   257744         0    257744   0% /dev/shm


Would like ot know what is going on though as not wure what is SWAP and what is the rest....

 

by: grbladesPosted on 2009-07-23 at 11:41:17ID: 24928608

9GB for linux is a bit small.

1st line is your main operating system drive
2nd line is the boot partition. It just contains the operating system kernel and boot configuration. The idea of it being kept separate is that the partition will rarely be written to so even if the computer gets reset the data should not become at all corrupt so it will boot. At that point if there is a problem with the main partition it can fix itself since the full operating system code has loaded.
The 3rd line is basically a ramdisk. Its dynamic so if you dont save to it then it wont use any computer memory so no harm it being there.
Since swap isnt a file system it is not listed. The 'free' command tells you how much swap you have used and free.

 

by: shaunwinginPosted on 2009-07-23 at 12:11:40ID: 24928948

Tx very much.

 

by: shaunwinginPosted on 2009-07-23 at 12:29:10ID: 24929117

What directories can I delete if I just need a basic Asterisk system so that I can get by on 9Gig?

 

by: grbladesPosted on 2009-07-23 at 12:46:51ID: 24929269

You cant really delete directories due to the way Linux works in that programs store executables and data files in lots of places. You can remove packages.

"rpm -qa | sort" will give you a list of packages. There will be lots of them but you need to know what they are to know if you need them or not.

 

by: shaunwinginPosted on 2009-07-23 at 13:14:19ID: 24929454

Tx. I've tried rpm -e <package> but gives error " failed dependencies" ?

 

by: grbladesPosted on 2009-07-23 at 13:43:23ID: 24929718

It should list the dependencies. Basically the dependencies rely on the program you are deinstalling. If you dont need the dependencies then specify them on the same command line.

 

by: shaunwinginPosted on 2009-07-24 at 03:47:07ID: 24933607

I've now loaded TrixBox but on 1st boot it hangs with message op_server.pl: no process killed. Any ideas please?

 

by: grbladesPosted on 2009-07-24 at 03:56:50ID: 24933643

Sorry no ideas. Trixbox have their own forums so that is probably the best place to ask.

 

by: shaunwinginPosted on 2009-07-24 at 04:07:50ID: 24933692

Tx

20120131-EE-VQP-002

3 Ways to Join

30-Day Free Trial

The Experts

98% positive feedback on 31,087 answers since March 2000. angeliii is a Microsoft Most Valuable Professional for his work with MS SQL Server & Develoment.

He has also proven his knowledge of Visual Basic Programming, PHP Scripting and Oracle Databases.

The Experts

97% positive feedback on 10,752 answers since July 2000. lrmoore has more than 18 years experience in the networking industry.

The six-time Mircosoft MVPs specialties include firewalls, virtual private networking, and network management.

Testimonials

"...and excellent source for support... Kind of like having your very own IT dept." Electriciansnet

Testimonials

"I was apprehensive at signing up at first. However... it has already made my life as an IT administrator much easier." JaCrews

Testimonials

"WOW! You guys have great, active, and knowledgeable people on here." moore50

Business Clients

Business Clients

In the Press

"If you’ve got a question... Experts Exchange can supply an answer.”

In the Press

"...an invaluable aid for both IT professionals and those who require tech support."

In the Press

"where IT professionals provide quick answers on just about any topic"

Business Account Plans

Loading Advertisement...