Magento: Remove old session files

find var/session/ -name "sess*" -type f -delete

A litte bash script, if there a > 1 Mio files in this folder.

#!/bin/bash

NUMBERS="0 1 2 3 4 5 6 7 8 9 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"

for number in `echo $NUMBERS`
do
    for number2 in `echo $NUMBERS`
    do
        rm var/session/sess_$number$number2*
    done
done

Sven Wappler

TYPO3 Experte, symfony, Magento, SEO, Frontend und Backend

Das könnte Dich auch interessieren …