[Tikzdevice-bugs] Error in createLockFile(lockname) : cannot create lock file

Vegard Nossum vegard.nossum at gmail.com
Mon May 23 15:51:41 CEST 2011


Hi,

I got this error:

> tikz(file="plot.tex")
> cr.plots(lm(A ~ B, data = C), ask = F)
Error in createLockFile(lockname) : cannot create lock file

By some googling, I found a similar report (with no replies):

http://r.789695.n4.nabble.com/debug-R-device-plot-tt3403638.html

So what's wrong is that I had earlier aborted cr.plots() by pressing
ctrl-C, and it appears that somebody didn't clean up the
tikzMetricDictionary lock file. Moreover, tikzDevice appears to
proceed to call close(-1) if creating the file fails (strace output):

open("/tmp/Rtmp1HU5cv/tikzMetricsDictionary", O_RDONLY) = 4
open("/tmp/Rtmp1HU5cv/tikzMetricsDictionary___LOCK",
O_WRONLY|O_CREAT|O_EXCL, 0666) = -1 EEXIST (File exists)
close(4294967295)                       = -1 EBADF (Bad file descriptor)
write(2, "Error in createLockFile(lockname"..., 60) = 60

Removing the ___LOCK file fixed things for me.

Just wanted to let you know. My version of R is 2.10.0 (2009-10-26)
and my version of tikzDevice is 0.5.3.


Vegard


More information about the Tikzdevice-bugs mailing list