From: rac8006@aol.com To: samba-technical@lists.samba.org Subject: browse.dat file X-Mailer: JAS STD After doing some investigation. I've found that about every twelve minutes the process process_local_master_announce procedure. This procedure also calls update_server_ttl Both of these procedures sets subrec->work_changed to true. The update_server_ttl updades the ttl value. but this value is not stored in the browse.dat file. Yet it sets the work_changed to true. This causes the browse.dat file to be written. The process local_master _announce procedure either does a create_server or remove_server or updates the record. It should write the browse.dat file id it creates or removes data. But most of the time it is updating the record with the same data that is already in the file. Why does it have to open a new file. Write the data. Close the file. unlink the file. chmod on the file. then rename the file to browse.dat. Every twelve minutes. The WD MY Cloud NAS after 10 minutes of no disk writes. puts the disk in standby mode. Then two minutes of so later it wakes the disk to rewrite the browse.dat file. Why can't the file only be written when it changes.
Created attachment 11016 [details] git-am fix for master. Submitted to samba-technical. Back-ports to 4.2.next, 4.1.next to follow once it's in.
Created attachment 11017 [details] git-am cherry-pick from master for 4.2.next, 4.1.next. Fix that went into master, cherry-picked for 4.2.next, 4.1.next.
Comment on attachment 11017 [details] git-am cherry-pick from master for 4.2.next, 4.1.next. LGTM
Karolin, please add the patches to the next releases. Thanks
Pushed to v4-1-test and v4-2-test. Closing out bug report. Thanks!