-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
repositories gone when upgrade from 2.2.4 to 2.3.5 #18019
Comments
Maybe related with #17544. |
You should add a semicolon at the end of the sql. |
registry=# select * from task; registry=# select * from execution; The result is nothing. |
Could you try to execute |
[root@harbor_test ~]# docker exec -it harbor-db bash registry=# select * from artifact; registry=# select * from repository; The old repo files of v2.2.4 is in /opt/docker-hub/data/registry/docker/registry/v2/repositories/, but can not find anything in the database |
It seems the database directory/file is incorrect. There is a similar issue, could you please apply this workaround? |
Harbor version: v2.2.4
OS: CentOS Linux release 7.6.1810 (Core)
Docker version:
Client: Docker Engine - Community
Version: 20.10.22
API version: 1.41
Go version: go1.18.9
Git commit: 3a2c30b
Built: Thu Dec 15 22:30:24 2022
OS/Arch:
Context: default
Experimental: true
Server: Docker Engine - Community
Engine:
Version: 20.10.22
API version: 1.41 (minimum version 1.12)
Go version: go1.18.9
Git commit: 42c8b31
Built: Thu Dec 15 22:28:33 2022
OS/Arch: linux/amd64
Experimental: false
containerd:
Version: 1.4.3
GitCommit: 269548fa27e0089a8b8278fc4fc781d7f65a939b
runc:
Version: 1.0.0-rc92
GitCommit: ff819c7e9184c13b7c2607fe6c30ae19403a7aff
docker-init:
Version: 0.19.0
GitCommit: de40ad0
follow the document in https://goharbor.io/docs/2.3.0/administration/upgrade/
![图片](https://user-images.githubusercontent.com/13330963/208896812-c296d18f-e279-4355-9f49-657e6d2350f7.png)
There are no issues during the the process of upgrading and logging.
The harbor.yaml is below:
When I login the harbor, the old repositories are gone, but I can find the files in /opt/docker-hub/data/registry/docker/registry/v2/repositories, it seems that the database has someting wrong: there is no data in table task and execution
![图片](https://user-images.githubusercontent.com/13330963/208895607-34ff9aa1-d40f-4e9d-a4c2-7f6cb8ec4027.png)
The log of harbor-core and harbor-db containers are here:
harbor-core.log
harbor-db.log
By the way, when I try to upgrade from 2.2.4 to 2.4.3, the issue is the same. How could I fix it?
The text was updated successfully, but these errors were encountered: