No password for database update - catch 22.
My Zencart site was recently hacked and I decided to update from 1.5.1 to 1.5.5 as part of the fix. Setup a localhost server on my W7 machine and installed Xampp/Apache, MySQL, etc. Got everything going up to the point of updating the database from the old one from my website. When I installed Xampp I didn't put in a password for the SuperUser (me - not the best move I find out) but when it came time to update the database for Zencart, it required a password! Trying to change the password (in phpmyadmin = MySQL) didn't work (if I changed to 'password required', then MySQL wouldn't recognize the database. I can't get the database updated without a password but there isn't one and adding one renders the database unusable - catch22. Any ideas? Is there a way to stop Zencart from requiring a password for the "SuperUser"?
Re: No password for database update - catch 22.
When you say you tried to set the password in phpmyadmin, are you referring to using this FAQ? https://www.zen-cart.com/content.php?44
Or are you referring to a password for the database itself?
Re: No password for database update - catch 22.
Thanks for your quick response. I have to admit that I was a bit confused on which username and password are needed. It does say the user/pw for the Zencart Admin account. I tried the new one for the 1.5.5 I just installed but it didn't work. Doing the "add admin" account (Admin, admin) as you suggested didn't work either. I thought perhaps it should be a database user/pw because that's the point at which is asks for those things. No go.
I finally gave on the database upgrade at this point and went with a fresh install, which went fine. I'll try to update the database later. For people like me who only work on this every 5 years, it's daunting! I do appreciate your help.
Re: No password for database update - catch 22.
Wise choice to go the route of the fresh install first. That is one of the "steps" in the following upgrade FAQ. (hint: deal with one "problem" at a time and generally things will go smoother.)
http://www.zen-cart.com/entry.php?3-...d-of-upgrading
Re: No password for database update - catch 22.
Quote:
Originally Posted by
ryankit
My Zencart site was recently hacked and I decided to update from 1.5.1 to 1.5.5 as part of the fix. Setup a localhost server on my W7 machine and installed Xampp/Apache, MySQL, etc. Got everything going up to the point of updating the database from the old one from my website. When I installed Xampp I didn't put in a password for the SuperUser (me - not the best move I find out) but when it came time to update the database for Zencart, it required a password! Trying to change the password (in phpmyadmin = MySQL) didn't work (if I changed to 'password required', then MySQL wouldn't recognize the database. I can't get the database updated without a password but there isn't one and adding one renders the database unusable - catch22. Any ideas? Is there a way to stop Zencart from requiring a password for the "SuperUser"?
If you replace the admin user and password manually in the .sql file (import) or on screen with a working password it will 'find' the 'correct' Superuser password and continue with the upgrade process.
Note: User ID must be 1 for this to work. Remove or change the ID for any other accounts in series starting after ID 1.
Be sure to use the same user and password you have manually added when you login/upgrade the database.
Re: No password for database update - catch 22.
Quote:
Originally Posted by
twitchtoo
If you replace the admin user and password manually in the .sql file (import) or on screen with a working password it will 'find' the 'correct' Superuser password and continue with the upgrade process.
Note: User ID must be 1 for this to work. Remove or change the ID for any other accounts in series starting after ID 1.
Be sure to use the same user and password you have manually added when you login/upgrade the database.
What in the process or code requires this renumbering?
Re: No password for database update - catch 22.
I think he meant admin_profile_id. In old ZC version this was sometimes 0
Quote:
Originally Posted by
mc12345678
What in the process or code requires this renumbering?
Re: No password for database update - catch 22.
Quote:
Originally Posted by
Design75
I think he meant admin_profile_id. In old ZC version this was sometimes 0
Agree that have sometimes seen issues with "auto-numbered" fields (as they are now at least) having been set/or allowed to be 0 (pre-upgrade). Have seen individual as well as combinations of the admin_id/profile_id incorrectly set as 0 as part of that. I also understand that perhaps it was seen that I was questioning the use of the term 'User ID'; however, in this context I understood that to mean the admin_id and was questioning the need to renumber the values of the admin_id just to have them start at 1 if they were perhaps assigned to some other value and/or why it was stated that it had to be listed first.
Re: No password for database update - catch 22.
Quote:
Originally Posted by
mc12345678
What in the process or code requires this renumbering?
In my experience being set as a super user in the admin wasn't enough to bypass the install error related to the username and password not being a superuser. I changed the ID from 4 to 1 and everything worked - the zc_install could see the superuser and the user/password and the old database upgrade continued as it should.
Re: No password for database update - catch 22.
Quote:
Originally Posted by
mc12345678
Agree that have sometimes seen issues with "auto-numbered" fields (as they are now at least) having been set/or allowed to be 0 (pre-upgrade). Have seen individual as well as combinations of the admin_id/profile_id incorrectly set as 0 as part of that. I also understand that perhaps it was seen that I was questioning the use of the term 'User ID'; however, in this context I understood that to mean the admin_id and was questioning the need to renumber the values of the admin_id just to have them start at 1 if they were perhaps assigned to some other value and/or why it was stated that it had to be listed first.
The old database had listings from 1 - 3 with the 4th being the one I was trying to use. Although it was set as the superuser the ID change from 4 to 1 corrected the problem. Yes I renumbered/removed the other entries to clean things up as well.