Error: I can't find the format file pdflatex.fmt

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.


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

Tags:

Pdftex