This is part of The Pile, a partial archive of some open source mailing lists and newsgroups.
To: modperl@apache.org From: <modperl@mail.thefriend.com> Subject: setting a variable based on the server. Date: Fri, 1 Dec 2000 14:34:17 -0800 (PST) Our website runs on linux and solaris boxes. One of the external applications that we have though can only be run on the solaris boxes. We can deal with this mostly through our switch and content filtering. Unfortuantly, there are some situations that we haven't been able to find where the linux server attempts to run a program that can only be run on solaris. The child that it(out code) is running in dies and is left as a defunct process that isn't cleaned up until the main server process is restarted. The solution i'm working on is something like this: in the httpd.conf add in the linux box PerlSetVar NETP 0 in the solaris box PerlSetVar NETP 1 then change the code to if ($NETP) { return $netp->run(); }else{ reutrn 0; } The only problem i'm concerned with here is that i remember something somewhere saying that there was a performance hit to doing either this method, or some other method. Any thoughts? Is there a better | more correct method? === To: modperl@apache.org From: Stephen Beitzel <sbeitzel@envolved.com> Subject: Re: setting a variable based on the server. Date: Fri, 1 Dec 2000 15:00:01 -0800 (PST) > The solution i'm working on is something like this: > in the httpd.conf add > in the linux box > PerlSetVar NETP 0 > in the solaris box > PerlSetVar NETP 1 > > then change the code to > if ($NETP) > { > return $netp->run(); > }else{ > return 0; > } I've seen some problems with the PerlSetVar directive at my site, but otherwise I do something quite similar. I wound up defining the variables I need in apachectl (SYBASE=/opt/sybase; export SYBASE; etc.). ===