swauth-prep error

asked 2012-02-17 07:32:07 -0500

kkh1049 gravatar image

my proxy-server.conf

[DEFAULT] cert_file = /etc/swift/cert.crt key_file = /etc/swift/cert.key bind_port = 8080 workers = 8 user = swift

[pipeline:main] pipeline = catch_errors cache swauth proxy-server

[app:proxy-server] use = egg:swift#proxy allow_account_management = true

[filter:swauth] use:egg:swauth#swauth set log_name = swauth super_admin_key = swauthkey default_swift_cluster = local#https://xxx.xxx.xxx.218:8080/v1

[filter:cache] use = egg:swift#memcache memcache_servers = xxx.xxx.xxx.218:11211

[filter:catch_errors] use = egg:swift#catch_errors

swauth-prep -K key -A https://xxx.xxx.xxx.218:8080/v1

Traceback (most recent call last): File "/usr/local/bin/swauth-prep", line 5, in <module> pkg_resources.run_script('swauth==1.0.3.dev', 'swauth-prep') File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 467, in run_script self.require(requires)[0].run_script(script_name, ns) File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1200, in run_script execfile(script_filename, namespace, namespace) File "/usr/local/lib/python2.7/dist-packages/swauth-1.0.3.dev-py2.7.egg/EGG-INFO/scripts/swauth-prep", line 56, in <module> ssl=(parsed.scheme == 'https')) File "/usr/lib/python2.7/dist-packages/swift/common/bufferedhttp.py", line 168, in http_connect_raw conn.endheaders() File "/usr/lib/python2.7/httplib.py", line 951, in endheaders self._send_output(message_body) File "/usr/lib/python2.7/httplib.py", line 811, in _send_output self.send(msg) File "/usr/lib/python2.7/httplib.py", line 773, in send self.connect() File "/usr/lib/python2.7/httplib.py", line 1158, in connect self.sock = ssl.wrap_socket(sock, self.key_file, self.cert_file) File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 285, in wrap_socket return GreenSSLSocket(sock, a, *kw) File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 46, in __init__ super(GreenSSLSocket, self).__init__(sock.fd, args, *kw) File "/usr/lib/python2.7/ssl.py", line 134, in __init__ self.do_handshake() File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 193, in do_handshake super(GreenSSLSocket, self).do_handshake) File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 77, in _call_trampolining return func(a, *kw) File "/usr/lib/python2.7/ssl.py", line 296, in do_handshake self._sslobj.do_handshake() socket.error: [Errno 104] Connection reset by peer

please my problem answer ㅠㅠ

edit retag flag offensive close merge delete

5 answers

Sort by » oldest newest most voted
0

answered 2012-02-17 15:26:27 -0500

btorch gravatar image

try "swauth-prep -K swauthkey -A https://xxx.xxx.xxx.218:8080/auth/%22 (https://xxx.xxx.xxx.218:8080/auth/")

edit flag offensive delete link more
0

answered 2012-02-20 00:32:41 -0500

kkh1049 gravatar image

Dear, Marcelo Martins

Thank you for replying on.

As you told me, I typed the instruction but the following is the log.

swauth-prep -K swauthkey -A https://xxx.xxx.xxx.218:8080/auth/

Traceback (most recent call last): File "/usr/local/bin/swauth-prep", line 5, in <module> pkg_resources.run_script('swauth==1.0.3.dev', 'swauth-prep') File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 467, in run_script self.require(requires)[0].run_script(script_name, ns) File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1200, in run_script execfile(script_filename, namespace, namespace) File "/usr/local/lib/python2.7/dist-packages/swauth-1.0.3.dev-py2.7.egg/EGG-INFO/scripts/swauth-prep", line 56, in <module> ssl=(parsed.scheme == 'https')) File "/usr/lib/python2.7/dist-packages/swift/common/bufferedhttp.py", line 168, in http_connect_raw conn.endheaders() File "/usr/lib/python2.7/httplib.py", line 951, in endheaders self._send_output(message_body) File "/usr/lib/python2.7/httplib.py", line 811, in _send_output self.send(msg) File "/usr/lib/python2.7/httplib.py", line 773, in send self.connect() File "/usr/lib/python2.7/httplib.py", line 1158, in connect self.sock = ssl.wrap_socket(sock, self.key_file, self.cert_file) File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 285, in wrap_socket return GreenSSLSocket(sock, a, *kw) File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 46, in __init__ super(GreenSSLSocket, self).__init__(sock.fd, args, *kw) File "/usr/lib/python2.7/ssl.py", line 134, in __init__ self.do_handshake() File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 193, in do_handshake super(GreenSSLSocket, self).do_handshake) File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 77, in _call_trampolining return func(a, *kw) File "/usr/lib/python2.7/ssl.py", line 296, in do_handshake self._sslobj.do_handshake() socket.error: [Errno 104] Connection reset by peer

edit flag offensive delete link more
0

answered 2012-02-23 02:36:11 -0500

As you are using https, just change the port from 8080 to 443 and try again.

edit flag offensive delete link more
0

answered 2012-02-23 04:45:28 -0500

kkh1049 gravatar image

Dear, amwang

Thank you for replying on

but, that's same problem...

swauth-prep -K swauthkey -A https://xxx.xxx.xxx.218:443/auth/

Traceback (most recent call last): File "/usr/local/bin/swauth-prep", line 5, in <module> pkg_resources.run_script('swauth==1.0.3.dev', 'swauth-prep') File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 467, in run_script self.require(requires)[0].run_script(script_name, ns) File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1200, in run_script execfile(script_filename, namespace, namespace) File "/usr/local/lib/python2.7/dist-packages/swauth-1.0.3.dev-py2.7.egg/EGG-INFO/scripts/swauth-prep", line 56, in <module> ssl=(parsed.scheme == 'https')) File "/usr/lib/python2.7/dist-packages/swift/common/bufferedhttp.py", line 168, in http_connect_raw conn.endheaders() File "/usr/lib/python2.7/httplib.py", line 951, in endheaders self._send_output(message_body) File "/usr/lib/python2.7/httplib.py", line 811, in _send_output self.send(msg) File "/usr/lib/python2.7/httplib.py", line 773, in send self.connect() File "/usr/lib/python2.7/httplib.py", line 1158, in connect self.sock = ssl.wrap_socket(sock, self.key_file, self.cert_file) File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 285, in wrap_socket return GreenSSLSocket(sock, a, *kw) File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 46, in __init__ super(GreenSSLSocket, self).__init__(sock.fd, args, *kw) File "/usr/lib/python2.7/ssl.py", line 134, in __init__ self.do_handshake() File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 193, in do_handshake super(GreenSSLSocket, self).do_handshake) File "/usr/lib/python2.7/dist-packages/eventlet/green/ssl.py", line 77, in _call_trampolining return func(a, *kw) File "/usr/lib/python2.7/ssl.py", line 296, in do_handshake self._sslobj.do_handshake() socket.error: [Errno 104] Connection reset by peer


swift@proxy-218:/etc/swift$ cat proxy-server.conf [DEFAULT] cert_file = /etc/swift/cert.crt key_file = /etc/swift/cert.key bind_port = 443 workers = 8 user = swift

[pipeline:main] pipeline = catch_errors cache swauth proxy-server

[app:proxy-server] use = egg:swift#proxy allow_account_management = true

[filter:swauth] use:egg:swauth#swauth set log_name = swauth super_admin_key = swauthkey default_swift_cluster = local#https://xxx.xxx.xxx.218:443/v1

[filter:cache] use = egg:swift#memcache memcache_servers = xxx.xxx.xxx.218:11211

edit flag offensive delete link more
0

answered 2012-02-23 14:41:31 -0500

btorch gravatar image

Stop all services. Make sure they all indeed have stopped and there is nothing else listening on each of the ports.

Remove SSL so that you can troubleshoot this and once you have things working you can add it.

Then start all the services again. Make sure that the proxy services and the other services are responding properly by doing a healthcheck call to each IP:PORT. Ex: curl -i http://PROXY_IP:PROXY_PORT/healthcheck

Then, try the swauth-prep again, make sure to also check not only the proxy logs but also the account, container, object logs.


swift@proxy-218:/etc/swift$ cat proxy-server.conf [DEFAULT] #cert_file = /etc/swift/cert.crt #key_file = /etc/swift/cert.key bind_port = 8080 workers = 8 user = swift

[pipeline:main] pipeline = catch_errors cache swauth proxy-server

[app:proxy-server] use = egg:swift#proxy allow_account_management = true

[filter:swauth] use:egg:swauth#swauth set log_name = swauth super_admin_key = swauthkey default_swift_cluster = local#https://xxx.xxx.xxx.218:8080/v1

[filter:cache] use = egg:swift#memcache memcache_servers = xxx.xxx.xxx.218:11211

edit flag offensive delete link more

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2012-02-17 07:32:07 -0500

Seen: 196 times

Last updated: Feb 23 '12