--- loncom/lonmemcached 2005/07/08 01:23:29 1.4 +++ loncom/lonmemcached 2025/04/27 22:15:30 1.8 @@ -1,4 +1,6 @@ #!/usr/bin/perl +# $Id: lonmemcached,v 1.8 2025/04/27 22:15:30 raeburn Exp $ + $pidfile="/home/httpd/perl/logs/lonmemcached.pid"; $logfile="/home/httpd/perl/logs/lonmemcached.log"; @@ -15,10 +17,13 @@ open (PIDSAVE,">$pidfile"); print PIDSAVE "$$\n"; close(PIDSAVE); +my @args = ('-m','400','-l','127.0.0.1','-p','11211','-U','0','-v'); if (-e '/usr/sbin/memcached') { - exec('/usr/sbin/memcached','-m','256','-v'); + unshift(@args,'/usr/sbin/memcached'); + exec( { $args[0] } @args); } elsif (-e '/usr/bin/memcached') { - exec('/usr/sbin/memcached','-m','256','-v'); + unshift(@args,'/usr/bin/memcached'); + exec( { $args[0] } @args); } else { die("Unable to find memcached"); }