[Samba] Problems with offline files and Explorer 'hangs'

Damir Dezeljin programing at nib.si
Tue Mar 19 06:44:40 GMT 2002


I'm working on a HSM product for Linux. The product has to handle file 
writing and reading trough samba. When there remains only for ex. 10% of 
free disk space, the product convert files that aren't accessed for a 
while to offline files - product marks files offline and removes files 
contents from disk and make it sparse file.

When some client from samba tries to access one of offline files, the 
product put the samba process to sleep (kernel sleep) until the file is 
recalled. 

I encountered two problems:
- When someone with windows explorer goes into an exported share, read 
events are generated for .exe files and this cause the recall (explorer 
try to get an icon data from the file).
- When someone tries to copy a directory with offline files from samba 
export to local HDD, the samba process on the server is put to sleep and 
explorer "hangs" until the process is released from the sleep 

And now questions:
- Starting with NTFS 5, M$ support an "offline" file attribute. If the 
server is located on Win2k or greater, clients "detect" this attribute and 
don't try to read an icon data from the file (don't trigger a read event). 
Is there a way to mark a file on samba share with this attribute? If not, 
where I have to hack sources (I'm not familiar with samba sources)?
- Is there a way to configure samba so that a client accessing one SAMBA 
export produce more processes or threads to avoid Explorer hangs?

Regards,
Dezo





More information about the samba mailing list