I have the following script
#!/bin/bash
# Script for running the snapshot of target directories
now=$(date +'%Y-%m-%d')
/bin/hdfs dfs -createSnapshot /apps/hive/warehouse/xyz.db $now
How do i delete the same in a script
see below a example
/apps/hive/warehouse/xyz.db/.snapshot/2017-05-24