Giter VIP home page Giter VIP logo

Comments (18)

ewrogers avatar ewrogers commented on September 20, 2024 7

Confirmed to be an issue on 16.04. There appears to be two problems:

  • root is required to run iptables, service runs as mysterium-node (permissions?)
  • Not sure where ${DAEMON_OPTS} are injected from, but do not seem to work

My workaround is to manually edit the /lib/systemd/system/mysterium-node.service file like so (replacing NODE_KEY with your own):

NOTE: This will run the service as root!

[Unit]
Description=Server for decentralised VPN built on blockchain
Documentation=https://mysterium.network/
After=network-online.target

[Service]
# User=mysterium-node
# Group=mysterium-node
WorkingDirectory=/etc/mysterium-node
ExecStart=/usr/bin/mysterium_server --node=NODE_KEY --runtime-dir /tmp
KillMode=control-group
Restart=on-failure

[Install]
WantedBy=multi-user.target

Did a reboot and now the service is running without issue.

from node.

Waldz avatar Waldz commented on September 20, 2024 2

Thanks for detailed description, we will fix it.

Problem is because You try to start Service via Systemd.
Currently it was tested only with Initd:

/etc/init.d/mysterium-node start

from node.

Nipol avatar Nipol commented on September 20, 2024 2

Clearing.

/lib/systemd/system/mysterium-node.service

[Unit]
Description=Server for decentralised VPN built on blockchain
Documentation=https://mysterium.network/
After=network-online.target

[Service]
# User=mysterium-node
# Group=mysterium-node
WorkingDirectory=/etc/mysterium-node
ExecStart=/usr/bin/mysterium_server --node=NODE_KEY --config-dir=/etc/mysterium-node --runtime-dir=/var/run/mysterium-node
KillMode=control-group
Restart=on-failure

[Install]
WantedBy=multi-user.target

reboot. or reload.

sudo mkdir /var/run/mysterium-node
sudo service mysterium-node start
sudo service mysterium-node status

check.

from node.

OneCricketeer avatar OneCricketeer commented on September 20, 2024 2

Alternative solution, actually define DAEMON_OPTS in some fashion

$ sudo cat /etc/default/mysterium-node 
MYSTERIUM_SERVER_NODE=
MYSTERIUM_SERVER_CONF_DIR=/etc/mysterium-node
MYSTERIUM_SERVER_RUN_DIR=/var/run/mysterium-node

Couldn't figure out how to get this working, but someone may get the idea.

DAEMON_OPTS="--node=$MYSTERIUM_SERVER_NODE --config-dir=$MYSTERIUM_SERVER_CONF_DIR"

Then, you could edit the service this way

ExecStart=/usr/bin/mysterium_server --node=${MYSTERIUM_SERVER_NODE} --config-dir=${MYSTERIUM_SERVER_CONF_DIR} --runtime-dir=${MYSTERIUM_SERVER_RUN_DIR}

Tested with Debian 8.8

from node.

hubiktomas avatar hubiktomas commented on September 20, 2024 1

I had the same problem. Just create the mysterium-node directory if it is not there and it should work. It is a workaround for a problem that is there.

from node.

hostile123 avatar hostile123 commented on September 20, 2024

same on ubuntu 16.04

from node.

hostile123 avatar hostile123 commented on September 20, 2024

thx

from node.

geodavies avatar geodavies commented on September 20, 2024

It appears as though the .deb file only installs with systemd as when I run the command you suggested I get: '/etc/init.d/mysterium-node: No such file or directory'

I've had a look inside of of the init.d directory and can confirm it's not there.

I have also tried running with 'systemctl start mysterium_node' but get a similar issue of 'Unit mysterium_node.service could not be found.'

from node.

Waldz avatar Waldz commented on September 20, 2024

Exact starting command should be like this:

sudo /usr/bin/mysterium_server --node=NODE_KEY --config-dir=/etc/mysterium-node --runtime-dir=/var/run/mysterium-node

from node.

hubiktomas avatar hubiktomas commented on September 20, 2024

Same problem here with Debian 8.8 - manually changing systemd startup script worked.

from node.

princevince avatar princevince commented on September 20, 2024

This is what I get when running from the command-line:

1495313522082784450 [Info] [ipify.api] IP detected: [my-public-ip-address]
1495313522083917601 [Info] [nat] IP forwarding enabled
1495313522084779221 [Info] [nat] Forwarding packets from '10.8.0.0/24' to IP: [my-public-ip-address]
listen unix /var/run/mysterium-node/openvpn-management-4ec7ba0nat.sock: bind: no such file or directory

from node.

princevince avatar princevince commented on September 20, 2024

Thanks! That worked.

from node.

seamlik avatar seamlik commented on September 20, 2024

Please fix this bug ASAP, or it just blocks more volunteers from trying. Ubuntu and Debian already use systemd now, testing it on systemd should have been the top priority.

from node.

geodavies avatar geodavies commented on September 20, 2024

Can confirm the temporary fix suggested by @ewrogers worked for me also.

from node.

fnzv avatar fnzv commented on September 20, 2024

@geodavies The workaround works but how its safe to run as root?

from node.

ewrogers avatar ewrogers commented on September 20, 2024

You should be using the docker container for proper isolation.

from node.

ne0ark avatar ne0ark commented on September 20, 2024

Be aware that 16.04 will start the mysterium but !check will fail best way is to start it using sudo /usr/bin/mysterium_server --node=NODE_KEY --config-dir=/etc/mysterium-node --runtime-dir=/var/run/mysterium-node

from node.

sanox1 avatar sanox1 commented on September 20, 2024

I recevie similar error after running apt-get upgrade yesterday :

systemctl status mysterium-node.service
Б≈▐ mysterium-node.service - Server for Mysterium - decentralised VPN Network
Loaded: loaded (/lib/systemd/system/mysterium-node.service; enabled; vendor preset: enabled)
Active: activating (auto-restart) (Result: exit-code) since Mon 2024-01-29 08:28:17 GMT; 3s ago
Docs: https://mysterium.network/
Process: 6148 ExecStart=/usr/bin/myst $CONF_DIR $SCRIPT_DIR $DATA_DIR $RUN_DIR $DAEMON_OPTS --ui.features=restart service --agreed-terms-and-conditions $SERVICE_OPTS
Main PID: 6148 (code=exited, status=2)

Jan 29 08:28:17 raspberrypi myst[6148]: runtime.goPanicIndex(0x3d56244f, 0x100000)
Jan 29 08:28:17 raspberrypi myst[6148]: /usr/lib/go-1.20/src/runtime/panic.go:112 +0x2c fp=0x7e8d2838 sp=0x7e8d2818 pc=0x50f3c
Jan 29 08:28:17 raspberrypi myst[6148]: runtime.gentraceback(0x485c44, 0x3e1f88c, 0x0, 0x3c020f0, 0x3, 0x4004000, 0x20, 0x0, 0x0, 0x0)
Jan 29 08:28:17 raspberrypi myst[6148]: /usr/lib/go-1.20/src/runtime/traceback.go:366 +0x186c fp=0x7e8d2a3c sp=0x7e8d2838 pc=0x7fd0c
Jan 29 08:28:17 raspberrypi myst[6148]: runtime.callers.func1()
Jan 29 08:28:17 raspberrypi myst[6148]: /usr/lib/go-1.20/src/runtime/traceback.go:844 +0x74 fp=0x7e8d2a70 sp=0x7e8d2a3c pc=0x811bc
Jan 29 08:28:17 raspberrypi myst[6148]: runtime.systemstack()
Jan 29 08:28:17 raspberrypi myst[6148]: /usr/lib/go-1.20/src/runtime/asm_arm.s:317 +0x60 fp=0x7e8d2a74 sp=0x7e8d2a70 pc=0x8d4a4
Jan 29 08:28:17 raspberrypi systemd[1]: mysterium-node.service: Main process exited, code=exited, status=2/INVALIDARGUMENT
Jan 29 08:28:17 raspberrypi systemd[1]: mysterium-node.service: Failed with result 'exit-code'.

my config looks like this :

[Unit]
Description=Server for Mysterium - decentralised VPN Network
Documentation=https://mysterium.network/
Requires=network-online.target
After=network-online.target

[Service]
User=mysterium-node
Group=mysterium-node

RuntimeDirectory=mysterium-node
RuntimeDirectoryMode=0750
LogsDirectory=mysterium-node

EnvironmentFile=-/etc/default/mysterium-node
ExecStart=/usr/bin/myst
$CONF_DIR
$SCRIPT_DIR
$DATA_DIR
$RUN_DIR
$DAEMON_OPTS
--ui.features=restart
service
--agreed-terms-and-conditions
$SERVICE_OPTS
KillMode=process
SendSIGKILL=yes
Restart=on-failure
RestartSec=5
AmbientCapabilities=CAP_NET_BIND_SERVICE

[Install]
WantedBy=multi-user.target

please advise how to modify so that it runs again ? Thanks

from node.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.