monit-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: The multi interface code


From: Rory Toma
Subject: Re: The multi interface code
Date: 01 Jul 2002 12:15:05 -0700

> 
> 1) You can not easily add ip-strings and hostnames to bind to in
>    addition to interfaces, because the code is bound to using 
>    interfaces. E.g. in net.c:
>         if (ioctl(s, SIOCGIFCONF, &ifc) < 0)

Unfortunately for me, I have an absolute requirement to support binding
to a specific interface by interface name, so I guess I'll have to
support 2 versions.
> 
> 2) Instead of having one server socket you have X which makes the code
>    in engine.c much more complicated. It also possible to write this
>    with less code and a bit cleaner (not much tough):

You must have one socket per interface, so I don't see a way around
this.

>    Example of other stuff in engine.c: Why do you do this and then
>    later let the socket_producer allocate W?
> 
>    for (i=0; i < numberInterfaces; i++) {
>      W[i] = malloc(sizeof(struct requestwrapper));
>    }

Probably an oversight.
> 
>    We use xstrdup not strdup for a reason. Comment the code, and make
>    sure it does not have any side effects like:

I'll look at xstrdup.
> 
> 3) start.c and stop.c does not work with your code. Check out 
>    'monit start program' and 'monit stop program'

I can start/stop individual programs on mine - I tested that.

> Yes, I know. You must have worked hard, but this was your itch, not
> mine. But after you patched the code I started to itch a lot - sorry.

I suppose I'll leave mine as is, and start working on the dependency code,
which I still need anyway.
 
-- 
Rory Toma               address@hidden
VP of Run Level 5       http://www.trs80.net
Digeo Digital           http://www.digeo.com

Attachment: signature.asc
Description: This is a digitally signed message part


reply via email to

[Prev in Thread] Current Thread [Next in Thread]