diff options
author | Phil Davis <phil.davis@inf.org> | 2017-04-19 09:19:15 +0545 |
---|---|---|
committer | Phil Davis <phil.davis@inf.org> | 2017-04-19 09:19:15 +0545 |
commit | 3e20b9ca7beec08714e312234612df4e9bac1859 (patch) | |
tree | ceb2a4d497e576e5824e18bff1bd794087bf7e81 /src | |
parent | 2f20d4dc58cb44b89e0aa6cca3e81611a65f5ac3 (diff) | |
download | pfsense-3e20b9ca7beec08714e312234612df4e9bac1859.zip pfsense-3e20b9ca7beec08714e312234612df4e9bac1859.tar.gz |
Fix var/empty operation not permitted
Diffstat (limited to 'src')
-rwxr-xr-x | src/etc/pfSense-rc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/etc/pfSense-rc b/src/etc/pfSense-rc index 4b9990d..0bb0f2b 100755 --- a/src/etc/pfSense-rc +++ b/src/etc/pfSense-rc @@ -228,7 +228,12 @@ SWAPDEVICE=`/bin/cat /etc/fstab | /usr/bin/grep swap | /usr/bin/cut -f1` # make some directories in /var /bin/mkdir -p $varrunpath /var/log /var/etc /var/db/entropy /var/db/rrd /var/at/jobs/ /var/empty /var/log/nginx 2>/dev/null + +# turn off the immutable flag, set /var/empty to read-only, make it immutable again +chflags noschg /var/empty chmod 0555 /var/empty +chflags schg /var/empty + /bin/rm -rf $varrunpath/* # Cleanup configuration files from previous instance |