Skip to content

Instantly share code, notes, and snippets.

@abdul
Forked from mklooss/gist:4023540
Created March 23, 2016 08:46
Show Gist options
  • Save abdul/bf8bcd851aca44dae4ed to your computer and use it in GitHub Desktop.
Save abdul/bf8bcd851aca44dae4ed 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