Search Type:
Search for:

Language:

Product:
Category:
No categories for selected product

Upgrade to Plesk 8.2 failed with the "Duplicate entry 'localhost-admin' for key 1" error.

Article ID: 2013 
Last Review: Mar,19 2009
Author: Vitaly Malakhov
Last updated by: Vitaly Malakhov APPLIES TO:
  • Plesk 8.2 for Linux/Unix

Symptoms

Upgrade to Plesk 8.2 fails with the following error:

===> Installing psa database
mysqld (pid 2064) is running...
 Trying to define valid mysql credentials...  Trying to establish test
connection... connected
done
 Trying to remove chunks from MySQL database... ERROR 1062 (23000) at line 3:
Duplicate entry 'localhost-admin' for key 1

ERROR while trying to remove chunks from MySQL database



Cause

This problem occurs if the record  for 'root' user exists in mysql.user table. Plesk tries to rename 'root' user to 'admin' and fails with the error.


Resolution

Rename 'root' mysql user to some other and rerun the upgrade with '--force' option:

# mysql -uadmin -p`cat /etc/psa/.psa.shadow `  mysql -e 'update user set user="root_user" where user="root";flush privileges;'
# rpm -Uvh --force ./*



 After upgrade is done, rename 'root' user back if you need it.

# mysql -uadmin -p`cat /etc/psa/.psa.shadow `  mysql -e 'update user set user="root" where user="root_user";flush privileges;'


Subscription for changes to this article Subscription for changes to this article

Please provide feedback on this article

Did this article help you solve your issue?
Yes
No
Partially
I do not know yet
 
Strongly Agree   Strongly Disagree
  9 8 7 6 5 4 3 2 1
The article is easy to understand
The article is accurate
Additional Comments:
*Please provide us with your email address in case we need to contact you.
* - required fields
 
 
 
 
 
 
For Home
For Business
For Hosters
For SaaS
For Developers
 
Desktop Virtualization
- Parallels Desktop Switch to Mac Edition
- Parallels Desktop for Mac
- Parallels Desktop 4 for Windows & Linux
- Parallels Workstation Extreme
- Parallels Solution for Windows 7
Server Virtualization
- Parallels Server for Mac
- Parallels Server 4 Bare Metal
- Parallels Virtuozzo Containers
Automation
- Parallels Operations Automation
- Parallels Business Automation
- Parallels Virtual Automation
- Parallels Plesk Panel Suite
More Products