<div dir="ltr"><div>If anyone else needs a solution for this, here is mine.</div><div>First, build your release upgrade package as you normally would. I use rebar, so I issue:<br></div><div><br></div><div><font face="monospace, monospace">$ rebar generate-appups previous_release=myapp-1.4.6</font></div><div><br></div><div>Modify your .appup files as needed, then generate the upgrade package:</div><div><br></div><div><font face="monospace, monospace">$ rebar generate-upgrade previous_release=myapp-1.4.6</font></div><div><br></div><div>Then, open up the upgrade package, and look for the relup file <font face="monospace, monospace">releases/1.5.0/relup</font>.</div><div>In your relup instructions, before the point_of_no_return instruction ensure to load the setup app:</div><div><br></div><div><font face="monospace, monospace">{load_object_code,{setup,"1.5.0",[setup,setup_gen,setup_lib]}},</font></div><div><br></div><div>Just after the point_of_no_return, ensure to stop it:</div><div><br></div><div><font face="monospace, monospace">{apply,{application,stop,[setup]}},</font></div><div><br></div><div>Finally, after all the other instructions ensure to start it:</div><div><br></div><div><font face="monospace, monospace">{apply,{application,start,[setup,permanent]}}</font></div><div><br></div><div><br></div><div>Now, on a live system, check which applications are live:</div><div><br></div><div><font face="monospace, monospace">1> application:which_applications().</font></div><div><font face="monospace, monospace">[{myapp,"My App.","1.4.6"},</font></div><div><font face="monospace, monospace"> {exometer_core,"Code instrumentation and metrics collection package.",</font></div><div><font face="monospace, monospace">                "1.4.6"},</font></div><div><font face="monospace, monospace"> {setup,"Generic setup application for Erlang-based systems","1.4.6"},</font></div><div><br></div><div><br></div><div>Then proceed to the normal upgrade:</div><div><br></div><div><font face="monospace, monospace">2> release_handler:unpack_release("myapp_1.5.0").</font></div><div><font face="monospace, monospace">3> release_handler:install_release("1.5.0").</font></div><div><font face="monospace, monospace">4> release_handler:make_permanent("1.5.0").</font></div><div><br></div><div><br></div><div>Check applications again:</div><div><br></div><div><font face="monospace, monospace">5> application:which_applications().</font></div><div><font face="monospace, monospace">[{setup,"Generic setup application for Erlang-based systems","1.5.0"},</font></div><div><font face="monospace, monospace"> {myapp,"My app.","1.5.0"},</font></div><div><font face="monospace, monospace"> {exometer_core,"Code instrumentation and metrics collection package.",</font></div><div><font face="monospace, monospace">                "1.5.0"},</font></div><div><br></div><div>You can see that it upgraded successfully.</div><div><br></div><div class="gmail_extra">Hope this can help somebody else.</div><div class="gmail_extra"><br></div><div class="gmail_extra">Best,</div><div class="gmail_extra">r.</div></div>