• D
    afs: Fix unlink · 440fbc3a
    David Howells 提交于
    Repeating creation and deletion of a file on an afs mount will run the box
    out of memory, e.g.:
    
    	dd if=/dev/zero of=/afs/scratch/m0 bs=$((1024*1024)) count=512
    	rm /afs/scratch/m0
    
    The problem seems to be that it's not properly decrementing the nlink count
    so that the inode can be scrapped.
    
    Note that this doesn't fix local creation followed by remote deletion.
    That's harder to handle and will require a separate patch as we're not told
    that the file has been deleted - only that the directory has changed.
    Reported-by: NMarc Dionne <marc.dionne@auristor.com>
    Signed-off-by: NDavid Howells <dhowells@redhat.com>
    440fbc3a
inode.c 13.9 KB