pyWebHdfs is the Python module for interaction with HDFS (Hadoop Distributed File System). Besides standard WebHDFS operations the module contents UNIX-like operations such us “ls”, “cp”, “mkdir”, etc.
from pyWebHdfs import WebHdfs
hdfs = WebHdfs("localhost")
hdfs.ls("/path/to/dir")