gitlab从卸载到放弃

最近要调用gitlab-ci,正好测试环境的huanggai这机器上,安装了gitlab,但是使用起来总有一些问题,应该安装时候的问题吧。决定重装gitlab,首先,我关闭gitlab服务

1
gitlab-ctl stop

但是执行关了这个命令以后,还是有一些gitlab的进程存在

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
[deploy@huanggai /opt/gitlab/sv/unicorn]$ ps aux | grep gitlab
root 3499 0.0 0.0 11420 1296 ? Ss 12:34 0:00 /bin/sh /opt/gitlab/embedded/bin/gitlab-logrotate-wrapper
root 11996 0.0 0.0 35516 3136 ? Ss 13:10 0:00 /opt/gitlab/embedded/sbin/nginx -p /var/opt/gitlab/nginx
git 12016 0.0 0.0 11428 1376 ? Ss 13:10 0:00 /bin/bash /opt/gitlab/embedded/bin/gitlab-unicorn-wrapper
deploy 12054 0.0 0.0 103416 888 pts/1 S+ 13:10 0:00 grep gitlab
root 84470 0.0 0.0 4176 460 ? Ss 11:34 0:02 runsvdir -P /opt/gitlab/service log: to lock directory: /var/log/gitlab/redis-exporter: temporary failure?svlogd: fatal: no functional log directories.?svlogd: warning: unable to lock directory: /var/log/gitlab/postgres-exporter: temporary failure?svlogd: fatal: no functional log directories.?svlogd: warning: unable to lock directory: /var/log/gitlab/node-exporter: temporary failure?svlogd: fatal: no functional log directories.?
root 84471 0.0 0.0 4024 404 ? Ss 11:34 0:02 runsv gitlab-workhorse
root 84477 0.0 0.0 4024 404 ? Ss 11:34 0:02 runsv gitlab-monitor
root 84483 0.0 0.0 4168 520 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/gitlab-workhorse
root 84487 0.0 0.0 4168 520 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/sidekiq
root 84488 0.0 0.0 4168 524 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/prometheus
root 84489 0.0 0.0 4168 524 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/registry
root 84491 0.0 0.0 4168 520 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/gitlab-monitor
root 84492 0.0 0.0 4168 524 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/redis
root 84496 0.0 0.0 4168 524 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/gitaly
root 84498 0.0 0.0 4168 520 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/postgresql
root 84643 0.0 0.0 4168 520 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/unicorn
root 84796 0.0 0.0 4168 524 ? S 11:34 0:00 svlogd -tt /var/log/gitlab/nginx
490 88143 0.0 0.0 125980 5488 ? Ssl 11:34 0:00 /opt/gitlab/embedded/bin/node_exporter -web.listen-address=localhost:9100 -collector.textfile.directory=/var/opt/gitlab/node-exporter/textfile_collector
491 93239 0.0 0.0 121308 4280 ? Ssl 11:12 0:00 /opt/gitlab/embedded/bin/postgres_exporter -web.listen-address=localhost:9187 -extend.query-path=/var/opt/gitlab/postgres-exporter/queries.yaml
root 93241 0.0 0.0 4168 536 ? S 11:12 0:00 svlogd -tt /var/log/gitlab/node-exporter
root 93244 0.0 0.0 4168 536 ? S 11:12 0:00 svlogd -tt /var/log/gitlab/redis-exporter
root 93245 0.0 0.0 4168 540 ? S 11:12 0:00 svlogd -tt /var/log/gitlab/postgres-exporter
490 93247 0.0 0.0 202560 5892 ? Ssl 11:12 0:00 /opt/gitlab/embedded/bin/node_exporter -web.listen-address=localhost:9100 -collector.textfile.directory=/var/opt/gitlab/node-exporter/textfile_collector
492 93249 0.0 0.0 44856 3900 ? Ssl 11:12 0:00 /opt/gitlab/embedded/bin/redis_exporter -web.listen-address=localhost:9121 -redis.addr=unix:///var/opt/gitlab/redis/redis.socket
492 124573 0.0 0.0 44856 3516 ? Ssl 11:35 0:00 /opt/gitlab/embedded/bin/redis_exporter -web.listen-address=localhost:9121 -redis.addr=unix:///var/opt/gitlab/redis/redis.socket
491 127359 0.0 0.0 121308 4008 ? Ssl 11:36 0:00 /opt/gitlab/embedded/bin/postgres_exporter -web.listen-address=localhost:9187 -extend.query-path=/var/opt/gitlab/postgres-exporter/queries.yaml
root 140336 0.0 0.0 4168 444 ? S 12:12 0:00 svlogd -tt /var/log/gitlab/logrotate
[deploy@huanggai /opt/gitlab/sv/unicorn]$

于是我决定把这些进程都杀掉,然后删除gitlab相关的问题,这样就算彻底卸载完成了吧.我用awk过滤出这些进程的Pid,然后调用kill -9 杀掉.

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
[deploy@huanggai /opt/gitlab/sv/unicorn]$ ps aux | grep gitlab | awk '{print $2}' | xargs kill -9
kill 3499: Operation not permitted
kill 72338: Operation not permitted
kill 72389: Operation not permitted
kill 72491: No such process
kill 84470: Operation not permitted
kill 84471: Operation not permitted
kill 84477: Operation not permitted
kill 84483: Operation not permitted
kill 84487: Operation not permitted
kill 84488: Operation not permitted
kill 84489: Operation not permitted
kill 84491: Operation not permitted
kill 84492: Operation not permitted
kill 84496: Operation not permitted
kill 84498: Operation not permitted
kill 84643: Operation not permitted
kill 84796: Operation not permitted
kill 88143: Operation not permitted
kill 93239: Operation not permitted
kill 93241: Operation not permitted
kill 93244: Operation not permitted
kill 93245: Operation not permitted
kill 93247: Operation not permitted
kill 93249: Operation not permitted
kill 124573: Operation not permitted
kill 127359: Operation not permitted
kill 140336: Operation not permitted

这里提示权限不够,原因是gitlab是root用户启动的,我给他加上root权限在执行kill -9

1
2
[deploy@huanggai /opt/gitlab/sv/unicorn]$ ps aux | grep gitlab | awk '{print $2}' | xargs sudo kill -9
kill 92992: No such process

这里有提示进程不存在了,这回我就纳闷了,怎么会进程不存在了呢,92992这个进程并不是上面awk过滤出来的,试了好久,查了很多资料都没有找到这样原因,我想那就手动kill -9 一个一个的杀掉这些进程,当时执行了大概4次kill命令以后,我发现这些经常的个数并没有减少,每次杀到以他又重新启动起来了,让找网上的说法,是杀掉守护进程,就是pid为93032的这个

1
root      93032  0.0  0.0   4176   456 ?        Ss   13:14   0:00 runsvdir -P /opt/gitlab/service log: to lock directory: /var/log/gitlab/node-exporter: temporary failure?svlogd: fatal: no functional log directories.?svlogd: warning: unable to lock directory: /var/log/gitlab/postgres-exporter: temporary failure?svlogd: fatal: no functional log directories.?svlogd: warning: unable to lock directory: /var/log/gitlab/redis-exporter: temporary failure?svlogd: fatal: no functional log directories.?

于是我sudo kill -9 93032杀掉这个进程,我在ps aux | greo gitlab一看,这样经常还在,而且创建时间就是刚才,我注意到了这个进程的启动命令前面有一个runsvdir命令,我man runsvdir并没有找到这个命令的说明,于是我上网查了下,找到了这货的说明,他的是用方式是

1
runsvdir [-P] dir [ log ]

这不就是咋们上面的gitlab命令行的启动方式吗,所以这里我已经大概命令了,gitlab服务的进程被runsvdir管理着,每次我kill了进程,他有会立马他进程给启动起来,与这货关联的还有一个runit,这里我就先不讲这个runit了,下一篇文章再来好好说说他。咋们在回到gitlab卸载的事情上,我进入了/opt/gitlab/service目录,ls 看一下里面都有些啥

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
[deploy@huanggai /opt/gitlab/service]$ ls -al
total 8
drwxr-xr-x 2 root root 4096 Oct 19 11:14 .
drwxr-xr-x 10 root root 4096 Oct 17 12:49 ..
lrwxrwxrwx 1 root root 21 Oct 17 12:50 gitaly -> /opt/gitlab/sv/gitaly
lrwxrwxrwx 1 root root 29 Oct 17 12:50 gitlab-monitor -> /opt/gitlab/sv/gitlab-monitor
lrwxrwxrwx 1 root root 31 Oct 17 12:50 gitlab-workhorse -> /opt/gitlab/sv/gitlab-workhorse
lrwxrwxrwx 1 root root 24 Oct 17 12:50 logrotate -> /opt/gitlab/sv/logrotate
lrwxrwxrwx 1 root root 20 Oct 17 12:50 nginx -> /opt/gitlab/sv/nginx
lrwxrwxrwx 1 root root 28 Oct 17 12:50 node-exporter -> /opt/gitlab/sv/node-exporter
lrwxrwxrwx 1 root root 32 Oct 17 12:50 postgres-exporter -> /opt/gitlab/sv/postgres-exporter
lrwxrwxrwx 1 root root 25 Oct 17 12:49 postgresql -> /opt/gitlab/sv/postgresql
lrwxrwxrwx 1 root root 25 Oct 17 12:50 prometheus -> /opt/gitlab/sv/prometheus
lrwxrwxrwx 1 root root 20 Oct 17 12:49 redis -> /opt/gitlab/sv/redis
lrwxrwxrwx 1 root root 29 Oct 17 12:50 redis-exporter -> /opt/gitlab/sv/redis-exporter
lrwxrwxrwx 1 root root 23 Oct 19 11:14 registry -> /opt/gitlab/sv/registry
lrwxrwxrwx 1 root root 22 Oct 17 12:49 sidekiq -> /opt/gitlab/sv/sidekiq
lrwxrwxrwx 1 root root 22 Oct 17 12:49 unicorn -> /opt/gitlab/sv/unicorn

都是link,那就进入到gitlab-monitor这个link指向的文件夹看看吧

1
2
3
4
5
[deploy@huanggai /opt/gitlab/service/gitlab-monitor]$ ls -l
total 12
drwxr-xr-x 4 root root 4096 Oct 30 18:25 log
-rwxr-xr-x 1 root root 152 Oct 17 12:50 run
drwxr-xr-x 2 root root 4096 Mar 28 13:38 supervise

我有看看了其他的文件,基本都是这个目录结构,三个文件,log, run ,supervise。这个run文件是可执行的,cat看一下

1
2
3
4
5
#!/bin/sh
exec 2>&1

umask 077
exec chpst -P -U git -u git /opt/gitlab/embedded/bin/gitlab-mon web -c /var/opt/gitlab/gitlab-monitor/gitlab-monitor.yml

搜一下,确实有gitlab-mon这个进程,那么现在我把/opt/gitlab这个文件夹删除,然后在杀掉那些进程,应该就不会在被重新启动起来了吧.删除之前看一下这个文件夹下面有那些文件

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
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
[deploy@huanggai /opt]$ tree -L 2 gitlab
gitlab
├── bin
│   ├── gitlab-ctl
│   ├── gitlab-geo-psql
│   ├── gitlab-healthcheck
│   ├── gitlab-psql
│   ├── gitlab-rails
│   └── gitlab-rake
├── dependency_licenses.json
├── embedded
│   ├── bin
│   ├── client_body_temp
│   ├── conf
│   ├── cookbooks
│   ├── etc
│   ├── fastcgi_temp
│   ├── html
│   ├── include
│   ├── lib
│   ├── libexec
│   ├── logs
│   ├── man
│   ├── nodes
│   ├── postgresql
│   ├── proxy_temp
│   ├── sbin
│   ├── scgi_temp
│   ├── selinux
│   ├── service
│   ├── share
│   ├── ssl
│   └── uwsgi_temp
├── etc
│   ├── gitaly
│   ├── gitlab-healthcheck-rc
│   ├── gitlab-psql-rc
│   ├── gitlab-rails
│   ├── gitlab.rb.template
│   ├── gitlab-workhorse
│   └── postgres-exporter
├── init
│   ├── gitaly -> /opt/gitlab/embedded/bin/sv
│   ├── gitlab-monitor -> /opt/gitlab/embedded/bin/sv
│   ├── gitlab-workhorse -> /opt/gitlab/embedded/bin/sv
│   ├── logrotate -> /opt/gitlab/embedded/bin/sv
│   ├── nginx -> /opt/gitlab/embedded/bin/sv
│   ├── node-exporter -> /opt/gitlab/embedded/bin/sv
│   ├── postgres-exporter -> /opt/gitlab/embedded/bin/sv
│   ├── postgresql -> /opt/gitlab/embedded/bin/sv
│   ├── prometheus -> /opt/gitlab/embedded/bin/sv
│   ├── redis -> /opt/gitlab/embedded/bin/sv
│   ├── redis-exporter -> /opt/gitlab/embedded/bin/sv
│   ├── registry -> /opt/gitlab/embedded/bin/sv
│   ├── sidekiq -> /opt/gitlab/embedded/bin/sv
│   └── unicorn -> /opt/gitlab/embedded/bin/sv
├── LICENSE
├── LICENSES
│   ├── bundler-LICENSE.md
│   ├── bzip2-LICENSE
│   ├── cacerts-index.815ca599c9df.txt
│   ├── chef-gem-LICENSE
│   ├── chef-zero-LICENSE
│   ├── config_guess-LICENSE
│   ├── consul-LICENSE
│   ├── curl-COPYING
│   ├── gitaly-LICENSE
│   ├── git-COPYING
│   ├── gitlab-config-template-LICENSE
│   ├── gitlab-cookbooks-LICENSE
│   ├── gitlab-ctl-ee-LICENSE
│   ├── gitlab-ctl-LICENSE
│   ├── gitlab-elasticsearch-indexer-LICENSE
│   ├── gitlab-geo-psql-LICENSE
│   ├── gitlab-healthcheck-LICENSE
│   ├── gitlab-monitor-LICENSE
│   ├── gitlab-psql-LICENSE
│   ├── gitlab-rails-gitlab-gem-licenses
│   ├── gitlab-rails-LICENSE
│   ├── gitlab-scripts-LICENSE
│   ├── gitlab-selinux-LICENSE
│   ├── gitlab-shell-LICENSE
│   ├── gitlab-workhorse-LICENSE
│   ├── jemalloc-COPYING
│   ├── krb5-NOTICE
│   ├── libedit-COPYING
│   ├── libevent-LICENSE
│   ├── libffi-LICENSE
│   ├── libiconv-COPYING.LIB
│   ├── libicu-LICENSE
│   ├── liblzma-COPYING
│   ├── libossp-uuid-README
│   ├── libre2-LICENSE
│   ├── libtool-COPYING
│   ├── libxml2-COPYING
│   ├── libxslt-COPYING
│   ├── libyaml-LICENSE
│   ├── logrotate-COPYING
│   ├── makedepend-COPYING
│   ├── mattermost-GITLAB-MATTERMOST-COMPILED-LICENSE.txt
│   ├── mixlib-log-LICENSE
│   ├── mysql-client-COPYING
│   ├── ncurses-LICENSE
│   ├── nginx-LICENSE
│   ├── node-exporter-LICENSE
│   ├── ohai-LICENSE
│   ├── omnibus-ctl-LICENSE
│   ├── openssl-LICENSE
│   ├── package-scripts-LICENSE
│   ├── pcre-LICENCE
│   ├── pgbouncer-COPYRIGHT
│   ├── pkg-config-lite-COPYING
│   ├── popt-COPYING
│   ├── postgres-exporter-LICENSE
│   ├── postgresql-COPYRIGHT
│   ├── prometheus-LICENSE
│   ├── python3-LICENSE
│   ├── python-docutils-COPYING.txt
│   ├── rb-readline-LICENSE
│   ├── redis-COPYING
│   ├── redis-exporter-LICENSE
│   ├── registry-LICENSE
│   ├── repmgr-LICENSE
│   ├── rsync-COPYING
│   ├── ruby-BSDL
│   ├── ruby-COPYING
│   ├── rubygems-LICENSE.txt
│   ├── ruby-LEGAL
│   ├── runit-COPYING
│   ├── unzip-LICENSE
│   ├── util-macros-COPYING
│   ├── xproto-COPYING
│   └── zlib-README
├── service
│   ├── gitaly -> /opt/gitlab/sv/gitaly
│   ├── gitlab-monitor -> /opt/gitlab/sv/gitlab-monitor
│   ├── gitlab-workhorse -> /opt/gitlab/sv/gitlab-workhorse
│   ├── logrotate -> /opt/gitlab/sv/logrotate
│   ├── nginx -> /opt/gitlab/sv/nginx
│   ├── node-exporter -> /opt/gitlab/sv/node-exporter
│   ├── postgres-exporter -> /opt/gitlab/sv/postgres-exporter
│   ├── postgresql -> /opt/gitlab/sv/postgresql
│   ├── prometheus -> /opt/gitlab/sv/prometheus
│   ├── redis -> /opt/gitlab/sv/redis
│   ├── redis-exporter -> /opt/gitlab/sv/redis-exporter
│   ├── registry -> /opt/gitlab/sv/registry
│   ├── sidekiq -> /opt/gitlab/sv/sidekiq
│   └── unicorn -> /opt/gitlab/sv/unicorn
├── sv
│   ├── gitaly
│   ├── gitlab-monitor
│   ├── gitlab-workhorse
│   ├── logrotate
│   ├── nginx
│   ├── node-exporter
│   ├── postgres-exporter
│   ├── postgresql
│   ├── prometheus
│   ├── redis
│   ├── redis-exporter
│   ├── registry
│   ├── sidekiq
│   └── unicorn
├── var
│   └── unicorn
├── version-manifest.json
└── version-manifest.txt

63 directories, 102 files
[deploy@huanggai /opt]$
[deploy@huanggai /opt]$ pwd
/opt
[deploy@huanggai /opt]$ tree -L 2 /opt/gitlab
/opt/gitlab
├── bin
│   ├── gitlab-ctl
│   ├── gitlab-geo-psql
│   ├── gitlab-healthcheck
│   ├── gitlab-psql
│   ├── gitlab-rails
│   └── gitlab-rake
├── dependency_licenses.json
├── embedded
│   ├── bin
│   ├── client_body_temp
│   ├── conf
│   ├── cookbooks
│   ├── etc
│   ├── fastcgi_temp
│   ├── html
│   ├── include
│   ├── lib
│   ├── libexec
│   ├── logs
│   ├── man
│   ├── nodes
│   ├── postgresql
│   ├── proxy_temp
│   ├── sbin
│   ├── scgi_temp
│   ├── selinux
│   ├── service
│   ├── share
│   ├── ssl
│   └── uwsgi_temp
├── etc
│   ├── gitaly
│   ├── gitlab-healthcheck-rc
│   ├── gitlab-psql-rc
│   ├── gitlab-rails
│   ├── gitlab.rb.template
│   ├── gitlab-workhorse
│   └── postgres-exporter
├── init
│   ├── gitaly -> /opt/gitlab/embedded/bin/sv
│   ├── gitlab-monitor -> /opt/gitlab/embedded/bin/sv
│   ├── gitlab-workhorse -> /opt/gitlab/embedded/bin/sv
│   ├── logrotate -> /opt/gitlab/embedded/bin/sv
│   ├── nginx -> /opt/gitlab/embedded/bin/sv
│   ├── node-exporter -> /opt/gitlab/embedded/bin/sv
│   ├── postgres-exporter -> /opt/gitlab/embedded/bin/sv
│   ├── postgresql -> /opt/gitlab/embedded/bin/sv
│   ├── prometheus -> /opt/gitlab/embedded/bin/sv
│   ├── redis -> /opt/gitlab/embedded/bin/sv
│   ├── redis-exporter -> /opt/gitlab/embedded/bin/sv
│   ├── registry -> /opt/gitlab/embedded/bin/sv
│   ├── sidekiq -> /opt/gitlab/embedded/bin/sv
│   └── unicorn -> /opt/gitlab/embedded/bin/sv
├── LICENSE
├── LICENSES
│   ├── bundler-LICENSE.md
│   ├── bzip2-LICENSE
│   ├── cacerts-index.815ca599c9df.txt
│   ├── chef-gem-LICENSE
│   ├── chef-zero-LICENSE
│   ├── config_guess-LICENSE
│   ├── consul-LICENSE
│   ├── curl-COPYING
│   ├── gitaly-LICENSE
│   ├── git-COPYING
│   ├── gitlab-config-template-LICENSE
│   ├── gitlab-cookbooks-LICENSE
│   ├── gitlab-ctl-ee-LICENSE
│   ├── gitlab-ctl-LICENSE
│   ├── gitlab-elasticsearch-indexer-LICENSE
│   ├── gitlab-geo-psql-LICENSE
│   ├── gitlab-healthcheck-LICENSE
│   ├── gitlab-monitor-LICENSE
│   ├── gitlab-psql-LICENSE
│   ├── gitlab-rails-gitlab-gem-licenses
│   ├── gitlab-rails-LICENSE
│   ├── gitlab-scripts-LICENSE
│   ├── gitlab-selinux-LICENSE
│   ├── gitlab-shell-LICENSE
│   ├── gitlab-workhorse-LICENSE
│   ├── jemalloc-COPYING
│   ├── krb5-NOTICE
│   ├── libedit-COPYING
│   ├── libevent-LICENSE
│   ├── libffi-LICENSE
│   ├── libiconv-COPYING.LIB
│   ├── libicu-LICENSE
│   ├── liblzma-COPYING
│   ├── libossp-uuid-README
│   ├── libre2-LICENSE
│   ├── libtool-COPYING
│   ├── libxml2-COPYING
│   ├── libxslt-COPYING
│   ├── libyaml-LICENSE
│   ├── logrotate-COPYING
│   ├── makedepend-COPYING
│   ├── mattermost-GITLAB-MATTERMOST-COMPILED-LICENSE.txt
│   ├── mixlib-log-LICENSE
│   ├── mysql-client-COPYING
│   ├── ncurses-LICENSE
│   ├── nginx-LICENSE
│   ├── node-exporter-LICENSE
│   ├── ohai-LICENSE
│   ├── omnibus-ctl-LICENSE
│   ├── openssl-LICENSE
│   ├── package-scripts-LICENSE
│   ├── pcre-LICENCE
│   ├── pgbouncer-COPYRIGHT
│   ├── pkg-config-lite-COPYING
│   ├── popt-COPYING
│   ├── postgres-exporter-LICENSE
│   ├── postgresql-COPYRIGHT
│   ├── prometheus-LICENSE
│   ├── python3-LICENSE
│   ├── python-docutils-COPYING.txt
│   ├── rb-readline-LICENSE
│   ├── redis-COPYING
│   ├── redis-exporter-LICENSE
│   ├── registry-LICENSE
│   ├── repmgr-LICENSE
│   ├── rsync-COPYING
│   ├── ruby-BSDL
│   ├── ruby-COPYING
│   ├── rubygems-LICENSE.txt
│   ├── ruby-LEGAL
│   ├── runit-COPYING
│   ├── unzip-LICENSE
│   ├── util-macros-COPYING
│   ├── xproto-COPYING
│   └── zlib-README
├── service
│   ├── gitaly -> /opt/gitlab/sv/gitaly
│   ├── gitlab-monitor -> /opt/gitlab/sv/gitlab-monitor
│   ├── gitlab-workhorse -> /opt/gitlab/sv/gitlab-workhorse
│   ├── logrotate -> /opt/gitlab/sv/logrotate
│   ├── nginx -> /opt/gitlab/sv/nginx
│   ├── node-exporter -> /opt/gitlab/sv/node-exporter
│   ├── postgres-exporter -> /opt/gitlab/sv/postgres-exporter
│   ├── postgresql -> /opt/gitlab/sv/postgresql
│   ├── prometheus -> /opt/gitlab/sv/prometheus
│   ├── redis -> /opt/gitlab/sv/redis
│   ├── redis-exporter -> /opt/gitlab/sv/redis-exporter
│   ├── registry -> /opt/gitlab/sv/registry
│   ├── sidekiq -> /opt/gitlab/sv/sidekiq
│   └── unicorn -> /opt/gitlab/sv/unicorn
├── sv
│   ├── gitaly
│   ├── gitlab-monitor
│   ├── gitlab-workhorse
│   ├── logrotate
│   ├── nginx
│   ├── node-exporter
│   ├── postgres-exporter
│   ├── postgresql
│   ├── prometheus
│   ├── redis
│   ├── redis-exporter
│   ├── registry
│   ├── sidekiq
│   └── unicorn
├── var
│   └── unicorn
├── version-manifest.json
└── version-manifest.txt

63 directories, 102 files

下次再研究下每个文件的功能. 这回再次kill,没有问题,没有启动了.再次访问gitlab的页面,居然还能访问,显示404,说明还有进程没有关闭

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
[deploy@huanggai ~]$ sudo lsof -i:7201
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
nginx 48663 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48664 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48665 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48666 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48667 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48669 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48671 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48672 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48673 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48674 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48675 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48676 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48677 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48678 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48679 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48680 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48681 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48684 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48685 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48695 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48697 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48699 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48702 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48703 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48704 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48706 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48708 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48708 gitlab-www 26u IPv4 2935749941 0t0 TCP huanggai:dlip->shawujing:25189 (ESTABLISHED)
nginx 48709 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48710 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48711 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48712 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)
nginx 48713 gitlab-www 9u IPv4 2916601470 0t0 TCP *:dlip (LISTEN)

好家伙,这货还在

1
sudo lsof -i:7201 | awk '{print $2}' |xargs sudo kill -9

再访问,这回终于停了,至此gitlab已经彻底卸载。