Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sockets with fd 0 unsupported #51

Open
andusvan opened this issue Mar 4, 2015 · 4 comments
Open

sockets with fd 0 unsupported #51

andusvan opened this issue Mar 4, 2015 · 4 comments
Labels

Comments

@andusvan
Copy link

andusvan commented Mar 4, 2015

If I start the chilli process without stdin/stdout/stderr (which are closed by the calling program before), the chilli daemon does not function correctly.
The first error you will see is "Failed to create redir listen", but it seems to be a global problem, that a (valid) socket with fd 0 is not supported.
(Not sure, if this problem does only occur, if the debug mode is activated).

@geohuz
Copy link

geohuz commented Nov 3, 2015

I got the same problem, and I can't turn on the redir option. I noticed you were saying "If I start the chilli process without stdin/stdout/stderr (which are closed by the calling program before)", so is there an "unofficial" way to start the chilli? As I only use the stock /etc/init.d/chilli to start it, Anyway if you can point out a way to start chilli with redir option on It will be a great help for me. BTW, I have debug mode turns on, also I have full of the following messages in the log:
Oct 9 20:40:24 vyos coova-chilli[3799]: Having to re-launch chilli_redir... PID 16674 exited
Oct 9 20:40:24 vyos coova-chilli[3799]: Having to re-launch chilli_redir... PID 16676 exited
Oct 9 20:40:24 vyos coova-chilli[3799]: Having to re-launch chilli_redir... PID 16677 exited
Oct 9 20:40:24 vyos coova-chilli[3799]: Having to re-launch chilli_redir... PID 16678 exited
Oct 9 20:40:24 vyos coova-chilli[3799]: Having to re-launch chilli_redir... PID 16679 exited
Oct 9 20:40:25 vyos coova-chilli[3799]: Having to re-launch chilli_redir... PID 16680 exited
Oct 9 20:40:25 vyos coova-chilli[3799]: Having to re-launch chilli_redir... PID 16681 exited
Oct 9 20:40:25 vyos coova-chilli[3799]: Having to re-launch chilli_redir... PID 16682 exited
Oct 9 20:40:25 vyos coova-chilli[3799]: Having to re-launch chilli_redir... PID 16683 exited

@andusvan
Copy link
Author

andusvan commented Nov 3, 2015

Am 03.11.2015 um 11:33 schrieb geohuz:

I got the same problem, and I can't turn on the redir option. I noticed you were saying "If I start the chilli process without stdin/stdout/stderr
(which are closed by the calling program before)", so is there an "unofficial" way to start the chilli? As I only use the stock /etc/init.d/chilli to
start it, Anyway if you can point out a way to start chilli with redir option on It will be a great help for me.

Hello!

A collegue solved this problem. I do not know, what he exactly did, but
I found the following patch. Maybe this helps...

--- coova-chilli-1.3.0/src/redir.c.orig 2015-03-05 12:36:05.242229771 +0100
+++ coova-chilli-1.3.0/src/redir.c 2015-03-05 12:36:20.018651913 +0100
@@ -3210,7 +3210,7 @@
}
#endif
if (forked) _redir_close_exit(socket.fd[0], socket.fd[1]);

  • return _redir_close(socket.fd[0], socket.fd[1]);
  • return 0; //_redir_close(socket.fd[0], socket.fd[1]);
    }

Regards
Sven

Sven Anders anders@anduras.de () UTF-8 Ribbon Campaign
/\ Support plain text e-mail
ANDURAS intranet security AG
Messestraße 3 - 94036 Passau - Germany
Web: www.anduras.de - Tel: +49 (0)851-4 90 50-0 - Fax: +49 (0)851-4 90 50-55

Rechtsform: Aktiengesellschaft - Sitz: Passau - Amtsgericht: Passau HRB 6032
Mitglieder des Vorstands: Dipl.-Inf. Sven Anders, Dipl.-Inf. Marcus Junker
Vorsitzender des Aufsichtsrats: RA Mark Peters

@geohuz
Copy link

geohuz commented Nov 3, 2015

I saw the patch is based on 1.3.0, but I am having issue with the git version: 1.3.1, could you confirm the patch is applied to version 1.3.0? Thanks

@wlanmac
Copy link
Contributor

wlanmac commented Nov 3, 2015

The patch suggested seems to leak file descriptors, which wouldn't be good.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants