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 8274577
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T07:46:04+00:00 2026-06-08T07:46:04+00:00

I try to scale my socket.io application and try to run several processes on

  • 0

I try to scale my socket.io application and try to run several processes on my server.

I use redis store instead of memory store as described here: https://github.com/LearnBoost/Socket.IO/wiki/Configuring-Socket.IO

My server listens to port 8090:
var io = require(‘/usr/local/lib/node_modules/socket.io’).listen(8090);

When I start a second process, I get an address in use error:
warn – error raised: Error: listen EADDRINUSE

What’s the best way handle this issue?
A port for each process and a load balancer to distinguish between them?

Or is there a better solution?

  • 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-08T07:46:06+00:00Added an answer on June 8, 2026 at 7:46 am

    For this I use node-http-proxy, and route the traffic to internal ports based off of the URL being requested. Below is a very stripped down example of what I am using to route requests.

    var httpProxy = require('http-proxy');
    
    var httpOptions = {
        router: {
            'domain1.com/foo': 'localhost:3001',
            'domain1.com/bar': 'localhost:3002',
            'domain2.com/baz': 'localhost:3003',
        } 
    };
    
    var httpServer = httpProxy.createServer(httpOptions);
    httpServer.listen(80);
    

    More details on my particular setup can be found on this question: How to use vhosts alongside node-http-proxy?

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

Sidebar

Related Questions

I am working on a large scale application. I carefully try to handle all
I‘m learning Scala by the book Programming in Scala. When I try to run
I try to read numeric/decimal/money columns from SQL Server via ODBC in the following
Should I frequently use try catch blocks and how do I determine when and
i'm try to determine the amount to scale down an image, which is in
I try using the auto re-size stated at Auto Scale TextView Text to Fit
If I try to plot multiple plots with a logarithmic axis, the log scale
i try to write a project to use Quart.net (http://quartznet.sourceforge.net/) to make job scheduling
I try to scale an image derivedfrom a file, to any (sensible) scale. The
I'm trying to write a simple client/server chat application in 2 languages - Java

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.