Skip to content

Instantly share code, notes, and snippets.

@mklooss
Created November 6, 2012 08:46
Show Gist options
  • Save mklooss/4023540 to your computer and use it in GitHub Desktop.
Save mklooss/4023540 to your computer and use it in GitHub Desktop.
Magento Delete Old Session Files
#!/bin/bash
# delete files older than 14 days
DIR=/var/www/magento/var/session/
/usr/bin/find $DIR -depth -mtime +14 -exec rm -rf '{}' \;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment