V iewf s' (C li ent' Si de'M ou nt‐tables)'Guide'for'Federa ted' HD FS'
Sanjay&Radia&
Yahoo!&&Inc&
!
1! Introduction!....................................................................................................................................................................!1!
2! The!Old!World!(Prior!to!Federation)!....................................................................................................................!1!
2.1! Multiple!Clusters!...................................................................................................................................................!1!
2.2! Pathnames!usage!pattern!..................................................................................................................................!2!
2.3! Bad!Pathname!usage!patterns!........................................................................................................................!2!
3! New!World!–!Federation!and!Viewfs!....................................................................................................................!2!
3.1! How!the!clusters!will!look!................................................................................................................................!2!
3.2! A!global!namespace!per!cluster!using!Viewfs!..........................................................................................!3!
3.3! Pathname!usage!pattern!....................................................................................................................................!4!
3.4! Bad!Pathname!Usage!Patterns!................................................................ ........................................................!4!
3.5! Renaming!a!file!or!directories!across!Namespace!volumes!(NNs)!will!not!work!....................!4!
3.6! FAQ!.............................................................................................................................................................................!5!
4! Appendix!A:!Viewfs!–!More!Details!.......................................................................................................................!6!
5! Appendix!B:!An!Example!of!a!Config!for!Mount!tables!.................................................................................!6!
!
!
1 Introdu ction+
The!viewfs!file!system!provides!a!way!to!manage!multiple!Hadoop!file!system!namespace!(or!
namespace!volumes).!It!is!particularly!useful!clusters!having!multiple!namenodes!(post!
federation)!and!hence!multiple!namespaces.!Viewfs!is!analogous!to!the!client!side!mount!tables!
in!some!Unix/Linux!systems.!Viewfs!can!be!used!to!create!personalized!namespace!views!and!
also!per‐cluster!common!views.!This!document!describes!how!to!use!viewfs!in!the!federated!
HDFS!to!provide!a!per‐cluster!global!namespace!so!that!applications!can!operate!in!a!way!similar!
to!the!pre‐federation!world.!
!
This!guide!is!described!in!the!context!of!a!large!Hadoop!customer!that!has!several!clusters,!each!
if!which!are!going!to!be!federated!using!the!new!Federated!HDFS.!
!
!
2 The+Old+World +(Prior+to+Federation)+
2.1 Multiple+Clusters+
In!the!old!world!prior!to!the!upcoming!of!Federation!(ie!Hadoop!release!of!20.xxx)!each!cluster!
has!single!NameNode!(NN)!which!provides!single!independent!file!system!namespace!for!that!
cluster.!The!file!system!namespaces!of!each!cluster!are!completely!independent!and!disjoint.!
Furthermore,!physical!storage!is!NOT!shared!across!clusters!(i.e.!the!Datanodes!are!not!shared!
across!clusters)!