MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    mmap() failed: Cannot allocate memory

    Scheduled Pinned Locked Moved Troubleshooting
    15 Posts 2 Posters 3.7k Views 2 Watching
    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 Offline
      sdetweil @Egnos
      last edited by

      @Egnos said in mmap() failed: Cannot allocate memory:

      Mem: 924 495 54 251 374 127
      Swap: 99 99

      u always have memory available, and never consume any swap space…

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      E 1 Reply Last reply Reply Quote 0
      • E Offline
        Egnos @sdetweil
        last edited by

        @sdetweil

        pi@MagicMirror:~ $ free -m
                      total        used        free      shared  buff/cache   available
        Mem:            924         495          54         251         374         127
        Swap:            99          99           0
        
        

        I see that all swap memory is finished … “Used =99 and free=0”.
        I dont understand why it is already using swap memory if it is not out of RAM yet …

        Why the swap memory always occupied?
        Finished the task shouldn’t it free itself?

        My Mirror https://forum.magicmirror.builders/topic/17262/the-raspimirror-was-born/7

        S 3 Replies Last reply Reply Quote 0
        • S Offline
          sdetweil @Egnos
          last edited by sdetweil

          @Egnos try this

          for file in /proc/*/status ; do awk '/VmSwap|Name/{printf $2 " " $3}END{ print ""}' $file; done | sort -k 2 -n -r | less
          

          should give a list of processes using swap, most to least

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          1 Reply Last reply Reply Quote 0
          • S Offline
            sdetweil @Egnos
            last edited by

            @Egnos so, I would make the swap bigger just for for testing 1 gig

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            1 Reply Last reply Reply Quote 0
            • S Offline
              sdetweil @Egnos
              last edited by

              @Egnos try this

              pm2 stop all
              export NODE_OPTIONS=--max_old_space_size=4096
              npm start
              

              u can add that export line to the installers/mm.sh
              if using pm2

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              1 Reply Last reply Reply Quote 0
              • 1
              • 2
              • 2 / 2
              • First post
                Last post
              Enjoying MagicMirror? Please consider a donation!
              MagicMirror created by Michael Teeuw.
              Forum managed by Sam, technical setup by Karsten.
              This forum is using NodeBB as its core | Contributors
              Contact | Privacy Policy