Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Erlang detach shell from node / Quit shell without killing node

Tags:

erlang

rebar

I feel like I'm missing something stupid obvious, but I've looked all over and can't find the answer to my question.

Suppose I have an application release that I've built with rebar and I start it a la

rel/my_app/bin/my_app start

I let it happily go about its business for a while, and then I want to attach a console to check on things, so I do

rel/my_app/bin/my_app attach

and get a shell. I muck around, and then when I'm done I want to quit the shell but leave the application running. If I do ^G q or q()., it brings down the entire application.

I've also played with starting the app with +Bi to stop it from allowing someone to accidentally close it, but then how does one even exit an attached shell at all?

like image 318
dantswain Avatar asked Oct 17 '12 02:10

dantswain


1 Answers

I don't use rebar, I've never understood what problem it was meant to solve, but I assume when you "attach" you are doing the same thing as running to_erl. To exit in from this you type control-D (EOF).

like image 64
Vance Shipley Avatar answered Sep 24 '22 15:09

Vance Shipley