/free_cache

Primary LanguageShellMIT LicenseMIT

free_cache

Free your cache when your memory is used to a certain level


::::: Documentation :::::

How to use

  • Initial run
    Give setup.bash execution permission
    chmod +x setup.sh
    Run setup.bash to initialize
    $ ./setup.sh
    edit crontab as the following
    minute hour date-of-month month day-of-week . /root/free_cache.bash
    example0) Run every hour:
    0 * * * * . /root/free_cache.bash
    example1) Run every hour and set the trigger to 2GB (minimal is 1GB)
    0 * * * * . /root/free_cache.bash 2000000
  • Manual
    Run crontab -e with root user privileges (or with sudo)
    # crontab -e

::::: Updates :::::

  • September 2, 2020
    • Initialized repository
    • Added devel branch
    • Added:
      • free_cache.bash
      • setup.sh
    • Merged with devel branch
  • September 3, 2020
    • Fixed target to used memory size
    • Fixed target size