summaryrefslogtreecommitdiff
path: root/man/radosgw.8
blob: 3119c57cea92d7b5cddeb70953677bc77cce2a82 (plain)
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
.TH "RADOSGW" "8" "September 22, 2011" "dev" "Ceph"
.SH NAME
radosgw \- rados REST gateway
.
.nr rst2man-indent-level 0
.
.de1 rstReportMargin
\\$1 \\n[an-margin]
level \\n[rst2man-indent-level]
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
-
\\n[rst2man-indent0]
\\n[rst2man-indent1]
\\n[rst2man-indent2]
..
.de1 INDENT
.\" .rstReportMargin pre:
. RS \\$1
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
. nr rst2man-indent-level +1
.\" .rstReportMargin post:
..
.de UNINDENT
. RE
.\" indent \\n[an-margin]
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
.nr rst2man-indent-level -1
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.\" Man page generated from reStructeredText.
.
.SH SYNOPSIS
.nf
\fBradosgw\fP
.fi
.sp
.SH DESCRIPTION
.sp
\fBradosgw\fP is an HTTP REST gateway for the RADOS object store, a part
of the Ceph distributed storage system. It is implemented as a FastCGI
module using libfcgi, and can be used in conjunction with any FastCGI
capable web server.
.SH OPTIONS
.INDENT 0.0
.TP
.B \-c ceph.conf, \-\-conf=ceph.conf
Use \fIceph.conf\fP configuration file instead of the default
\fB/etc/ceph/ceph.conf\fP to determine monitor addresses during startup.
.UNINDENT
.INDENT 0.0
.TP
.B \-m monaddress[:port]
Connect to specified monitor (instead of looking through
\fBceph.conf\fP).
.UNINDENT
.INDENT 0.0
.TP
.B \-\-rgw\-socket\-path=path
Specify a unix domain socket path.
.UNINDENT
.SH CONFIGURATION
.sp
Currently it's the easiest to use the RADOS Gateway with Apache and mod_fastcgi
.sp
.nf
.ft C
FastCgiExternalServer /var/www/s3gw.fcgi -socket /tmp/radosgw.sock

<VirtualHost *:80>
  ServerName rgw.example1.com
  ServerAlias rgw
  ServerAdmin webmaster@example1.com
  DocumentRoot /var/www

  RewriteEngine On
  RewriteRule ^/([a\-zA\-Z0\-9\-_.]*)([/]?.*) /s3gw.fcgi?page=$1&params=$2&%{QUERY_STRING} [E=HTTP_AUTHORIZATION:%{HTTP:Authorization},L]

  <IfModule mod_fastcgi.c>
    <Directory /var/www>
      Options +ExecCGI
      AllowOverride All
      SetHandler fastcgi\-script
      Order allow,deny
      Allow from all
      AuthBasicAuthoritative Off
    </Directory>
  </IfModule>

  AllowEncodedSlashes On
  ServerSignature Off
</VirtualHost>
.ft P
.fi
.sp
And the corresponding radosgw script (/var/www/s3gw.fgci):
.sp
.nf
.ft C
#!/bin/sh
exec /usr/bin/radosgw -c /etc/ceph/ceph.conf -n client.radosgw.gateway
.ft P
.fi
.sp
The radosgw daemon is a standalone process which needs a configuration section in the ceph.conf
The section name should start with 'client.radosgw.' as specified in /etc/init.d/radosgw
.sp
.nf
.ft C
[client.radosgw.gateway]
    host = gateway
    keyring = /etc/ceph/keyring.radosgw.gateway
    rgw socket path = /tmp/radosgw.sock
.ft P
.fi
.sp
You will also have to generate a key for the radosgw to use for authentication with the cluster
.sp
.nf
.ft C
ceph-authtool -C -n client.radosgw.gateway --gen-key /etc/ceph/keyring.radosgw.gateway
ceph-authtool -n client.radosgw.gateway --cap mon 'allow r' --cap osd 'allow rwx' --cap mds 'allow' /etc/ceph/keyring.radosgw.gateway
.ft P
.fi
.sp
And add the key to the auth entries
.sp
.nf
.ft C
ceph auth add client.radosgw.gateway --in-file=keyring.radosgw.gateway
.ft P
.fi
.sp
Now you can start Apache and the radosgw daemon
.sp
.nf
.ft C
/etc/init.d/apache2 start
/etc/init.d/radosgw start
.ft P
.fi
.SH AVAILABILITY
.sp
\fBradosgw\fP is part of the Ceph distributed file system. Please refer
to the Ceph wiki at \fI\%http://ceph.newdream.net/wiki\fP for more
information.
.SH SEE ALSO
.sp
\fBceph\fP(8)
.SH COPYRIGHT
2011, New Dream Network
.\" Generated by docutils manpage writer.
.\" 
.