Batch file not working in iis6 window2003 - batch-file

I want to run a batch file that will call openssl.exe to verify signature and after successful verification it will unzip the ziped file. The batch file is working fine manually, but when I call it from classic asp page it is not getting executed.
I have tried everything but it's not executing; it not even showing any message. I'm using a 32bit OS.

Add "Read and execute" permission for files CMD.EXE, OpenSSL.EXE for the user that running your Application pool.

Related

Why isn't my Batch file opening when windows start?

The batch I created is intended to start a Python file, and for reasons of dependency with Python and Geckodriver, I have no way to work with the Batch file directly in the Startup folder, for this reason I need to work with registries.
I entered the following key in the HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run path:
But for some reason the Batch file associated with the key does not open when Windows starts. I already checked everything, the Batch file works perfectly when executed manually and path in the key value is totally correct. It is not working on RunOnce either. I also checked the Startup tab in the Task Manager and it is enabled. Does anyone know what could be happening? why is the file not working?

Why ERROR: Input redirection is not supported, exiting the process immediately

I have a batch file (inside server) that calls a python script (inside server) to unzip and that calls another batch (inside server) with popen. The issue is related to the fact that each time i call the batch the file are unzipped but the second batch is not called. I think because of the error message in the title. However if I try to run everything on my pc, instead of locating those files within server everything works
Thank you for the attention

Batch File not starting automatically as a service

i am having trouble while starting a batch file as a service. the batch file runs fine when started manually but it doesnt starts a service and no ouput is observed. i have used nssm service manager to start the service.
below are the commands which i have used :
D:\nssm-2.24\win32>nssm install call
D:\nssm-2.24\win32>nssm start call
while installing i have provided the path of batch file.
the batch file contains the windows script to start few programs automatically.
you cannot just install any old executable as a service, and certainly not a batch file. a service is a program with a specific API which makes it react to service manager calls. ignore that, i just read up on nssm. still, there are probably better ways.
your use case sound rather like you might want to put your batch file in the autostart startmenu folder, to run it at login/startup.
or a scheduled task, if you want to restart it regularly.
one thing to consider, too, is the user under which the script is executed.

Console Program crashes when run from Windows Service

I am using a Windows Service to run my batch file on scheduled times. The batch file runs an .exe file that is a Console application that simply shows a message and creates a file on a folder. When I run this program manually, the program works and the file is created. But when I try to run the program via my Windows Service the program crashes (or in some cases it asks for permission which is not good).
If I do not use the Console in my program however (nothing shown to the user and everything done in the background), the file is correctly created. I need to make sure that the service runs my .exe/.bat files but it looks like running executable files are a bit risky with services.
Is there a way to solve this problem or should I change my program so that it only does things in the background and does not display anything?
Is your service being run in the LocalSystem account -- the default for all Windows Services? If so, then your console application is being launched in that same account, where it may not be able to find its settings.
Try providing your Windows account on the service's Log On tab to see if that gets around the problems. Be sure to set an account where the console application runs normally!

Jenkins: Unable to execute batch file on a virtual machine

I created a new free-style software project and under "Configure", I added a "Execute Windows batch command" under the section "Build".
My command in the text-box is as follows:
call \\ukvc-miu29-12\c$\Testing1\testing.bat
My console output when I try to run my build is as follows:
Started by user anonymous
Building in workspace C:\Program Files (x86)\Jenkins\jobs\Run comparison script\workspace
[workspace] $ cmd /c call C:\Windows\TEMP\hudson1649447975658279345.bat
C:\Program Files (x86)\Jenkins\jobs\Run comparison script\workspace>call \\ukvc-miu29-12\c$\Testing1\testing.bat
Access is denied.
C:\Program Files (x86)\Jenkins\jobs\Run comparison script\workspace>exit 1
Build step 'Execute Windows batch command' marked build as failure
Finished: FAILURE
Have spent close to two hours looking for a solution online, but I am unable to find one.
New to Jenkins, so any suggestion/s is/are appreciated, thanks!
I guess Jenkins runs as another user than the one you're logged in with. So that user probably isn't allowed to access that network share (or doesn't have the login credentials cached).
The easiest way of making sure it will work, would probably be to add the same user with the same password that Jenkins runs under to \\ukvc-miu29-12.
(As for the call, I'm not sure you really need it and I have a vague suspicion that you end up failing the build every time if you use call here. The temporary batch Jenkins executes there looks like it relies on the fact that control won't return if the batch file was executed successfully. But that's just a guess on my part.)

Resources