Page 1 of 1

Could not connect to the database server using the username and password provide

Posted: Wed Oct 22, 2008 4:49 pm
by ixnay
This is my first install of the product and I cannot get past base 1!
Host name is localhost as usual, and I def have the name, username and password set.
What now?
I was looking forward to getting this going todaay. I have never had a problem connecting to datrabases before on this server.
Thanks.
j

Re: Could not connect to the database server using the username and password pro

Posted: Wed Oct 22, 2008 5:09 pm
by bruce
There are currently quite a few versions of opencart. Which one are you using?

Re: Could not connect to the database server using the username and password provide

Posted: Wed Oct 22, 2008 7:24 pm
by Qphoria
I'll ask the silly questions:  ;D

Did you create the db on your isp?
Does your isp prefix your accout name to your db? (like you made db "opencart" and it changed to "ixnay_opencart"
Are you sure you are putting the correct info on the correct field. Sometimes my eyes cross and I see "DB Name" as "DB UserName"

Re: Could not connect to the database server using the username and password pro

Posted: Wed Oct 22, 2008 8:19 pm
by bruce
good questions, never the less  :D

Re: Could not connect to the database server using the username and password provide

Posted: Wed Oct 22, 2008 9:39 pm
by ixnay
..and the correct questions it would appear! I am so used to entering db name first, then user details. Its a lame excuse I know, but the only one I have. Thanks!
So its all installed but I am getting permission errors. I believe I set all the permissions as specced, but have a look:

http://www.opallingerie.com/store/

Thanks very much
J

Re: Could not connect to the database server using the username and password provide

Posted: Wed Oct 22, 2008 9:42 pm
by Qphoria
ixnay wrote: So its all installed but I am getting permission errors. I believe I set all the permissions as specced, but have a look:

http://www.opallingerie.com/store/
First guess, be sure the cache folder and image folders are set to 755, I'm not sure if thats the permission as spec'd or not. But its just a first guess

Re: Could not connect to the database server using the username and password provide

Posted: Thu Oct 23, 2008 12:03 am
by ixnay
Yes, set to 755

Re: Could not connect to the database server using the username and password provide

Posted: Thu Oct 23, 2008 4:47 am
by randomfactor
Whu .. huh?

cache, image, image/cache, and download all need to be set 0777 (not 0755) because apache typically runs as a different user than the ftp user that uploaded the files.

Re: Could not connect to the database server using the username and password provide

Posted: Thu Oct 23, 2008 4:48 am
by Qphoria
hmm.. mine are 755
In fact, my host, for security reasons, won't let me go higher than 755

Re: Could not connect to the database server using the username and password provide

Posted: Thu Oct 23, 2008 6:47 pm
by ixnay
Sorted! Thanks. I have reset all permissions, including those to 777 and now it opens without errors.

"apache typically runs as a different user than the ftp user that uploaded the files."

Thats true and a very good point. It would also explain why you sometimes cannot delete folders from test installs on php/sql applications.

So, I am looking forward to getting to grips with this cart. Its SO great to have something that is British, and is as simple as it needs to be (but no simpler, to quote Einstein)
Kudos to the developers and contributors, and more power to ye!

Cheers