title: mysql change default character set latin1 to utf8
body: <p>I have PHP 5.5.9 and MySQL 5.5.43 Innodb. This is in Kubuntu LTS /etc/mysql/my.cnf</p>
  
  <p>printf("Current character set: %s\n", mysqli_character_set_name($conn));</p>
  
  <p>Current character set: latin1</p>
  
  <p>I've tried </p>
  
  <p>default-character-set = utf8 </p>
  
  <p>first but then my mysql server didn't restart</p>
  
  <p>Then I've tried </p>
  
  <p>character-set-server = utf8</p>
  
  <p>then my mysql shell didn't start</p>
  
  <p>How can I rescue this issue? I've managed with 
  init_connect = 'SET NAMES utf8'
  solve the problem for nonroot users, but the charset remains the same (it only displays as nonprivileged users UTF8, it is still Latin1).</p>
  
  <p>And if (a big if) smnd could tell me WHERE should I use utf8mb4? Also in my.cnf file? I had my tables in utf8 and have migrated those with which I am working to utf8mb4 ...</p>
  
  <p>Another Q: IS that applicable for Linux (Kubuntu) server:
  <a href="https://www.youtube.com/watch?v=3M1Wpw4uOoM" rel="nofollow">https://www.youtube.com/watch?v=3M1Wpw4uOoM</a></p>
  
  <p>Please help me, thanks, Gregor from lilaum.com</p>