質問編集履歴
7
問題の訂正
test
CHANGED
File without changes
|
test
CHANGED
@@ -212,7 +212,7 @@
|
|
212
212
|
|
213
213
|
```
|
214
214
|
|
215
|
-
[error] 6439#0: *251 connect() to unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock failed (111: Connection refused) while connecting to upstream, client:
|
215
|
+
[error] 6439#0: *251 connect() to unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock failed (111: Connection refused) while connecting to upstream, client: xxx.xx.xx.xx, server: IPアドレス, request: "GET / HTTP/1.1", upstream: "http://unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock:/", host: "IPアドレス"
|
216
216
|
|
217
217
|
```
|
218
218
|
|
@@ -222,6 +222,10 @@
|
|
222
222
|
|
223
223
|
|
224
224
|
|
225
|
+
またclientとserverは異なる数字でも問題ないのでしょうか?
|
226
|
+
|
227
|
+
|
228
|
+
|
225
229
|
この問題が原因だった場合nginx側の設定をどの様に変更すれば解決できるのでしょうか?
|
226
230
|
|
227
231
|
わかる方がいれば教えて頂きたいですm(_ _)m
|
6
内容の詳細提示
test
CHANGED
File without changes
|
test
CHANGED
@@ -8,7 +8,7 @@
|
|
8
8
|
|
9
9
|
```
|
10
10
|
|
11
|
-
[error] 6439#0: *2
|
11
|
+
[error] 6439#0: *251 connect() to unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock failed (111: Connection refused) while connecting to upstream, client: 219.66.81.44, server: IPアドレス, request: "GET / HTTP/1.1", upstream: "http://unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock:/", host: "IPアドレス"
|
12
12
|
|
13
13
|
```
|
14
14
|
|
@@ -203,3 +203,25 @@
|
|
203
203
|
を行うと".unicorn.sock" [Permission Denied]と表示されます。
|
204
204
|
|
205
205
|
これが原因なのでしょうか?
|
206
|
+
|
207
|
+
|
208
|
+
|
209
|
+
##追記
|
210
|
+
|
211
|
+
``/var/www/rails/ToDoGame/backend/log/nginx.error.log``
|
212
|
+
|
213
|
+
```
|
214
|
+
|
215
|
+
[error] 6439#0: *251 connect() to unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock failed (111: Connection refused) while connecting to upstream, client: 219.66.81.44, server: IPアドレス, request: "GET / HTTP/1.1", upstream: "http://unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock:/", host: "IPアドレス"
|
216
|
+
|
217
|
+
```
|
218
|
+
|
219
|
+
の ``http://unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock:/`` が怪しいのでしょうか?
|
220
|
+
|
221
|
+
この場合``unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock:/``になるべきなのでしょうか?
|
222
|
+
|
223
|
+
|
224
|
+
|
225
|
+
この問題が原因だった場合nginx側の設定をどの様に変更すれば解決できるのでしょうか?
|
226
|
+
|
227
|
+
わかる方がいれば教えて頂きたいですm(_ _)m
|
5
ファイル場所の提示
test
CHANGED
File without changes
|
test
CHANGED
@@ -192,7 +192,7 @@
|
|
192
192
|
|
193
193
|
気になる点
|
194
194
|
|
195
|
-
|
195
|
+
``/var/www/rails/ToDoGame/backend/tmp/sockets``
|
196
196
|
|
197
197
|
```
|
198
198
|
|
4
詳細の提示
test
CHANGED
File without changes
|
test
CHANGED
@@ -187,3 +187,19 @@
|
|
187
187
|
I, [2020-09-26T06:25:59.828147 #7380] INFO -- : worker=0 ready
|
188
188
|
|
189
189
|
```
|
190
|
+
|
191
|
+
|
192
|
+
|
193
|
+
気になる点
|
194
|
+
|
195
|
+
|
196
|
+
|
197
|
+
```
|
198
|
+
|
199
|
+
[Kazuki@ip-10-0-0-59 sockets]$ sudo vi .unicorn.sock
|
200
|
+
|
201
|
+
```
|
202
|
+
|
203
|
+
を行うと".unicorn.sock" [Permission Denied]と表示されます。
|
204
|
+
|
205
|
+
これが原因なのでしょうか?
|
3
unicornのlogを追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -167,3 +167,23 @@
|
|
167
167
|
srwxrwxrwx 1 Kazuki Kazuki 0 Sep 26 06:25 /var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock
|
168
168
|
|
169
169
|
```
|
170
|
+
|
171
|
+
|
172
|
+
|
173
|
+
``/var/www/rails/ToDoGame/backend/log/unicorn.log``
|
174
|
+
|
175
|
+
```
|
176
|
+
|
177
|
+
I, [2020-09-26T06:25:59.160571 #7375] INFO -- : Refreshing Gem list
|
178
|
+
|
179
|
+
I, [2020-09-26T06:25:59.815317 #7375] INFO -- : unlinking existing socket=/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock
|
180
|
+
|
181
|
+
I, [2020-09-26T06:25:59.815457 #7375] INFO -- : listening on addr=/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock fd=9
|
182
|
+
|
183
|
+
I, [2020-09-26T06:25:59.820600 #7375] INFO -- : master process ready
|
184
|
+
|
185
|
+
I, [2020-09-26T06:25:59.827812 #7381] INFO -- : worker=1 ready
|
186
|
+
|
187
|
+
I, [2020-09-26T06:25:59.828147 #7380] INFO -- : worker=0 ready
|
188
|
+
|
189
|
+
```
|
2
質問内容の詳細提示
test
CHANGED
File without changes
|
test
CHANGED
@@ -155,3 +155,15 @@
|
|
155
155
|
[Kazuki@ip-10-0-0-59 sockets]$ ls
|
156
156
|
|
157
157
|
```
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
|
162
|
+
|
163
|
+
```
|
164
|
+
|
165
|
+
[Kazuki@ip-10-0-0-59 ~]$ ls -l /var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock
|
166
|
+
|
167
|
+
srwxrwxrwx 1 Kazuki Kazuki 0 Sep 26 06:25 /var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock
|
168
|
+
|
169
|
+
```
|
1
内容の詳細提示
test
CHANGED
File without changes
|
test
CHANGED
@@ -108,6 +108,50 @@
|
|
108
108
|
|
109
109
|
![イメージ説明](64c20c737bd77c7b416bc162dcba1c05.png)
|
110
110
|
|
111
|
+
一ヶ月くらいデプロイできない状態が続いており、かなり苦しいです。解決策を知っている方がいれば教えていただきたいです!
|
111
112
|
|
112
113
|
|
114
|
+
|
115
|
+
##unicorn関連
|
116
|
+
|
117
|
+
unicornの起動確認
|
118
|
+
|
119
|
+
```
|
120
|
+
|
113
|
-
|
121
|
+
[Kazuki@ip-10-0-0-59 ~]$ ps -ef | grep unicorn | grep -v grep
|
122
|
+
|
123
|
+
Kazuki 7375 1 0 06:25 ? 00:00:00 unicorn_rails master -c /var/www/rails/ToDoGame/backend/config/unicorn.conf.rb -D -E production
|
124
|
+
|
125
|
+
Kazuki 7380 7375 0 06:25 ? 00:00:00 unicorn_rails worker[0] -c /var/www/rails/ToDoGame/backend/config/unicorn.conf.rb -D -E production
|
126
|
+
|
127
|
+
Kazuki 7381 7375 0 06:25 ? 00:00:00 unicorn_rails worker[1] -c /var/www/rails/ToDoGame/backend/config/unicorn.conf.rb -D -E production
|
128
|
+
|
129
|
+
```
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
unix:/var/www/rails/ToDoGame/backend/tmp/sockets/.unicorn.sock の存在確認
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
``/var/www/rails/ToDoGame/backend/tmp/sockets``
|
138
|
+
|
139
|
+
```
|
140
|
+
|
141
|
+
[Kazuki@ip-10-0-0-59 sockets]$ ls -a
|
142
|
+
|
143
|
+
. .. .unicorn.sock
|
144
|
+
|
145
|
+
```
|
146
|
+
|
147
|
+
|
148
|
+
|
149
|
+
気になるのがlsだけでは表示されないことです。
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
```
|
154
|
+
|
155
|
+
[Kazuki@ip-10-0-0-59 sockets]$ ls
|
156
|
+
|
157
|
+
```
|