[FATAL] cannot connect to database

hi everybody !!

          I am trying to install FreePBX-2.3.1 with Asterisk-1.4.19 on my CentOS-5 system.

The problem arose when I was trying to install freepbx. At a stage i was suggested to disable the selinux. After disabling selinux and rebooting the system when i m trying to give ./install_amp command then finally its showing this message :

Connecting to database…FAILED
Try running ./install_amp --usernamename=user --password=pass (using your own user and pass)
[FATAL] Cannot access to database

  After that i gave the previous command using my username and password that i had been set during : Enter your USERNAME to connect to 'asterisk' database:

AND
Enter your PASSWORD to connect to ‘asterisk’ database:

but its still showing the same[FATAL]… error.
SO could anyone of u guyz can kindly help me to sortout this problem plzzzzz…

thanks in advance.

Check MySQL is running, and confirm the root username and password that you use to connect to MySQL. Then run the FreePBX install again. Use this username and password and password this time.

Joe