RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login
    Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first

    SOLVED: Running out of MEM and SWAP when compiling lr-mame

    Scheduled Pinned Locked Moved Help and Support
    compilelr-mameswap filememory
    16 Posts 2 Posters 2.3k 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.
    • dankcushionsD
      dankcushions Global Moderator @johnodon
      last edited by dankcushions

      @johnodon i am not sure how many makefile jobs your hardware will support. it calculates it here: https://github.com/RetroPie/RetroPie-Setup/blob/master/scriptmodules/system.sh#L92-L108

      if it allows the maximum 4 (quadcore CPU? not sure how many proc it will report) jobs then that could consume quite a lot of memory.

      15 mins into compilation and available memory is already down to 221MB. Is that normal?

      i would say so. just let it do its thing for a few hours. it's going to hammer your system until it's done.

      johnodonJ 1 Reply Last reply Reply Quote 0
      • johnodonJ
        johnodon @dankcushions
        last edited by

        @dankcushions said in Running out of MEM and SWAP when compiling lr-mame:

        @johnodon i am not sure how many makefile jobs your hardware will support. it calculates it here: https://github.com/RetroPie/RetroPie-Setup/blob/master/scriptmodules/system.sh#L92-L108

        if it allows the maximum 4 (quadcore CPU? not sure how many proc it will report) jobs then that could consume quite a lot of memory.

        15 mins into compilation and available memory is already down to 221MB. Is that normal?

        i would say so. just let it do its thing for a few hours. it's going to hammer your system until it's done.

        Thanks. I let it run overnight but again that was via SSH and I lost my connection. Now that I am doing it on the console, I should be able to see if it moves along.

        John

        1 Reply Last reply Reply Quote 0
        • johnodonJ
          johnodon
          last edited by

          FYI...ps -aux finally came back...

          USER         PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
          root           1  0.2  0.0 167324   348 ?        Ds   06:20   0:18 /sbin/init
          root           2  0.0  0.0      0     0 ?        S    06:20   0:00 [kthreadd]
          root           3  0.0  0.0      0     0 ?        I<   06:20   0:00 [rcu_gp]
          root           4  0.0  0.0      0     0 ?        I<   06:20   0:00 [rcu_par_gp]
          root           6  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/0:0H-kblockd]
          root           7  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/0:1-events]
          root           9  0.0  0.0      0     0 ?        I<   06:20   0:00 [mm_percpu_wq]
          root          10  0.0  0.0      0     0 ?        S    06:20   0:00 [ksoftirqd/0]
          root          11  0.0  0.0      0     0 ?        I    06:20   0:02 [rcu_sched]
          root          12  0.0  0.0      0     0 ?        S    06:20   0:00 [migration/0]
          root          13  0.0  0.0      0     0 ?        S    06:20   0:00 [idle_inject/0]
          root          14  0.0  0.0      0     0 ?        S    06:20   0:00 [cpuhp/0]
          root          15  0.0  0.0      0     0 ?        S    06:20   0:00 [cpuhp/1]
          root          16  0.0  0.0      0     0 ?        S    06:20   0:00 [idle_inject/1]
          root          17  0.0  0.0      0     0 ?        S    06:20   0:00 [migration/1]
          root          18  0.0  0.0      0     0 ?        S    06:20   0:00 [ksoftirqd/1]
          root          20  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/1:0H-kblockd]
          root          21  0.0  0.0      0     0 ?        S    06:20   0:00 [cpuhp/2]
          root          22  0.0  0.0      0     0 ?        S    06:20   0:00 [idle_inject/2]
          root          23  0.0  0.0      0     0 ?        S    06:20   0:00 [migration/2]
          root          24  0.0  0.0      0     0 ?        S    06:20   0:00 [ksoftirqd/2]
          root          26  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/2:0H-kblockd]
          root          27  0.0  0.0      0     0 ?        S    06:20   0:00 [cpuhp/3]
          root          28  0.0  0.0      0     0 ?        S    06:20   0:00 [idle_inject/3]
          root          29  0.0  0.0      0     0 ?        S    06:20   0:00 [migration/3]
          root          30  0.0  0.0      0     0 ?        S    06:20   0:00 [ksoftirqd/3]
          root          31  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/3:0-cgroup_destroy]
          root          32  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/3:0H-kblockd]
          root          33  0.0  0.0      0     0 ?        S    06:20   0:00 [cpuhp/4]
          root          34  0.0  0.0      0     0 ?        S    06:20   0:00 [idle_inject/4]
          root          35  0.0  0.0      0     0 ?        S    06:20   0:00 [migration/4]
          root          36  0.0  0.0      0     0 ?        S    06:20   0:00 [ksoftirqd/4]
          root          38  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/4:0H-kblockd]
          root          39  0.0  0.0      0     0 ?        S    06:20   0:00 [cpuhp/5]
          root          40  0.0  0.0      0     0 ?        S    06:20   0:00 [idle_inject/5]
          root          41  0.0  0.0      0     0 ?        S    06:20   0:00 [migration/5]
          root          42  0.0  0.0      0     0 ?        S    06:20   0:00 [ksoftirqd/5]
          root          43  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/5:0-events]
          root          44  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/5:0H-events_highpri]
          root          45  0.0  0.0      0     0 ?        S    06:20   0:00 [cpuhp/6]
          root          46  0.0  0.0      0     0 ?        S    06:20   0:00 [idle_inject/6]
          root          47  0.0  0.0      0     0 ?        S    06:20   0:00 [migration/6]
          root          48  0.0  0.0      0     0 ?        S    06:20   0:00 [ksoftirqd/6]
          root          50  0.0  0.0      0     0 ?        I<   06:20   0:01 [kworker/6:0H-kblockd]
          root          51  0.0  0.0      0     0 ?        S    06:20   0:00 [cpuhp/7]
          root          52  0.0  0.0      0     0 ?        S    06:20   0:00 [idle_inject/7]
          root          53  0.0  0.0      0     0 ?        S    06:20   0:00 [migration/7]
          root          54  0.0  0.0      0     0 ?        S    06:20   0:00 [ksoftirqd/7]
          root          56  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/7:0H-kblockd]
          root          57  0.0  0.0      0     0 ?        S    06:20   0:00 [kdevtmpfs]
          root          58  0.0  0.0      0     0 ?        I<   06:20   0:00 [netns]
          root          59  0.0  0.0      0     0 ?        S    06:20   0:00 [rcu_tasks_kthre]
          root          60  0.0  0.0      0     0 ?        S    06:20   0:00 [kauditd]
          root          61  0.0  0.0      0     0 ?        S    06:20   0:00 [khungtaskd]
          root          62  0.0  0.0      0     0 ?        S    06:20   0:00 [oom_reaper]
          root          63  0.0  0.0      0     0 ?        I<   06:20   0:00 [writeback]
          root          64  0.0  0.0      0     0 ?        S    06:20   0:00 [kcompactd0]
          root          65  0.0  0.0      0     0 ?        SN   06:20   0:00 [ksmd]
          root          66  0.0  0.0      0     0 ?        SN   06:20   0:00 [khugepaged]
          root          72  0.0  0.0      0     0 ?        I    06:20   0:01 [kworker/6:1-mm_percpu_wq]
          root         113  0.0  0.0      0     0 ?        I<   06:20   0:00 [kintegrityd]
          root         114  0.0  0.0      0     0 ?        I<   06:20   0:00 [kblockd]
          root         115  0.0  0.0      0     0 ?        I<   06:20   0:00 [blkcg_punt_bio]
          root         116  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/1:1-mm_percpu_wq]
          root         117  0.0  0.0      0     0 ?        I<   06:20   0:00 [tpm_dev_wq]
          root         118  0.0  0.0      0     0 ?        I<   06:20   0:00 [ata_sff]
          root         119  0.0  0.0      0     0 ?        I<   06:20   0:00 [md]
          root         120  0.0  0.0      0     0 ?        I<   06:20   0:00 [edac-poller]
          root         121  0.0  0.0      0     0 ?        I<   06:20   0:00 [devfreq_wq]
          root         122  0.0  0.0      0     0 ?        S    06:20   0:00 [watchdogd]
          root         124  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/3:1-mm_percpu_wq]
          root         125  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/4:1-events]
          root         127 27.8  0.0      0     0 ?        S    06:20  36:09 [kswapd0]
          root         128  0.0  0.0      0     0 ?        S    06:20   0:00 [ecryptfs-kthrea]
          root         130  0.0  0.0      0     0 ?        I<   06:20   0:00 [kthrotld]
          root         131  0.0  0.0      0     0 ?        I<   06:20   0:00 [acpi_thermal_pm]
          root         132  0.0  0.0      0     0 ?        I<   06:20   0:00 [vfio-irqfd-clea]
          root         134  0.0  0.0      0     0 ?        I<   06:20   0:00 [kstrp]
          root         137  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/u17:0-rb_allocator]
          root         143  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/2:1-mm_percpu_wq]
          root         151  0.0  0.0      0     0 ?        I<   06:20   0:00 [charger_manager]
          root         200  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/1:2-events]
          root         202  0.0  0.0      0     0 ?        S    06:20   0:00 [scsi_eh_0]
          root         204  0.0  0.0      0     0 ?        I<   06:20   0:00 [scsi_tmf_0]
          root         205  0.0  0.0      0     0 ?        S    06:20   0:00 [scsi_eh_1]
          root         207  0.0  0.0      0     0 ?        I<   06:20   0:00 [scsi_tmf_1]
          root         208  0.0  0.0      0     0 ?        S    06:20   0:00 [scsi_eh_2]
          root         209  0.0  0.0      0     0 ?        I<   06:20   0:00 [scsi_tmf_2]
          root         210  0.0  0.0      0     0 ?        S    06:20   0:00 [scsi_eh_3]
          root         211  0.0  0.0      0     0 ?        I<   06:20   0:00 [scsi_tmf_3]
          root         212  0.0  0.0      0     0 ?        S    06:20   0:00 [scsi_eh_4]
          root         213  0.0  0.0      0     0 ?        I<   06:20   0:00 [scsi_tmf_4]
          root         214  0.0  0.0      0     0 ?        S    06:20   0:00 [scsi_eh_5]
          root         215  0.0  0.0      0     0 ?        I<   06:20   0:00 [scsi_tmf_5]
          root         216  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/0:2-events]
          root         223  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/6:1H]
          root         224  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/7:4-events]
          root         225  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/5:1-memcg_kmem_cache]
          root         227  0.0  0.0      0     0 ?        I    06:20   0:00 [kworker/2:2-events]
          root         229  0.0  0.0      0     0 ?        I<   06:20   0:01 [kworker/7:1H-kblockd]
          root         230  0.0  0.0      0     0 ?        S    06:20   0:00 [cec-DP-2]
          root         266  0.0  0.0      0     0 ?        S    06:20   0:00 [jbd2/sda5-8]
          root         267  0.0  0.0      0     0 ?        I<   06:20   0:00 [ext4-rsv-conver]
          root         268  0.0  0.0      0     0 ?        I<   06:20   0:01 [kworker/0:1H-kblockd]
          root         279  0.0  0.0      0     0 ?        I<   06:20   0:01 [kworker/2:1H-kblockd]
          root         283  0.0  0.0      0     0 ?        I<   06:20   0:01 [kworker/5:1H-kblockd]
          root         285  0.4  0.0      0     0 ?        I<   06:20   0:35 [kworker/4:1H-kblockd]
          root         290  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/3:1H-kblockd]
          root         301  0.0  0.0      0     0 ?        I<   06:20   0:01 [kworker/1:1H-kblockd]
          root         308  0.0  0.1  59676  9020 ?        S<s  06:20   0:03 /lib/systemd/systemd-journald
          root         331  0.0  0.0  23436     0 ?        Ss   06:20   0:00 /lib/systemd/systemd-udevd
          systemd+     342  0.0  0.0  26604     0 ?        Ss   06:20   0:01 /lib/systemd/systemd-networkd
          root         387  0.0  0.0      0     0 ?        I<   06:20   0:00 [cfg80211]
          root         401  0.0  0.0      0     0 ?        S    06:20   0:00 [irq/32-iwlwifi]
          root         403  0.0  0.0      0     0 ?        I<   06:20   0:00 [cryptd]
          root         444  0.0  0.0      0     0 ?        I<   06:20   0:00 [kworker/u17:1-rb_allocator]
          systemd+     491  0.0  0.0  23892     0 ?        Ss   06:20   0:03 /lib/systemd/systemd-resolved
          systemd+     492  0.0  0.0  90252     0 ?        Ssl  06:20   0:00 /lib/systemd/systemd-timesyncd
          avahi        499  0.1  0.0   8528   964 ?        Ss   06:20   0:08 avahi-daemon: running [ELITEDESK.local]
          root         500  0.0  0.0   9412     0 ?        Ss   06:20   0:00 /usr/sbin/cron -f
          message+     501  0.0  0.0   7952     0 ?        Ss   06:20   0:06 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only
          root         503  0.2  0.0 335744     0 ?        Dsl  06:20   0:17 /usr/sbin/NetworkManager --no-daemon
          root         509  0.1  0.0  81900     0 ?        Ssl  06:20   0:11 /usr/sbin/irqbalance --foreground
          root         513  0.0  0.0  32044     0 ?        Ss   06:20   0:00 /usr/bin/python3 /usr/bin/networkd-dispatcher --run-startup-triggers
          root         515  0.0  0.0 234628     0 ?        Ssl  06:20   0:00 /usr/lib/policykit-1/polkitd --no-debug
          syslog       518  0.0  0.0 224348     0 ?        Ssl  06:20   0:00 /usr/sbin/rsyslogd -n -iNONE
          root         520  0.0  0.0  16856     0 ?        Ss   06:20   0:00 /lib/systemd/systemd-logind
          nobody       521  0.0  0.0   5324    12 ?        Ss   06:20   0:00 /usr/sbin/thd --triggers /etc/triggerhappy/triggers.d/ --socket /run/thd.socket --user nobody --deviceglob /dev/input/event*
          root         522  0.0  0.0  14064     0 ?        Ss   06:20   0:03 /sbin/wpa_supplicant -u -s -O /run/wpa_supplicant
          avahi        525  0.0  0.0   8344     0 ?        S    06:20   0:00 avahi-daemon: chroot helper
          root         553  0.0  0.0 313748     0 ?        Ssl  06:20   0:00 /usr/sbin/ModemManager --filter-policy=strict
          root         567  0.0  0.0   5752     0 tty1     Ss+  06:20   0:00 /bin/login -f
          root         573  0.0  0.0  12176     0 ?        Ss   06:20   0:00 sshd: /usr/sbin/sshd -D [listener] 0 of 10-100 startups
          root         576  0.0  0.0 110504     0 ?        Ssl  06:20   0:00 /usr/bin/python3 /usr/share/unattended-upgrades/unattended-upgrade-shutdown --wait-for-signal
          root         592  0.0  0.0  36552     0 ?        Ss   06:20   0:06 /usr/sbin/nmbd --foreground --no-process-group
          root         604  0.0  0.0  51576  1376 ?        Ss   06:20   0:00 /usr/sbin/smbd --foreground --no-process-group
          root         606  0.0  0.0  49348   132 ?        S    06:20   0:00 /usr/sbin/smbd --foreground --no-process-group
          root         607  0.0  0.0  49356   192 ?        S    06:20   0:00 /usr/sbin/smbd --foreground --no-process-group
          root         609  0.0  0.0  51560    88 ?        S    06:20   0:00 /usr/sbin/smbd --foreground --no-process-group
          pi           634  0.0  0.0  18408     4 ?        Ss   06:20   0:00 /lib/systemd/systemd --user
          pi           635  0.0  0.0 168732     0 ?        S    06:20   0:00 (sd-pam)
          pi           641  0.0  0.0 356892     0 ?        S<sl 06:20   0:02 /usr/bin/pulseaudio --daemonize=no --log-target=journal
          pi           642  0.0  0.0   2608     4 tty1     S+   06:20   0:00 /bin/sh /usr/bin/startx --
          rtkit        645  0.0  0.0 152932     0 ?        SNsl 06:20   0:00 /usr/libexec/rtkit-daemon
          pi           669  0.0  0.0   4136     0 tty1     S+   06:20   0:00 xinit /etc/X11/xinit/xinitrc -- /etc/X11/xinit/xserverrc :0 vt1 -keeptty -auth /tmp/serverauth.dv50TzGl7S
          pi           670  1.6  0.0 737008  6852 tty1     Dl   06:20   2:07 /usr/lib/xorg/Xorg -nolisten tcp :0 vt1 -keeptty -auth /tmp/serverauth.dv50TzGl7S
          pi           671  0.0  0.0   7372     4 ?        Ss   06:20   0:00 /usr/bin/dbus-daemon --session --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only
          pi           689  0.0  0.0 231116     0 tty1     Sl   06:20   0:00 /usr/bin/openbox --startup /usr/lib/x86_64-linux-gnu/openbox-autostart OPENBOX
          pi           723  0.0  0.0   6308     0 tty1     S    06:20   0:00 /usr/bin/unclutter -idle 1 -root
          pi           725  0.0  0.0   6032     0 ?        Ss   06:20   0:00 /usr/bin/ssh-agent /usr/bin/im-launch /bin/bash /home/pi/.xsession
          pi           740  0.0  0.0 239572     0 ?        Ssl  06:20   0:00 /usr/libexec/gvfsd
          pi           859  0.0  0.0 305272     0 ?        Ssl  06:21   0:00 /usr/libexec/at-spi-bus-launcher
          pi           864  0.0  0.0   7108     0 ?        S    06:21   0:00 /usr/bin/dbus-daemon --config-file=/usr/share/defaults/at-spi2/accessibility.conf --nofork --print-address 3
          pi           867  0.0  0.0 541200  7260 ?        Ssl  06:21   0:06 /usr/libexec/gnome-terminal-server
          pi           872  0.0  0.0 162868     0 ?        Sl   06:21   0:00 /usr/libexec/at-spi2-registryd --use-gnome-session
          pi           879  0.0  0.0   9624     4 pts/0    Ss+  06:21   0:00 /bin/bash /usr/bin/emulationstation --no-splash
          pi           886  0.0  0.0   2608     0 pts/0    S+   06:21   0:00 /bin/sh /opt/retropie/supplementary/emulationstation/emulationstation.sh --no-splash
          pi           889  6.5  0.0 1651512    4 pts/0    Sl+  06:21   8:27 /opt/retropie/supplementary/emulationstation/emulationstation --no-splash
          pi          1094  0.0  0.0  38236     0 pts/0    S+   06:22   0:00 feh --geometry +3840+0 /opt/retropie/configs/all/arcade_wallpaper.jpg
          root        1121  0.0  0.0  13976   156 ?        Ss   06:23   0:00 sshd: pi [priv]
          pi          1161  0.0  0.0  14108   212 ?        R    06:23   0:01 sshd: pi@pts/1
          pi          1162  0.0  0.0  11036   376 pts/1    Ss   06:23   0:00 -bash
          pi          1169  0.0  0.0   7108     4 ?        Ss   06:23   0:00 /usr/bin/dbus-daemon --syslog --fork --print-pid 4 --print-address 6 --session
          pi          1174  0.0  0.0 156092     0 ?        Sl   06:23   0:00 /usr/libexec/dconf-service
          pi          1181  0.0  0.0   7108     0 ?        Ss   06:23   0:00 /usr/bin/dbus-daemon --syslog --fork --print-pid 4 --print-address 6 --session
          pi          1186  0.0  0.0 156092     0 ?        Sl   06:23   0:00 /usr/libexec/dconf-service
          pi          1193  0.0  0.0   7108     4 ?        Ss   06:23   0:00 /usr/bin/dbus-daemon --syslog --fork --print-pid 4 --print-address 6 --session
          pi          1198  0.0  0.0 156092     0 ?        Sl   06:23   0:00 /usr/libexec/dconf-service
          pi          1205  0.0  0.0   7108     4 ?        Ss   06:23   0:00 /usr/bin/dbus-daemon --syslog --fork --print-pid 4 --print-address 6 --session
          pi          1210  0.0  0.0 156092     0 ?        Sl   06:23   0:00 /usr/libexec/dconf-service
          pi          1217  0.0  0.0   7108     4 ?        Ss   06:23   0:00 /usr/bin/dbus-daemon --syslog --fork --print-pid 4 --print-address 6 --session
          pi          1222  0.0  0.0 156092     0 ?        Sl   06:23   0:00 /usr/libexec/dconf-service
          pi          1229  0.0  0.0   7108     4 ?        Ss   06:23   0:00 /usr/bin/dbus-daemon --syslog --fork --print-pid 4 --print-address 6 --session
          pi          1234  0.0  0.0 156092     0 ?        Sl   06:23   0:00 /usr/libexec/dconf-service
          pi          1241  0.0  0.0   7108     4 ?        Ss   06:23   0:00 /usr/bin/dbus-daemon --syslog --fork --print-pid 4 --print-address 6 --session
          pi          1246  0.0  0.0 156092     0 ?        Sl   06:23   0:00 /usr/libexec/dconf-service
          pi          1254  0.0  0.0 156092     0 ?        Sl   06:23   0:00 /usr/libexec/dconf-service
          root        1417  0.0  0.0      0     0 ?        I    06:35   0:00 [kworker/7:0-events]
          root        1484  0.0  0.0      0     0 ?        I    06:35   0:00 [kworker/4:0]
          root        1512  0.0  0.0      0     0 ?        I    06:42   0:00 [kworker/6:2]
          root        1616  0.0  0.0      0     0 ?        I    07:46   0:00 [kworker/u16:0-events_unbound]
          pi          1625  0.0  0.0   2608     0 pts/0    S+   07:49   0:00 sh -c sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/rpsetup.rp </dev/tt
          root        1626  0.0  0.0  11912     0 pts/0    S+   07:49   0:00 sudo /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/rpsetup.rp
          root        1628  0.0  0.0  20956     4 pts/0    S+   07:49   0:00 bash /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/rpsetup.rp
          root        1761  0.5  0.0 383220   964 pts/0    Sl+  07:49   0:13 python3 /home/pi/RetroPie-Setup/scriptmodules/supplementary/runcommand/joy2key_sdl.py /dev/input/jsX kcub1 kcuf1 kcuu1 kcud1 0
          root        1776  0.0  0.0   7032     0 pts/0    S+   07:49   0:00 dbus-launch --autolaunch 6067fd4f4b7343958b611b99ad1b43e1 --binary-syntax --close-stderr
          root        1778  0.3  0.0   7228   180 ?        Ds   07:49   0:09 /usr/bin/dbus-daemon --syslog-only --fork --print-pid 5 --print-address 7 --session
          root        1831  0.0  0.0  20824     0 pts/0    S+   07:49   0:00 bash /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/rpsetup.rp
          root        1833  0.0  0.0  20824     0 pts/0    S+   07:49   0:00 bash /home/pi/RetroPie-Setup/retropie_packages.sh retropiemenu launch /home/pi/RetroPie/retropiemenu/rpsetup.rp
          root        1834  0.0  0.0   8088     0 ?        Ss   07:49   0:00 tee /dev/fd/63
          root        1835  0.0  0.0   3252   164 ?        Ss   07:49   0:00 gzip --stdout
          root        1928  0.0  0.0  23612     4 pts/0    S+   07:50   0:01 make OSD=retro RETRO=1 NOWERROR=1 OS=linux TARGETOS=linux CONFIG=libretro NO_USE_MIDI=1 TARGET=mame PYTHON_EXECUTABLE=python3
          root        5501  0.0  0.0   8576   108 pts/0    S+   07:51   0:00 make -R --no-print-directory -C build/projects/retro/mamearcade/gmake-linux config=libretro64
          root        9734  0.0  0.0   8692   620 pts/0    S+   07:58   0:00 make --no-print-directory -C . -f emu.make
          root       10501  0.0  0.0   2608     0 pts/0    S+   07:59   0:00 /bin/sh -c g++  -march=native -O2  -march=native -O2  -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFL
          root       10502  0.0  0.0   9344     0 pts/0    S+   07:59   0:00 g++ -march=native -O2 -march=native -O2 -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFLAC__NO_DLL -DP
          root       10503  6.6  5.2 2180228 426592 pts/0  D+   07:59   2:05 /usr/lib/gcc/x86_64-linux-gnu/9/cc1plus -quiet -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/lib -
          root       10504  0.0  0.3  97088 27428 pts/0    S+   07:59   0:01 as -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/lib -I ../../../../../src/lib/util -I ../../../..
          root       10549  0.0  0.0   2608     0 pts/0    S+   07:59   0:00 /bin/sh -c g++  -march=native -O2  -march=native -O2  -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFL
          root       10550  0.0  0.0   9344     0 pts/0    S+   07:59   0:00 g++ -march=native -O2 -march=native -O2 -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFLAC__NO_DLL -DP
          root       10551  6.4  5.2 2355808 425320 pts/0  D+   07:59   2:00 /usr/lib/gcc/x86_64-linux-gnu/9/cc1plus -quiet -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/lib -
          root       10552  0.0  0.2  79388 20724 pts/0    S+   07:59   0:00 as -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/lib -I ../../../../../src/lib/util -I ../../../..
          root       10557  0.0  0.0   2608     0 pts/0    S+   07:59   0:00 /bin/sh -c g++  -march=native -O2  -march=native -O2  -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFL
          root       10558  0.0  0.0   9344     0 pts/0    S+   07:59   0:00 g++ -march=native -O2 -march=native -O2 -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFLAC__NO_DLL -DP
          root       10559  6.3  5.3 2508124 431884 pts/0  D+   07:59   1:57 /usr/lib/gcc/x86_64-linux-gnu/9/cc1plus -quiet -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/lib -
          root       10560  0.0  0.2  63436 17212 pts/0    S+   07:59   0:00 as -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/lib -I ../../../../../src/lib/util -I ../../../..
          root       10966  0.0  0.0   8568   344 pts/0    S+   08:06   0:00 make --no-print-directory -C . -f frontend.make
          root       10997  0.0  0.0   2608    72 pts/0    S+   08:06   0:00 /bin/sh -c g++  -march=native -O2  -march=native -O2  -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFL
          root       10998  0.0  0.0   9344   200 pts/0    S+   08:06   0:00 g++ -march=native -O2 -march=native -O2 -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFLAC__NO_DLL -DP
          root       10999  6.4 26.9 2531732 2172888 pts/0 D+   08:06   1:33 /usr/lib/gcc/x86_64-linux-gnu/9/cc1plus -quiet -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/lib -
          root       11000  0.0  0.6  66616 54748 pts/0    S+   08:06   0:00 as -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/lib -I ../../../../../src/lib/util -I ../../../..
          root       11017  0.0  0.0   2608    72 pts/0    S+   08:06   0:00 /bin/sh -c g++  -march=native -O2  -march=native -O2  -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFL
          root       11018  0.0  0.0   9344   184 pts/0    S+   08:06   0:00 g++ -march=native -O2 -march=native -O2 -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFLAC__NO_DLL -DP
          root       11019  5.1 32.8 2971436 2647496 pts/0 D+   08:06   1:14 /usr/lib/gcc/x86_64-linux-gnu/9/cc1plus -quiet -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/front
          root       11020  0.0  0.1  23420 12756 pts/0    S+   08:06   0:00 as -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/frontend/mame -I ../../../../../src/devices -I ..
          root       11035  0.0  0.0   2608    68 pts/0    S+   08:06   0:00 /bin/sh -c g++  -march=native -O2  -march=native -O2  -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFL
          root       11036  0.0  0.0   9344   180 pts/0    S+   08:06   0:00 g++ -march=native -O2 -march=native -O2 -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFLAC__NO_DLL -DP
          root       11037  2.0 10.9 1060856 884900 pts/0  D+   08:06   0:29 /usr/lib/gcc/x86_64-linux-gnu/9/cc1plus -quiet -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/front
          root       11038  0.0  0.0  14972  4548 pts/0    S+   08:06   0:00 as -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/frontend/mame -I ../../../../../src/devices -I ..
          root       11040  0.0  0.0   2608    72 pts/0    S+   08:07   0:00 /bin/sh -c g++  -march=native -O2  -march=native -O2  -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFL
          root       11041  0.0  0.0   9344   168 pts/0    S+   08:07   0:00 g++ -march=native -O2 -march=native -O2 -MMD -MP -MP -D__LIBRETRO__ -DNDEBUG -DPTR64=1 -DCRLF=2 -DLSB_FIRST -DFLAC__NO_DLL -DP
          root       11042  1.3  3.5 501904 283976 pts/0   D+   08:07   0:19 /usr/lib/gcc/x86_64-linux-gnu/9/cc1plus -quiet -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/front
          root       11043  0.0  0.0  14972  4380 pts/0    S+   08:07   0:00 as -I ../../../../../src/osd -I ../../../../../src/emu -I ../../../../../src/frontend/mame -I ../../../../../src/devices -I ..
          root       11053  0.8  0.0  51604   468 ?        D    08:14   0:08 /usr/sbin/smbd --foreground --no-process-group
          root       11054  0.0  0.0      0     0 ?        I    08:14   0:00 [kworker/u16:3-i915]
          pi         11071  1.1  0.0  11684  1908 pts/1    R+   08:21   0:06 ps -aux
          root       11075  1.1  0.0  51620   860 ?        D    08:22   0:05 /usr/sbin/smbd --foreground --no-process-group
          root       11076  1.2  0.0  51620   808 ?        D    08:23   0:04 /usr/sbin/smbd --foreground --no-process-group
          root       11082  2.1  0.0  51620   868 ?        D    08:27   0:04 /usr/sbin/smbd --foreground --no-process-group
          root       11085  0.0  0.0      0     0 ?        I    08:29   0:00 [kworker/u16:2-events_power_efficient]
          root       11086 24.1  0.0  51620  1092 ?        D    08:30   0:03 /usr/sbin/smbd --foreground --no-process-group
          
          
          1 Reply Last reply Reply Quote 0
          • johnodonJ
            johnodon
            last edited by johnodon

            EDIT: Just saw this...

            Compiling src/frontend/mame/luaengine_mem.cpp...
            g++: fatal error: Killed signal terminated program cc1plus
            compilation terminated.
            make[2]: *** [emu.make:2084: ../../../../libretro/obj/x64/libretro/src/emu/emumem_aspace.o] Error 1
            make[2]: *** Waiting for unfinished jobs....
            

            OK...bad news it failed. Good news is this time it actually told me it failed and I was able to get the log. Bad news is that it doesn't seem to give much of a hint...

            https://pastebin.com/JUn10BKZ

            dankcushionsD 1 Reply Last reply Reply Quote 0
            • dankcushionsD
              dankcushions Global Moderator @johnodon
              last edited by

              @johnodon that does look like a classic out of memory type error. is it possible to increase your swap? the alternative would be tweak the retropie scripts to reduce the amount of concurrent build jobs.

              johnodonJ 1 Reply Last reply Reply Quote 0
              • johnodonJ
                johnodon @dankcushions
                last edited by

                @dankcushions said in Running out of MEM and SWAP when compiling lr-mame:

                @johnodon that does look like a classic out of memory type error. is it possible to increase your swap? the alternative would be tweak the retropie scripts to reduce the amount of concurrent build jobs.

                This is for a dedicated arcade cab with hand picked ROMs so I have a lot of empty space. I'll give the SWAP 50GB and see what happens.

                1 Reply Last reply Reply Quote 0
                • johnodonJ
                  johnodon
                  last edited by

                  Compiling now...

                                total        used        free      shared  buff/cache   available
                  Mem:          7.7Gi       314Mi       6.8Gi       123Mi       553Mi       7.0Gi
                  Swap:          49Gi          0B        49Gi
                  
                  
                  johnodonJ 1 Reply Last reply Reply Quote 0
                  • johnodonJ
                    johnodon @johnodon
                    last edited by

                    @johnodon said in Running out of MEM and SWAP when compiling lr-mame:

                    Compiling now...

                                  total        used        free      shared  buff/cache   available
                    Mem:          7.7Gi       314Mi       6.8Gi       123Mi       553Mi       7.0Gi
                    Swap:          49Gi          0B        49Gi
                    
                    

                    Compiled successfully.

                    So, the question becomes why this would even be an issue on an x86 machine with 8GB of RAM?

                    dankcushionsD 1 Reply Last reply Reply Quote 0
                    • dankcushionsD
                      dankcushions Global Moderator @johnodon
                      last edited by

                      @johnodon like i said it depends on how many processes it's running. if you run nproc at command line what does it return?

                      don't underestimate how much of a beefy task it is to compile MAME. there's probably not many bigger executables out there.

                      on a 32-bit rpi it requires 4GB of mem+swap, to run 2 processes (-j2). your 64-bit and more (4?) processes needs much more memory. likely the script needs adjusting to create a larger temporary rpSwap swap file for your usecase.

                      johnodonJ 1 Reply Last reply Reply Quote 0
                      • johnodonJ
                        johnodon @dankcushions
                        last edited by

                        @dankcushions said in Running out of MEM and SWAP when compiling lr-mame:

                        @johnodon like i said it depends on how many processes it's running. if you run nproc at command line what does it return?

                        don't underestimate how much of a beefy task it is to compile MAME. there's probably not many bigger executables out there.

                        on a 32-bit rpi it requires 4GB of mem+swap, to run 2 processes (-j2). your 64-bit and more (4?) processes needs much more memory. likely the script needs adjusting to create a larger temporary rpSwap swap file for your usecase.

                        Doesn't the lr-mame scriptmodule interrogate the system to determine how many make processes to run?

                        dankcushionsD 1 Reply Last reply Reply Quote 0
                        • dankcushionsD
                          dankcushions Global Moderator @johnodon
                          last edited by

                          @johnodon yes, i pointed you towards the script earlier. however the script provides an informed guess rather than a cast-iron guarantee. normally it's enough.

                          lr-mame is in the experimental packages for a reason...

                          johnodonJ 1 Reply Last reply Reply Quote 0
                          • johnodonJ
                            johnodon @dankcushions
                            last edited by

                            @dankcushions said in Running out of MEM and SWAP when compiling lr-mame:

                            @johnodon yes, i pointed you towards the script earlier. however the script provides an informed guess rather than a cast-iron guarantee. normally it's enough.

                            lr-mame is in the experimental packages for a reason...

                            Gotcha. Thanks for all your help.

                            1 Reply Last reply Reply Quote 1
                            • First post
                              Last post

                            Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.

                            Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.