Last active
August 29, 2015 14:07
-
-
Save hawkeyetwolf/338ebc78d7e0722147d9 to your computer and use it in GitHub Desktop.
Increase OS X Open Files Limit
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo '<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Label</key> | |
<string>Increase open files limit</string> | |
<key>ProgramArguments</key> | |
<array> | |
<string>/bin/launchctl</string> | |
<string>limit</string> | |
<string>maxfiles</string> | |
<string>unlimited</string> | |
</array> | |
<key>RunAtLoad</key> | |
<true/> | |
<key>ServiceIPC</key> | |
<false/> | |
</dict> | |
</plist>' | sudo tee /Library/LaunchDaemons/com.apple.launchd.limit.plist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Label</key> | |
<string>Increase open files limit</string> | |
<key>ProgramArguments</key> | |
<array> | |
<string>/bin/launchctl</string> | |
<string>limit</string> | |
<string>maxfiles</string> | |
<string>unlimited</string> | |
</array> | |
<key>RunAtLoad</key> | |
<true/> | |
<key>ServiceIPC</key> | |
<false/> | |
</dict> | |
</plist> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Create in /Library/LaunchDaemons/ with permissions root:wheel 644