summaryrefslogtreecommitdiffstats
path: root/usr/local/www/installer/installer.php
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2010-12-18 16:20:17 -0500
committerScott Ullrich <sullrich@pfsense.org>2010-12-18 16:20:17 -0500
commit1ddd4ba39051ed20fd0d82800ecfe81b3d02ff1b (patch)
tree206d913702f42e99ab411e60fb9b30871588e618 /usr/local/www/installer/installer.php
parent502e7c83f6579d9f135b4f81ced2896c51c7c85d (diff)
downloadpfsense-1ddd4ba39051ed20fd0d82800ecfe81b3d02ff1b.zip
pfsense-1ddd4ba39051ed20fd0d82800ecfe81b3d02ff1b.tar.gz
USe memory *2 for default swap space
Diffstat (limited to 'usr/local/www/installer/installer.php')
-rw-r--r--usr/local/www/installer/installer.php18
1 files changed, 10 insertions, 8 deletions
diff --git a/usr/local/www/installer/installer.php b/usr/local/www/installer/installer.php
index d9ee154..e0c0ba9 100644
--- a/usr/local/www/installer/installer.php
+++ b/usr/local/www/installer/installer.php
@@ -726,19 +726,19 @@ EOF;
<hr>
<table id='maintable'><tbody>
<tr>
- <td>
- <b>Mount point</b>
+ <td align="middle">
+ <b>Mount</b>
</td>
<td>
- <b>Filesysyem type</b>
+ <b>Filesysyem</b>
</td>
- <td>
+ <td align="middle">
<b>Disk</b>
</td>
- <td>
+ <td align="middle">
<b>Size</b>
</td>
- <td>
+ <td align="middle">
<b>Encryption password</b>
</td>
<td>
@@ -750,13 +750,15 @@ EOF;
EOF;
// Output disk editor rows
+ $memory = get_memory();
+ $swap_size = $memory[0] * 2;
$first_disk = trim(installer_find_first_disk());
$disk_info = pcsysinstall_get_disk_info($first_disk);
$size = $disk_info['size'];
- $first_disk_size = $size - 256;
+ $first_disk_size = $size - $swap_size;
echo "\n\n<!-- $first_disk - " . print_r($disk_info, true) . " - $size - $first_disk_size -->\n\n";
$custom_txt .= return_rowhelper_row("0", "/", "UFS", $first_disk, "{$first_disk_size}", "");
- $custom_txt .= return_rowhelper_row("1", "none", "SWAP", $first_disk, "256", "");
+ $custom_txt .= return_rowhelper_row("1", "none", "SWAP", $first_disk, "$swap_size", "");
$custom_txt .= "</tr>";
$custom_txt .= "<tfoot></tfoot></tbody></table>";
OpenPOWER on IntegriCloud