Actions
Bug #526
closedbug in /etc/rc.php_ini_setup
Start date:
04/19/2010
Due date:
% Done:
0%
Estimated time:
Plus Target Version:
Release Notes:
Affected Version:
2.0
Affected Architecture:
Description
There looks like bug in /etc/rc.php_ini_setup.
Faulty code is:
- Grab amount of memory that is detected
if [ -f /var/log/dmesg.boot ]; then
AVAILMEM=`/bin/cat /var/log/dmesg.boot |/usr/bin/awk '/avail memory/ { print $5 }'| sed 's/(//g'|tail -1`
else
AVAILMEM=`/sbin/dmesg -a |/usr/bin/awk '/avail memory/ { print $5 }'| sed 's/(//g'|tail -1`
fi
Above code produces following output in RouterStation Pro:
[2.0-BETA1][root@pfsense.mobicom.mn]/root(2): /bin/cat /var/log/dmesg.boot |/usr/bin/awk '/avail memory/ { print $5 }'| sed 's/(//g'|tail -1
118MB)
Old code still works without a problem:
[2.0-BETA1][root@pfsense.mobicom.mn]/root(3): cat /var/log/dmesg.boot | grep "memory" | grep "avail" | awk '{ print $5 }' | cut -d'(' -f2 | cut -d'M' -f1
118
Actions