R
R
resident2015-01-07 06:38:42
linux
resident, 2015-01-07 06:38:42

Xinetd sees only part of the config, how to fix it?

Good day! Happy winter holidays everyone!
Actually the essence of the issue. There is a config for xinetd of the following form:

service redirect1
{
  disable = no
  type = UNLISTED
  socket_type = stream
  protocol = tcp
  wait = no
  port = 4461
  redirect = 107.181.161.157 5025
  user = nobody
}

service redirect2
{
  disable = no
  type = UNLISTED
  socket_type = stream
  protocol = tcp
  wait = no
  port = 4462
  redirect = 107.181.161.157 5025
  user = nobody
}

There are more than 2000 such redirects at the moment. More are planned in the future. And the problem is that only the first 1000 rules work, the rest are simply ignored and I don’t understand why. If there are experts on networks in Linux here, please tell me what could be the problem?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
V
Vladimir, 2015-01-07
@resident

perhaps ran into the limits on open files for the user nobody

A
Armenian Radio, 2015-01-07
@gbg

There is an opinion that this task should be solved using iptables

iptables -t nat -I PREROUTING --src $SRC_IP_MASK --dst $DST_IP -p tcp --dport $portNumber -j REDIRECT --to-ports $rediectPort

V
Vlad Zhivotnev, 2015-01-07
@inkvizitor68sl

This task is best handled with rinetd.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question