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

[leafnode-list] Lock file troubles.




Short form:

The short form of the following story is I am on FreeBSD 3.1 and
running 1.9.2 because 1.9.4 won't compile.  Fetch doesn't work, I get 
logs entrys about the lock file every time I run fetch, but I can see 
nothing wrong with the lock file.  

I just subscribed (yes I read big chunks of the archives) to this list
, so please CC me (just to be sure).

Very Long form:

I have been running leafnode plus mail2leafnode for many months
on my personal, but 24/7 connected, machine.   From time to time
I would get messages in my log files about a problem between fetch
and a lock file.  In most cases I believe this was because my
crontab would lauch an additional fetch before the previous
one would finish.  Occationally this lock file would appear
with no process still apparent and I would delete it.

At one point it stopped fetch additonal news entirely.  Mail injection
kept working.  After about a month I looked into the problem and was
able to resolve it by running fetch with -f (i.e. "Force rereading of
whole active file... ".

Given these problems I decided to upgrade to a newer version.
So I downloaded leafnode-1.9.4, but it fails to compile on
FreeBSD.  It had warnings, which I poked at until they
went away.  But a fatal errors around "extern long int timezone;"
made me loose heart.

I then downloade the FreeBSD package with a prebuilt version
in it.  That installed and ran just fine.  It announces 
  200 Leafnode NNTP Daemon, version 1.9.2 running (etc..)
when you connect to it.

Then I had a power failure, afterward I now get this:
  ... fetch[9948]: unable to open lockfile: 2 No such file or directory
every time fetch runs.

Seems like an ovious problem but I'm entirely stuck.

    zap# strings /usr/local/sbin/fetch | grep lock
    /var/spool/lock/news/fetch.lck
    Removing stale lockfile.
    Removing stale lockfile: pid %d
    lockfile %s exists, abort ...
    lockfile %s exists, abort ...
    unable to read lockfile %s, abort ...
    unable to open lockfile: %d %m
    Could not open lockfile %s for writing, abort program ...
    Could not open lockfile %s for writing: %m

So It would appear the lock file is named: "/var/spool/lock/news/fetch.lck"


But it doesn't exist.

    zap# ls -l /var/spool/lock/news/fetch.lck
    ls: /var/spool/lock/news/fetch.lck: No such file or directory

And the directory seems to have the approprate protections:

    zap# ls -ld /var/spool/lock/news/
    drwxr-xr-x  2 news  news  512 Jul 26 12:21 /var/spool/lock/news/

Well where is what I'm running on:
  zap# uname -a
  FreeBSD zap.... 3.1-RELEASE FreeBSD 3.1-RELEASE #3: Sun Mar 21 23:39:27 GMT 1999 ...

Maybe somebody can see what this truss output is telling me.

  Any help most welcome. - ben.


zap# truss /usr/local/sbin/fetch
syscall __sysctl(0xefbfdba8,0x2,0x800fd94,0xefbfdbb0,0x0,0x0)
	returns 0 (0x0)
syscall mmap(0x0,32768,0x3,0x1002,-1,0x0)
	returns 671436800 (0x28055000)
syscall geteuid()
	returns 0 (0x0)
syscall getuid()
	returns 0 (0x0)
syscall getegid()
	returns 0 (0x0)
syscall getgid()
	returns 0 (0x0)
syscall open("/var/run/ld-elf.so.hints",0,01000174550)
	returns 3 (0x3)
syscall read(0x3,0xefbfdb68,0x80)
	returns 128 (0x80)
syscall lseek(3,0x80,0)
	returns 128 (0x80)
syscall read(0x3,0x28059000,0x37)
	returns 55 (0x37)
syscall close(3)
	returns 0 (0x0)
syscall access(0x28056040,0x0)
	returns 0 (0x0)
syscall open("/usr/lib/libc.so.3",0,01000174550)
	returns 3 (0x3)
syscall read(0x3,0xefbfcbe8,0x1000)
	returns 4096 (0x1000)
syscall mmap(0x0,524288,0x5,0x2,3,0x0)
	returns 671469568 (0x2805d000)
syscall mmap(0x280c9000,20480,0x3,0x12,3,0x6b000)
	returns 671911936 (0x280c9000)
syscall mmap(0x280ce000,61440,0x3,0x1012,-1,0x0)
	returns 671932416 (0x280ce000)
syscall close(3)
	returns 0 (0x0)
syscall mkdir(0x8057750,0x1fd)
	errno 17 'File exists'
syscall mkdir(0x8057750,0x1ed)
	errno 17 'File exists'
syscall mkdir(0x8057750,0x1fd)
	errno 17 'File exists'
syscall mkdir(0x8057750,0xac3)
	errno 17 'File exists'
syscall geteuid()
	returns 0 (0x0)
syscall readlink("/etc/malloc.conf",0xefbfdac4,63)
	errno 2 'No such file or directory'
syscall mmap(0x0,4096,0x3,0x1002,-1,0x0)
	returns 671993856 (0x280dd000)
syscall break(0x805a000)
	returns 0 (0x0)
syscall break(0x805b000)
	returns 0 (0x0)
syscall stat("/etc/spwd.db",0xefbfdb5c)
	returns 0 (0x0)
syscall open("/etc/spwd.db",0,00)
	returns 3 (0x3)
syscall fcntl(0x3,0x2,0x1)
	returns 0 (0x0)
syscall read(0x3,0x805a000,0x104)
	returns 260 (0x104)
syscall break(0x805c000)
	returns 0 (0x0)
syscall break(0x805d000)
	returns 0 (0x0)
syscall break(0x805e000)
	returns 0 (0x0)
syscall lseek(3,0x7000,0)
	returns 28672 (0x7000)
syscall read(0x3,0x805d000,0x1000)
	returns 4096 (0x1000)
syscall break(0x805f000)
	returns 0 (0x0)
syscall madvise(0x805d000,0x1000,0x5)
	returns 0 (0x0)
syscall madvise(0x805b000,0x1000,0x5)
	returns 0 (0x0)
syscall close(3)
	returns 0 (0x0)
syscall madvise(0x805a000,0x1000,0x5)
	returns 0 (0x0)
syscall madvise(0x805c000,0x1000,0x5)
	returns 0 (0x0)
Jul 26 12:19:06 zap fetch[10093]: unable to open lockfile: 2 No such file or directory
Jul 26 12:19:06 zap fetch[10093]: unable to open lockfile: 2 No such file or directory

-- 
leafnode-list@xxxxxxxxxxxxxxxxxxxxxxxxxxxx -- mailing list for leafnode
To unsubscribe, send mail with "unsubscribe" in the subject to the list