title: Changes to my.cnf don't take effect (Ubuntu 16.04, mysql 5.6)
body: <p>Changes I make to my.cnf don't seem to have any effect on the mysql environment. Here's a summary of what's happened...</p>
  
  <p>I installed mysql 5.7 on Ubuntu 16.04 but then realized I needed to downgrade to mysql 5.6 due to incompatibility issues.</p>
  
  <p>I apt purged the related applications and then removed any remaining directories such at /etc/mysql and /var/lib/mysql</p>
  
  <p>I then installed mysql-5.6 (server and client) and related packages.</p>
  
  <p>I was able to load one database from a dump from a server also running mysql 5.6 but when I tried to load a second database from a second dump from that same server, I got this error:</p>
  
  <pre><code>ERROR 2006 (HY000) at line 1721: MySQL server has gone away
  </code></pre>
  
  <p>When I Googled that, I saw results saying to set various options via the my.cnf file.</p>
  
  <p>When I run...</p>
  
  <pre><code>updatedb &amp;&amp; locate my.cnf
  </code></pre>
  
  <p>...I only see four results which are all links back to the same file: /etc/mysql/my.cnf.fallback. E.g. /etc/mysql/my.cnf.fallback == /etc/mysql/my.cnf</p>
  
  <p>There are no .my.cnf files in either the root home directory or my user's home directory. I put a typo into the my.cnf file and reloaded mysql just to see the expected error and know the file was being loaded. I then removed the erroneous code and added the following:</p>
  
  <pre><code>[mysqld]
  max_allowed_packet=1073741824
  </code></pre>
  
  <p>I then reloaded mysql by running in various ways:</p>
  
  <pre><code>service mysql restart
  </code></pre>
  
  <p>or</p>
  
  <pre><code>service mysql stop
  service mysql start
  </code></pre>
  
  <p>or </p>
  
  <pre><code>/etc/init.d/mysql stop
  /etc/init.d/mysql start
  </code></pre>
  
  <p>I then kept getting this default value indicating that it was not getting set from my.cnf:</p>
  
  <pre><code>mysql&gt; SHOW VARIABLES LIKE 'max_allowed_packet';
  +--------------------+---------+
  | Variable_name      | Value   |
  +--------------------+---------+
  | max_allowed_packet | 4194304 |
  +--------------------+---------+
  </code></pre>
  
  <p>If I do this:</p>
  
  <pre><code>mysql&gt; SET GLOBAL max_allowed_packet=1073741824;
  </code></pre>
  
  <p>and log out and back into the mysql client, I see the correct value:</p>
  
  <pre><code>mysql&gt; SHOW VARIABLES LIKE 'max_allowed_packet';
  +--------------------+------------+
  | Variable_name      | Value      |
  +--------------------+------------+
  | max_allowed_packet | 1073741824 |
  +--------------------+------------+
  </code></pre>
  
  <p>But of course, if I restart the mysql server, the value reverts.</p>
  
  <p>I've exhausted my search ability. What can I possibly be doing wrong?</p>