diff options
author | Ermal <eri@pfsense.org> | 2013-01-05 16:38:53 +0000 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2013-01-05 16:38:53 +0000 |
commit | 9f1e3d64807c0eaf2a9ade1010a8a90e63d719be (patch) | |
tree | 57f7c9f484e25369fdef46559ecbfc31ca963d2a | |
parent | f2d7436a70913496bb3d31af772c03f1dce52bdd (diff) | |
download | pfsense-9f1e3d64807c0eaf2a9ade1010a8a90e63d719be.zip pfsense-9f1e3d64807c0eaf2a9ade1010a8a90e63d719be.tar.gz |
Sync rc.php_init_setup with master
-rwxr-xr-x | etc/rc.php_ini_setup | 21 |
1 files changed, 7 insertions, 14 deletions
diff --git a/etc/rc.php_ini_setup b/etc/rc.php_ini_setup index 4d10aef..a7b4357 100755 --- a/etc/rc.php_ini_setup +++ b/etc/rc.php_ini_setup @@ -47,18 +47,9 @@ fi # Calculate APC SHM size according # to detected memory values -if [ "$AVAILMEM" -lt "65" ]; then - APCSHMEMSIZE="1M" -fi -if [ "$AVAILMEM" -lt "96" ]; then - APCSHMEMSIZE="5M" -fi -if [ "$AVAILMEM" -lt "128" ]; then +if [ "$AVAILMEM" -gt "135" ]; then APCSHMEMSIZE="10M" fi -if [ "$AVAILMEM" -gt "128" ]; then - APCSHMEMSIZE="15M" -fi if [ "$AVAILMEM" -gt "256" ]; then APCSHMEMSIZE="20M" fi @@ -69,7 +60,7 @@ if [ "$AVAILMEM" -gt "512" ]; then APCSHMEMSIZE="30M" fi if [ "$AVAILMEM" -gt "784" ]; then - APCSHMEMSIZE="35M" + APCSHMEMSIZE="40M" fi # Set upload directory @@ -81,8 +72,10 @@ fi # Define php modules. Do not add .so, it will # be done automatically by the script below. -PHPMODULES="apc" -PHPMODULES="$PHPMODULES standard" +PHPMODULES="standard" +if [ "$AVAILMEM" -gt "135" ]; then + PHPMODULES="$PHPMODULES apc" +fi # Downloading via HTTP/FTP (pkg mgr, etc) PHPMODULES="$PHPMODULES curl date" # Internationalization @@ -252,7 +245,7 @@ done RAM=`/sbin/sysctl hw.realmem | /usr/bin/awk '{print $2/1000000}' | /usr/bin/awk -F '.' '{print $1}'` export RAM export LOWMEM -if [ "$RAM" -gt 96 ]; then +if [ "$RAM" -gt 135 ]; then /bin/cat >>/usr/local/lib/php.ini <<EOF |