1

When I try opening the MikTex console I get an error window saying "MiKTeX Console is already running". I tried closing literally every program, and I still get it. I opened Task Manager to see if it showed up there, but no. I tried restarting my laptop. I tried running the console as an administrator, but I get the same message. Any help? Thank you.

4

When launching MiKTeX-console via a .bat / .cmd file or shortcut it will usually show as an icon, however if you don't have show all icons it may not be visible.

enter image description here

You may need to expand all icons to locate it in the taskbar then you should be able to right click and control it. That is preferable rather than using > to expand the Windows Command Processor and killing it there.

enter image description here

It is possible in a dual set-up of Administrator & User that is is running under the other login. to avoid any update problems ensure the user session is not activated by your editor.

To trouble-shoot a dual install log in as user first, check NO editor or Console is active. Log-off as user and login as administrator, DO NOT run any LaTeX related application prior to running MiKTeX-console and if you see this message again you will need to re-boot to flush all active threads.

You should review your launch methods to avoid any dual loading in the first place, and without going into any detail here, there are ways to auto detect and killtask prior to relaunch but that is outside the scope of this site, it should not be necessary and best asked on other stack exchange forums.

2

When I was in this situation, I found that MiKTeX had generated a file named miktex-console.lock in my user folder (C:\Users\MyUsername for Windows users). Deleting the file permitted the application to run.

It appears that the MiKTeX console, for whatever ridiculous reason, does not simply check for other instances of the miktex-console.exe process, and instead generates this "miktex-console.lock" file when launched. Deleting the offending file whenever it is created lets you run as many MiKTeX console instances as you like.

This is horrifically bad design.

  • 1
    It may be possible that in your case the lock file is stopping another MiKTeX session However that is not a reason for the error message as shown in this question. In most cases when MiKTeX crashes or otherwise leaves the lock behind it will normally just reuse it the next time then delete on clean closure. The problem here is that either the file is locked by another application or a second session held open most often by a pdf reader a virus checker or an editor not letting go, hence the need to shut down all memory. Your view is most valid perhaps if MiKTeX cant reset a read only lock file. – KJO Mar 28 at 21:19
  • @KJO Yet, the symptoms shown by the OP are the exact conditions I experienced (no running MiKTeX processes of any kind, but attempting to start the console yields the "already running" prompt). While I don't know the application's requirements, the "already running" message implies an intent to prevent multiple instances of the console from running. Leveraging the filesystem exclusively for this task, thus introducing all the opportunities for issue that you mentioned (and more), is needlessly roundabout and very bad practice. – TiberiumFusion Mar 29 at 1:48
  • I agree that your experience is totally valid and gave +1 for the alternative reason I had forgotten. However in testing I found that the presence of an old lock file did not make a fresh starting MiKTeX complain of one active it simply replaced the lock file. I am single user with elevated privilege so may have greater sway than basic user to cause such behaviour. As you may note another answer where user elevated themselves to admin at system level & say that was their solution. My view is that dual users may have basic user &admin user conflicts & the simplest way to untangle is to log off – KJO Mar 29 at 2:49
0

Well, go on MikTex Console icon, clic onto it with the right button, then click on Other and then click on Execute as Administrator. it should open (at least it opens to me). But don't you think your problems are over with MikTex...

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.