[fatal] Could not listen on IP "::" on port 6667: all connections in use

If you hit any installation issues or cannot connect to your freshly installed UnrealIRCd then this forum is for you.

Moderator: Supporters

Post Reply
AdmiraL8544
Posts: 3
Joined: Wed Nov 27, 2019 1:15 pm

[fatal] Could not listen on IP "::" on port 6667: all connections in use

Post by AdmiraL8544 »

There is no problem in unrealircd-6.1.3, I get the following error in the latest version, unrealircd6.1.4

How can I fix

[info] Loading IRCd configuration..
[info] Testing IRCd configuration..
[info] Configuration loaded
[fatal] Could not listen on IP "::" on port 6900: all connections in use
[fatal] Could not listen on IP "0.0.0.0" on port 6900: all connections in use
[fatal] Could not listen on IP "::" on port 6697: all connections in use
[fatal] Could not listen on IP "0.0.0.0" on port 6697: all connections in use
[fatal] Could not listen on IP "::" on port 6667: all connections in use
[fatal] Could not listen on IP "0.0.0.0" on port 6667: all connections in use
[fatal] Unable to listen on any ports. Please verify that no other process is using the ports. Also, on some IRCd shells you may have to use listen::bind-ip with a specific IP assigned to you (rather than "*").
Syzop
UnrealIRCd head coder
Posts: 2110
Joined: Sat Mar 06, 2004 8:57 pm
Location: .nl
Contact:

Re: [fatal] Could not listen on IP "::" on port 6667: all connections in use

Post by Syzop »

Could you show the full output of the UnrealIRCd booting? Including the "This server can handle" line etc.
AdmiraL8544
Posts: 3
Joined: Wed Nov 27, 2019 1:15 pm

Re: [fatal] Could not listen on IP "::" on port 6667: all connections in use

Post by AdmiraL8544 »

[ircsohbe@localhost unrealircd]$ ./unrealircd start
Starting UnrealIRCd
_ _ _ ___________ _____ _
| | | | | |_ _| ___ \/ __ \ | |
| | | |_ __ _ __ ___ __ _| | | | | |_/ /| / \/ __| |
| | | | '_ \| '__/ _ \/ _` | | | | | / | | / _` |
| |_| | | | | | | __/ (_| | |_| |_| |\ \ | \__/\ (_| |
\___/|_| |_|_| \___|\__,_|_|\___/\_| \_| \____/\__,_|
v6.1.4

UnrealIRCd is brought to you by Bram Matthys (Syzop),
Krzysztof Beresztant (k4be), Gottem and i

Using the following libraries:
* OpenSSL 1.1.1k FIPS 25 Mar 2021
* libsodium 1.0.18
* c-ares 1.19.1
* PCRE2 10.42 2022-12-11
* jansson 2.14

This server can handle 150 concurrent sockets (-100 clients + 250 reserve)

[info] Loading IRCd configuration..
[info] Testing IRCd configuration..
[info] Configuration loaded
[fatal] Could not listen on IP "::" on port 6900: all connections in use
[fatal] Could not listen on IP "0.0.0.0" on port 6900: all connections in use
[fatal] Could not listen on IP "::" on port 6697: all connections in use
[fatal] Could not listen on IP "0.0.0.0" on port 6697: all connections in use
[fatal] Could not listen on IP "::" on port 6667: all connections in use
[fatal] Could not listen on IP "0.0.0.0" on port 6667: all connections in use
[fatal] Unable to listen on any ports. Please verify that no other process is us ing the ports. Also, on some IRCd shells you may have to use listen::bind-ip wit h a specific IP assigned to you (rather than "*").
=====================================================
UnrealIRCd failed to start. Check above for possible errors.
If you don't understand the problem, then have a look at our:
* FAQ (Frequently Asked Questions): https://www.unrealircd.org/docs/FAQ
* Documentation: https://www.unrealircd.org/docs/
=====================================================
[ircsohbe@localhost unrealircd]$
Syzop
UnrealIRCd head coder
Posts: 2110
Joined: Sat Mar 06, 2004 8:57 pm
Location: .nl
Contact:

Re: [fatal] Could not listen on IP "::" on port 6667: all connections in use

Post by Syzop »

I see. Seems there is a bug in 6.1.3 and 6.1.4 that can happen in some unusual circumstances. Thanks for bringing it up, I will look into fixing it into a future version.

You have an unusual low amount of "file descriptors" available to you, the "maximum number of connections" you may use. You can see it yourself with "ulimit -n" it will show you "150". Your server can only handle 150 connections because your shell (your system admin) limited it to 150. Normally this is something like "1024" or even "10240". The "150" means it is intentionally limited by your system admin (root).

A workaround for this bug in UnrealIRCd would be to run ./Config again and then, when you see this question:

Code: Select all

What is the maximum number of sockets (and file descriptors) that
UnrealIRCd may use?
It is recommended to leave this at the default setting 'auto',
which at present results in a limit of up to 16384, depending on
the system. When you boot UnrealIRCd later you will always see
the effective limit.
[auto] -> 
There you answer: 150

And then after pressing more ENTER and when ./Config finishes, you need to run "make" and "make install".

This should solve your problem.

Or, don't do all that, and ask your system admin to give you a higher limit than 150, like 1024 is more normal, but that may mean you need to pay more ;)
Post Reply