title: How do I enable transparent huge pages by default on Ubuntu?
body: <p>How do I enable transparent huge pages by default on Ubuntu?</p>
  <pre class="lang-none prettyprint-override"><code>~$ uname -a
  Linux yoda 3.5.0-23-generic #35~precise1-Ubuntu SMP Fri Jan 25 17:13:26 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux
  ~$ cd /sys/kernel/mm/transparent_hugepage/
  /sys/kernel/mm/transparent_hugepage$ ls
  defrag  enabled  khugepaged
  /sys/kernel/mm/transparent_hugepage$ cat enabled 
  always [madvise] never
  /sys/kernel/mm/transparent_hugepage$ sudo echo always &gt; enabled 
  -bash: enabled: Permission denied
  /sys/kernel/mm/transparent_hugepage$ sudo ls
  [sudo] password for &lt;...&gt;: 
  defrag  enabled  khugepaged
  /sys/kernel/mm/transparent_hugepage$ sudo ls
  defrag  enabled  khugepaged
  /sys/kernel/mm/transparent_hugepage$ sudo echo always &gt; enabled 
  -bash: enabled: Permission denied
  /sys/kernel/mm/transparent_hugepage$ cat enabled 
  always [madvise] never
  </code></pre>