axkibe/lsyncd — Issue #49: 15:27:43 Error: IN LUA: lsyncd.lua:3393: event does not have field 'isList'
Author: axkibe
Created: 2011-11-16 15:03:53+00:00
State: open

Originally filed by aivan...@gmail.com on 2011-02-24T14:32:52

What steps will reproduce the problem?
1.

mkdir /tmp/1 /tmp/2

[alex@alex-c5-64 2]$ cat /etc/lsyncd.conf

sync { default.rsync,
name="alex-c5",
source="/tmp/2",
target="/tmp/1",
rsyncOps={"-a", "--numeric-ids", "--bwlimit=10000", "--delay-updates", "--partial-dir=.rsync.tmp" },
exclude=".rsync.tmp",
init=false
}

gzip_text_pdf = {
onCreate = "sleep 5; test -f ^sourcePathname && echo ^sourcePathname | grep -q txt$ && gzip -f ^sourcePathname",
}
sync { gzip_text_pdf,
name="alex-c5-gzip",
source="/tmp/2",
}
[alex@alex-c5-64 2]$ lsyncd -nodaemon -log all /etc/lsyncd.conf

2. in another terminal:

cd /tmp/2
for i in aa bb cc dd; do echo $i > $i.txt; sleep 15 ; done

What is the expected output? What do you see instead?

files in /tmp/2 should be gzipped and synced to /tmp/1 , instead I see

15:27:38 Inotify: got event Create bb.txt(1)
15:27:38 Function: delay(alex-c5, Create, /bb.txt, (nil))
15:27:38 Exclude: '/bb.txt' NOT matches '/.rsync.tmp'
15:27:38 Delay: New Create:/bb.txt
15:27:38 Function: delay(alex-c5-gzip, Create, /bb.txt, (nil))
15:27:38 Delay: New Create:/bb.txt
15:27:38 Call: inotifyEvent()
15:27:38 Inotify: got event Modify bb.txt(1)
15:27:38 Function: delay(alex-c5, Modify, /bb.txt, (nil))
15:27:38 Exclude: '/bb.txt' NOT matches '/.rsync.tmp'
15:27:38 Delay: Modify:/bb.txt absorbed by Create:/bb.txt
15:27:38 Function: delay(alex-c5-gzip, Modify, /bb.txt, (nil))
15:27:38 Delay: Modify:/bb.txt absorbed by Create:/bb.txt
15:27:38 Call: cycle()
15:27:38 Function: invokeActions('alex-c5',(Timestamp: 316531.19))
15:27:38 Function: invokeActions('alex-c5-gzip',(Timestamp: 316531.19))
15:27:38 Normal: Event Create spawns shell 'sleep 5; test -f /tmp/2//bb.txt && echo /tmp/2//bb.txt | grep -q txt$ && gzip -f /tmp/2//bb.txt'
15:27:38 Exec: /bin/sh [-c] [sleep 5; test -f "$1" && echo "$1" | grep -q txt$ && gzip -f "$1"] [/bin/sh] [/tmp/2//bb.txt]
15:27:38 Call: getAlarm()
15:27:38 Debug: getAlarm returns: (false)
15:27:38 Masterloop: going into select (no timeout).
rsync error: some files could not be transferred (code 23) at main.c(892) [sender=2.6.8]
15:27:38 Call: collectProcess()
15:27:38 Delay: collected a list
15:27:38 Normal: Finished a list = 23
15:27:38 Delay: Finished list = 23
15:27:38 Call: cycle()
15:27:38 Function: invokeActions('alex-c5',(Timestamp: 316531.21))
15:27:38 Function: invokeActions('alex-c5-gzip',(Timestamp: 316531.21))
15:27:38 Call: getAlarm()
15:27:38 Debug: getAlarm returns: (Timestamp: 316546.19)
15:27:38 Masterloop: going into select (timeout 14.98 seconds)
15:27:43 Call: inotifyEvent()
15:27:43 Inotify: got event Create bb.txt.gz(1)
15:27:43 Function: delay(alex-c5, Create, /bb.txt.gz, (nil))
15:27:43 Exclude: '/bb.txt.gz' NOT matches '/.rsync.tmp'
15:27:43 Delay: New Create:/bb.txt.gz
15:27:43 Function: delay(alex-c5-gzip, Create, /bb.txt.gz, (nil))
15:27:43 Delay: New Create:/bb.txt.gz
15:27:43 Call: inotifyEvent()
15:27:43 Inotify: got event Attrib bb.txt.gz(1)
15:27:43 Function: delay(alex-c5, Attrib, /bb.txt.gz, (nil))
15:27:43 Exclude: '/bb.txt.gz' NOT matches '/.rsync.tmp'
15:27:43 Delay: Attrib:/bb.txt.gz absorbed by Create:/bb.txt.gz
15:27:43 Function: delay(alex-c5-gzip, Attrib, /bb.txt.gz, (nil))
15:27:43 Delay: Attrib:/bb.txt.gz absorbed by Create:/bb.txt.gz
15:27:43 Call: inotifyEvent()
15:27:43 Inotify: got event Modify bb.txt.gz(1)
15:27:43 Function: delay(alex-c5, Modify, /bb.txt.gz, (nil))
15:27:43 Exclude: '/bb.txt.gz' NOT matches '/.rsync.tmp'
15:27:43 Delay: Modify:/bb.txt.gz absorbed by Create:/bb.txt.gz
15:27:43 Function: delay(alex-c5-gzip, Modify, /bb.txt.gz, (nil))
15:27:43 Delay: Modify:/bb.txt.gz absorbed by Create:/bb.txt.gz
15:27:43 Call: inotifyEvent()
15:27:43 Inotify: got event Attrib bb.txt.gz(1)
15:27:43 Function: delay(alex-c5, Attrib, /bb.txt.gz, (nil))
15:27:43 Exclude: '/bb.txt.gz' NOT matches '/.rsync.tmp'
15:27:43 Delay: Attrib:/bb.txt.gz absorbed by Create:/bb.txt.gz
15:27:43 Function: delay(alex-c5-gzip, Attrib, /bb.txt.gz, (nil))
15:27:43 Delay: Attrib:/bb.txt.gz absorbed by Create:/bb.txt.gz
15:27:43 Call: inotifyEvent()
15:27:43 Inotify: got event Delete bb.txt(1)
15:27:43 Function: delay(alex-c5, Delete, /bb.txt, (nil))
15:27:43 Exclude: '/bb.txt' NOT matches '/.rsync.tmp'
15:27:43 Delay: Delete:/bb.txt replaces Create:/bb.txt
15:27:43 Function: delay(alex-c5-gzip, Delete, /bb.txt, (nil))
15:27:43 Call: collectProcess()
15:27:43 Delay: collected an event
15:27:43 Error: IN LUA: lsyncd.lua:3393: event does not have field 'isList'
15:27:43 Error: Backtrace 1 :[C]:-1
15:27:43 Error: Backtrace 2 :lsyncd.lua:722
15:27:43 Error: Backtrace 3 :lsyncd.lua:3393
15:27:43 Error: Backtrace 4 :lsyncd.lua:1198
15:27:43 Error: Backtrace 5 :lsyncd.lua:2500

What version of the product are you using? On what operating system?

lsyncd 2.0.2 on centos5 x86_64

Please provide any additional information below.