Ticket #824 (closed defect: fixed)

Opened 2 years ago

Last modified 1 year ago

lighttpd & fam: monitoring dirs with empty names

Reported by: chernousov Assigned to: jan
Priority: normal Milestone: 1.4.17
Component: core Version: 1.4.13
Severity: minor Keywords: fam, statcache, monitoring dir failed, bad filename, stat_cache
Cc: Blocking:
Need Feedback: 0

Description

svn sources, revision 1270.

I see in error.log:

(stat_cache.c.604) monitoring dir failed:  Bad filename

Patched:

svn diff stat_cache.c
Index: stat_cache.c
===================================================================
--- stat_cache.c        (revision 1270)
+++ stat_cache.c        (working copy)
@@ -608,6 +608,9 @@

                                fam_dir_entry_free(fam_dir);
                        } else {
+                               log_error_write(srv, __FILE__, __LINE__, "sb",
+                                                       "monitoring dir:",
+                                                       fam_dir->name);
                                int osize = 0;

                                if (sc->dirs) {

Now I see that actually lighttpd tries to monitor empty directory with fam just first 2 times after start, and after that monitoring works good:

log.c.139: (trace) server started
2006-08-27 18:25:59: (stat_cache.c.604) monitoring dir failed:  Bad filename
2006-08-27 18:25:59: (stat_cache.c.604) monitoring dir failed:  Bad filename
2006-08-27 18:25:59: (stat_cache.c.611) monitoring dir: /www
2006-08-27 18:26:03: (stat_cache.c.611) monitoring dir: /www/dir1
2006-08-27 18:26:03: (stat_cache.c.611) monitoring dir: /www/dir1/dir
2006-08-27 18:26:05: (stat_cache.c.611) monitoring dir: /www/dir1/dir/dir
2006-08-27 18:26:15: (stat_cache.c.611) monitoring dir: /www/dir2
2006-08-27 18:26:21: (stat_cache.c.611) monitoring dir: /www/dir3
...

I didn't investigated deeper in problem, but in stat_cache.c:595 while doing

buffer_copy_string_buffer(fam_dir->name, sc->dir_name);

sc->dir_name is empty.

Attachments

Change History

08/17/2007 11:19:54 PM changed by jan

  • status changed from new to closed.
  • version changed from 1.4.x-svn to 1.4.13.
  • milestone set to 1.4.17.
  • resolution set to fixed.
  • blocking changed.
  • pending changed.

in [1940] I added some extra debug code.

please reopen the bug, when this happens again.


Add/Change #824 (lighttpd & fam: monitoring dirs with empty names)




Change Properties
Action