MySQL connection via SSH getting ‘reading ini…… packet’ error.

If you access MySQL through SSH tunnel and get "ERROR 2013 (HY000): Lost connection to MySQL server at 'reading initial communication packet', system error: 0" error, this can be indication for a lot of problems, but one of the weirdest is related by disabled “AllowTCPForwarding” option in ssh config.

By default in Ubuntu and Debian it's enabled, but some system administrators for security reason disable this option.

For enabling it again you must have root access or you can kindly ask your system administrator to do it for you.
In different Linux distribution it's my be in different place, but in Ubuntu and Debian it's at /etc/ssh/sshd_config.