aboutsummaryrefslogtreecommitdiffstats
path: root/package/base-files/files
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2015-11-24 18:32:09 +0000
committerJohn Crispin <blogic@openwrt.org>2015-11-24 18:32:09 +0000
commit39dd97633fb57b95f053e9e25c145b9a44e1fd6e (patch)
tree69c44e7abeec99bda1cd0ed4d8f0b8dea53efe1b /package/base-files/files
parent7929372c24ab6caf6892bc1cd71fcf3301a1f2b2 (diff)
downloadmaster-187ad058-39dd97633fb57b95f053e9e25c145b9a44e1fd6e.tar.gz
master-187ad058-39dd97633fb57b95f053e9e25c145b9a44e1fd6e.tar.bz2
master-187ad058-39dd97633fb57b95f053e9e25c145b9a44e1fd6e.zip
base-files: show hint when JFFS2-partition is full and overlayfs mounted read-only
since r45833 and r45848 the overlayfs is automatically mounted read-only (and blocks remounts as r/w) when JFFS2 is full. see ticket #19564 because of this normal file deletion is not possible anymore. if a user logins interactively (e.g. SSH) show a hint for this, that files must be removed in /overlay/upper/... v2: fix subject line Signed-off-by: Bastian Bittorf <bittorf@bluebottle.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@47623 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/base-files/files')
-rw-r--r--package/base-files/files/etc/profile4
1 files changed, 4 insertions, 0 deletions
diff --git a/package/base-files/files/etc/profile b/package/base-files/files/etc/profile
index bd008a84d7..8a55fecb37 100644
--- a/package/base-files/files/etc/profile
+++ b/package/base-files/files/etc/profile
@@ -1,6 +1,10 @@
#!/bin/sh
[ -f /etc/banner ] && cat /etc/banner
[ -e /tmp/.failsafe ] && cat /etc/banner.failsafe
+fgrep -sq '/ overlay ro,' /proc/mounts && {
+ echo 'Your JFFS2-partition seems full and overlayfs is mounted read-only.'
+ echo 'Please try to remove files from /overlay/upper/... and reboot!'
+}
export PATH=/usr/sbin:/usr/bin:/sbin:/bin
export HOME=$(grep -e "^${USER:-root}:" /etc/passwd | cut -d ":" -f 6)