Solved

Running a batch file as a service

Posted on 1998-02-02
6
211 Views
Last Modified: 2013-12-19
My question is simple, and for those with time, probably easy to answer.  So earn a quick 100 points and help me here.

I am running NT Server 4.0 on a Dual Pentium Pro 200 system with 256 megs of RAM.  This is the intranet server here at work.

We have some java programs that require server side control to function (directory mapper, etc).  Right now, I have the java programs run when I login, but I don't want to have to be logged in.  If the server crashes, I can reboot it remotely, but logging the machine in is a problem.

I know this can be done, but I can't remember how.  All I want to do is have these batch files run as a system service.
0
Comment
Question by:libido011397
6 Comments
 
LVL 2

Expert Comment

by:igroove
ID: 1570753
Use the AT scheduler as an administrator.  Don't forget to enable it in your service control panel.

0
 
LVL 2

Expert Comment

by:moellert
ID: 1570754
The correct way is to use the srvany.exe program from the Rersourcekit. You will find a txt.file which explains the correct way to implement it. If you have any questions to feel free to ask me.
If this is the correct answer for you, please tell me and I will change this comment to an answer.
0
 
LVL 2

Expert Comment

by:moellert
ID: 1570755
The correct way to do this, is to use the srvany program from the Resourcekit. This tool makes it possible to run any program (exe, bat, cmd) as a service. You will find a txt.file which explains the correct way to implement it. If you have any questions to feel free to ask me.
If this is the correct answer for you, please tell me and I will change this comment to an answer.
0
Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

 

Author Comment

by:libido011397
ID: 1570756
Sorry, I just like moellert's answer more...

moellert:  Write that as an answer to receive the points
0
 
LVL 3

Expert Comment

by:os012897
ID: 1570757
There is also the free tool AutoExNT that lets you start a batch-file called autoexnt.bat where you in turn can do whatever u want.

Greetings,

        os

0
 
LVL 2

Accepted Solution

by:
moellert earned 100 total points
ID: 1570758
The correct way to do this, is to use the srvany program from the Resourcekit. This tool makes it possible to run any program (exe, bat, cmd) as a service. You will find a txt.file which explains the correct way to implement it. If you have any questions to feel free to ask me.
If this is the correct answer for you, please tell me and I will change this comment to an answer.  
0

Featured Post

Control application downtime with dependency maps

Visualize the interdependencies between application components better with Applications Manager's automated application discovery and dependency mapping feature. Resolve performance issues faster by quickly isolating problematic components.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Sometimes you might need to configure routing based not only on destination IP address, but also on a combination of destination IP address (or hostname) and destination port number. I will describe a method how to accomplish this with free tools. …
This article offers some helpful and general tips for safe browsing and online shopping. It offers simple and manageable procedures that help to ensure the safety of one's personal information and the security of any devices.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
This is a video that shows how the OnPage alerts system integrates into ConnectWise, how a trigger is set, how a page is sent via the trigger, and how the SENT, DELIVERED, READ & REPLIED receipts get entered into the internal tab of the ConnectWise …

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now