Thank you all for help There were 2 problems in my config: 1. viq was right about php, it had to connect to /var/run/mysql/mysql.sock, not to /var/www/var/run/mysql/mysql.sock 2. chaton was right about the soft link
So now everything works fine :) Thanks you once again. BTW Edd, I liked your trick :)