100% CPU usage #17

Open
opened 2022-10-16 16:09:34 +02:00 by rmanach · 2 comments
rmanach commented 2022-10-16 16:09:34 +02:00 (Migrated from gitea.thegux.fr)

htop shown 100% CPU usage by simple-auth. strace on the child thread shows:

epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1
epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1
epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1
epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1
epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1
epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1

How is this possible since there's no error in log ? Brute force attack by a bot ?

NOTE: log the client ip address and/or block some?

**htop** shown 100% CPU usage by `simple-auth`. **strace** on the child thread shows: ```log epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1 epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1 epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1 epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1 epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1 epoll_wait(3, [{events=EPOLLIN, data={u32=2147483648, u64=2147483648}}], 1024, -1) = 1 ``` How is this possible since there's no error in log ? Brute force attack by a bot ? **NOTE**: log the client ip address and/or block some?
rmanach commented 2022-10-16 16:20:10 +02:00 (Migrated from gitea.thegux.fr)

To limit the CPU usage (temp solution), add CPUQuota parameter on the service:

CPUQuota=10%

see documentation for more details.

To limit the CPU usage (temp solution), add CPUQuota parameter on the service: ```bash CPUQuota=10% ``` see [documentation](https://www.man7.org/linux/man-pages/man5/systemd.resource-control.5.html) for more details.
rmanach commented 2022-11-07 12:20:03 +01:00 (Migrated from gitea.thegux.fr)
seems related to: https://gitea.thegux.fr/rmanach/system/issues/8
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: rmanach/simple-auth#17
No description provided.