Jump to content

How Schedule Qboost Memory Optimization... for Emby


Recommended Posts

Hispanico957
Posted (edited)

Since even asking QNap support they don't give info/help to be able to use the utility, after several attempts I succeeded and I explain how:

- using WinSCP  or Filezilla etc. create a "Nas" folder (or name of your choice) in share/CACHEDEV1_DATA
- create a .sh file in the folder (which I called cache) using the nano or Vi editor with the following content and save it

#!/bin/sh
/share/CACHEDEV1_DATA/Nas/cache.sh

using Putty in SSH mode go to the folder and type the following command to make the file executable

chmod +x cache.sh

then with the editor nano open crontab

nano /etc/config/crontab

and insert the following lines at the bottom of the list

0 19 * * * /share/CACHEDEV1_DATA/Nas/cache.sh
0 21 * * * /share/CACHEDEV1_DATA/Nas/cache.sh
0 23 * * * /share/CACHEDEV1_DATA/Nas/cache.sh

which means that QBoost (or clear cache utility) starts every day at 19, 21 and 23.

save the crontab file modified in this way and then give the following command to reload the crontab file:

crontab /etc/config/crontab && /etc/init.d/crond.sh restart

This utility and routine is very important using an Emby server on my QNAP, which uses a lot of memory when using.

Attached is a before and after example

Hispa

 

Notes:

- QNap page of reference https://www.qnap.com/en-in/how-to/faq/article/how-to-schedule-qboost-memory-optimization
- QNap page for scheduling https://www.qnap.com/es-es/how-to/faq/article/how-to-add-jobs-to-crontab-to-schedule-a-job
- crontab timing/scheduling reference page https://crontab.guru/
- reference page drop caches to clear cache https://unix.stackexchange.com/questions/17936/setting-proc-sys-vm-drop-caches-to-clear-cache

Senza-titolo.png

Senza-titolo2.png

Edited by Hispanico957
  • Thanks 1
Hispanico957
Posted (edited)

Sorry but I mistyped the command in the .sh file (cache.sh) and here below I report everything correctly and revised:

- using WinSCP  or Filezilla etc. create a "Nas" folder (or name of your choice) in share/CACHEDEV1_DATA
- create a .sh file in the folder (which I called cache) using the nano or Vi editor with the following content and save it

#!/bin/sh
/bin/echo 1 > /proc/sys/vm/drop_caches

using Putty in SSH mode go to the folder and type the following command to make the file executable

chmod +x cache.sh

then with the editor nano open crontab

nano /etc/config/crontab

and insert the following line at the bottom of the list

0 19-23/2 * * * /share/CACHEDEV1_DATA/Nas/cache.sh 

which mean that QBoost (or clear cache utility) starts every day at 19, 21 and 23 (every 2 hours)

save the crontab file modified in this way and then give the following command to reload the crontab file:

crontab /etc/config/crontab && /etc/init.d/crond.sh restart

 

Hispa

 

Edited by Hispanico957
  • Thanks 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...