A few days after cleaning it, I checked the /tmp folder again and there were already quite a lot of files there.
Here's what to do to check and clean in (the script is at the end):
- Boot into ram (there are files in /tmp that I don't think should be deleted while running...).
- Mount (with pmount or mut) the partition (hda4 in my case) containing the pup_save file.
- Manually mount the pup_save file:
Code: Select all
mount -o loop /mnt/hda4/pup_save.3fs /mnt/data
- now move into the /tmp folder (cd /mnt/data/tmp) and try deleting hidden files:
Code: Select all
rm -f .*
- If you've got many hidden files there, you'll get an error message:
Code: Select all
rm : argument list too long
Code: Select all
./clean.sh
The script:
Code: Select all
#!/bin/bash
FOLDER=/mnt/data/tmp
search_and_delete()
{
for SYM in 1 2 3 4 5 6 7 8 9 0 _ - . a b c d e f g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
do
rm -rf "$1""$SYM"*
if [ $? != "0" ];then
NAME="$1""$SYM"
echo "checking "$NAME"*"
search_and_delete "$NAME"
fi
done
}
cd $FOLDER
NAME="."
search_and_delete $NAME
exit