[ 
https://issues.apache.org/jira/browse/HBASE-22086?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16802486#comment-16802486
 ] 

Sakthi commented on HBASE-22086:
--------------------------------

Hey [~elserj].
 * As far as deleting snapshots from hdfs manually is concerned, 
admin.listsnapshots would take care of not listing them out while we are 
calculating current quota usage for snapshots as it doesn't rely on in-memory 
cached info. So I think we are good on that aspect.
 * Also, the case where files not necessarily gone from the filesystem when a 
snapshot is deleted (because other snapshots might be using them), is handled 
aptly by FileArchiveNotifier where it takes the snapshots listed by 
#listsnapshots and then calculates exact usage by avoiding duplication. I'm not 
sure what should we be worried about here (like do you see a case where we 
might over-calculate or under-calculate the snapshots size calculations? If 
yes, then could you please share a scenario as such?) 
 * If an user manually renames snapshot dir within .hbase-snapshot dir and 
accordingly edits .snapshotinfo file, then surely admin would still list it out 
and we would be still fine.
 * But the case, where a user manually messes up with .snapshotinfo file or 
moves/renames the snapshot directory, in that case, for sure the files still 
sit around the system but #listsnapshots doesn't list it out so we wouldn't 
include the size of the store files in that case for the quota of the table. 
(This is one of the possible tricky situations I could see). 

Could you please present any situation which I might have missed here? :)  
Thanks josh

> space quota issue: deleting snapshot doesn't update the usage of table
> ----------------------------------------------------------------------
>
>                 Key: HBASE-22086
>                 URL: https://issues.apache.org/jira/browse/HBASE-22086
>             Project: HBase
>          Issue Type: Bug
>            Reporter: Ajeet Rai
>            Assignee: Sakthi
>            Priority: Minor
>
> space quota issue: deleting snapshot doesn't update the usage of table
> Steps: 1:
> set_quota TYPE => SPACE, TABLE => 'bugatti', LIMIT => '7M', POLICY => 
> NO_WRITES_COMPACTIONS
> 2: ./hbase pe --table="bugatti" --nomapred --rows=200 sequentialWrite 10
> 3: ./hbase pe --table="bugatti" --nomapred --rows=200 sequentialWrite 10
> 4: snapshot 'bugatti','bugatti_snapshot'
> 5: ./hbase pe --table="bugatti" --nomapred --rows=200 sequentialWrite 10
> 6: major_compact 'bugatti'
> 7: delete_snapshot 'bugatti_snapshot'
> now check the usage and observe that it is not getting updated.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to