File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -170,6 +170,25 @@ To manually trigger GitLab log rotation with `logrotate`, use the following comm
170
170
/opt/gitlab/embedded/sbin/logrotate -fv -s /var/opt/gitlab/logrotate/logrotate.status /var/opt/gitlab/logrotate/logrotate.conf
171
171
```
172
172
173
+ ### Increase how often logrotate is triggered
174
+
175
+ The logrotate script triggers every 50 minutes and waits for 10 minutes before attempting to rotate the logs.
176
+
177
+ To modify these values:
178
+
179
+ 1 . Edit ` /etc/gitlab/gitlab.rb ` :
180
+
181
+ ``` ruby
182
+ logrotate[' pre_sleep' ] = 600 # sleep 10 minutes before rotating after start-up
183
+ logrotate[' post_sleep' ] = 3000 # wait 50 minutes after rotating
184
+ ```
185
+
186
+ 1 . Reconfigure GitLab:
187
+
188
+ ``` shell
189
+ sudo gitlab-ctl reconfigure
190
+ ```
191
+
173
192
## UDP log forwarding
174
193
175
194
DETAILS:
You can’t perform that action at this time.
0 commit comments