I'm having some issues with externalising my tikz images.

I'm using the following preambel with -shell-escape enabled using lualatex:

% for splitting lines on maths
% these packages are for inserting graphics, allowing spaces in file paths and specifiying file path
% bibliography setup:
\usepackage[firstinits=true,backend=bibtex,style=authoryear,natbib=true,maxbibnames=99,urldate=long]{biblatex}% use "[style=authoryear]" alternatively.
\DeclareFieldFormat[article]{volume}{\bibstring{volume}\addnbspace #1}
\DeclareFieldFormat[article]{number}{\bibstring{number}\addnbspace #1}
%for landscape pages
% for wider margins
% for inserting Tikz Figures 


% setting output name same as input name
%   \tikzsetnextfilename{#1}%
%       \input{./TikzInput/#1.tikz}%
%for tables
% to include matlab scripts (make sure mcode.sty is in the master tex location)
% adjusting the margins
% for inserting Pages
% for inserting pdfs
% for making Tikz Pie charts
% for the tick symbol

% For the Title Page
  honours-prelim, % "honours-final" for the final report

where "TESTING DELETE" contains:




When I run the code without the externalise (\usetikzlibrary{external} and \tikzexternalize[prefix=TikzOutput2/]) it compiles fine.

But when I include the two lines I then get that the file cannot be created, the error that appears is

! Package tikz Error: Sorry, the system call 'pdflatex -halt-on-error -interact ion=batchmode -jobname "TikzOutput2/FinalReport-figure0" "\def\tikzexternalreal job{FinalReport}\input{FinalReport}"' did NOT result in a usable output file 'T ikzOutput2/FinalReport-figure0' (expected one of .pdf:.jpg:.jpeg:.png:). Please verify that you have enabled system calls. For pdflatex, this is 'pdflatex -sh ell-escape'. Sometimes it is also named 'write 18' or something like that. Or maybe the command simply failed? Error messages can be found in 'TikzOutput2/Fin alReport-figure0.log'. If you continue now, I'll try to typeset the picture.

Besides the fact I'm probably horribly using the wrong packages here and there, can anyone see the issue? I can't seem to find the issue in the log file either.

closed as unclear what you're asking by darthbith, user13907, Maarten Dhondt, Stefan Kottwitz Jan 5 '16 at 12:39

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • 1
    Try \tikzset{external/system call={lualatex -shell-escape -halt-on-error -interaction=batchmode -jobname "\image" "\texsource"}} \tikzexternalize - This works for me, as long e.g. no remember picture is used. If it doesn't work, prepare a MWE, otherwise you can be sure that no one can help you, as even the tikz code is missing. – John Sep 29 '14 at 11:33
  • 1
    I've never gotten it to work either. It's faster to develop a tikzpicure using a separate standalone, then just use \inputgraphics once it is stable. – John Kormylo Sep 29 '14 at 13:47
  • I don't see lua in the preamble. What about the size of the tikz? Maybe it is using too much memory. – Ali Sep 29 '14 at 14:19
  • @JohnKormylo I half agree. (But I +1ed your comment as I cant +.5 ;).) It does sometimes work. But it is unpredictable (to me) when, so it is necessary to keep turning it on and off in the file, and to some extent learning by trial and error. This is a shame since using standalone does not always fit very well and adds its own complexities, to boot. I've never gotten the forest derivative to work. It does, however, work quite well for mindmaps. (This is useful as they take forever to compile for me.) – cfr Sep 29 '14 at 23:36
  • @cfr Would you mind to collect the problems you encountered into a "suitable" bug report and sent it to me by email? I have read you suggestion here and in tex.stackexchange.com/questions/204712/… and I am willing to see what could be done about the problems. Apparently, you have a couple of offending documents. My mail address can be found in the manual of pgfplots. – Christian Feuersänger Nov 1 '14 at 21:25