Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 19 Aug 2016 10:40:58 +0100
From:      Steve O'Hara-Smith <steve@sohara.org>
To:        freebsd-questions@freebsd.org
Subject:   Re: How do I limit I/O usage for a user/process? A user broke my system
Message-ID:  <20160819104058.1c60a63fb832fbdc1524207c@sohara.org>
In-Reply-To: <CAM4nNt8dOojYNA6FK6_zj7vN92e6ML2A0QbsXH3fz8rP%2BCbVTg@mail.gmail.com>
References:  <CAM4nNt8dOojYNA6FK6_zj7vN92e6ML2A0QbsXH3fz8rP%2BCbVTg@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 19 Aug 2016 09:23:16 +0000
Magnus Ahriman <magnus.ahriman@gmail.com> wrote:

> Hi,
> 
> Today I had a user who decided to open a very large text file in pico. The
> result was a complete denial of service of the system and everything
> stalled/was working veeeeery slowly.

	How much memory have you got on that box, and how much is in use
normally ? It sounds like the system got pushed into swapping by opening
that file.

> Even after the user had killed the process it took quite some while for
> the system to recover and I seemed to notice improvements of certain
> services after having restarted them.
> 
> What are my options to limit resource usage for users? I tried renicing

	Take a look at login.conf it lets you define many limits by login
class - you can assign users to classes using vipw or chpass and of course
with adduser when adding new users.

> the user's process but to no help and the problem was most certainly with
> disk I/O. I don't want a normal user being able to lock up my entire
> system just by viewing text files. So any ideas?

	Very likely the problem was due to memory use and you are tight on
memory for your normal load.

-- 
Steve O'Hara-Smith <steve@sohara.org>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20160819104058.1c60a63fb832fbdc1524207c>