Location of the sysctl kernel parameters for osX

mac-osxsysctl

I would like to read up on os X kernel parameters. I can find them listed, but where can I find the meaning of them?

For example this parameter

net.alf.loglevel: 55  

which are not in the man pages , for either BSD or osX.

How do people know what to set them to?

EDIT: I have found this link. It has helped me a lot.

Best Answer

The only real way to get all kinds of information about kernel parameters is to read the includes that those variables come from, in Mac OS X the list starts with

  • sys/sysctl.h: definitions for top level identifiers, second level kernel and hardware identifiers, and user level identifiers
  • sys/socket.h: definitions for second level network identifiers
  • sys/gmon.h: definitions for third level profiling identifiers
  • vm/vm_param.h: definitions for second level virtual memory identifiers
  • netinet/in.h: definitions for third level Internet identifiers and fourth level IP identifiers
  • netinet/icmp_var.h: definitions for fourth level ICMP identifiers
  • netinet/udp_var.h: definitions for fourth level UDP identifiers

It's a though read! :)

Also there's no standard way of tuning all these kernel parameters, everyone has different needs and Mac OS X will come preconfigured with values that'll meet "most" but still will leave some people with the need to tweak it, as you want to.

What I normally do if I want to tweak a kernel parameter I don't know much about is to Google it up, read as much as I can about what it does and what other people are doing and why, and from there try a value that can work from me.

Sorry that this is not the easy answer you were looking for, but I hope this will help you find the answers quickly :)

Related Topic