I wanted to kill all tasks running on my Synology for a package before uninstalling this one. Here is the how-to:
Click to Read More
The tasks running for a service are all listed in /sys/fs/cgroup/cpuacct/[the service]/tasks
The service can be pgsql, nginx, nmbd, ftpd, sshd, … or synotifyd, synologd, synobackupd, … or a package like pkgctl-CloudSync, pkgctl-AudioStation, pkgctl-SurveilanceStation, …
Ex.:
- To see all tasks running for Synology’s StorageAnalyzer, type something like: cat /sys/fs/cgroup/cpuacct/pkgctl-StorageAnalyzer/tasks
- To kill all those tasks, type something like: for task in $(cat /sys/fs/cgroup/cpuacct/pkgctl-StorageAnalyzer/tasks); do kill $task; done
Leave a Reply