DragonFly BSD
DragonFly kernel List (threaded) for 2003-09
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: cache_lookup() work this week.

From: Joerg Sonnenberger <joerg@xxxxxxxxxxxxxxxxx>
Date: Fri, 5 Sep 2003 14:29:30 +0200

On Thu, Sep 04, 2003 at 11:27:54AM -0700, Matthew Dillon wrote:
>     This is a good one, and easy to solve... rm would just unlink() or
>     rmdir() the directory first, whether it is empty or not.  If the unlink
>     succeeds then rm considers its work done.  
>     The last instance of the directory would not be unlinkable... rm -rf
>     would have to recurse through and delete the underlying files first.

Another problem: How do you want to effently determine the number of
hard links of a directory without changing the filesystem? ATM the link
count of a directory is 2+number of subdirectories. It is possible
to compute the number of instances as the number of subdirectoriesi
plus 1, but that is very slow for large directories.  

Anyway, the idea of semi-hard links also exist in the Hurd, so we
might want to coordinate the userspace representation with them.


[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]