y2k-shubham
y2k-shubham

Reputation: 11607

Correct way to restart presto-server service on EMR

I have to restart presto-server on EMR to load my plugin. With reference to official AWS EMR docs:

sudo restart presto-server

sudo stop presto-server followed by sudo start presto-server


While Restarting a service page favours the 2nd technique above,

Note: Stop/start is required; do not use the restart command.

I have found that both work without a glitch.


Questions:


Platform / Frameworks:

Upvotes: 4

Views: 7538

Answers (2)

Piotr Findeisen
Piotr Findeisen

Reputation: 20770

EMR 6.1

sudo systemctl stop presto-server
sudo systemctl start presto-server
sudo systemctl status presto-server

EMR 5.15 (likely anything before 5.30)

restart does not reload the service configuration file (unfortunately, i don't remember the path to the file; this is the file which tells e.g. which user Presto runs as). Depending on the changes you introduce, this may or may not be an issue. Eg. if you are changing Presto config files or plugins, this is not an issue. If, however, you're changing the Presto service definition file, restart will not pick up your changes, whereas stop + start will.

Note: while the answer hopefully is/was applicable to EMR 5.15, it seems not applicable to EMR 6.1.

Upvotes: 8

akl
akl

Reputation: 46

The configs aren't picked up with the restarts. It's always suggested to use the start stops on EMR.

$sudo status presto-server presto-server start/running, process 16147

$sudo stop presto-server presto-server stop/waiting

$sudo stop presto-server presto-server stop/waiting

Upvotes: 2

Related Questions