3

I know that there are two ways to run Memgraph on Ubuntu:

  1. sudo systemctl start memgraph
  2. sudo service memgraph start

Is there a preferred way to run Memgraph?

I've seen that if Ubuntu is run as WSL that the command for running it is sudo runuser -l memgraph -c '/usr/lib/memgraph/memgraph'. Can I use this command also on standalone Ubuntu installation, or is this one only for WSL?

1 Answers1

3
  1. systemctl interacts with systemd which is an init(and manager) system. When the Linux kernel is booted, there are some services that must start, etc. These are managed by systemd which is controlled by systemctl. service is the same as systemctl but for older systems which do not use systemd as their init system.

  2. This command is simply running the executable placed in /usr/lib/memgraph/memgraph with the user memgraph.

The difference between these two is that the latter one won't start on the startup while the first one will.

underpeak
  • 46
  • 1