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

  • SEARCH
  • Home
  • 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 730787
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T06:57:07+00:00 2026-05-14T06:57:07+00:00

I am working on a decentralized Erlang application. I am currently working on a

  • 0

I am working on a decentralized Erlang application. I am currently working on a single PC and creating multiple nodes by initializing erl with the -sname flag.

When I spawn a process using spawn/4 on its home node, I can see output generated by calls io:format/2 within that process in its home erl instance.

When I spawn a process remotely by using spawn/4 in combination with register_name, output of io:format/2 is sometimes redirected back to the erl instance where the remote spawn/4 call was made, and sometimes remains completely invisible.

Similarly, when I use rpc:call/4, output of io:format/2 calls is redirected back to the erl instance where the `rpc:call/4′ call is made.

How do you get a process to emit debugging output back to its parent erl instance?

  • 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-05-14T06:57:07+00:00Added an answer on May 14, 2026 at 6:57 am

    You can supply 1st argument to io:format/3 on the second node, using result of erlang:group_leader() from the first node.

    Starting first node, registering local shell process group leader globally:

    erl -sname a
    (a@localhost)1> global:register_name(global_io_srv, group_leader()).
    yes
    

    Starting second node, connecting, using globally registered process as io device

    erl -sname b
    (b@localhost)1> net_kernel:connect(a@localhost).
    true
    (b@localhost)2> io:format(global:whereis_name(global_io_srv),"test output",[]).
    ok
    

    You will see test output in the first node.
    This is the same way that Christian suggested, just a bit more explicit. So you can have error_logger for production logging and io:format/3 just for quick debugging.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Working on a page with multiple sections. at the very top there is a
Working on a legacy application at the moment and we are replacing the data
Working with an API that can handle multiple connections (i.e. sessions), each of these
Working with an Oracle 9i database from an ASP.NET 2.0 (VB) application using OLEDB.
Working with Excel interop, I'm trying be very careful about not implicitly creating any
Working on a legacy ASP.NET application we've found that ASP.NET session gets used for
Working in FlashBuilder, I build a mobile AS3 application that uses a Loader to
Working on a bunch of forms at the moment and I'm finding that I
Working on a website that has Employee and Branch entities, using a database table
Working on a rather small, and simple layout, I decided to use Meyer's CSS

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.