Project

General

Profile

Actions

Bug #16581

closed

rgw: error is logged when binding civetweb to an ip

Added by Ruben Kerkhof almost 8 years ago. Updated about 1 year ago.

Status:
Closed
Priority:
Low
Assignee:
-
Target version:
-
% Done:

0%

Source:
other
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

I have the following in /etc/ceph/ceph.conf:

rgw_frontends = "civetweb port=127.0.0.1:7480"

This causes the following to be logged:

Jul 04 12:14:42 localhost radosgw19865: error parsing int: 127.0.0.1:7480: The option value '127.0.0.1:7480' seems to be invalid

It does seem harmless, the daemon starts and binds on 127.0.0.1 just fine, but I wanted to report it nonetheless.

Actions #1

Updated by Abhishek Lekshmanan almost 8 years ago

  • Status changed from New to Need More Info

Actually the value of port needs to be an integer, and not an ip:port... here my guess on what actually ended up happening is, we fell back to the defaults which is port 7480 for civetweb... do you see any error messages when you actually set the port as just an integer value ie. civetweb port=80 or civetweb port=8000 for eg.

Actions #2

Updated by Ruben Kerkhof almost 8 years ago

Abhishek Lekshmanan wrote:

Actually the value of port needs to be an integer, and not an ip:port... here my guess on what actually ended up happening is, we fell back to the defaults which is port 7480 for civetweb...

No, ip:port works just fine. I checked with netstat that Civetweb binds to 127.0.0.1 instead of 0.0.0.0.
This syntax is documented in https://github.com/civetweb/civetweb/blob/5cd3da5ad218b16938251107d74447864832d646/docs/UserManual.md#listening_ports-8080

do you see any error messages when you actually set the port as just an integer value ie. civetweb port=80 or civetweb port=8000 for eg.

No error messages when just specifying the port.

Actions #3

Updated by James Saint-Rossy over 7 years ago

+1. I've confirmed that the civetweb documentation says this is a valid syntax:

https://github.com/civetweb/civetweb/blob/master/docs/UserManual.md#listening_ports-8080

Also I've confirmed that it accepts the syntax:

[root@pistorergw2-cc38-h02 ceph]# systemctl restart ceph-radosgw@rgw.pistorergw2-cc38-h02
[root@pistorergw2-cc38-h02 ceph]# systemctl status ceph-radosgw@rgw.pistorergw2-cc38-h02
● ceph-radosgw@rgw.pistorergw2-cc38-h02.service - Ceph rados gateway
   Loaded: loaded (/usr/lib/systemd/system/ceph-radosgw@.service; enabled; vendor preset: disabled)
   Active: active (running) since Mon 2016-08-01 23:26:46 UTC; 52s ago
 Main PID: 539165 (radosgw)
   CGroup: /system.slice/system-ceph\x2dradosgw.slice/ceph-radosgw@rgw.pistorergw2-cc38-h02.service
           └─539165 /usr/bin/radosgw -f --cluster ceph --name client.rgw.pistorergw2-cc38-h02 --setuser ceph --setgroup ceph

Aug 01 23:26:46 pistorergw2-cc38-h02.ece.comcast.net systemd[1]: Started Ceph rados gateway.
Aug 01 23:26:46 pistorergw2-cc38-h02.ece.comcast.net systemd[1]: Starting Ceph rados gateway...
Aug 01 23:26:46 pistorergw2-cc38-h02.ece.comcast.net radosgw[539165]: error parsing int: 10.251.1.163:1234: The option value '10.251.1.163:1234' seems to be invalid
[root@pistorergw2-cc38-h02 ceph]# netstat -nat | grep 1234
tcp        0      0 10.251.1.163:1234       0.0.0.0:*               LISTEN
Actions #4

Updated by Abhishek Lekshmanan over 7 years ago

  • Status changed from Need More Info to 12
Actions #5

Updated by Abhishek Lekshmanan over 7 years ago

Yeah, we seem to parse port as an integer early, though civetweb seperately gets the conf value as a string, so it does bind correctly. This is also used the env var: SERVER_PORT in rgw error logs etc at full debug where it will be shown as 0 instead of whatever is the original value

Actions #6

Updated by Abhishek Lekshmanan over 7 years ago

  • Status changed from 12 to In Progress
  • Assignee set to Abhishek Lekshmanan
Actions #7

Updated by Abhishek Lekshmanan over 7 years ago

While we're at it, there is an upstream pr support for ssl + civetweb, we could probably address this one also as a part of that pr https://github.com/ceph/ceph/pull/10335

*edit- added pr, ref.

Actions #8

Updated by Abhishek Lekshmanan over 7 years ago

  • Assignee deleted (Abhishek Lekshmanan)

Abhishek Lekshmanan wrote:

While we're at it, there is an upstream support for ssl + civetweb, we could probably address this one also as a part of that pr https://github.com/ceph/ceph/pull/10335

Actions #9

Updated by Casey Bodley about 1 year ago

  • Status changed from In Progress to Closed
Actions

Also available in: Atom PDF