5 ms·
Sorry but this is really bad 'default' advice. Shocking, but defaults often are default for a reason. Cranking everything up to 11 is a sign of ignorance in w
by kev009 12y ago
Sorry but this is really bad 'default' advice. Shocking, but defaults often are default for a reason. Cranking everything up to 11 is a sign of ignorance in which case you need to step back and understand what you are doing first.
The mmap, file-max, and SHM advice is application dependent. Understand what your system is doing, and only increase if necessary. i.e. PostgreSQL < 9.3 is the only large user of SHM I can think of off hand.
The limits.conf advice is also bad. You should have a safety net here and increase these as needed and per user in /etc/security/limits.d
A less harmful guide would be something like "these are the knobs you may need to turn for certain apps, and here is the documentation on what they affect" - this looks a bit better https://wiki.archlinux.org/index.php/sysctl https://wiki.archlinux.org/index.php/sysctl
- mathnode 12y agoIn fact any RDBMS of a similar design to Ingres requires a larger shmax value including, postgres, sybase axe, and informix.
- colanderman 12y agoYa, this reminds me of car modders who suggest stupid things like drilling holes in your air intake. Any variable whose change (1) is cheap or free, (2) doesn't violate some emissions standard or whatnot, and (3) doesn't cut into profit of a pricier model, is practically guaranteed to be set by the manufacturer at its optimal value for the vehicle's intended use. They're not morons and they have an interest in maximizing the car's utility. Sysctl variables in Linux meet all these same criteria. Linux is already tuned for general use (or is damn close to it). Any knob you tweak is likely to make things worse in a way you don't understand. Just leave things unless you have a specific use case that requires different tuning.
- zorbo 12y ago> is practically guaranteed to be set by the manufacturer at its optimal value The optimal value for what? Speed? Performance? Comfort? Economics? I don't drive a car, but wouldn't trade-offs apply to car tuning just like it does to everything else?
- colanderman 12y agoYou clipped my sentence. "For its intended use", I said. Sporty cars are tuned for performance. Cushy cars are tuned for comfort. Econoboxes are tuned for economy. Of course if you want to make your Yaris do 0-60 in 6.0 s there are changes you can make. But drilling random holes on your STi ain't gonna do shit for its time on the track.
- Cthulhu_ 12y agoSporty cares are tuned for performance, but the really high-end ones are often speed limited, too; I guess some of these settings are the equivalent of removing / turning off the speed limiter, if you know what you're doing / can drive on a proverbial track where you have need for those speeds.
- coldpie 12y agoThat's exactly his point. Those speed limiters aren't there to arbitrarily limit your fun, they're there because the stock wheels and tires can't handle greater speeds. If you don't understand why the limit is there in the first place, you're going to have a nasty surprise when you exceed the tires' limits while going well north of 150 MPH.
- camperman 12y agomplayer and VLC also use SHM and are completely broken with these settings.
- stevekemp 12y agoI put together a simple page of some notes here: http://tweaked.io/guide/kernel/ http://tweaked.io/guide/kernel/ In practice the file-handles tweak is the one that many people seem to forget, and can make a big difference for heavy webservers.
- lloeki 12y agoinstead of blindly suggesting noatime, investigate on nodiratime and relatime, which may or may not be what one needs. Side note: noatime is possible on OSX too [0] [0]: https://github.com/tlvince/noatime-osx/blob/master/com.tlvince.noatime.plist https://github.com/tlvince/noatime-osx/blob/master/com.tlvin...