question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Systemctl not working: (code=dumped, signal=SEGV)

See original GitHub issue

spark-wallet --version 0.1.1 OS: 4.15.0-34-generic #37-Ubuntu SMP My spark-wallet.system file:

[Unit]
Description=Spark Lightning Wallet
Requires=network.target
After=network.target

[Service]
User=bitcoin
Group=bitcoin
#Restart=on-failure

ExecStart=/home/bitcoin/.npm-global/bin/spark-wallet --no-test-conn
# --no-test-conn because c-lightning might not be ready when we boot up.
# this delays opening the connection until we get the first API call from a user.
# if c-lightning is running as a systemd service, you should make this service depend on it instead.

SyslogIdentifier=spark-wallet
PIDFile=/var/run/spark-wallet.pid
StandardInput=null
StandardOutput=syslog
StandardError=syslog

# Hardening measures
PrivateTmp=true
ProtectSystem=full
NoNewPrivileges=true
PrivateDevices=true
MemoryDenyWriteExecute=true

[Install]
WantedBy=multi-user.target

my commands and outputs:

bitcoin@bitseed3:~$ sudo systemctl daemon-reload                                                                   │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:19: Unknown lvalue 'RuntimeDirectory' i
bitcoin@bitseed3:~$ sudo systemctl start spark-wallet.service                                                      │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:21: Unknown lvalue 'User' in section 'U
bitcoin@bitseed3:~$ sudo systemctl status spark-wallet.service                                                     │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:22: Unknown lvalue 'Group' in section '
● spark-wallet.service - Spark Lightning Wallet                                                                    │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:23: Unknown lvalue 'Type' in section 'U
   Loaded: loaded (/etc/systemd/system/spark-wallet.service; enabled; vendor preset: enabled)                      │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:24: Unknown lvalue 'PIDFile' in section
   Active: failed (Result: core-dump) since Fri 2018-09-28 17:18:08 CEST; 5s ago                                   │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:25: Unknown lvalue 'Restart' in section
  Process: 10544 ExecStart=/home/bitcoin/.npm-global/bin/spark-wallet --no-test-conn (code=dumped, signal=SEGV)    │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:31: Unknown lvalue 'PrivateTmp' in sect
 Main PID: 10544 (code=dumped, signal=SEGV)                                                                        │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:34: Unknown lvalue 'ProtectSystem' in s
                                                                                                                   │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:38: Unknown lvalue 'NoNewPrivileges' in
Sep 28 17:18:08 bitseed3 systemd[1]: Started Spark Lightning Wallet.                                               │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:42: Unknown lvalue 'PrivateDevices' in 
Sep 28 17:18:08 bitseed3 systemd[1]: spark-wallet.service: Main process exited, code=dumped, status=11/SEGV        │Sep 28 17:11:17 bitseed3 systemd[1]: /etc/systemd/system/lightningd.service:45: Unknown lvalue 'MemoryDenyWriteExec
Sep 28 17:18:08 bitseed3 systemd[1]: spark-wallet.service: Failed with result 'core-dump'.                         │Sep 28 17:11:17 bitseed3 lnd[2142]: 2018-09-28 17:11:17.551 [DBG] PEER: Received QueryShortChanIDs(chain_hash=00000

I found a coredump in the logs I think is related

systemd-coredump[11355]: Process 11335 (node) of user 1000 dumped core.
                                                  
                                                  Stack trace of thread 11335:
                                                  #0  0x0000000000fe8280 _ZN2v88internal18RegExpResultsCache5ClearEPNS0_10FixedArrayE (node)
                                                  #1  0x0000000000dee26a _ZN2v88internal4Heap19MarkCompactPrologueEv (node)
                                                  #2  0x0000000000dee92f _ZN2v88internal4Heap11MarkCompactEv (node)
                                                  #3  0x0000000000e0a119 _ZN2v88internal4Heap24PerformGarbageCollectionENS0_16GarbageCollectorENS_15GCCallbackFlagsE (node)
                                                  #4  0x0000000000e0afe8 _ZN2v88internal4Heap14CollectGarbageENS0_15AllocationSpaceENS0_23GarbageCollectionReasonENS_15GCCallbackFlagsE.constprop.934 (node)
                                                  #5  0x0000000000e0bb6c _ZN2v88internal4Heap12ReserveSpaceEPSt6vectorINS1_5ChunkESaIS3_EEPS2_IPhSaIS7_EE (node)
                                                  #6  0x00000000010634b7 _ZN2v88internal12Deserializer12ReserveSpaceEv (node)
                                                  #7  0x0000000001072a7e _ZN2v88internal19StartupDeserializer15DeserializeIntoEPNS0_7IsolateE (node)
                                                  #8  0x0000000000eb14f6 _ZN2v88internal7Isolate4InitEPNS0_19StartupDeserializerE (node)
                                                  #9  0x0000000001072141 _ZN2v88internal8Snapshot10InitializeEPNS0_7IsolateE (node)
                                                  #10 0x0000000000a87fc8 _ZN2v814IsolateNewImplEPNS_8internal7IsolateERKNS_7Isolate12CreateParamsE (node)
                                                  #11 0x00000000008d51ad _ZN4node5StartEP9uv_loop_siPKPKciS5_ (node)
                                                  #12 0x00000000008d4900 _ZN4node5StartEiPPc (node)
                                                  #13 0x00007f2ffdee1b97 __libc_start_main (libc.so.6)
                                                  #14 0x000000000089e0e1 _start (node)

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:19 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
gabridomecommented, Feb 11, 2019

Well, It turns out in the “user” version of the file I add a wrong directive:

“MemoryDenyWriteExecute”

It was not in the built standard version so, I guess I copied that from bitcoind.service In the various trials (my bad). I apologize but probably too many trial lead to erroneous attempts… 😦

On a side note I have noticed this after rebuilding the service:

sudo systemctl start spark-wallet
Failed to start spark-wallet.service: Unit lightningd.target not found.

The reason being, in my system, lightningd is not a “target” but it is inserted into “multi-user.target”. I changed my settings accordingly.

I started smoothly. The ticket can be closed as far as I’m concerning.

Thank you for the patience of everybody involved.

1reaction
daywalker90commented, Feb 8, 2019

It works indeed.

Read more comments on GitHub >

github_iconTop Results From Across the Web

[SOLVED] Apache startup fails with core dump
Something went wrong and my machine wouldn't reboot so I had to chroot and run mkinitcpio but after that, everything is fine. Except...
Read more >
Error starting up RabbitMQ - Google Groups
Running systemctl status rabbitmq-server.service I get the following: ... Main PID: 7838 (code=dumped, signal=SEGV).
Read more >
How to resolve 'segmentation fault (core dumped)' (systemd ...
This is usually caused by the code trying to access some memory address it isn't allowed to. The operating system only allocates RAM...
Read more >
Main process exited, code=dumped, status=11/SEGV
Today, I caught a SEGV/core-dump; the server stopped systemctl status ... status=0/SUCCESS) Main PID: 1103 (code=dumped, signal=SEGV) CPU: ...
Read more >
1304062 – [docker-storage-setup] Docker daemon does not ...
[root@boole var]# systemctl status docker.service ... (code=dumped, signal=SEGV) Main PID: 6836 (code=dumped, signal=SEGV) Feb 02 14:02:29 ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found