Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Slow incremental Memory usage

    Scheduled Pinned Locked Moved General pfSense Questions
    9 Posts 3 Posters 1.8k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S
      stevegingercat
      last edited by

      Hi

      I have a Alix 2-3 its been running fine and a few weeks ago I took the plunge and updated to

      2.1-RELEASE (i386)
      built on Wed Sep 11 18:16:44 EDT 2013

      I've been noticing a slow increase in memory usage over the last couple of weeks - from about 40 -50 % to about 81 % this morning ?

      Anyone have any idea what might be the cause of this and what I might do to sort it?

      I dropped into the cli and ran top - there is not much in the way of process's running

      Although I did notice an instance of tcpdump running (/usr/sbin/tcpdump -s 256 -v -S -l -n -e -ttt -i pflog0 ) is this something that is used for the gui?

      ps aux | awk '{print $2, $4, $11}' | sort -k2r | head -n 10

      Generated the following

      87220 9.3 /usr/local/bin/php
      21829 7.5 /usr/local/sbin/lighttpd
      56574 6.3 /usr/local/bin/php
      21848 5.5 /usr/local/bin/php
      22487 5.5 /usr/local/bin/php
      71213 3.2 /usr/local/sbin/dhcpd
      48058 27.5 /usr/sbin/tcpdump
      73128 2.6 /usr/local/bin/ntpd
      97218 1.3 sshd:
      66691 1.1 /usr/local/sbin/dnsmasq

      Any thoughts ides?

      TIA

      Steve

      1 Reply Last reply Reply Quote 0
      • chpalmerC
        chpalmer
        last edited by

        What packages do you have installed?

        Triggering snowflakes one by one..
        Intel(R) Core(TM) i5-4590T CPU @ 2.00GHz on an M400 WG box.

        1 Reply Last reply Reply Quote 0
        • S
          stevegingercat
          last edited by

          Its a very minimal install - no additional packages

          Running

          [2.1-RELEASE][admin@pfsense.localdomain]/root(2): pkg_info

          pkg_info: no packages installed

          Steve

          1 Reply Last reply Reply Quote 0
          • P
            phil.davis
            last edited by

            Other than firewall rules, DHCP and DNS Forwarder, whatbuilt-in features are you using? OpenVPN? Dynamic DNS? Gateways with failover/load-balancing?
            I am interested to see how much of a base configuration this happens on, because my Alix systems seem to also "lose memory" slowly over time.

            As the Greek philosopher Isosceles used to say, "There are 3 sides to every triangle."
            If I helped you, then help someone else - buy someone a gift from the INF catalog http://secure.inf.org/gifts/usd/

            1 Reply Last reply Reply Quote 0
            • S
              stevegingercat
              last edited by

              Other than firewall rules, DHCP and DNS Forwarder, whatbuilt-in features are you using?

              Not much! -
              1 custom nat rule
              Couple of firewall rules (2!) on top of a standard setup

              No ip sec
              No traffic Shaping

              What I'll do is have a look at it tomorrow and run the same ps aux command mentioned earlier and hopefully it will show us what is on the increase! (I have a feeling it may be PHP related )

              1 Reply Last reply Reply Quote 0
              • S
                stevegingercat
                last edited by

                Ok so again this morning I had a look at my machine and it's gone from 81 % to 84 % Memory usage

                ps aux | awk '{print $2, $4, $11}' | sort -k2r | head -n 10

                Every thing is exactly the same as yesterday with 1 exception!

                87220 9.3 /usr/local/bin/php
                21829 7.1 /usr/local/sbin/lighttpd
                56574 6.3 /usr/local/bin/php
                21848 5.5 /usr/local/bin/php
                22487 5.5 /usr/local/bin/php
                71213 3.2 /usr/local/sbin/dhcpd
                48058 28.4 /usr/sbin/tcpdump
                73128 2.6 /usr/local/bin/ntpd
                55669 1.3 sshd:  <–------------------------------------? sshd process is smaller?!
                66691 1.1 /usr/local/sbin/dnsmasq

                I'll run the script on 20 process and see if we can glean more info!

                87220 9.3 /usr/local/bin/php
                21829 7.1 /usr/local/sbin/lighttpd
                56574 6.3 /usr/local/bin/php
                21848 5.5 /usr/local/bin/php
                22487 5.5 /usr/local/bin/php
                71213 3.2 /usr/local/sbin/dhcpd
                48058 28.4 /usr/sbin/tcpdump
                73128 2.6 /usr/local/bin/ntpd
                55669 1.3 sshd:
                66691 1.1 /usr/local/sbin/dnsmasq
                15556 1.0 /usr/sbin/sshd
                8539 0.9 awk
                319 0.9 /sbin/devd
                67715 0.9 /bin/tcsh
                66295 0.6 login
                44703 0.6 /usr/sbin/syslogd
                16876 0.6 /usr/local/bin/rrdtool
                59592 0.6 /bin/sh
                8470 0.5 ps
                11878 0.5 /usr/sbin/inetd

                Might re start ssh process see if that makes a difference

                any thoughts on the above appreciated!

                Steve

                PS just re started and ssh is now taking up more mem
                This is strange!

                1 Reply Last reply Reply Quote 0
                • P
                  phil.davis
                  last edited by

                  It would also be useful to monitor the amount of user/kernel/free… memory splitup. If it is a memory leak in a driver or kernel module then it would not show up in a particular process.
                  I thought about doing all this, then I thought FreeBSD10, 2,2 snapshots, these sort of things could be fixed by any of 1,000 fixes to FreeBSD between 8.3 and 10.0. So I was planning to grab a 2.2 snapshot (when they start building again) and try it on Alix 2D13, then monitor that for memory.

                  As the Greek philosopher Isosceles used to say, "There are 3 sides to every triangle."
                  If I helped you, then help someone else - buy someone a gift from the INF catalog http://secure.inf.org/gifts/usd/

                  1 Reply Last reply Reply Quote 0
                  • S
                    stevegingercat
                    last edited by

                    I'll keep monitoring this - although I've also updated recently so I still don't have enough data

                    What I'm seeing is a very slow increase of Mem usage at about 1 % per day

                    I'll see if I can find any other data that may point back to a mem issue

                    Steve

                    1 Reply Last reply Reply Quote 0
                    • S
                      stevegingercat
                      last edited by

                      OK so I up dated to 2.1.3 the most recent release and for the last 3 days my memory allocation has been sitting at 46 %
                      Don't know what the dev guys did but she is looking nice and stable now!

                      Thanks

                      Steve

                      1 Reply Last reply Reply Quote 0
                      • First post
                        Last post
                      Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.