From: John Wilkins Date: Tue, 11 Jun 2013 19:12:46 +0000 (-0700) Subject: doc: Added some Java S3 API troubleshooting entries. X-Git-Tag: v0.65~107 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=c7fb7a3f464e50a83dcd18966b671902edf48673;p=ceph.git doc: Added some Java S3 API troubleshooting entries. Signed-off-by: John Wilkins --- diff --git a/doc/radosgw/troubleshooting.rst b/doc/radosgw/troubleshooting.rst index 19221a7ca4af..1a67b7db1341 100644 --- a/doc/radosgw/troubleshooting.rst +++ b/doc/radosgw/troubleshooting.rst @@ -103,4 +103,54 @@ This tells us to look at ``osd.1``, the primary copy for this PG:: ... The ``flag_point`` field indicates that the OSD is currently waiting -for replicas to respond, in this case ``osd.0``. +for replicas to respond, in this case ``osd.0``. + + +Java S3 API Troubleshooting +=========================== + + +Peer Not Authenticated +---------------------- + +You may receive an error that looks like this:: + + [java] INFO: Unable to execute HTTP request: peer not authenticated + +The Java SDK for S3 requires a valid certificate from a recognized certificate +authority, because it uses HTTPS by default. If you are just testing the Ceph +Object Storage services, you can resolve this problem in a few ways: + +#. Prepend the IP address or hostname with ``http://``. For example, change this:: + + conn.setEndpoint("myserver"); + + To:: + + conn.setEndpoint("http://myserver") + +#. After setting your credentials, add a client configuration and set the + protocol to ``Protocol.HTTP``. :: + + AWSCredentials credentials = new BasicAWSCredentials(accessKey, secretKey); + + ClientConfiguration clientConfig = new ClientConfiguration(); + clientConfig.setProtocol(Protocol.HTTP); + + AmazonS3 conn = new AmazonS3Client(credentials, clientConfig); + + + +405 MethodNotAllowed +-------------------- + +If you receive an 405 error, check to see if you have the S3 subdomain set up correctly. +You will need to have a wild card setting in your DNS record for subdomain functionality +to work properly. + +Also, check to ensure that the default site is disabled. + + [java] Exception in thread "main" Status Code: 405, AWS Service: Amazon S3, AWS Request ID: null, AWS Error Code: MethodNotAllowed, AWS Error Message: null, S3 Extended Request ID: null + + +