title: SET GLOBAL max_allowed_packet doesn't work
body: <p>I found out how to change the default value of <code>max_allowed_packet</code> in MySQL using <code>SET GLOBAL</code>. However, each time I used this command, the default value stayed untouched! 
  I used these commands:</p>
  
  <pre><code>mysql --user=root --password=mypass
  mysql&gt; SET GLOBAL max_allowed_packet=32*1024*1024;
  Query OK, 0 rows affected (0.00 secs)
  mysql&gt; SHOW VARIABLES max_allowed_packet;
  </code></pre>
  
  <p>And then the result is max_allowed_packet = 1048576. What am I missing? </p>