for example, when user creates an account, resets password etc.
First step is to set mail server credentials in LocalSettings.php file, as per this document: http://www.mediawiki.org/wiki/Manual_talk:$wgSMTP#Example_using_Google_Mail
But after you do this, you will get "PEAR mail package is not installed" error message. How to solve this?
Turns out it's relatively simple:
Open web manager (http://domain.name/index.php) and install the following packages in PEAR (not sure if some of them are redundant but after I installed them, i was able to connect to GMAIL server)
Rename index.php into index.php.pear, and go-pear.php into go-pear.php.pear, and rename index.php.old back to index.php
Try to register - you should get an email