Welcome to mirror list, hosted at ThFree Co, Russian Federation.

storage.md « raketasks « administration « doc - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: bac8fa4bd9dd685fe6f7b12e8fc7735e02bbeee3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
# Repository Storage Rake Tasks

This is a collection of rake tasks you can use to help you list and migrate 
existing projects from Legacy storage to the new Hashed storage type.

You can read more about the storage types [here][storage-types].

## List projects on Legacy storage

To have a simple summary of projects using **Legacy** storage:

**Omnibus Installation**

```bash
gitlab-rake gitlab:storage:legacy_projects
```

**Source Installation**

```bash
rake gitlab:storage:legacy_projects

```

------

To list projects using **Legacy** storage:

**Omnibus Installation**

```bash
gitlab-rake gitlab:storage:list_legacy_projects
```

**Source Installation**

```bash
rake gitlab:storage:list_legacy_projects

```

## List projects on Hashed storage

To have a simple summary of projects using **Hashed** storage:

**Omnibus Installation**

```bash
gitlab-rake gitlab:storage:hashed_projects
```

**Source Installation**

```bash
rake gitlab:storage:hashed_projects

```

------

To list projects using **Hashed** storage:

**Omnibus Installation**

```bash
gitlab-rake gitlab:storage:list_hashed_projects
```

**Source Installation**

```bash
rake gitlab:storage:list_hashed_projects

```

## Migrate existing projects to Hashed storage

Before migrating your existing projects, you should 
[enable hashed storage][storage-migration] for the new projects as well.

This task will schedule all your existing projects to be migrated to the 
**Hashed** storage type:

**Omnibus Installation**

```bash
gitlab-rake gitlab:storage:migrate_to_hashed
```

**Source Installation**

```bash
rake gitlab:storage:migrate_to_hashed

```

You can monitor the progress in the _Admin > Monitoring > Background jobs_ screen.
There is a specific Queue you can watch to see how long it will take to finish: **project_migrate_hashed_storage**

After it reaches zero, you can confirm every project has been migrated by running the commands above.
If you find it necessary, you can run this migration script again to schedule missing projects.

Any error or warning will be logged in the sidekiq log file.


[storage-types]: ../repository_storage_types.md
[storage-migration]: ../repository_storage_types.md#how-to-migrate-to-hashed-storage