IncScheduler eating all my server's CPU

I’m using a VPS with 2 CPUs. But I noticed there are two instances of IncScheduler running and using 99% CPU.

I assume they’re for the local scheduled backup I have set up. Is there a way to limit the amount of CPU these processes will use or to limit it to only a single instance?

seems you have set a scheduled backup and on the time of backups creation usage is always high

Yes I know I’ve scheduled a backup :slight_smile: My question is can I set a limit of how much CPU it is using, or limit the number of processes it starts? Currently it is starting two instances (I’m assuming it starts 1 per CPU?).

You could use any of these three options available to limit any process CPU usage (be aware that this will prolong the backup process):

  1. nice <process>
  2. cpulimit -l 60 <process>
  3. control groups (Cgroups)
sudo cgcreate -g cpu:/restrained
sudo cgset -r cpu.shares=768 restrained
sudo cgexec -g cpu: restrained <process>

Thanks, for am I putting the path to the python file?

nice python_script_name
cpulimit -l 60 -p `pgrep -f python_script_name\.py`

Thanks, where do I put this? Is the backup started by a cron task?

i suggest you to not set any limit and let it be done normally but if you set limit it will take whole day to complete

It’s taking down my site when using 99% CPU. Why is it so inefficient? I’m only running a local backup.