cculianu / Fulcrum

A fast & nimble SPV Server for BCH, BTC, and LTC
Other
339 stars 76 forks source link

Active: Failed when status when running systemctl status fulcrum.service #226

Closed Elshaffah closed 8 months ago

Elshaffah commented 9 months ago

Hi, I need your assistant in resolving this issue so I tried to configure/build the fulcrum server on my bitcoin node and whenever I run the "systemctl status fulcrum.service" it displays this:

fulcrum.service - Fulcrum After=Network.target Loaded: loaded (/etc/systemd/system/fulcrum.service; enabled; vendor preset: enabled) Active: failed (Result: exit-code) since Wed 2024-01-10 12:40:45 GMT; 31s ago Process: 2042503 ExecStart=/home/admin/fulcrum/Fulcrum /home/admin/fulcrum/fulcrum.conf (code=exited, status=217/USER) Main PID: 2042503 (code=exited, status=217/USER) CPU: 0

how do I resolve this?

EchterAgo commented 9 months ago

status=217/USER indicates that the user you specified in the systemd unit does not exist. This is not a Fulcrum issue but an issue with your systemd configuration.

cculianu commented 9 months ago

Thanks @EchterAgo I don't run Linux as my day-to-day anymore and have a hard time knowing instantly what these various misconfiguration issues are without investigating. Thanks for chiming in.

Elshaffah commented 8 months ago

Thank you for your responses but how do I go about creating the specified user in the systemd? I really need help with this

EchterAgo commented 8 months ago

I don't know what is in your systemd unit file nor do I know anything about your system. Are you trying to follow some kind of guide?

We have a systemd unit file for the RPM build here: https://github.com/cculianu/Fulcrum/blob/master/contrib/rpm/fulcrum.service

This one specifies the user to be called fulcrum. On most Linux system you'd use the useradd command to add this user: https://linux.die.net/man/8/useradd

You likely want to make it a system user (-r option) and do not specify a password so the account can not be logged in.

You'll also have to make sure the data directory you specified in the Fulcrum configuration file or on the command line is readable and writable for the fulcrum user, usually something like chown -R fulcrum /path/to/fulcrum/datadir and chmod -R u+rwX /path/to/fulcrum/datadir

Elshaffah commented 8 months ago

I don't know what is in your systemd unit file nor do I know anything about your system. Are you trying to follow some kind of guide?

We have a systemd unit file for the RPM build here: https://github.com/cculianu/Fulcrum/blob/master/contrib/rpm/fulcrum.service

This one specifies the user to be called fulcrum. On most Linux system you'd use the useradd command to add this user: https://linux.die.net/man/8/useradd

You likely want to make it a system user (-r option) and do not specify a password so the account can not be logged in.

You'll also have to make sure the data directory you specified in the Fulcrum configuration file or on the command line is readable and writable for the fulcrum user, usually something like chown -R fulcrum /path/to/fulcrum/datadir and chmod -R u+rwX /path/to/fulcrum/datadir

Thank you so much for your response. My node is a Bitcoin-core-26.0 + LND so the configuration for the /etc/systemd/system/fulcrum.service should be for bitcoind

I tried to set up the Fulcrum server on my node by following a guide on YouTube… I'll send you a screen shot of what's in my systemd image

Elshaffah commented 8 months ago

I have tried to figure this out and when I enter sudo systemctl status fulcrum.service I keep getting this:

● fulcrum.service - Fulcrum Loaded: loaded (/etc/systemd/system/fulcrum.service; enabled; vendor preset: enabled) Active: failed (Result: exit-code) since Fri 2024-01-12 04:05:30 GMT; 4min 5s ago Process: 745738 ExecStart=/home/admin/fulcrum -S --fulcrum_db /var/lib/fulcrum /etc/fulcrum.conf (code=exited, status=217/USE> Main PID: 745738 (code=exited, status=217/USER) CPU: 0

Jan 12 04:05:30 raspberrypi systemd[1]: Started Fulcrum. Jan 12 04:05:30 raspberrypi systemd[1]: fulcrum.service: Main process exited, code=exited, status=217/USER Jan 12 04:05:30 raspberrypi systemd[1]: fulcrum.service: Failed with result 'exit-code'.

Also, when I enter journalctl -fu fulcrum.service, this is the display I get:

Hint: You are currently not seeing messages from other users and the system. Users in groups 'adm', 'systemd-journal' can see all messages. Pass -q to turn off this notice. No journal files were opened due to insufficient permissions.

I really need assistance in resolving this issue

cculianu commented 8 months ago

This is an issue tracker for issues with the Fulcrum software itself. While we often help users with configuration issues — the assumption is that most users are fairly comfortable with system administration tasks on Linux such as setting up systemd services.

What seems to have happened is there is some system administration stuff that is not configured right …

With much love and respect I say perhaps you should join a forum or chat room and get some real-time help from other users. I’m not sure this is a task for Fulcrum devs to help you solve.

EchterAgo commented 8 months ago

@cculianu you might want to consider enabling GitHub discussions for the Fulcrum repository, that could be used to give peer to peer support without polluting the issue list. I know a bunch of repos that manage support questions like this and it seems to work very well.

cculianu commented 8 months ago

Oh, I didn't know about GitHub discussions. It's new. Wasn't around a few years ago. Yeah so @Elshaffah you can try asking in GitHub discussions. :)

https://github.com/cculianu/Fulcrum/discussions