After Installing Ubuntu Server finished. Let's use
#sudo passwd root
Make sure you have LAMP stack installed.
#tasksel install lamp-server
Then install Cacti package.
#apt-get install cacti cacti-spine
-Screen WARNING: include path for php has changed! > Enter
-Which kind of web server should be used by cacti? Select Apache2 > Enter
-Configure database for cacti with dbconfig-common? Yes > Enter
-Password of your database's administrative user: type root'spassword > Enter
-MySQL application password for cacti: type cacti's password ex.123456 > Enter
-Password confirmation: type cacti's password again.
Access http://server/cacti/ using user: admin and password: admin
Cacti will ask you to change password so then you can access.