There are two places where changes need to be recorded:
sysctl.conf is for setting a system wide ceiling:
# max open files (systemic limit) fs.file-max = 65536
limits.conf is for setting a user space floor and ceiling:
Ensure both a hard limit and a soft limit are set, otherwise the setting will not become active.
For example: to set the number of files any user of the system may have open at a given time to 4096
* soft nofile 4092 * hard nofile 65536