What does hdfs cacheadmin command do ? and what is cache pools?

Free Online Certification Courses – Learn Today. Lead Tomorrow. Forums Apache Hadoop What does hdfs cacheadmin command do ? and what is cache pools?

Viewing 1 reply thread
  • Author
    Posts
    • #4901
      DataFlair TeamDataFlair Team
      Spectator

      What does hdfs cacheadmin command do ? and what is cache pools?

    • #4903
      DataFlair TeamDataFlair Team
      Spectator

      cacheadmin commands and cache pools

      By using hdfs cacheadmin subcommand, administrators and users can interact with cache pools and directives, On the command-line.

      Though, by a unique, non-repeating 64-bit integer ID, Cache directives are identified. Although, even if a cache directive is later removed, IDs will not be reused.

      And, by a unique string name, Cache pools are identified.

      – Cache directive commands

      i. addDirective Command
      Usage: hdfs cacheadmin -addDirective -path <path> -pool <pool-name> [-force] [-replication <replication>] [-ttl <time-to-live>]

      It helps to add a new cache directive.

      ii. removeDirective
      Usage: hdfs cacheadmin -removeDirective <id>

      It helps to remove a cache directive.

      iii. removeDirectives
      Usage: hdfs cacheadmin -removeDirectives <path>

      It helps to remove every cache directive with the specified path.

      iv. listDirectives
      Usage: hdfs cacheadmin -listDirectives [-stats] [-path <path>] [-pool <pool>]

      It helps to list cache directives.

      – Cache pool commands

      i.addPool
      Usage: hdfs cacheadmin -addPool <name> [-owner <owner>] [-group <group>] [-mode <mode>] [-limit <limit>] [-maxTtl <maxTtl>

      It helps to add a new cache pool.

      ii. modifyPool
      Usage: hdfs cacheadmin -modifyPool <name> [-owner <owner>] [-group <group>] [-mode <mode>] [-limit <limit>] [-maxTtl <maxTtl>]

      iii. removePool
      Usage: hdfs cacheadmin -removePool <name>

      It helps to remove a cache pool. Also, it uncaches paths which are associated with the pool.

      iv. listPools
      Usage: hdfs cacheadmin -listPools [-stats] [<name>]

      This command helps to display information about one or more cache pools, for example, name, owner, group, permissions, etc.

      v. help
      Usage: hdfs cacheadmin -help <command-name>

      It helps to get detailed help about a command.

Viewing 1 reply thread
  • You must be logged in to reply to this topic.