Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9048613
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T12:11:52+00:00 2026-06-16T12:11:52+00:00

I have compiled my Erlang application by using basho rebar which makes an stand-alone

  • 0

I have compiled my Erlang application by using basho rebar which makes an stand-alone escript executable file. I run it from command line like:
./myapp myconfig.config

My questio is that how can I determine the Erlang node name that run my application. When in my application I run ‘node()’ command, it returns by default “nonode@nohost” but I want to give my name to that node (e.g. mynode@domain.com), so when I run ‘node()’ in my application, I like to see ‘mynode@domain.com’ instead of ‘nonode@nohost’

I know about “erlang -name ‘mynode@domain.com'” but please consider I run the application from command line. I think an Erlang VM is run and terminate during the application life-time automatically.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T12:11:53+00:00Added an answer on June 16, 2026 at 12:11 pm

    The best way is of course to set nodename in command line through “-sname node” or “-name node@host”.
    But it is possible to use `net_kernel’ module instead. It is described at http://www.erlang.org/doc/man/net_kernel.html

    $ erl
    Erlang R15B01 (erts-5.9.1) [source] [64-bit] [smp:2:2] [async-threads:0] [hipe] [kernel-poll:false]
    
    Eshell V5.9.1  (abort with ^G)
    1> node().
    nonode@nohost
    2> net_kernel:start([rumata, shortnames]).
    {ok,<0.34.0>}
    (rumata@rumata-osx)3> node().
    'rumata@rumata-osx'
    (rumata@rumata-osx)4> net_kernel:stop().
    ok
    5> node().
    nonode@nohost
    6> net_kernel:start(['rumata@myhost', longnames]). 
    {ok,<0.44.0>}
    (rumata@myhost)7> node().
    rumata@myhost
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have compiled a .NET application using Any CPU option. This .NET application uses
I have compiled my application on Linux (Intel) machine using this command gcc –g
I have an Erlang application and I can compile it easily and run it
I have a file .erlang in the current dir I run erl shell that
I have compiled and build my application in Netbeans which includes Java DB. Now
I have an escript file which runs fine from the command line, i.e.: ./escript_file
I have compiled Android source code already (which I downloaded using GIT) and I
I have erlang application: *.app file and some *.erl files. I compile all of
I have compiled a matlab standalone exe which I can run on any computer
I have compiled my preload file on Ubuntu server (two files for x32 and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.