0

There are other posts on the forum with similar titles, but I think my problem is different and hence am posting this inquiry here.

What I encountered is the same (as other posts) in that I was "suddenly" prompted with an error message "perl is not recognized as an internal or external command, operable program or batch file".

But the differences are (or so I think) -

(1) Strawberry Perl (64-bit) installed and ran well earlier.

(2) After the error message showed up, I typed path under cmd and it showed that Strawberry perl was "still" in the path (assuming my understanding of the path in cmd was correct). See at the end the full "PATH".

(3) Earlier of the day I ran a few perl scripts with no problems. Then I noticed my Panda Free Antivirus was disabled. I re-enabled it and started a full scan. It seems that right after I started the scan, the error message about perl not recognized showed up when I attempted to run another script.

Any solution as to how I could run perl scripts, assuming PATH is correctly set. (Antivirus Scan is ongoing. I know perhaps I should have waited until the scan is finished and re-test the perl module, but I wonder why anti-virus, if at all, would cause the conflict with Strawberry Perl module)

Not sure if this is a question for stackoverflow or if I should direct my question to anti-virus forum/am-I-infected forum ?

Any suggestion?

PATH=C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\Cuminas\Document Express DjVu Plug-in\;c:\Program Files (x86)\Intel\iCLS Client\;c:\Program Files\Intel\iCLS Client\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;c:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files (x86)\Intel\OpenCL SDK\3.0\bin\x86;C:\Program Files (x86)\Intel\OpenCL SDK\3.0\bin\x64;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Strawberry\perl\bin;C:\Strawberry\perl\site\bin;C:\Strawberry\c\bin;

Mark
  • 2,380
  • 11
  • 29
  • 49
B Chen
  • 923
  • 2
  • 12
  • 21
  • 1
    Did your antivirus find a false positive on `perl.exe` and quarantine or delete it? Is there a `perl.exe` in `C:\Strawberry\perl\bin`? – cjm Jun 07 '15 at 03:08
  • No & Yes. So far, no antivirus did not pick up perl.exe as a suspect (scan not finished). And yes, perl.exe (perl15.22.0.exe) is still in strawberry\perl\bin – B Chen Jun 07 '15 at 03:55
  • 2
    `perl.exe` and `perl5.22.0.exe` are two separate (though identical) files. Typing "perl" will run `perl.exe`, not `perl5.22.0.exe`. You'd have to type "perl5.22.0" to run that. – cjm Jun 07 '15 at 04:22
  • to clarify, am i supposed to have perl.exe from Strawberryperl ? a search in C: shows that there is no perl.exe. so either it's been quarantined, or it's never there to begin with. but as i never check after installing strawberryperl, it's difficult to know now if i had it at the beginning (a quick look at strawberryperl.com didn't seem to suggest perl.exe exists though) – B Chen Jun 07 '15 at 04:35
  • @CJM, you are right ! It turns out antivirus DID quarantine perl.exe as a suspect. Thanks a lot for the help ! – B Chen Jun 07 '15 at 05:14
  • I've summarized my comments as an answer so you can accept it. – cjm Jun 07 '15 at 20:33

1 Answers1

2

Just because the Strawberry Perl bin directory is still in your path, it doesn't follow that perl.exe is still located in that directory. perl.exe and perl5.22.0.exe are two separate (though identical) files. Typing "perl" will run perl.exe, not perl5.22.0.exe. You'd have to type "perl5.22.0" to run that.

The message "perl is not recognized as an internal or external command, operable program or batch file" indicates that perl.exe was not found in any directory in your path. (Or your system is so messed up it can't run .exe files anymore, which can happen.) So something (e.g. your antivirus) must have removed perl.exe.

cjm
  • 61,471
  • 9
  • 126
  • 175