Solved

Command Prompt inquiry

Posted on 2012-12-30
7
616 Views
Last Modified: 2013-01-02
Hello Experts,
Just wanted to get myself educated on the items that i was asked to run and create a schedule task in our server.
Would you be able to shed some light or links on what this command parameters actually do and the best approach when creating  schedule task using the command mentioned.
Anyway here is the command...

C:\AppScript\run - c all

...on C:\AppScript\ folder there are our files...
C:\AppScript\run.bat
C:\AppScript\run.conf
C:\AppScript\run.jar
C:\AppScript\run.sh

Can you please help me understand....
1.0 Does the dos command runs all the files under the folder?
2.0 If Yes(on 1.0) , does it have a sequence ( i meant run one at a time)? If Yes what is it?
3.0 If no sequesnce, does it just run everything the same time without any dependencies.?
4.0 Lastly , if i am to create a scheduled task do i have to run each file (e.g. run.bat, run.jar, run.conf and run.sh) spearately (or create one start a program entry on each)?

Thanks,
0
Comment
Question by:jsuanque
7 Comments
 
LVL 51

Expert Comment

by:Bill Prew
Comment Utility
We will need to see the contents of the BAT file, that is what should be executed, so to tell what will happen depends on what it contains.

~bp
0
 
LVL 78

Accepted Solution

by:
David Johnson, CD, MVP earned 75 total points
Comment Utility
C:\AppScript\run - c all

this will only start 'run.bat', which may depending upon what it's contents do other items..
%1 will be -
%2 will be c
%3 will be all
and in the batch file it will check these variables and act upon them as required.
0
 
LVL 10

Assisted Solution

by:Korbus
Korbus earned 25 total points
Comment Utility
ve3ofa probabaly has the answer you are looking for.
But you should also be aware of the fact that if there were a run.exe file in the folder, that .exe file would get executed by the command
   C:\AppScript\run - c all

But even if there were such a file, you can always specify exactly which file to run like this:
  C:\AppScript\run.bat - c all
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 14

Assisted Solution

by:Don Thomson
Don Thomson earned 50 total points
Comment Utility
The actual Run.bat  is the only file that will actually load on it's own


The run.conf  file is typically just an instruction set for something like Dosbox.exe

Depending on what is in the run.conf  it would load as a line item in the run.bat
Example :

dosbox.exe run.conf

For the run.jar  you need to put in the program and Parameters that you want to pass to the java script

For Instance:

java -jar run.jar

The run.sh  is a script file but you need to have something like Cygwin installed in order for Dos to know what to do with it. The run.sh will not run natively in DOS

Overall - your question doesn't really make a lot of sense. You're asking us to fix your car without opening the Hood - The three different extensions that you are using are basically control or information files for other programs - and need to be run by those programs - Without knowing what is in the scripts - not much we can tell you
0
 
LVL 78

Expert Comment

by:David Johnson, CD, MVP
Comment Utility
just to expand upon the order of execution DOSKEY Macro  .COM  .EXE  .BAT in versions of dos >4
0
 
LVL 78

Assisted Solution

by:David Johnson, CD, MVP
David Johnson, CD, MVP earned 75 total points
Comment Utility
part 4: you would need a task scheduler entry for each entry, OR create a new batch file that has the following
---- runall.bat ----
start C:\AppScript\run.bat
start C:\AppScript\run.conf
start C:\AppScript\run.jar
start C:\AppScript\run.sh
---- end of runall.bat ----
0
 

Author Comment

by:jsuanque
Comment Utility
Hello Guys thanks for the response.

Hello Korbus, there are no other files (i.e. run.exe) on the directory other than the ones mentioned on the list.  

Hello DTHConsulting, Thanks for the explanation.

Hello Ve30fa, Thanks and as for the scheduled task i created one action...
C:\AppScript\run

And then added argument...
-c all.

I reckon this should be sufficient as for schduling that task  But i guess i'll know tomorrow if its succesfull.
0

Featured Post

Want to promote your upcoming event?

Are you going to an event? Are you going to be exhibiting at a tradeshow? Talking at a conference? Using a promotional banner in your email signature ensures that your organization’s most important contacts stay in the know and can potentially spread the word about the event.

Join & Write a Comment

Scenario:  You do full backups to a internal hard drive in either product (SBS or Server 2008).  All goes well for a very long time.  One day, backups begin to fail with a message that the disk is full.  Your disk contains many, many more backups th…
You might have come across a situation when you have Exchange 2013 server in two different sites (Production and DR). After adding the Database copy in ECP console it displays Database copy status unknown for the DR exchange server. Issue is strange…
This tutorial will walk an individual through locating and launching the BEUtility application and how to execute it on the appropriate database. Log onto the server running the Backup Exec database. In a larger environment, this would generally be …
This tutorial will walk an individual through setting the global and backup job media overwrite and protection periods in Backup Exec 2012. Log onto the Backup Exec Central Administration Server. Examine the services. If all or most of them are stop…

743 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