[GH-ISSUE #70] Is there a way to reset the database sort of uninstalling photoprism? #20

Closed
opened 2026-03-02 16:47:05 +03:00 by kerem · 4 comments
Owner

Originally created by @bobkoure on GitHub (Apr 8, 2021).
Original GitHub issue: https://github.com/photoprism/photoprism-docs/issues/70

I have a complete copy of my photo archive on a Synology box (which has docker / docker-compose) on it.
I've recently installed photoprism on it.
I pointed photoprism at my photo archive and told it to index.
It turns out that most/all the date/shoot/subject information I have is in hierarchical folder naming and photoprism does not pick that info up. Unfair of me to have expected an app to understand that the entire path was the name of the folder. Agreed that 'folders' is not nearly as good as tags, as photos can only be in one folder - but I was hoping to add that post-index.
So... I need to reset the database, so I can import the folders I want to make available.
Are there any pointers on how to do that, short of a full uninstall/reinstall?
Also, is there a way for me to specify a complete folder name to use during an index? And is there a way to tell index to ignore particular folders - or even file types?
Sorry to add this as an issue, but I'm not finding an answer...
Thanks!

Originally created by @bobkoure on GitHub (Apr 8, 2021). Original GitHub issue: https://github.com/photoprism/photoprism-docs/issues/70 I have a complete copy of my photo archive on a Synology box (which has docker / docker-compose) on it. I've recently installed photoprism on it. I pointed photoprism at my photo archive and told it to index. It turns out that most/all the date/shoot/subject information I have is in hierarchical folder naming and photoprism does not pick that info up. Unfair of me to have expected an app to understand that the entire path was the name of the folder. Agreed that 'folders' is not nearly as good as tags, as photos can only be in one folder - but I was hoping to add that post-index. So... I need to reset the database, so I can import the folders I want to make available. Are there any pointers on how to do that, short of a full uninstall/reinstall? Also, is there a way for me to specify a complete folder name to use during an index? And is there a way to tell index to ignore particular folders - or even file types? Sorry to add this as an issue, but I'm not finding an answer... Thanks!
kerem closed this issue 2026-03-02 16:47:05 +03:00
Author
Owner

@alexislefebvre commented on GitHub (Apr 8, 2021):

It looks like it's unrelated to the documentation? This question can be asked in the discussions of the main repository: https://github.com/photoprism/photoprism/discussions

<!-- gh-comment-id:816040763 --> @alexislefebvre commented on GitHub (Apr 8, 2021): It looks like it's unrelated to the documentation? This question can be asked in the discussions of the main repository: https://github.com/photoprism/photoprism/discussions
Author
Owner

@bobkoure commented on GitHub (Apr 9, 2021):

I will ask there - but you don't think the docs should have this information?

<!-- gh-comment-id:816369551 --> @bobkoure commented on GitHub (Apr 9, 2021): I will ask there - but you don't think the docs should have this information?
Author
Owner

@lastzero commented on GitHub (Apr 13, 2021):

You can create .ppignore files to list files and folders you want to ignore. It should be mentioned in our docs.

To delete the complete database, you can delete the associated docker volume. MariaDB will then start empty. Of course you can also use any standard SQL tool or the mysql command line tool to drop all tables using standard SQL if you prefer that.

We do our best to improve the docs. On the other hand, we don't have the resources to write a complete Linux / MariaDB tutorial covering all circumstances.

<!-- gh-comment-id:818944699 --> @lastzero commented on GitHub (Apr 13, 2021): You can create `.ppignore` files to list files and folders you want to ignore. It should be mentioned in our docs. To delete the complete database, you can delete the associated docker volume. MariaDB will then start empty. Of course you can also use any standard SQL tool or the `mysql` command line tool to drop all tables using standard SQL if you prefer that. We do our best to improve the docs. On the other hand, we don't have the resources to write a complete Linux / MariaDB tutorial covering all circumstances.
Author
Owner

@lastzero commented on GitHub (Apr 13, 2021):

There's also a photoprism reset command to reset / delete the index. You can see all commands by running photoprism help in a terminal. A command reference is as well part of our "Getting Started" docs, scroll to reset database:

https://docs.photoprism.org/getting-started/docker-compose/

<!-- gh-comment-id:818946715 --> @lastzero commented on GitHub (Apr 13, 2021): There's also a `photoprism reset` command to reset / delete the index. You can see all commands by running `photoprism help` in a terminal. A command reference is as well part of our "Getting Started" docs, scroll to **reset database**: https://docs.photoprism.org/getting-started/docker-compose/
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/photoprism-docs#20
No description provided.