Interval pushing cpu to 100%

Describe the problem/error/question

I was trying to be smart ( clearly not smart ) used an expression to set the interval ( seconds ) and its forcing the cpu to 100% - as such i cant get the web interface to respond, the browser just times out.

After a lot of effort, i can get the ssh to connect very slowly…

Is there a way to remove the expression or stop the interval( stop the cron?? ) or disable the workflow or anything else similar, from the command line… i was thinking disabling the workflow from the db??

but how do I do any of that from the command line.

What is the error message (if any)?

browser times out

Please share your workflow

Information on your n8n setup

running via docker with default, so sqlite…

Hey @Nathan,

Welcome to the community :raised_hands:

Using an expression to set the interval shouldn’t break it so it would be nice to know what you were using for the expression.

If the workflow is activated you could try using the cli in the container to disable the workflow but if it isn’t enabled and is causing issues you could try exporting the workflows with the cli then deleting the database and starting again with the workflow exports.

n8n cli docs: CLI commands | n8n Docs

Thanks for the thoughts on the cli…

the expression,

Math.floor(Math.random() * (1000 - 60 + 1)) + 60

rather than a fixed time, i wanted to have it change between 1 and 15ish minutes.

It only started being an issue after I enabled it… so will try the cli option you describe and will come back to you…

Hey @Nathan,

I have just given it a go just because I am curious to know what value it will use for the schedule as we register the schedule when you click activate and I am not sure what a dynamic value would actually do.

How long did it take to crash for you and are you using the schedule node or an older interval node?

1 Like

the web interface died almost immediately… hence i assumed it was this… however if it uses the value at activate i guess thats not executing this code over and over, so maybe something else is wrong?? but she is still running along at 100% and cant even get the command line just now! i am using interval not schedule.

Excuse the newbie question, when I ssh to the machine, and try and execute “n8n update:workflow --all --active=false” i get a n8n command not found.

Is there something I need to do to get it so cli commands work?

What version of n8n are you running? We removed the interval node from the node list a while back or did you find it from a workflow template?

As you are using Docker you would first need to access the container so it could be something like the below where the first n8n is the name of the container.

docker exec -u node -it n8n n8n update:workflow --all --active=false

when i get back in, i will confirm versions!

Its a docker install from about 2 months ago… so feasibly when i get stable and update everything, thei node will go away!

thanks for the docker command… will try !

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.