Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I encountered a problem when trying to run pdfLaTeX using Texmaker: I get

log file not found

for the test "hello world" script.

I tried reinstalling MikTeX and Texmaker, but still get the same problem.

Anybody has any idea?

share|improve this question
2  
Welcome to TeX.SX! You can have a look on our starter guide to familiarize yourself further with our format. Did you restart PC to take the Path of miktex bin into effect after MiKTeX installation ?. Verify on command line window by typing pdflatex sample2e to get a sample2e.pdf document to ensure TeX distribution installed properly. BTW Are you using latest version TeXmaker. Save the filename as filename.tex with .tex extension –  texenthusiast Jun 4 '13 at 16:02
1  
I encounter the same problem today. It worked fine a few days ago. Suddenly it did not work anymore. When I typed pdflatex sample2e on the command line window, it says pdflatex is not recognized as an internal or external command, operable program or batch file. –  user32229 Jun 14 '13 at 3:36
    
You should try to run TeXmaker as administrator. Does that solve your problem? –  Werner Jul 8 '13 at 18:50
    
I have this problem, and can confirm that running TeXmaker (v 3.2 on Ubuntu 12.04) as root does not fix it. Several "log file not found" dialogs pop up, and then the PDF is successfully generated. What causes them? –  Ian Aug 4 '13 at 20:55
    
Did you installed TeX distribution correctly? TeXmaker is just a plain text editor, and it will not work without TeX distribution. –  Ch'en Meng Dec 3 '13 at 14:28
show 4 more comments

4 Answers

I have "log file not found" errors, but the PDF is successfully generated.

This appears to be caused by the -output-directory=/tmp option in my configuration for the latex executable. Texmaker looks for the logfile in the same directory as your source file.

I was able to solve this by creating an empty file in the same directory as my .tex file.

For example, if your file is called myfile.tex, create an empty file in that same directory called myfile.log. It suppresses the error.

You can also ln -s /tmp/myfile.log ./ in your project directory, which suppresses the error and shows you the error log if you make when you make errors.

I am using Texmaker v3.2 on Ubuntu 12.04.

share|improve this answer
1  
Have a look at solutions to common problems based on TeXmaker errors Unable to compile TeXmaker 4.0.2 with MiKTeX 2.9 –  texenthusiast Aug 4 '13 at 22:05
    
Thanks @texenthusiast but these don't apply to me. I'm not on Windows, and my latex installation does indeed work -- my PDFs were successfully generated (I just had to click through some annoying messageboxes). I've updated my answer with this info. –  Ian Aug 5 '13 at 12:45
    
BTW Just for info: Latest version of TeXmaker is 4.0.3 –  texenthusiast Aug 5 '13 at 14:03
    
Are you using that on Ubuntu? –  Ian Aug 5 '13 at 14:51
    
Yes, I downloaded from here xm1math.net/texmaker/download.html#linux. Those errors from TeXmaker are relevant for any OS and some are specific to OS also. It's a mix. –  texenthusiast Aug 5 '13 at 15:00
add comment

Texmaker -> Options/Configure Texmaker/Commands/LaTeX...

click on the folder icon and find this file:

C:/Program Files/MiKTeX 2.9/miktex/bin/x64/latex.exe

Texmaker -> Options/Configure Texmaker/Commands/PdfLaTeX...

find

C:/Program Files/MiKTeX 2.9/miktex/bin/x64/pdflatex.exe 
share|improve this answer
add comment

I solved the problem in one hour by uninstalling MikTex and Texmaker and reinstalling it again ... (after many hours struggling to solve the problem...)

share|improve this answer
add comment

I already posted this in the comments, but it seems to be a common problem. As @texenthusiast mentions, you want to make sure that you can use pdflatex (or whatever LaTeX compiler you want to use) from command line. The following is for Windows:

First, test it out. Press Windows-Key+R (for Run). Then, type cmd to open Windows' command line terminal. Now type pdflatex. If you, like some people in the comments, encounter command not found, below is a way to fix this. If this is not your problem, the following won't help you (press CTRL+C to exit the program).

  1. Make sure, you have MiKTex (or some other TeX or LaTeX distribution) installed.
  2. Make sure that it's binary folder is added to the Windows PATH. To do that, follow these instructions on how to edit your PATH system variable. It is a semicolon-separated list of folders from where it will look-up any executable file that you try to use (such as pdflatex). Add your MiKTex bin folder to it. For me, that is: c:\Program Files\MiKTeX 2.9\miktex\bin\x64\.
  3. The PATH variable (for some retarded reason) has a max length of 1000 characters or so. If you, like me, tend to exceed that limit, you might want to take a look at this SO discussion on the matter.
  4. Always restart your editor (or command line terminal) after changing system variables (they get loaded when a program starts).

Good luck!

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.