RE: ceph cli delay when one mon is down

2014-01-15 Thread Dietmar Maurer
 Caching the last successfully connected mon isn't a bad idea either...
 care to open a feature ticket?

http://tracker.ceph.com/issues/7150

--
To unsubscribe from this list: send the line unsubscribe ceph-devel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


v0.75 contributors credits ( experimental)

2014-01-15 Thread Loic Dachary
Hi Ceph,

Here is a sorted list of authors and organizations who contributed to v0.75, by 
number of commits or reviews back to v0.74. The affiliation of authors to 
organizations can be updated by submitting a patch to 
https://github.com/ceph/ceph/blob/master/.organizationmap

If you are curious about how it is done, the details are at the end of this 
mail. 

Commits by authors
 1  104 Sage Weil s...@inktank.com
 2   86 Loic Dachary l...@dachary.org
 3   18 Noah Watkins noah.watk...@inktank.com
 4   12 David Zafman david.zaf...@inktank.com
 58 Josh Durgin josh.dur...@inktank.com
 67 John Wilkins john.wilk...@inktank.com
 76 Samuel Just sam.j...@inktank.com
 84 Yan, Zheng zheng.z@intel.com
 93 Ken Dreyer ken.dre...@inktank.com
102 Yehuda Sadeh yeh...@inktank.com
112 Greg Farnum g...@inktank.com
122 Gary Lowell gary.low...@inktank.com
132 David Moreau Simard dmsim...@iweb.com
142 Christophe Courtaut christophe.court...@gmail.com
151 Yan, Zheng uker...@gmail.com
161 Xihui He xihu...@gmail.com
171 Rutger ter Borg rut...@terborg.net
181 Kun Huang academicgar...@gmail.com
191 Jonathan Dieter jdie...@lesbg.com
201 Dan Mick dan.m...@inktank.com
211 Bjørnar Ness bjornar.n...@gmail.com
221 Andreas Peters andreas.joachim.pet...@cern.ch
Commits by organizations
 1  165 Inktank cont...@inktank.com
 2   88 Cloudwatt libre.licens...@cloudwatt.com
 34 Intel cont...@intel.com
 42 IWeb cont...@iweb.com
 51 Yan, Zheng uker...@gmail.com
 61 Xihui He xihu...@gmail.com
 71 Rutger ter Borg rut...@terborg.net
 81 Kun Huang academicgar...@gmail.com
 91 Jonathan Dieter jdie...@lesbg.com
101 CERN cont...@cern.ch
111 Bjørnar Ness bjornar.n...@gmail.com
Reviews by authors
 1   28 Sage Weil s...@inktank.com
 26 Loic Dachary l...@dachary.org
 36 Josh Durgin josh.dur...@inktank.com
 43 Samuel Just sam.j...@inktank.com
 52 Yan, Zheng zheng.z@intel.com
 62 João Eduardo Luís joao.l...@inktank.com
 72 Greg Farnum g...@inktank.com
 82 Dan Mick dan.m...@inktank.com
 91 Yehuda Sadeh yeh...@inktank.com
101 Roald J. van Loon ro...@roaldvanloon.nl
111 Noah Watkins noah.watk...@inktank.com
121 David Moreau Simard dmsim...@iweb.com
131 Andreas Peters andreas.joachim.pet...@cern.ch
Reviews by organizations
 1   45 Inktank cont...@inktank.com
 26 Cloudwatt libre.licens...@cloudwatt.com
 32 Intel cont...@intel.com
 41 Roald van Loon Consultancy ro...@roaldvanloon.nl
 51 IWeb cont...@iweb.com
 61 CERN cont...@cern.ch

The script used to generate this output is (copy paste at the root of a git 
clone https://github.com/ceph/ceph.git):

cat  credits.sh 'EOF'
previous_version=$1
next_version=$2

echo Commits by authors
git log --after $previous_version --before $next_version --pretty='%aN %aE' | 
sort | uniq -c | sort -rn | nl
echo Commits by organizations
git log --after $previous_version --before $next_version --pretty='%aN %aE' | 
git -c mailmap.file=.organizationmap check-mailmap --stdin | sort | uniq -c | 
sort -rn | nl
echo Reviews by authors
git log --after $previous_version --before $next_version --pretty=%b | perl -n 
-e 'print $_\n if(s/^\s*Reviewed-by:\s*(.*.*)\s*$/\1/)' | git check-mailmap 
--stdin | sort | uniq -c | sort -rn | nl
echo Reviews by organizations
git log --after $previous_version --before $next_version --pretty=%b | perl -n 
-e 'print $_\n if(s/^\s*Reviewed-by:\s*(.*.*)\s*$/\1/)' | git check-mailmap 
--stdin | git -c mailmap.file=.organizationmap check-mailmap --stdin | sort | 
uniq -c | sort -rn | nl
EOF
v0_74=2013-12-30 ; v0_75=2014-01-14 ; bash credits.sh $v0_74 $v0_75

Authors names are normalized with .mailmap and authors affiliations to a given 
organization comes from .organizationmap, both of which can be found and 
patched at the root of the ceph source tree.

-- 
Loïc Dachary, Artisan Logiciel Libre



signature.asc
Description: OpenPGP digital signature


Re: [Ceph-community] v0.75 contributors credits ( experimental)

2014-01-15 Thread Patrick McGarry
Andrew,

We have some of that at metrics.ceph.com (and are planning to add a
release-specific aspect to it).  What parts of stackalytics do you
think are the best things to include?  Right now I'm thinking of the
following for each tagged major release:

* new committers
* total committers during this release cycle
* lines of code added
* commits
* list messages during the release cycle
* irc messages during release cycle
* Activity per repository this release cycle (perhaps we can help
break out by module: rgw/rbd/mds/rados/core?)

Anything I'm missing?



Best Regards,

Patrick McGarry
Director, Community || Inktank
http://ceph.com  ||  http://inktank.com
@scuttlemonkey || @ceph || @inktank


On Wed, Jan 15, 2014 at 10:47 AM, Andrew Woodward xar...@gmail.com wrote:
 Loric,

 Have you seen the stackalytics project that we use for OpenStack?

 http://www.stackalytics.com/
 https://github.com/Mirantis/stackalytics



 On Wed, Jan 15, 2014 at 12:21 AM, Loic Dachary l...@dachary.org wrote:

 Hi Ceph,

 Here is a sorted list of authors and organizations who contributed to
 v0.75, by number of commits or reviews back to v0.74. The affiliation of
 authors to organizations can be updated by submitting a patch to
 https://github.com/ceph/ceph/blob/master/.organizationmap

 If you are curious about how it is done, the details are at the end of
 this mail.

 Commits by authors
  1  104 Sage Weil s...@inktank.com
  2   86 Loic Dachary l...@dachary.org
  3   18 Noah Watkins noah.watk...@inktank.com
  4   12 David Zafman david.zaf...@inktank.com
  58 Josh Durgin josh.dur...@inktank.com
  67 John Wilkins john.wilk...@inktank.com
  76 Samuel Just sam.j...@inktank.com
  84 Yan, Zheng zheng.z@intel.com
  93 Ken Dreyer ken.dre...@inktank.com
 102 Yehuda Sadeh yeh...@inktank.com
 112 Greg Farnum g...@inktank.com
 122 Gary Lowell gary.low...@inktank.com
 132 David Moreau Simard dmsim...@iweb.com
 142 Christophe Courtaut christophe.court...@gmail.com
 151 Yan, Zheng uker...@gmail.com
 161 Xihui He xihu...@gmail.com
 171 Rutger ter Borg rut...@terborg.net
 181 Kun Huang academicgar...@gmail.com
 191 Jonathan Dieter jdie...@lesbg.com
 201 Dan Mick dan.m...@inktank.com
 211 Bjørnar Ness bjornar.n...@gmail.com
 221 Andreas Peters andreas.joachim.pet...@cern.ch
 Commits by organizations
  1  165 Inktank cont...@inktank.com
  2   88 Cloudwatt libre.licens...@cloudwatt.com
  34 Intel cont...@intel.com
  42 IWeb cont...@iweb.com
  51 Yan, Zheng uker...@gmail.com
  61 Xihui He xihu...@gmail.com
  71 Rutger ter Borg rut...@terborg.net
  81 Kun Huang academicgar...@gmail.com
  91 Jonathan Dieter jdie...@lesbg.com
 101 CERN cont...@cern.ch
 111 Bjørnar Ness bjornar.n...@gmail.com
 Reviews by authors
  1   28 Sage Weil s...@inktank.com
  26 Loic Dachary l...@dachary.org
  36 Josh Durgin josh.dur...@inktank.com
  43 Samuel Just sam.j...@inktank.com
  52 Yan, Zheng zheng.z@intel.com
  62 João Eduardo Luís joao.l...@inktank.com
  72 Greg Farnum g...@inktank.com
  82 Dan Mick dan.m...@inktank.com
  91 Yehuda Sadeh yeh...@inktank.com
 101 Roald J. van Loon ro...@roaldvanloon.nl
 111 Noah Watkins noah.watk...@inktank.com
 121 David Moreau Simard dmsim...@iweb.com
 131 Andreas Peters andreas.joachim.pet...@cern.ch
 Reviews by organizations
  1   45 Inktank cont...@inktank.com
  26 Cloudwatt libre.licens...@cloudwatt.com
  32 Intel cont...@intel.com
  41 Roald van Loon Consultancy ro...@roaldvanloon.nl
  51 IWeb cont...@iweb.com
  61 CERN cont...@cern.ch

 The script used to generate this output is (copy paste at the root of a
 git clone https://github.com/ceph/ceph.git):

 cat  credits.sh 'EOF'
 previous_version=$1
 next_version=$2

 echo Commits by authors
 git log --after $previous_version --before $next_version --pretty='%aN
 %aE' | sort | uniq -c | sort -rn | nl
 echo Commits by organizations
 git log --after $previous_version --before $next_version --pretty='%aN
 %aE' | git -c mailmap.file=.organizationmap check-mailmap --stdin | sort |
 uniq -c | sort -rn | nl
 echo Reviews by authors
 git log --after $previous_version --before $next_version --pretty=%b |
 perl -n -e 'print $_\n if(s/^\s*Reviewed-by:\s*(.*.*)\s*$/\1/)' | git
 check-mailmap --stdin | sort | uniq -c | sort -rn | nl
 echo Reviews by organizations
 git log --after $previous_version --before $next_version --pretty=%b |
 perl -n -e 'print $_\n if(s/^\s*Reviewed-by:\s*(.*.*)\s*$/\1/)' | git
 

[no subject]

2014-01-15 Thread Elite Homes
Apply today for an affordable loan at 3% interest rate, kindly reply if 
interested.
--
To unsubscribe from this list: send the line unsubscribe ceph-devel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [Ceph-community] v0.75 contributors credits ( experimental)

2014-01-15 Thread Loic Dachary


On 15/01/2014 16:47, Andrew Woodward wrote:
 Loic,
 
 Have you seen the stackalytics project that we use for OpenStack? 
 
 http://www.stackalytics.com/
 https://github.com/Mirantis/stackalytics
 

Hi Andrew, 

I know of stackalytics and recently updated my affiliations there ;-) 

The purpose of this tiny script is originally to be of use to metrics.ceph.com 
: it can read from https://github.com/ceph/ceph/blob/master/.organizationmap to 
figure out the affiliation of authors. More importantly, authors can update 
this information with the same path they use on a daily basis to contribute to 
ceph itself: there is nothing to learn to fix a mistake or add a new 
affiliation. The command line is also a convenient way to see that the mapping 
works, without the need to deploy a graphical user interface.

And to answer Patrick's question : what I would like to see is a count of 
reviewers in a graphical user interface. It is important to me ( and probably 
others ) when I explain to my employer the nature of the work I do in Ceph. If 
reviews show on a leaderboard, it is easier to explain why it is important to 
keep the project healthy because other developers also spend time reviewing.

Cheers

 
 
 On Wed, Jan 15, 2014 at 12:21 AM, Loic Dachary l...@dachary.org 
 mailto:l...@dachary.org wrote:
 
 Hi Ceph,
 
 Here is a sorted list of authors and organizations who contributed to 
 v0.75, by number of commits or reviews back to v0.74. The affiliation of 
 authors to organizations can be updated by submitting a patch to 
 https://github.com/ceph/ceph/blob/master/.organizationmap
 
 If you are curious about how it is done, the details are at the end of 
 this mail.
 
 Commits by authors
  1  104 Sage Weil s...@inktank.com mailto:s...@inktank.com
  2   86 Loic Dachary l...@dachary.org mailto:l...@dachary.org
  3   18 Noah Watkins noah.watk...@inktank.com 
 mailto:noah.watk...@inktank.com
  4   12 David Zafman david.zaf...@inktank.com 
 mailto:david.zaf...@inktank.com
  58 Josh Durgin josh.dur...@inktank.com 
 mailto:josh.dur...@inktank.com
  67 John Wilkins john.wilk...@inktank.com 
 mailto:john.wilk...@inktank.com
  76 Samuel Just sam.j...@inktank.com 
 mailto:sam.j...@inktank.com
  84 Yan, Zheng zheng.z@intel.com 
 mailto:zheng.z@intel.com
  93 Ken Dreyer ken.dre...@inktank.com 
 mailto:ken.dre...@inktank.com
 102 Yehuda Sadeh yeh...@inktank.com 
 mailto:yeh...@inktank.com
 112 Greg Farnum g...@inktank.com mailto:g...@inktank.com
 122 Gary Lowell gary.low...@inktank.com 
 mailto:gary.low...@inktank.com
 132 David Moreau Simard dmsim...@iweb.com 
 mailto:dmsim...@iweb.com
 142 Christophe Courtaut christophe.court...@gmail.com 
 mailto:christophe.court...@gmail.com
 151 Yan, Zheng uker...@gmail.com mailto:uker...@gmail.com
 161 Xihui He xihu...@gmail.com mailto:xihu...@gmail.com
 171 Rutger ter Borg rut...@terborg.net 
 mailto:rut...@terborg.net
 181 Kun Huang academicgar...@gmail.com 
 mailto:academicgar...@gmail.com
 191 Jonathan Dieter jdie...@lesbg.com 
 mailto:jdie...@lesbg.com
 201 Dan Mick dan.m...@inktank.com 
 mailto:dan.m...@inktank.com
 211 Bjørnar Ness bjornar.n...@gmail.com 
 mailto:bjornar.n...@gmail.com
 221 Andreas Peters andreas.joachim.pet...@cern.ch 
 mailto:andreas.joachim.pet...@cern.ch
 Commits by organizations
  1  165 Inktank cont...@inktank.com mailto:cont...@inktank.com
  2   88 Cloudwatt libre.licens...@cloudwatt.com 
 mailto:libre.licens...@cloudwatt.com
  34 Intel cont...@intel.com mailto:cont...@intel.com
  42 IWeb cont...@iweb.com mailto:cont...@iweb.com
  51 Yan, Zheng uker...@gmail.com mailto:uker...@gmail.com
  61 Xihui He xihu...@gmail.com mailto:xihu...@gmail.com
  71 Rutger ter Borg rut...@terborg.net 
 mailto:rut...@terborg.net
  81 Kun Huang academicgar...@gmail.com 
 mailto:academicgar...@gmail.com
  91 Jonathan Dieter jdie...@lesbg.com 
 mailto:jdie...@lesbg.com
 101 CERN cont...@cern.ch mailto:cont...@cern.ch
 111 Bjørnar Ness bjornar.n...@gmail.com 
 mailto:bjornar.n...@gmail.com
 Reviews by authors
  1   28 Sage Weil s...@inktank.com mailto:s...@inktank.com
  26 Loic Dachary l...@dachary.org mailto:l...@dachary.org
  36 Josh Durgin josh.dur...@inktank.com 
 mailto:josh.dur...@inktank.com
  43 Samuel Just sam.j...@inktank.com 
 mailto:sam.j...@inktank.com
  52 Yan, Zheng zheng.z@intel.com 
 mailto:zheng.z@intel.com
  62 João Eduardo Luís 

[PATCH v2 0/2] Add ceph root filesystem functionality and documentation.

2014-01-15 Thread mark . doffman
From: Mark Doffman mark.doff...@codethink.co.uk

Hi All,

The following is a second version of a patch series that adds the ability to use
a ceph distributed file system as the root device.

Changes from version 1

fs/ceph/root.c:

The parsing code that takes the DHCP option 17 and kernel command line
parameters has been extensively altered.

The parsing now accepts multiple monitor addresses and ipv6 addresses.

The monitors listed in DHCP option 17 are now concatenated with those
listed on the kernel command line.

The patch series applies to v3.13-rc8-7-g3539717

Thanks

Mark

Mark Doffman (1):
  init: Add a new root device option, the Ceph file system

Rob Taylor (1):
  Documentation: Document the cephroot functionality

 Documentation/filesystems/{ = ceph}/ceph.txt |   0
 Documentation/filesystems/ceph/cephroot.txt   |  86 +
 fs/ceph/Kconfig   |  10 ++
 fs/ceph/Makefile  |   1 +
 fs/ceph/root.c| 176 ++
 include/linux/ceph/ceph_root.h|  10 ++
 include/linux/root_dev.h  |   1 +
 init/do_mounts.c  |  32 -
 net/ipv4/ipconfig.c   |  10 +-
 9 files changed, 323 insertions(+), 3 deletions(-)
 rename Documentation/filesystems/{ = ceph}/ceph.txt (100%)
 create mode 100644 Documentation/filesystems/ceph/cephroot.txt
 create mode 100644 fs/ceph/root.c
 create mode 100644 include/linux/ceph/ceph_root.h

-- 
1.8.4

--
To unsubscribe from this list: send the line unsubscribe ceph-devel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 2/4] Documentation: Document the cephroot functionality

2014-01-15 Thread Mark Doffman

Hi Sage,

On 12/06/2013 11:57 PM, Sage Weil wrote:

On Wed, 20 Nov 2013, mark.doff...@codethink.co.uk wrote:

From: Rob Taylor rob.tay...@codethink.co.uk

Document using the cephfs as a root device, its purpose,
functionality and use.

Signed-off-by: Mark Doffman mark.doff...@codethink.co.uk
Signed-off-by: Rob Taylor rob.tay...@codethink.co.uk
Reviewed-by: Ian Molton ian.mol...@codethink.co.uk
---
  Documentation/filesystems/{ = ceph}/ceph.txt |  0
  Documentation/filesystems/ceph/cephroot.txt   | 81 +++
  2 files changed, 81 insertions(+)
  rename Documentation/filesystems/{ = ceph}/ceph.txt (100%)
  create mode 100644 Documentation/filesystems/ceph/cephroot.txt

diff --git a/Documentation/filesystems/ceph.txt 
b/Documentation/filesystems/ceph/ceph.txt
similarity index 100%
rename from Documentation/filesystems/ceph.txt
rename to Documentation/filesystems/ceph/ceph.txt
diff --git a/Documentation/filesystems/ceph/cephroot.txt 
b/Documentation/filesystems/ceph/cephroot.txt
new file mode 100644
index 000..ae0f5bb
--- /dev/null
+++ b/Documentation/filesystems/ceph/cephroot.txt
@@ -0,0 +1,81 @@
+Mounting the root filesystem via Ceph (cephroot)
+===
+
+Written 2013 by Rob Taylor rob.tay...@codethink.co.uk
+
+derived from nfsroot.txt:
+
+Written 1996 by Gero Kuhlmann g...@gkminix.han.de
+Updated 1997 by Martin Mares m...@atrey.karlin.mff.cuni.cz
+Updated 2006 by Nico Schottelius nico-kernel-nfsr...@schottelius.org
+Updated 2006 by Horms ho...@verge.net.au
+
+
+
+In order to use a diskless system, such as an X-terminal or printer server
+for example, it is necessary for the root filesystem to be present on a
+non-disk device. This may be an initramfs (see Documentation/filesystems/
+ramfs-rootfs-initramfs.txt), a ramdisk (see Documentation/initrd.txt), a
+filesystem mounted via NFS or a filesystem mounted via Ceph. The following
+text describes on how to use Ceph for the root filesystem.
+
+For the rest of this text 'client' means the diskless system, and 'server'
+means the Ceph server.
+
+
+1.) Enabling cephroot capabilities
+-
+
+In order to use cephroot, CEPH_FS needs to be selected as
+built-in during configuration. Once this has been selected, the cephroot
+option will become available, which should also be selected.
+
+In the networking options, kernel level autoconfiguration can be selected,
+along with the types of autoconfiguration to support. Selecting all of
+DHCP, BOOTP and RARP is safe.
+
+
+2.) Kernel command line
+---
+
+When the kernel has been loaded by a boot loader (see below) it needs to be
+told what root fs device to use. And in the case of cephroot, where to find
+both the server and the name of the directory on the server to mount as root.
+This can be established using the following kernel command line parameters:
+
+root=/dev/ceph
+
+This is necessary to enable the pseudo-Ceph-device. Note that it's not a
+real device but just a synonym to tell the kernel to use Ceph instead of
+a real device.
+
+cephroot=monaddr:/[subdir],ceph-opts
+
+  monaddr Monitor address. Each takes the form host[:port]. If the port
+   is not specified, the Ceph default of 6789 is assumed.
+
+  subdir   A subdirectory subdir may be specified if a subset of the file
+   system is to be mounted
+
+  ceph-optsStandard Ceph options. All options are separated by commas.
+   See Documentation/filesystems/ceph/ceph.txt for options and
+   their defaults.


Maybe there is an existing convention here, but: it seems like it would be
simpler to do something like

  cephroot=ip[:port][,...]:/[subdir]

i.e., the existing syntax used by mount, that (among other things) can
also include a port, or be a list of mon ips, so that the parsing code
can be re-used.  Then,

  cephopts=ceph-opts

Hopefully this would avoid the parsing in root.c and make things behave
more consistently with respect to how mount(8) is used?


This would make things more consistent with mount, and easier! The 
reason to keep it the way it is is for consistency with NFS and DHCP 
option 17.


NFS concatenates the options in DHCP root-path (option 17) with the ones 
placed on the kernel command line. We could separate out the device and 
path strings from the options, but they would still be merged together 
in the DHCP string. Some parsing would still be required to split the 
DHCP string and merge with command line options. I'd prefer to keep them 
together on the command line also, just to have things stay similar to NFS.


Thanks

Mark



sage


+
+4.) References
+--
+
+
+5.) Credits
+---
+
+  cephroot was derived from nfsroot by Rob Taylor rob.tay...@codethink.co.uk
+  and Mark Doffman mark.doff...@codethink.co.uk
+
+  The nfsroot code in the kernel and the RARP support have been written
+  by Gero Kuhlmann g...@gkminix.han.de.
+
+  The rest of the 

[PATCH v2 1/2] init: Add a new root device option, the Ceph file system

2014-01-15 Thread mark . doffman
From: Mark Doffman mark.doff...@codethink.co.uk

Analogous to NFS add a new root device option, the ability
to boot using the Ceph networked file system as the root fs.

This patch adds a new root device option '/dev/ceph' that
uses a ceph networked file system. File system parameters
are passed using a new kernel parameter: 'cephroot'.

The 'cephroot' parameters are very similar to 'nfsroot'.

Signed-off-by: Mark Doffman mark.doff...@codethink.co.uk
Reviewed-by: Ian Molton ian.mol...@codethink.co.uk
---
 fs/ceph/Kconfig|  10 +++
 fs/ceph/Makefile   |   1 +
 fs/ceph/root.c | 176 +
 include/linux/ceph/ceph_root.h |  10 +++
 include/linux/root_dev.h   |   1 +
 init/do_mounts.c   |  32 +++-
 net/ipv4/ipconfig.c|  10 ++-
 7 files changed, 237 insertions(+), 3 deletions(-)
 create mode 100644 fs/ceph/root.c
 create mode 100644 include/linux/ceph/ceph_root.h

diff --git a/fs/ceph/Kconfig b/fs/ceph/Kconfig
index ac9a2ef..325e83d 100644
--- a/fs/ceph/Kconfig
+++ b/fs/ceph/Kconfig
@@ -25,3 +25,13 @@ config CEPH_FSCACHE
  caching support for Ceph clients using FS-Cache
 
 endif
+
+config ROOT_CEPH
+   bool Root file system on Ceph FS
+   depends on CEPH_FS=y  IP_PNP
+   help
+ If you want your system to mount its root file system via CEPH,
+ choose Y here.  For details, read
+ file:Documentation/filesystems/ceph/cephroot.txt.
+
+ If unsure say N.
diff --git a/fs/ceph/Makefile b/fs/ceph/Makefile
index 32e3010..af2dcbf 100644
--- a/fs/ceph/Makefile
+++ b/fs/ceph/Makefile
@@ -10,3 +10,4 @@ ceph-y := super.o inode.o dir.o file.o locks.o addr.o ioctl.o 
\
debugfs.o
 
 ceph-$(CONFIG_CEPH_FSCACHE) += cache.o
+ceph-$(CONFIG_ROOT_CEPH) += root.o
diff --git a/fs/ceph/root.c b/fs/ceph/root.c
new file mode 100644
index 000..1559c19
--- /dev/null
+++ b/fs/ceph/root.c
@@ -0,0 +1,176 @@
+/*
+ * Copyright (C) 2012 Codethink Ltd. mark.doff...@codethink.co.uk
+ *
+ * This file is released under the GPL v2
+ *
+ * Allow a CephFS filesystem to be mounted as root.
+ */
+
+#include linux/kernel.h
+#include linux/types.h
+#include linux/string.h
+#include linux/init.h
+#include linux/slab.h
+#include linux/utsname.h
+#include linux/root_dev.h
+#include linux/in.h
+#include net/ipconfig.h
+#include linux/ceph/ceph_root.h
+
+#define MAXPATHLEN 1024
+
+/* Parameters passed from the kernel command line */
+static char ceph_command_line_params[256] __initdata;
+
+/* server:path string passed to mount */
+static char ceph_root_device[MAXPATHLEN + 1] __initdata;
+
+/* Name of directory to mount */
+static char ceph_export_path[MAXPATHLEN + 1] __initdata;
+
+/* Mount options */
+static char ceph_root_options[256] __initdata;
+
+/*
+ *  Parse CephFS server and directory information passed on the kernel
+ *  command line.
+ *
+ *  cephroot=[server-ip][,server-ips]:root-dir[,cephfs-options]
+ */
+static int __init ceph_root_setup(char *line)
+{
+   ROOT_DEV = Root_CEPH;
+
+   strlcpy(ceph_command_line_params, line,
+   sizeof(ceph_command_line_params));
+
+   return 1;
+}
+
+__setup(cephroot=, ceph_root_setup);
+
+/*
+ * ceph_root_append - Concatenates an options or address string
+ * adding a ',' delimiter if neccessary.
+ *
+ * Returns 0 on success -E2BIG if the resulting string is too long.
+ */
+static int __init ceph_root_append(char *incoming,
+  char *dest,
+  const size_t destlen)
+{
+   int res = 0;
+
+   if (incoming != NULL  *incoming != '\0') {
+   size_t len = strlen(dest);
+
+   if (len  dest[len - 1] != ',') {
+   if (strlcat(dest, ,, destlen)  destlen)
+   res = -E2BIG;
+   }
+
+   if (strlcat(dest, incoming, destlen)  destlen)
+   res = -E2BIG;
+
+   }
+   return res;
+}
+
+/*
+ * ceph_root_parse_params - Parse out root export path and mount options from
+ * passed-in string @incoming.
+ *
+ * Copy the path into @path.
+ *
+ * Returns 0 on success -E2BIG if the resulting options string or device
+ * string are too long.
+ */
+static int __init ceph_root_parse_params(char *incoming, char *outpath,
+const size_t outpathlen)
+{
+   int res = -EINVAL;
+   char *options;
+   char *path;
+
+   options = strstr(incoming, :/);
+   if (options == NULL)
+   options = strstr(incoming, default);
+
+   if (options != NULL) {
+   path = strsep(options, ,);
+   if (*path != '\0'  strcmp(path, default) != 0)
+   strlcpy(outpath, path, outpathlen);
+   res = ceph_root_append(options, ceph_root_options,
+   sizeof(ceph_root_options));
+
+   if (res 

[PATCH v2 2/2] Documentation: Document the cephroot functionality

2014-01-15 Thread mark . doffman
From: Rob Taylor rob.tay...@codethink.co.uk

Document using the cephfs as a root device, its purpose,
functionality and use.

Signed-off-by: Mark Doffman mark.doff...@codethink.co.uk
Signed-off-by: Rob Taylor rob.tay...@codethink.co.uk
Reviewed-by: Ian Molton ian.mol...@codethink.co.uk
---
 Documentation/filesystems/{ = ceph}/ceph.txt |  0
 Documentation/filesystems/ceph/cephroot.txt   | 86 +++
 2 files changed, 86 insertions(+)
 rename Documentation/filesystems/{ = ceph}/ceph.txt (100%)
 create mode 100644 Documentation/filesystems/ceph/cephroot.txt

diff --git a/Documentation/filesystems/ceph.txt 
b/Documentation/filesystems/ceph/ceph.txt
similarity index 100%
rename from Documentation/filesystems/ceph.txt
rename to Documentation/filesystems/ceph/ceph.txt
diff --git a/Documentation/filesystems/ceph/cephroot.txt 
b/Documentation/filesystems/ceph/cephroot.txt
new file mode 100644
index 000..deda4f0
--- /dev/null
+++ b/Documentation/filesystems/ceph/cephroot.txt
@@ -0,0 +1,86 @@
+Mounting the root filesystem via Ceph (cephroot)
+===
+
+Written 2013 by Rob Taylor rob.tay...@codethink.co.uk
+
+derived from nfsroot.txt:
+
+Written 1996 by Gero Kuhlmann g...@gkminix.han.de
+Updated 1997 by Martin Mares m...@atrey.karlin.mff.cuni.cz
+Updated 2006 by Nico Schottelius nico-kernel-nfsr...@schottelius.org
+Updated 2006 by Horms ho...@verge.net.au
+
+
+
+In order to use a diskless system, such as an X-terminal or printer server
+for example, it is necessary for the root filesystem to be present on a
+non-disk device. This may be an initramfs (see Documentation/filesystems/
+ramfs-rootfs-initramfs.txt), a ramdisk (see Documentation/initrd.txt), a
+filesystem mounted via NFS or a filesystem mounted via Ceph. The following
+text describes on how to use Ceph for the root filesystem.
+
+For the rest of this text 'client' means the diskless system, and 'server'
+means the Ceph server.
+
+
+1.) Enabling cephroot capabilities
+-
+
+In order to use cephroot, CEPH_FS needs to be selected as
+built-in during configuration. Once this has been selected, the cephroot
+option will become available, which should also be selected.
+
+In the networking options, kernel level autoconfiguration can be selected,
+along with the types of autoconfiguration to support. Selecting all of
+DHCP, BOOTP and RARP is safe.
+
+
+2.) Kernel command line
+---
+
+When the kernel has been loaded by a boot loader (see below) it needs to be
+told what root fs device to use. And in the case of cephroot, where to find
+both the server and the name of the directory on the server to mount as root.
+This can be established using the following kernel command line parameters:
+
+root=/dev/ceph
+
+This is necessary to enable the pseudo-Ceph-device. Note that it's not a
+real device but just a synonym to tell the kernel to use Ceph instead of
+a real device.
+
+If cephroot is not specified, it is expected that that a valid mount will be
+found via DHCP option 17, Root Path [1]
+
+cephroot=monaddrs:/[subdir],ceph-opts
+
+  monaddrsMonitor addresses separated by commas. Each takes the form
+   host[:port]. If the port is not specified, the Ceph default
+   of 6789 is assumed.
+
+  subdir A subdirectory subdir may be specified if a subset of the file
+   system is to be mounted
+
+  ceph-opts  Standard Ceph options. All options are separated by commas.
+   See Documentation/filesystems/ceph/ceph.txt for options and
+   their defaults.
+
+4.) References
+--
+
+[1] http://tools.ietf.org/html/rfc2132
+
+5.) Credits
+---
+
+  cephroot was derived from nfsroot by Rob Taylor rob.tay...@codethink.co.uk
+  and Mark Doffman mark.doff...@codethink.co.uk
+
+  The nfsroot code in the kernel and the RARP support have been written
+  by Gero Kuhlmann g...@gkminix.han.de.
+
+  The rest of the IP layer autoconfiguration code has been written
+  by Martin Mares m...@atrey.karlin.mff.cuni.cz.
+
+  In order to write the initial version of nfsroot I would like to thank
+  Jens-Uwe Mager j...@anubis.han.de for his help.
-- 
1.8.4

--
To unsubscribe from this list: send the line unsubscribe ceph-devel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v2 2/2] Documentation: Document the cephroot functionality

2014-01-15 Thread Randy Dunlap

On 01/15/2014 09:26 AM, mark.doff...@codethink.co.uk wrote:

From: Rob Taylor rob.tay...@codethink.co.uk

Document using the cephfs as a root device, its purpose,
functionality and use.

Signed-off-by: Mark Doffman mark.doff...@codethink.co.uk
Signed-off-by: Rob Taylor rob.tay...@codethink.co.uk
Reviewed-by: Ian Molton ian.mol...@codethink.co.uk
---
  Documentation/filesystems/{ = ceph}/ceph.txt |  0
  Documentation/filesystems/ceph/cephroot.txt   | 86 +++
  2 files changed, 86 insertions(+)
  rename Documentation/filesystems/{ = ceph}/ceph.txt (100%)
  create mode 100644 Documentation/filesystems/ceph/cephroot.txt

diff --git a/Documentation/filesystems/ceph.txt 
b/Documentation/filesystems/ceph/ceph.txt
similarity index 100%
rename from Documentation/filesystems/ceph.txt
rename to Documentation/filesystems/ceph/ceph.txt
diff --git a/Documentation/filesystems/ceph/cephroot.txt 
b/Documentation/filesystems/ceph/cephroot.txt
new file mode 100644
index 000..deda4f0
--- /dev/null
+++ b/Documentation/filesystems/ceph/cephroot.txt
@@ -0,0 +1,86 @@
+Mounting the root filesystem via Ceph (cephroot)
+===
+
+Written 2013 by Rob Taylor rob.tay...@codethink.co.uk
+
+derived from nfsroot.txt:
+
+Written 1996 by Gero Kuhlmann g...@gkminix.han.de
+Updated 1997 by Martin Mares m...@atrey.karlin.mff.cuni.cz
+Updated 2006 by Nico Schottelius nico-kernel-nfsr...@schottelius.org
+Updated 2006 by Horms ho...@verge.net.au
+
+
+
+In order to use a diskless system, such as an X-terminal or printer server
+for example, it is necessary for the root filesystem to be present on a
+non-disk device. This may be an initramfs (see Documentation/filesystems/
+ramfs-rootfs-initramfs.txt), a ramdisk (see Documentation/initrd.txt), a
+filesystem mounted via NFS or a filesystem mounted via Ceph. The following
+text describes on how to use Ceph for the root filesystem.
+
+For the rest of this text 'client' means the diskless system, and 'server'
+means the Ceph server.
+
+
+1.) Enabling cephroot capabilities
+-
+
+In order to use cephroot, CEPH_FS needs to be selected as
+built-in during configuration. Once this has been selected, the cephroot
+option will become available, which should also be selected.
+
+In the networking options, kernel level autoconfiguration can be selected,
+along with the types of autoconfiguration to support. Selecting all of
+DHCP, BOOTP and RARP is safe.
+
+
+2.) Kernel command line
+---
+
+When the kernel has been loaded by a boot loader (see below) it needs to be
+told what root fs device to use. And in the case of cephroot, where to find


   use, and


+both the server and the name of the directory on the server to mount as root.
+This can be established using the following kernel command line parameters:
+
+root=/dev/ceph
+
+This is necessary to enable the pseudo-Ceph-device. Note that it's not a
+real device but just a synonym to tell the kernel to use Ceph instead of
+a real device.
+
+If cephroot is not specified, it is expected that that a valid mount will be


drop duplicate: that


+found via DHCP option 17, Root Path [1]
+
+cephroot=monaddrs:/[subdir],ceph-opts
+
+  monaddrsMonitor addresses separated by commas. Each takes the form
+   host[:port]. If the port is not specified, the Ceph default
+   of 6789 is assumed.
+
+  subdir   A subdirectory subdir may be specified if a subset of the file
+   system is to be mounted


mounted.


+
+  ceph-optsStandard Ceph options. All options are separated by commas.
+   See Documentation/filesystems/ceph/ceph.txt for options and
+   their defaults.
+
+4.) References
+--
+
+[1] http://tools.ietf.org/html/rfc2132
+
+5.) Credits
+---
+
+  cephroot was derived from nfsroot by Rob Taylor rob.tay...@codethink.co.uk
+  and Mark Doffman mark.doff...@codethink.co.uk
+
+  The nfsroot code in the kernel and the RARP support have been written
+  by Gero Kuhlmann g...@gkminix.han.de.
+
+  The rest of the IP layer autoconfiguration code has been written
+  by Martin Mares m...@atrey.karlin.mff.cuni.cz.
+
+  In order to write the initial version of nfsroot I would like to thank
+  Jens-Uwe Mager j...@anubis.han.de for his help.




--
~Randy
--
To unsubscribe from this list: send the line unsubscribe ceph-devel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: v0.75 contributors credits ( experimental)

2014-01-15 Thread Robin H. Johnson
On Wed, Jan 15, 2014 at 09:21:34AM +0100,  Loic Dachary wrote:
 Hi Ceph,
 
 Here is a sorted list of authors and organizations who contributed to
 v0.75, by number of commits or reviews back to v0.74. The affiliation
 of authors to organizations can be updated by submitting a patch to
 https://github.com/ceph/ceph/blob/master/.organizationmap
I think the script should use tags as the marker points, rather than
release dates.

# git log tags/v0.74 |fgrep -c robbat2
0
# git log tags/v0.75 |fgrep -c robbat2
6

Your script output however says I didn't have any changes in v0.75.

-- 
Robin Hugh Johnson
Gentoo Linux: Developer, Infrastructure Lead
E-Mail : robb...@gentoo.org
GnuPG FP   : 11ACBA4F 4778E3F6 E4EDF38E B27B944E 34884E85
--
To unsubscribe from this list: send the line unsubscribe ceph-devel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: v0.75 contributors credits ( experimental)

2014-01-15 Thread Loic Dachary
Thanks for pointing this problem : using --after --before makes things 
complicated and wrong. I'll send a version two momentarily.

On 15/01/2014 21:19, Robin H. Johnson wrote:
 On Wed, Jan 15, 2014 at 09:21:34AM +0100,  Loic Dachary wrote:
 Hi Ceph,

 Here is a sorted list of authors and organizations who contributed to
 v0.75, by number of commits or reviews back to v0.74. The affiliation
 of authors to organizations can be updated by submitting a patch to
 https://github.com/ceph/ceph/blob/master/.organizationmap
 I think the script should use tags as the marker points, rather than
 release dates.
 
 # git log tags/v0.74 |fgrep -c robbat2
 0
 # git log tags/v0.75 |fgrep -c robbat2
 6
 
 Your script output however says I didn't have any changes in v0.75.
 

-- 
Loïc Dachary, Artisan Logiciel Libre



signature.asc
Description: OpenPGP digital signature


v0.75 contributors credits ( experimental) (take 2)

2014-01-15 Thread Loic Dachary
[Amended after comments from Noah Watkins, Patrick McGarry, Andrew Woodward, 
Ian Colle, Robin H. Johnson] 

Hi Ceph,

Here is a sorted list of authors and organizations who contributed to v0.75, by 
number of commits or reviews back to v0.74. The affiliation of authors to 
organizations can be updated by submitting a patch to 
https://github.com/ceph/ceph/blob/master/.organizationmap

All commits are reviewed but the number of reviews is a fraction of the number 
of commits. The reviewer(s) is only mentioned in the message of the merge 
although it means that all associated commits have been reviewed. 

If you are curious about how it is done, the details are at the end of this 
mail. 

Commits by authors
 1  259 Sage Weil s...@inktank.com
 2   80 Loic Dachary l...@dachary.org
 3   39 Greg Farnum g...@inktank.com
 4   38 Yan, Zheng zheng.z@intel.com
 5   30 Noah Watkins noah.watk...@inktank.com
 6   23 Yehuda Sadeh yeh...@inktank.com
 7   15 Ilya Dryomov ilya.dryo...@inktank.com
 8   14 Josh Durgin josh.dur...@inktank.com
 9   14 João Eduardo Luís joao.l...@inktank.com
108 Haomai Wang haomaiw...@gmail.com
114 Alfredo Deza alfredo.d...@inktank.com
123 Robin H. Johnson robb...@gentoo.org
133 David Zafman david.zaf...@inktank.com
143 Alexandre Oliva ol...@gnu.org
152 Tamil Muthamizhan tamil.muthamiz...@inktank.com
162 John Wilkins john.wilk...@inktank.com
172 Andreas Peters andreas.joachim.pet...@cern.ch
181 Xihui He xihu...@gmail.com
191 Wido den Hollander w...@42on.com
201 Thomas Bechtold thomasbecht...@jpberlin.de
211 Steve Stock st...@technolope.org
221 Sebastien Han sebastien@enovance.com
231 Rutger ter Borg rut...@terborg.net
241 Laurent Barbe laur...@ksperis.com
251 Ken Dreyer ken.dre...@inktank.com
261 Kai Zhang zakir@gmail.com
271 Gary Lowell gary.low...@inktank.com
281 Dan van der Ster daniel.vanders...@cern.ch
291 Christophe Courtaut christophe.court...@gmail.com
301 Christian Marie pi...@anchor.net.au
311 Bjørnar Ness bjornar.n...@gmail.com
Commits by organizations
 1  407 Inktank cont...@inktank.com
 2   81 Cloudwatt libre.licens...@cloudwatt.com
 3   38 Intel cont...@intel.com
 48 UnitedStack cont...@unitedstack.com
 53 GNU cont...@gnu.org
 63 Gentoo cont...@gentoo.org
 73 CERN cont...@cern.ch
 81 Xihui He xihu...@gmail.com
 91 Wido 42on cont...@42on.com
101 Thomas Bechtold thomasbecht...@jpberlin.de
111 Steve Stock st...@technolope.org
121 Rutger ter Borg rut...@terborg.net
131 Laurent Barbe laur...@ksperis.com
141 Kai Zhang zakir@gmail.com
151 eNovance cont...@enovance.com
161 Christian Marie pi...@anchor.net.au
171 Bjørnar Ness bjornar.n...@gmail.com
Reviews by authors (one review spans multiple commits)
 1   54 Sage Weil s...@inktank.com
 2   14 Greg Farnum g...@inktank.com
 3   11 Loic Dachary l...@dachary.org
 47 Josh Durgin josh.dur...@inktank.com
 56 Samuel Just sam.j...@inktank.com
 66 João Eduardo Luís joao.l...@inktank.com
 73 Christophe Courtaut christophe.court...@gmail.com
 82 Yehuda Sadeh yeh...@inktank.com
 91 Andreas Peters andreas.joachim.pet...@cern.ch
Reviews by organizations (one review spans multiple commits)
 1   89 Inktank cont...@inktank.com
 2   14 Cloudwatt libre.licens...@cloudwatt.com
 31 CERN cont...@cern.ch

The script used to generate this output is (copy paste at the root of a git 
clone https://github.com/ceph/ceph.git):

cat  credits.sh 'EOF'
range=$1
echo Commits by authors
git log --pretty='%aN %aE' $range | sort | uniq -c | sort -rn | nl
echo Commits by organizations
git log --pretty='%aN %aE' $range | git -c mailmap.file=.organizationmap 
check-mailmap --stdin | sort | uniq -c | sort -rn | nl
echo Reviews by authors (one review spans multiple commits)
git log --pretty=%b $range | perl -n -e 'print $_\n 
if(s/^\s*Reviewed-by:\s*(.*.*)\s*$/\1/)' | git check-mailmap --stdin | sort | 
uniq -c | sort -rn | nl
echo Reviews by organizations (one review spans multiple commits)
git log --pretty=%b $range | perl -n -e 'print $_\n 
if(s/^\s*Reviewed-by:\s*(.*.*)\s*$/\1/)' | git check-mailmap --stdin | git -c 
mailmap.file=.organizationmap check-mailmap --stdin | sort | uniq -c | sort -rn 
| nl
EOF
bash credits.sh tags/v0.74...tags/v0.75

Authors names are normalized with .mailmap and authors affiliations to a given 
organization comes from .organizationmap, both of which can be found and 
patched at the root of