[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference decwet::advfs_support

Title:AdvFS Support/Info/Questions Notefile
Notice:note 187 is Freq Asked Questions;note 7 is support policy
Moderator:DECWET::DADDAMIO
Created:Wed Jun 02 1993
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:1077
Total number of notes:4417

1034.0. "advfs fragments" by UTRTSC::WINDMEIJER () Mon Apr 07 1997 06:21


Hello,


I've made a 10Mb adfvs domain/fileset and created a lot of small (less then 500
byte) in it until the disk was full.


Begin situation just after the domain/fileset creation:

# df -ki .
Filesystem       1024-blocks        Used       Avail Capacity     Iused       Ifree  %Iused  Moun
ted on
test_domain#test       10000          16        5744     0%           2       19621     0%   /mnt


Situation after the file creation:

# df -ki .
Filesystem       1024-blocks        Used       Avail Capacity     Iused       Ifree  %Iused  Moun
ted on
test_domain#test       10000        3685           0   100%        3461        3763    48%   /mnt



When I remove the file not all space is reclaimed
Situation after removing all files:

# df -ki .
Filesystem       1024-blocks        Used       Avail Capacity     Iused       Ifree  %Iused  Moun
ted on
test_domain#test       10000          16         240     6%           2        8039     0%   /mnt


As you can see of the 5744k I had originaly free only 240k remains after 
this create/delete action. As far as I understand advfs most of the space is 
held in the fragment file (.tags/1) and in the bitmap file (.tags/M-6). 
Now the strangness comes. At this point I can create all the small files 
again without any problems (+/- 3600k). But I can't create a file which is 
bigger than the available space (240k). 

The only explanation I can give is that not only blocks in the bitmap file
cannot be reused bot also the blocks in the fragment file when the request
is for more than 8k. This also implies that if you initialy make a lot
of small files and removed them afterwards you loose this space forever for 
bigger files.

I'm I wrong 

/Peter


                                                               
T.RTitleUserPersonal
Name
DateLines
1034.1You are right.NETRIX::"[email protected]"jwangMon Apr 07 1997 14:405
Yes.  This is a known problem for AdvFS. As you mentioned, creating a
lot of small files renders in fragmenting the BMT (bitfile metadata
table) and not leaving room for user data.  Development effort are 
given to address this problem in future releases. 
[Posted by WWW Notes gateway]
1034.2UTRTSC::WINDMEIJERTue Apr 08 1997 03:2444
    
    If I understand you correctly then the fragmentation if the BMT will
    makes it impossible to reuse the data in the fragment file.
    
    What I did is making a file domain with the -p option so the BMT will
    be preallocated. (almost no fragmentation)
    
    mkfdmn -o -p 220 /dev/rz3a test_domain
    
    
    showfile -x M-6 give 9 fragments. The size of .tags/1 and .tags/M-6
    were
    
    # ls -l 1 M-6
    ----------   0 root     system   3538944 Jan  1  1970 1
    ----------   0 root     system   2080768 Jan  1  1970 M-6
    
    # df -ik /mnt
    Filesystem       1024-blocks        Used       Avail Capacity     Iused      
    Ifree  %Iused  Mounted on
    test_domain#test       10000        3717           0   100%        3465       
    3647    49%   /mnt 
    
    
    After the removal of the files:
    
    # ls -l 1 M-6
    ----------   0 root     system   3538944 Jan  1  1970 1
    ----------   0 root     system   2080768 Jan  1  1970 M-6
    
    # df -ik /mnt
    Filesystem       1024-blocks        Used       Avail Capacity     Iused
          Ifree  %Iused  Mounted on
    test_domain#test       10000          16         272     6%           2
           8036     0%   /mnt
    
    
    As you can see I still have only 272 blocks available. Why can't I
    reuse the free block in the fragment file. (.tags/1)
    
    /Peter 
    
    
    [End of buffer]
1034.3Threshold for freeing space in frag fileNETRIX::"[email protected]"jwangTue Apr 08 1997 13:0011
AdvFS only free up space held in the fragment file when a configurable
threshold is exceeded.  The size of the fragment file in your example 
has not exceeded the default threshold which is set for larger domains.
The threshold is for the whole system and one needs to be careful about
changing it.  You can see that small domain is not too meaningful due
to % usage by the AdvFS overhead: the log, the BMT, the fragment file,  
as shown by your df -ik right after you create the domain and after you
removes those small files.  If you really need to create small 
domains, the threshold can be tuned to smaller number to allow reusing 
space previously allocated to the fragment file for large files.
[Posted by WWW Notes gateway]