mirror of
https://gitea.invidious.io/iv-org/documentation.git
synced 2024-08-15 00:53:34 +00:00
Updated About the database and tables (markdown)
This commit is contained in:
parent
fd059de486
commit
4c9eb2c131
1 changed files with 7 additions and 0 deletions
|
@ -9,6 +9,13 @@ Invidious needs one PostgreSQL database with five tables.
|
||||||
The table `videos` grows a lot and needs the most storage. You can clean it up using following commands:
|
The table `videos` grows a lot and needs the most storage. You can clean it up using following commands:
|
||||||
```bash
|
```bash
|
||||||
$ sudo -i -u postgres
|
$ sudo -i -u postgres
|
||||||
|
$ psql invidious -c "DELETE FROM nonces * WHERE expire < current_timestamp"
|
||||||
$ psql invidious -c "TRUNCATE TABLE videos"
|
$ psql invidious -c "TRUNCATE TABLE videos"
|
||||||
$ exit
|
$ exit
|
||||||
|
```
|
||||||
|
|
||||||
|
For regular maintenance you should add a cronjob for these commands
|
||||||
|
```bash
|
||||||
|
@weekly psql invidious -c "DELETE FROM nonces * WHERE expire < current_timestamp"
|
||||||
|
@weekly psql invidious -c "TRUNCATE TABLE videos"
|
||||||
```
|
```
|
Loading…
Reference in a new issue