2

On a mis-configured or buggy network filer (NFS NAS) writing a large file can cause the filer to freeze.

For diagnostics I need to be able to:

  1. Suspend (or in other words temporary freeze) all processes of a particular user
  2. Resume the user

Basically, like a kill -s SIGSTOP and kill -s SIGCONT but for the entire user.

To do that, is there a way to temporary take away all CPU-time from a user in Linux?

2 Answers2

4

You can do this more reliably than SIGSTOP and SIGCONT by using the cgroup freezer.

sciurus
  • 12,958
  • 3
  • 33
  • 51
0

Try pkill -STOP -u <username> and resume with pkill -CONT -u <username>

gravyface
  • 13,987