How to tune network options and others in SCALE?

So I’m getting familiar with the methods of tuning ZFS parameters.

echo 274877906944 >> /sys/module/zfs/parameters/zfs_arc_max

as an example. However, I read lots of threads that talk about other tuning metrics for SMB or network configurations and I’m not sure how I should be configuring those parameters.

For example, reading this post he talks about configuring options like net.inet.ip.intr_queue_maxlen: 2048, or this post with options like net.ipv4.tcp_window_scaling = 1.

How exactly do I set those parameters? For ZFS you would do the echo method above, but with other non-zfs parameters, how are those set?
Would you set them in init/shutdown section? If so, what is the syntax? Or would you be better off setting them in a *.conf file, and if so, where?