Questions tagged [sysctl]

sysctl is a mechanism for controlling options and limits in the Unix-like operating system kernels. Sysctls can be used to tune performance or change behaviors of many subsystems.

Linux:
The sysctl command and configuration file use the /proc filesystem's sys directory to read information and apply changes.

The Linux Journal has an article about using sysctl, but most for the most complete information look to this description of /proc/sys's contents.

BSD-derived:
The sysctl command is used to read and configure certain system settings. The Handbook describes its general use in more detail, and the FreeBSD Performance Tuning Community Wiki has some ideas.

120 questions
0
votes
0 answers

Amazon Linux 2023: systcl kernel parameters - network - hardening and tuning review

We are in the process of transitioning to Amazon Gnu/Linux 2023, and during the course of this migration, I came across some Ansible code that modifies kernel parameters. I would greatly appreciate it if you could review the parameters below and…
0
votes
0 answers

Static IPv6 LAN address while using SLAAC for global unicast

I have some IPv6 nodes in two IPv6 networks. There is a single IPv6 router, link-local to all nodes. The router sends out router advertisements(RA) containing two prefixes for the two networks. The nodes in the network accept the RA and create two…
0
votes
0 answers

Keep single IPv6 global unicast address on interface when prefix change

Looking for an option to update address (configured via SLAAC) on interface when new RA was received (maybe with some timeout) I've tried to set net.ipv6.conf.interface.max_addresses, but on network change, original address remained What could be…
0
votes
0 answers

Limit number of connection for a special port on Linux server

I have an Nginx server in Ubuntu 20, And has a multi-port listener on it for the proxy pass. I want to limit the number of connections per port. IP doesn't matter (I mean dont limit by IP). My IPTable has been disabled and I prefer to dont use it. I…
Mohsen
  • 103
  • 5
0
votes
1 answer

Optional sysctl configuration parameters

I am working on some automation that sets linux kernel parameters using sysctl. Specifically I am creating a template that can be deployed to systems with a high amount of connections. The automation can be found here:…
0
votes
1 answer

Which versions of Ubuntu share /etc/sysctl.conf compatibility?

I am looking to secure my Ubuntu 18.04 LTS server and have found a nice script but it was designed for Ubuntu 20.04 LTS which includes changes to /etc/sysctl.conf. Which versions of Ubuntu (or linux in general) share /etc/sysctl.conf compatibility?…
Currn Hyde
  • 11
  • 1
  • 2
0
votes
0 answers

How to determine which resource is exhausted

On a server with a very high load many of my daily cron jobs stopped working. I have postfix server running that only delivers locally so that I can see the output of the cron jobs with mutt. I grepped for cron in the logs and I saw this: Feb 23…
Pablo
  • 179
  • 1
  • 3
  • 13
0
votes
0 answers

Nginx: how to increase backlog (net.core.somaxconn), without changing sysctl.conf? Want to allow many pending connections

I am not running a webapp, but rather a Machine Learning model which needs to provide real-time predictions. Am using Nginx with Gunicorn, both of which are running in a docker container. The setup uses 4 gunicorn workers with 1 thread each (hosting…
0
votes
0 answers

Issue with HAProxy 2.0.7 setup with tproxy on Centos-7

I am Trying to setup HAProxy with transparent proxy on Centos-7 machine. Env: ( 2-http server ==>> HAProxy server ==>> ClientVM ) I have configured http servers with normal haproxy and it works fine. When i configure haproxy.cfg file as…
0
votes
1 answer

sysctl disable IPv6 autoconf

I'm trying to setup IPv6 on my OVH server using their guide. In the article they recommend to disable IPv6 autoconf and router advertising to prevent known issues You can do so by adding the following lines to your sysctl.conf file, which is…
0
votes
1 answer

Portainer: Pass vm.max_map_count to SonarQube Docker container

I need to set up a SonarQube container on my Portainer instance. SonarQube uses Elasticsearch, which needs a kernel setting passed from the host. This issue is well documented, as mentioned in this question, but unfortunately the poster did not…
Will Nilges
  • 67
  • 1
  • 9
-1
votes
1 answer

Changes in fs.* after rebooting?

After rebooting my machine, sysctl -a gave me different outputs (some of changes like kernel.sched_domain.cpu0.domain0.max_newidle_lb_cost is expected): 16c16 < fs.dentry-state = 37641 15280 45 0 0 0 --- > fs.dentry-state =…
HCSF
  • 245
  • 3
  • 14
-1
votes
1 answer

Fixing fs.file-max too small remotely

I was testing some things and breaking things in order to see if I could fix them. I was connected to a remote machine via Putty ssh and ended up changing fs.file-max to a very (comparatively) small number (4096) using the command sudo sysctl -w…
-1
votes
1 answer

available file handles is 0, how to increase

Since some days, we're getting "Too Many Open Files" within an Java application while loading files. So i start searching on Google, and increased fs.file-max to 200000 in my /etc/sysctl.conf. After this, i run sysctl -p. But, this not helped.…
Wouter0100
  • 103
  • 3
-3
votes
2 answers

/sbin/sysctl was overwritten accidentally , How do we restore it CentOS

We accidentally overwrote file /sbin/sysctl with command echo 1 > /sbin/sysctl How do we restore the file in centos?
Rahul
  • 1
1 2 3 4 5 6 7
8