<< | Thread Index | >> ]    [ << | Date Index | >> ]

Subject: Re: Windows routing
From: Carsten Emde <ce,AT,ceag,DOT,ch>
Date: Fri, 11 Apr 2003 00:47:38 +0200
In-reply-to: <Pine.LNX.4.21.0304102016030.4051-100000@cats.meow.at>

> b. One problem I do have it with startup/shutdown.  If I just reboot the
> tunnel doesn't come back on restart.  I have to disable the interface in
> the cipe control panel, reboot, reendable it.
This is known and has been discussed earlier in this newsgroup. The
problem is that cipesrvr may attempt to start before networking is up
and, therefore, fail. A quick workaround is to set the recovery option
of the cipe server ("DKW Heavy Industries VPN Adapter") to automatically
restart one minute after the first failure.

A better approach is to set the dependencies of the service but this
cannot be done interactively. If you add "LanmanWorkstation\0" as the
11th argument to CreateService() in CipeServiceBase.cpp, the dependency
will be set correctly and the reboot problem will go away. I have
modified the source accordingly and made it available along with a
binary for testing purposes. It works well so far and I hope that the
fix will make it into the next official release.

Also, the recovery option can be set programmatically. My proposed fix
calls ChangeServiceConfig2() when CreateService() returned with success:
     fa.dwResetPeriod = 86400; // One day
     fa.lpRebootMsg = NULL;
     fa.lpCommand = NULL;
     fa.cActions = 1;
     SC_ACTION sa[1];
     sa[0].Delay = 60000; // One minute
     sa[0].Type = SC_ACTION_RESTART;
     fa.lpsaActions = sa;
     l_Error = ChangeServiceConfig2

Carsten Emde.

<< | Thread Index | >> ]    [ << | Date Index | >> ]