Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

删除网站和数据库后,无法重新安装,提示账号重复 #830

Open
dragonadd opened this issue Dec 5, 2024 · 2 comments
Open

Comments

@dragonadd
Copy link

在利用宝塔面板建立好图床后,然后删除网站和对应的数据库,选择重新建立
image

但是按照同样的步骤,在输入管理员账号邮箱和密码后,却弹出以下代码提醒错误。
image

Dropping all tables .............................................. 25ms DONE

INFO Nothing to migrate.

INFO Seeding database.

Installation error!

SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'app_name' for key 'configs_name_unique' (SQL: insert into `configs` (`created_at`, `name`, `updated_at`, `value`) values (2024-12-05 21:10:35, app_name, 2024-12-05 21:10:35, Lsky Pro), (2024-12-05 21:10:35, app_version, 2024-12-05 21:10:35, V 2.1), (2024-12-05 21:10:35, site_keywords, 2024-12-05 21:10:35, Lsky Pro,lsky,兰空图床), (2024-12-05 21:10:35, site_description, 2024-12-05 21:10:35, Lsky Pro, Your photo album on the cloud.), (2024-12-05 21:10:35, site_notice, 2024-12-05 21:10:35, ), (2024-12-05 21:10:35, icp_no, 2024-12-05 21:10:35, ), (2024-12-05 21:10:35, is_enable_registration, 2024-12-05 21:10:35, 1), (2024-12-05 21:10:35, is_enable_gallery, 2024-12-05 21:10:35, 1), (2024-12-05 21:10:35, is_enable_api, 2024-12-05 21:10:35, 1), (2024-12-05 21:10:35, is_allow_guest_upload, 2024-12-05 21:10:35, 1), (2024-12-05 21:10:35, user_initial_capacity, 2024-12-05 21:10:35, 512000), (2024-12-05 21:10:35, is_user_need_verify, 2024-12-05 21:10:35, 0), (2024-12-05 21:10:35, mail, 2024-12-05 21:10:35, {"default":"smtp","mailers":{"smtp":{"smtp":"smtp","host":"smtp.mailgun.org","port":587,"encryption":"tls","username":"","password":"","timeout":null}}}))
@0xxb
Copy link
Collaborator

0xxb commented Dec 5, 2024

进数据库确认一下数据库是否是空的,没有任何表结构。

@dragonadd
Copy link
Author

dragonadd commented Dec 5, 2024

进数据库确认一下数据库是否是空的,没有任何表结构。

您好,我进入到phpmyadmin里面看,img下面没有表结构,

image
然后我又把数据库删除了重新建网站和数据库,现在错误代码变了,提示如下:

Dropping all tables .............................................. 31ms DONE

INFO Preparing database.

Creating migration table ......................................... 12ms FAIL
Installation error!

SQLSTATE[42S01]: Base table or view already exists: 1050 Table '`img`.`migrations`' already exists (SQL: create table `migrations` (`id` int unsigned not null auto_increment primary key, `migration` varchar(255) not null, `batch` int not null) default character set utf8mb4 collate 'utf8mb4_unicode_ci')

image
已经确定回收站里面的数据库也已经删除了。

而且可以确定,如果新建的数据库不是原来的“img”命名,是可以成功建立、安装成功的。这是什么原因呢?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants