21

For no particular reason that I could identify, I was faced with the impossibility to compile any latex document and invariably got this error message each time I tried :

LaTeX: problems after [0] pages

kpathsea: Running mktexfmt pdflatex.fmt
tcfmgr: config file `tcfmgr.map' (usually in $TEXMFMAIN/texconfig) not found.
I can't find the format file `pdflatex.fmt'!
  • For me I simply had to copy the .fmt file into the directory the PHP file was calling it from. It worked fine from a terminal but gave the error when running via PHP. – Alan Feb 17 '15 at 15:53
12

I thought I would post this here because it gave me some cold sweats as I could not make any sense of the error message and have only two months remaining to write my thesis.

In a terminal, just type

sudo texconfig rehash

which should give

mktexlsr: Updating /var/lib/texmf/ls-R-TEXMFMAIN...
mktexlsr: Updating /var/lib/texmf/ls-R-TEXLIVE...
mktexlsr: Updating /var/lib/texmf/ls-R...
mktexlsr: Done.

This solution was found on this website.

  • 4
    This answer led to another question. It is easier and more conventional to simply use sudo texhash. – Serge Stroobandt Jun 20 '13 at 9:31
  • 2
    Both rehash and texhash produce an analogous output, but I am still returned the same errore message. – Delio Sep 25 '14 at 13:23
1

I had this problem and none of the sites I visited helped. This is for linux. I was installing on a semi-incomplete backed-up image of a previous computer. My problem turned out to be the pre-existing config files in /etc/texmf/updmap.d

This is what I did:

  1. Remove all tex packages: sudo apt-get remove texlive*

  2. PURGE all tex packages: sudo apt-get purge texlive*

  3. Delete everything in /etc/texmf/updmap.d

  4. Re-install desired tex packages: sudo apt-get install texlive etc

It now seems to work fine.

Phil

1

Check whether the file is in your TeX search path.

kpsewhich pdflatex.ini

If the result is empty, then add path to TEXINPUTS, e.g. put into .bash_profile

export TEXINPUTS=.:/opt/tex/cur/texmf-dist/tex/latex/latexconfig/

UPD. If this doesn't help with other paths, it means that your installation is corrupt. To reisntall would be better in that case (I'm doing that at the moment).

  • Nuking and re-installing a 5GB piece of software, that took over 120 minutes of full tilt CPU, is a bit of an upsell for such a weak kind of error, I think the better solution as this point is to > /dev/null this pdflatex kaynine excrement. Problem solved! – Eric Leschinski Oct 28 '19 at 17:34
0

I solved the same problem in openSUSE Tumbleweed with re-installing texlive via

 zypper remove texlive*
 zypper install texlive
  • This doesn't work if recommended packages are not set to be installed as well. – ytg Dec 22 '17 at 15:34
0

If this can be of any help it happened the same to me and I realized that, since the last time I had opened Texmaker, I had installed Anaconda. It turns out that Anaconda had installed a texlive-core package, which was conflicting with my original texlive installation. I just had to remove the anaconda package through:

conda remove texlive-core

and it worked. None of the previous solutions worked for me for obvious reasons.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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