Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Database denied


yusiye

Recommended Posts

Posted

I'm installing oscommerce on my new server, but strange things happened to me this time. I couldn't get over the database installation.

My database host is: 127.0.0.1

username: ysyabc

 

database: ebusiness

 

i always get access denied.

Access denied for user: 'ysyabc@localhost' (Using password: YES)

 

what could be wrong? :'(

 

my config page on cPanel

yusiye_ebusiness

   Users in ebusiness
   yusiye_ysyabc (Privileges: ALL PRIVILEGES)

       Connection Strings
       Perl	$dbh = DBI->connect("DBI:mysql:yusiye_ebusiness:localhost","yusiye_ysyabc","<PASSWORD HERE>");
       PHP	$dbh=mysql_connect ("localhost", "yusiye_ysyabc", "<PASSWORD HERE>") or die ('I cannot connect to the database because: ' . mysql_error());
       mysql_select_db ("yusiye_ebusiness");

 

also I tried use yusiye_ebusiness as database, but didn't work either.

or username: yusiye_ysyabc, something happened.

Posted
nope, still not working

 

Did you try

 

define('DB_SERVER', 'localhost')

 

or is that too obvious?

Local: Mac OS X 10.5.8 - Apache 2.2/php 5.3.0/MySQL 5.4.10 • Web Servers: Linux

Tools: BBEdit, Coda, Versions (Subversion), Sequel Pro (db management)

Posted

looks like i made a mistake, the actaul database is different, but i still get a problem when use the new value

Table 'yusiye_ebusiness.configuration' doesn't exist

Posted

Instructions for cPanel users:

 

1. Click on MySQL Databases.

 

2. Specify a new databasename and click Add Db.

 

3. Specify a new username & password and click Add User.

 

4. Select username from User: dropdown list and database from Db: dropdown list, and click Add User to Db. This will attach the username/password to the database.

 

5. Use the Username, Password and Databasename above for your installation.

 

Please note that some hosts insists on using a prefix on your database name and user name.

 

It will not work unless you ATTACH username&password to the database as in step 4.

 

:thumbsup:

Posted

Hi, I'm having a similar problem setting up my host. I'd rather post it in this thread than start a new one.

 

I'm also stuck on the "adding a database step".

 

I've followed Alpha Ray's instructions to add a new MySQL database, and I have completed that critical step of Adding User to Db.

 

I see this in my CP:

Users in oscommerce
brahm2_admin (Privileges: ALL PRIVILEGES)

   Connection Strings
   Perl	$dbh = DBI->connect("DBI:mysql:brahm2_oscommerce:localhost","brahm2_admin","<PASSWORD HERE>");
   PHP	$dbh=mysql_connect ("localhost", "brahm2_admin", "<PASSWORD HERE>") or die ('I cannot connect to the database because: ' . mysql_error());
   mysql_select_db ("brahm2_oscommerce");

 

When I try to complete the Db step in OScommerce setup, I get "Access Denied" when I use my web address or my shared server's IP address. When I use "localhost" I get "Table 'brahm2_oscommerce.configuration' doesn't exist"

 

I've also tried logging on with every combination of prefixes, lack thereof, and different values for a server with no better luck.

 

I've tried AlanR's step, but to be honest I am new with MySQL and databases, etc, so I don't really know where to go from here.

 

Thanks for any help :)

Posted

Fixed it thanks to some GREAT help on AIM..

 

Here's what I did if anyone ever has the same problem

- Log into CP

- Go to the MySQL tabs

- You should have all of the above stuff set up already

- Run phpMyAdmin

- Click your created Db, then the SQL tab

- Use the location of the textfile box to upload oscommerse.sql which should be in the install directory on your computer

- Done!

 

Now I just have to change a bunch of permissions and stuff. :)

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...