- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
HDFS dsquota diskspace consumed calculation
- Labels:
-
Apache Hadoop
Created on ‎01-01-2018 05:22 PM - edited ‎08-18-2019 02:31 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
For a directory in HDFS, I have set dsquota as 1GB but when I try to copy a 500 MB file to that directory. I get a exception == copyFromLocal: The DiskSpace quota of /user/prateek is exceeded: quota = 1073741824 B = 1 GB but diskspace consumed = 1305477120 B = 1.22 GB.
The directory already contains four files.
1048576 /user/prateek/file1.txt
10485760 /user/prateek/file2.txt
10485760 /user/prateek/file3.txt
10485760 /user/prateek/file4.txt
How can we calculate the diskspace consumed(i.e.1.22GB in this case)?
Thanks in advance
Created ‎01-02-2018 06:13 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The disk quota in your case works fine as expected. HDFS by default has a replication factor of 3 as you can see in the 3rd column of your CLI output.
500MB *3 (replication factor) = 1.5 GB > 1GB (quota).
Created ‎01-02-2018 06:13 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The disk quota in your case works fine as expected. HDFS by default has a replication factor of 3 as you can see in the 3rd column of your CLI output.
500MB *3 (replication factor) = 1.5 GB > 1GB (quota).
