On Tue, 2008-10-28 at 14:43 -0400, Dale Worley wrote:
> There is a test in sipxcallresolver.sh{.in} to see if two copies of
> sipXproxy are running:
>
> procs=`ps -U dworley`
> if expr match "$procs" '.*sipXproxy.*' >/dev/null; then
> # At least one sipXproxy is running, check for another one
> if expr match "$procs" '.*sipXproxy.*sipXproxy.*' >/dev/null; then
>
> But I've seen it fail in practice:
Parsing the output of 'ps' is never a good idea. It suffers from all
sorts of portability and line-wrapping problems.
This strikes me as an example of someone solving a problem that should
have been solved at a different level altogether. Rather than a
configtest check looking for multiple proxies, the call resolver should
just have data integrity tests on its inputs.
_______________________________________________
sipx-dev mailing list
[email protected]
List Archive: http://list.sipfoundry.org/archive/sipx-dev
Unsubscribe: http://list.sipfoundry.org/mailman/listinfo/sipx-dev