0

I'm trying to view the vm.max_map_count and fs.file-max commands output on terminal of Mac Catalina operating system. But it doesn't work. Can i know the way to view it?

ProductName:    Mac OS X
ProductVersion: 10.15.7
BuildVersion:   19H1323
$ sysctl vm.max_map_count
sysctl: unknown oid 'vm.max_map_count'
$ sysctl fs.file-max
sysctl: unknown oid 'fs.file-max'

Also let me know to set these values permanently on Mac, which files i need to modify?

1 Answers1

1

These are Linux-specific settings (see the documentation for vm.max_map_count and fs.file-max-nr).

On macOS, the equivalent for fs.file-max-nr is kern.maxfiles. I don’t know if there’s an equivalent for vm.max_map_count.

To change these values permanently, add them to /etc/sysctl.conf; in some cases you might need to make other changes, see Why won't kern.maxfiles setting in /etc/sysctl.conf stick?

Stephen Kitt
  • 434,908