603,872 active members*
6,288 visitors online*
Register for free
Login
Results 1 to 3 of 3
  1. #1
    Join Date
    Aug 2014
    Posts
    257

    PP Memory Swapping

    Since running PPv2.x from the desktop I've noticed unusual swapping occurring even though there has been plenty of system memory available. I've been running 8GB of system memory with 2GB swap file so there should not be any swapping happening.

    So I was surprised to see swapping going on with plenty of main memory available. Although I never experienced any noticeable problems with this I had purposely installed 8GB to prevent swapping especially since I run multiple applications while running PP.

    For most people not using the desktop or just using the standard PP install this probably is not applicable, but it wouldn't hurt to check.

    Anyway, I finally figured out the default "Locked Memory Limit" for PPv2.x is only set for 64 & by increasing this to 2048 I've eliminated my swapping concerns.
    Note: You need to have enough main memory to do this.

    First, check the current value in effect using the terminal command:
    $ operator@tormachpcnc:~$ ulimit -l
    Then you can change this setting by creating the following file:
    $ operator@tormachpcnc:~$ sudo gedit /etc/security/limits.d/linuxcnc.conf
    Note: The password should be "tormach"

    Enter the following line:
    * - memlock 2048
    and save the file.

    After rebooting you should see the new value in effect and there should not be any swapping going on.

    This is documented here: Increase the locked memory limit

  2. #2
    Join Date
    Jul 2017
    Posts
    70

    Re: PP Memory Swapping

    Did you ever see the error message in the linuxcnc logs that is documented?
    ERROR: failed to map shmem

    I'd guess you're hitting the linux control group limits instead which is forcing some swapping on your custom system.

  3. #3
    Join Date
    Aug 2014
    Posts
    257

    Re: PP Memory Swapping

    Hmm, not so happy anymore. Could not find any 'shmem' errors & after removing the "linuxcnc.conf" file from my system it was still not swapping with the default value of 64.

    Since I recently restored my system all I can think of is that I must have installed something before the restore that was causing the issue. So what ever it is I installed I did so on my other machine as it is prematurely swapping also. I'll have to go back through my installs and find the culprit.

    Thanks for the sanity check ...

Similar Threads

  1. Swapping out tube for solidstate
    By diyengineer in forum Laser Engraving / Cutting Machine General Topics
    Replies: 5
    Last Post: 02-10-2018, 10:06 PM
  2. Swapping an axis
    By gregcoles@telko in forum CamSoft Products
    Replies: 2
    Last Post: 07-04-2013, 09:27 AM
  3. Swapping M3 and M4 in Fanuc 10T???
    By Andy Fritz in forum Fanuc
    Replies: 15
    Last Post: 01-25-2010, 06:20 PM
  4. swapping bearings?????
    By the4thseal in forum DIY CNC Router Table Machines
    Replies: 7
    Last Post: 12-13-2007, 02:20 AM
  5. Understanding swapping tools for a job
    By dneisler in forum MetalWork Discussion
    Replies: 8
    Last Post: 02-16-2006, 09:55 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •