I want to launch multiple scripts written in Java from command line

Hi,
I have created a Master script file (script.java) which call functions available in other class files. (created through Java code).
Now, let's say I have 10 functions(scripts) on master script file but I want random selection for executing these functions. Do we have any interface for selection from available scripts?
Edited by: 917140 on Apr 10, 2012 8:11 AM

"Everything I know about the command is in the man page. I can't give you a literal command, because I don't know what to put in for the arguments. To be honest, if the man page is not understandable enough for you to build the command, I don't think you should use it at all. Use Profile Manager in OS X Server, which is the right way to do what you're trying to do."
I do not know why this post did not show up here on the thread, I did get the email. Not sure how to respond. We have 800 stations. Can not go and touch each one, so looking for a command line to remove the ssid "campus" - If I read your message correct, you do not know the command line either for this. Thank you.

Similar Messages

  • How to launch a specific TestStand sequence file from command line?

    I've written a TestStand sequence file launching other sequence files.
    When I launch it via the TestStand GUI, it works well.
    Now, I would like to launch it via command line. Could you indicate me how to proceed?

    Hi,
    I think this link can help you:
    How to Run a Sequence File When Opened from Windows Explorer
    http://digital.ni.com/public.nsf/websearch/146D372C1F807E6D862567E7004881AB?OpenDocument
    regards,
    Alexandre D
    NIF

  • Need a sample file for IDQ parameter file and a Shell script to execute it from command line

    Hello,The parameter file itself is generated from cmd line using infacmd command and it automatically creates the parameters inside it based on the parameters created inside the mapping and the workflow. So, even if one provides you a paramtere file for IDQ, it might fail as your workflow definition and its paramters would be different. Thanks,K

    Hi all   My project migrated from Power Center to IDQ developer and I had to move all my mappings to IDQ developer. I was able to migrate everything except for the parameter files. It seems that the layout and syntax for parameter file is different from Power Center. Is there anyone who can help me out or send me a sample of a parameter file for IDQ? As well as a sample shell script to run the mapping or application from the Command line.This is an urgent need and It will be greatly appreciated.   ThanksNaveen Medisetti

  • TS1382 I want to add multiples of the same song from different playlists to my ipod but iTunes wont let me. How can I override this so that I get the songs I want on my ipod?

    I want to add multiples of the same song from different playlists to my ipod but iTunes wont let me. How can I override this so that I get the songs I want on my ipod?

    You can sync those different playlists to the iPod, and the song appears on each playlist.  However, the song is stored on the iPod once.  What is the practical reason for wanting to store the same song file multiple times (and waste storage space) on the iPod?

  • Running Oracle Scripts from Command Line

    Hi,
    How can i run Oracle scripts from command line.
    Actually i need to run these scripts from MSBuild before running Unit test projects

    C:\>sqlplus @myscript
    That would be the easiest variation
    C:\>sqlplus user/passwd@tns_alias @myscript
    would be an often used variation
    And then there is of course the version with parameter passing:
    C:\>sqlplus user/passwd@tns_alias @myscript param1 ... paramx
    Dunno about MSBuild

  • Launche DDDAUDIT from commande line

    Hi,
    how to Launche DDDAUDIT and SYSAUDIT, Initial alter audit from commande line ?
    Thank you.
    PS Version 8.48.16

    Go to PS_HOME\bin\client\winx86, and run in a DOS prompt window :
    pssqr -CT ORACLE -CD dbname -CA ps_username -CAP password -RP dddaudit -OT 2 -OF 2OT=2 for an output file
    OF=2 for a PDF format file
    That implies you already defined some env variables.
    For more info, just kick pssqr on the OS prompt, you'll get all the options.
    Or you could try to define a icon on your desktop pointing to the PSSQRW.EXE command and define the target as following - maybe the simplest way :
    -ZIF+ps_home_path+\sqr\pssqr.ini -i+ps_home_path+\sqr\ -f+output_directory+ -KEEP -PRINTER:PD
    Nicolas.

  • [Solved] Launching multiple instances of a service from systemd timer

    I have a short script that I want to run every 5 seconds.  I've set up a systemd timer, which runs the script every 5 seconds, assuming the script terminates before the next elapse of the timer.  However, if the script is still running when the timer elapses, systemd sees that the service is already active, so it does not run my script again. 
    How can I make my script run in another instance, every 5 seconds, even in cases where the script is still running from an earlier elapse of the timer? 
    I'd like to keep everything managed by systemd, in that it should capture stdout into the journal.  I've looked at using a systemd socket unit with ListenStream pointing to a file system socket, where the socket-activated service template runs my script.  Then, a timer unit runs a script that calls socat to send a single character to the file system socket to spin up an instance.  The nice thing about this approach is that systemd can manage limiting the number of socket activations that can be spun up.  However, I haven't gotten this idea to work yet. 
    Here's my test script, which I can cause to run for a long time by creating a lockfile. 
    [root@dogbert system]# cat /var/lib/misc/test1.py
    #!/usr/bin/python2
    import os
    import time
    import sys
    print "%d starting..." % os.getpid()
    sys.stdout.flush()
    while os.path.exists("/tmp/test1.lockfile"):
    print "%d sleeping..." % os.getpid()
    sys.stdout.flush()
    time.sleep(1.0)
    print "%d exiting..." % os.getpid()
    Here are my unit files:
    [root@dogbert system]# cat /etc/systemd/system/test1.timer
    [Timer]
    OnBootSec=1min
    OnCalendar=*:*:0/5
    AccuracySec=50ms
    [Install]
    WantedBy=timers.target
    [root@dogbert system]# cat /etc/systemd/system/test1.service
    [Service]
    Type=oneshot
    ExecStart=/var/lib/misc/test1.py
    Here's what happens if I create the lock file and then remove it.  The script does not run at 10:39:30, but I get one "catch-up" run of the script at 10:39:32. 
    May 02 10:39:20 dogbert test1.py[10209]: 10209 starting...
    May 02 10:39:20 dogbert test1.py[10209]: 10209 exiting...
    May 02 10:39:25 dogbert test1.py[10228]: 10228 starting...
    May 02 10:39:25 dogbert test1.py[10228]: 10228 sleeping...
    May 02 10:39:26 dogbert test1.py[10228]: 10228 sleeping...
    May 02 10:39:27 dogbert test1.py[10228]: 10228 sleeping...
    May 02 10:39:28 dogbert test1.py[10228]: 10228 sleeping...
    May 02 10:39:29 dogbert test1.py[10228]: 10228 sleeping...
    May 02 10:39:30 dogbert test1.py[10228]: 10228 sleeping...
    May 02 10:39:31 dogbert test1.py[10228]: 10228 sleeping...
    May 02 10:39:32 dogbert test1.py[10228]: 10228 exiting...
    May 02 10:39:32 dogbert test1.py[10250]: 10250 starting...
    May 02 10:39:32 dogbert test1.py[10250]: 10250 exiting...
    May 02 10:39:35 dogbert test1.py[10269]: 10269 starting...
    May 02 10:39:35 dogbert test1.py[10269]: 10269 exiting...
    May 02 10:39:40 dogbert test1.py[10287]: 10287 starting...
    May 02 10:39:40 dogbert test1.py[10287]: 10287 exiting...
    Last edited by johnp636 (2015-05-05 01:22:35)

    johnp636 wrote:However, if the script is still running when the timer elapses, systemd sees that the service is already active, so it does not run my script again.
    That's normal, you cannot start again an already active service unit, which is what the timer tries to do if the next trigger comes before the service ends.
    How can I make my script run in another instance, every 5 seconds, even in cases where the script is still running from an earlier elapse of the timer?
    I don't think that a timer can do this with a simple service.
    But a shell script can manage this.
    I'd like to keep everything managed by systemd, in that it should capture stdout into the journal.
    The command 'systemd-cat' can be used in the shell script to get this feature.
    I propose this bash script:
    #!/bin/bash
    nbprocess=0
    while true; do
    if ((nbprocess <= 2)); then
    systemd-cat /var/lib/misc/test1.py &
    fi
    nbprocess=$(pgrep test1.py|wc -l)
    sleep 5
    done
    It limits the number of test1.py processes to 3.
    This script can be started with a service unit, without using a timer:
    [Service]
    ExecStart=/var/lib/misc/test1.sh
    Stopping this service, will end all the running test1.py processes.
    Maybe there is a better way to do this, but this method is simple; if I find something else, I will post again.

  • Running Shell script from command line

    Hi,
    I am getting a Exception in thread "main" java.lang.NoClassDefFoundError: TestRuntime/java error when I run the following code on my linnux box...can anyone please help
    import java.io.*;
    public class TestRuntime {
            public static void main(String args[]) {
                    Runtime runtime = Runtime.getRuntime(); //get runtime information
            try {
                            Process Child = runtime.exec("/usr/bin/ksh"); // execute command
                            BufferedWriter outCommand = new BufferedWriter(new OutputStreamWriter(Child.getOutputStream()));
                            outCommand.write("/home/mypath/tesh.csh");
                            outCommand.flush();
                            try {
                                    Child.waitFor(); // wait for command to complete
                            } catch (InterruptedException e) { // handle waitFor failure
                                    System.out.println("ERROR: waitFor failure");
                                    System.exit(10); // exit application with exit code 10
                    } catch (IOException e) { // handle exec failure
                            System.out.println("ERROR: exec failure" + e);
                            System.exit(11); // exit application with exit code 11
    }

    If I'm reading your code correctly, you're starting a Korn shell session, then executing your C shell script as if you were at at the session window's prompt. If that is correct, you haven't caused your standard out (stdout) to hit ENTER yet. I'm not an expert, but I hope this works for you.
    Your code:
    Process Child = runtime.exec("/usr/bin/ksh"); // execute command
                            BufferedWriter outCommand = new BufferedWriter(new OutputStreamWriter(Child.getOutputStream()));
                            outCommand.write("/home/mypath/tesh.csh");
                            outCommand.flush();I think you need to enter one extra line before the flush():
    Process Child = runtime.exec("/usr/bin/ksh"); // execute command
                            BufferedWriter outCommand = new BufferedWriter(new OutputStreamWriter(Child.getOutputStream()));
                            outCommand.write("/home/mypath/tesh.csh");
                            outCommand.newLine();  // hit ENTER
                            outCommand.flush();P.S. If you're running this script and your Java program from the same UNIX machine, you could just execute the shell script inside the runtime.exec() call.

  • Running report from command line with multiple value for same parameter

    Hey,
    I know how to run a report from the command line specifying parameters values each time but I was wondering if someone could tell me how I would go about running the same report multiple times in a batch program but specifying a list of values to pass to a parameter each time.
    So for example if a parameter was 'School Number', how could I run a report in a batch program that would pass a school number to the report as a parameter using a list of school numbers generated for a sql statement or something. So if I had 300 school numbers in my list then I would get 300 different reports when the batch program finished.
    This leads me to another question. How can I dynamically change the name of the report generated by the batch to use the school number value passed in, so for example if the value 3 was passed in the name would be something like School 3.pdf, if 4 was passed in the name would be School 4.pdf....etc
    Any help on this?
    Thanks

    Hello,
    Bursting and Distribution may help you ....
    37 Bursting and Distributing a Report
    http://download-uk.oracle.com/docs/cd/B14099_17/bi.1012/b13895/orbr_dist.htm
    Regards

  • Windowing system wont launch at bootup? Goes to Darwin command line.

    After doing a recent software update my computer restarted but instead of going to the Mac OS GUI it boots to a command line prompt that says
    Darwin/BSD (my-computer-name.local) (console)
    Login:
    After entering my user and password it says password failed. Any idea what is wrong or how to fix it??
    Thanks

    See if one of these helps:
    Computer booting into Darwin Fix;
    Apple - Support - Discussions - Booting to Darwin-BSD Screen.
    If you cannot resolve the problem you will need to do the following:
    How to Perform an Archive and Install
    An Archive and Install will NOT erase your hard drive, but you must have sufficient free space for a second OS X installation which could be from 3-9 GBs depending upon the version of OS X and selected installation options. The free space requirement is over and above normal free space requirements which should be at least 6-10 GBs. Read all the linked references carefully before proceeding.
    1. Be sure to use Disk Utility first to repair the disk before performing the Archive and Install.
    Repairing the Hard Drive and Permissions
    Boot from your OS X Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Installer menu (Utilities menu for Tiger.) After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list. In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive. If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported, then quit DU and return to the installer.
    2. Do not proceed with an Archive and Install if DU reports errors it cannot fix. In that case use Disk Warrior and/or TechTool Pro to repair the hard drive. If neither can repair the drive, then you will have to erase the drive and reinstall from scratch.
    3. Boot from your OS X Installer disc. After the installer loads select your language and click on the Continue button. When you reach the screen to select a destination drive click once on the destination drive then click on the Option button. Select the Archive and Install option. You have an option to preserve users and network preferences. Only select this option if you are sure you have no corrupted files in your user accounts. Otherwise leave this option unchecked. Click on the OK button and continue with the OS X Installation.
    4. Upon completion of the Archive and Install you will have a Previous System Folder in the root directory. You should retain the PSF until you are sure you do not need to manually transfer any items from the PSF to your newly installed system.
    5. After moving any items you want to keep from the PSF you should delete it. You can back it up if you prefer, but you must delete it from the hard drive.
    6. You can now download a Combo Updater directly from Apple's download site to update your new system to the desired version as well as install any security or other updates. You can also do this using Software Update.

  • I want to launch multiple instances of JVM

    hi guys,
    When I go to a games room, the applet starts up and then a JVM is launched and it is visible in taskbar. If I click on another game room, the virtual machine launches another applet and the first one is destroyed, but thats no good to me, cos I want to have both applets running at the same time. I can achieve this by running one room from IE and another from Firefox, but is there a way to launch all from IE only, cos if I run both Firefox and IE it starts screwing up with my machine. So basically, I want to be able to run many instances of JVM.
    Thanks.

    That's odd, because one instance of the JVM should be
    able to handle multiple instances even of the same
    applet. Are you opening them in separate windows?no, in the same browser window...what happens is that when you click on a room, the previous window in whivh the applet was running is destrpyed and a new one is created

  • I want to use multiple iPads as external monitors from a PC using the iPad VGA adapter (wired)

    I want to send a VGA signal to a couple of iPads using them as monitors. I currently use a pair of regular 13" VGA 1024x768 lcd monitors looping thru an LCD projector displaying the same signal sent to the projector.
    I want to use the iPad VGA adapter and WIRE them in just like a convention LCD monitor. Yes there are apps like air display and others but they don't allow cloning and have latency issues and must be networked. I need an app to use the VGA adapter and actually wire them in using a VGA signal from my existing VGA distrubution amp.
    The size of the iPad is perfect for my application however I cannot find an app to let me send a signal into the iPad via VGA adapter.
    Any ideas?
    thanks,
    the Sherm

    http://www.shapeservices.com/en/products/details.php?product=idisplay&platform=i phone
    Cool ... takes on all of the complex-ip-aliasing to turn the Mac into the center wi-fi a screen share netork 

  • I want to open multiple jpeg's in ACR from pse 10. Is this possible?

    Just the headline question.

    only one JEPG can be opened in ACR dialog at one point of time
    + http:\\photoshopelementsbyadobe.blogspot.com

  • Run multiple SQL*Loader control files from command prompt

    I have written control files for 15 different tables with specific data files for each table. I have build the control files using toad for each one of them at once. Now I want to run the sql loader for all the tables one time. I know I cannot run multiple files from toad and not sure If I can run from the command prompt.
    Please let me know If I can.

    skvaish1 wrote:
    Hi,
    On unix you can create a script to runn all sqlldr at once like as followes.
    1. Create a script load_sqlldr.sh with following content.
    export ORACLE_SID=<YOUR DB_SID>
    export ORACLE_HOME=<Your Oracle Home>
    export PATH=$ORACLE_HOME/bin:$PATH
    sqlldr (Full command with parameter for 1st table) &
    sqlldr (Full command with parameter for 2nd table) &
    sqlldr (Full command with parameter for 3rd table) &
    sqlldr (Full command with parameter for 4th table) &
    sqlldr (Full command with parameter for 15th table) &
    2. Then execute the script.
    Regards1. Can I also write script load_sqlldr.sh with following content
    sqlldr user/psswd@db_name control=controlfile1.ctl
    sqlldr user/psswd@db_name control=controlfile2.ctl
    sqlldr user/psswd@db_name control=controlfile3.ctl
    sqlldr user/psswd@db_name control=controlfile15.ctl
    2. Then execute the script.

  • Load multiple records in 1 table from 1 line in text file w/sql loader

    hi guys,
    quick question, perhaps someone can help. searched around and didn't see this question asked before, and can't find any answer in SQL Loader faqs or docs.
    i know i can extract multiple logical records from a single physical record in the input file as two logical records, and then use two into tables clauses to load the data into the table. see oracle 9i sql loader control file reference chapter 5 to see what i am talking about.
    but my question follows:
    cust_id amount1_val amount1_qual amount2_val amount2_qual amount3_val amount3_qual
    123 1500.35 TA 230.34 VZ 3045.50 TW
    basically i want to use one sql loader statement to load these 3 records into 1 table. the issue for me is that i need to re-use the cust_id for all 3 records as the key, along with the qualifier code. the example in the Oracle docs only works for data where the logical records are completely separate -- no shared column values.
    i'm sure this is possible, perhaps using some :cust_id type parameter for the 2nd and 3rd records, or something, but i just don't have enough knowledge/experience with sql loader to know what to do. appreciate any help.
    wayne

    Hi wayne,
    I found an example on what exactly you were looking for from an SQL*Loader documentation. Please see if it of some help to you
    EXAMPLE
    The control file is ULCASE5.CTL.
    1234 BAKER 10 9999 101
    1234 JOKER 10 9999 777
    2664 YOUNG 20 2893 425
    5321 OTOOLE 10 9999 321
    2134 FARMER 20 4555 236
    2414 LITTLE 20 5634 236
    6542 LEE 10 4532 102
    2849 EDDS xx 4555
    4532 PERKINS 10 9999 40
    1244 HUNT 11 3452 665
    123 DOOLITTLE 12 9940
    1453 MACDONALD 25 5532
    In the above datafile
    Column1 - Empno
    Column2 - ENAME
    Column3 - Depno.
    Column4 - MGR
    Column5 - Proj no.
    -- Loads EMP records from first 23 characters
    -- Creates and loads PROJ records for each PROJNO listed
    -- for each employee
    LOAD DATA
    INFILE 'ulcase5.dat'
    BADFILE 'ulcase5.bad'
    DISCARDFILE 'ulcase5.dsc'
    1) REPLACE
    2) INTO TABLE emp
    (empno POSITION(1:4) INTEGER EXTERNAL,
    ename POSITION(6:15) CHAR,
    deptno POSITION(17:18) CHAR,
    mgr POSITION(20:23) INTEGER EXTERNAL)
    2) INTO TABLE proj
    (empno POSITION(1:4) INTEGER EXTERNAL,
    3) projno POSITION(25:27) INTEGER EXTERNAL) -- 1st proj
    Notes:
    REPLACE specifies that if there is data in the tables to be loaded (EMP and PROJ), SQL*loader should delete the data before loading new rows.
    Multiple INTO clauses load two tables, EMP and PROJ. The same set of records is processed three times, using different combinations of columns each time to load table PROJ.
    Regards,
    Murali Mohan

Maybe you are looking for

  • Trouble pasting table into Pages.

    I have been unable to copy a table from Numbers and paste it into a Pages document.  The data gets pasted, but not the formatting and it is also not placed in a table.  I am using Pages '09  and Numbers '08.  What appears to happen is teh text or cel

  • How can I exchange my whole data between my mac book pro and my iMac?

    How can I exchange my whole data between my mac book pro and my iMac?

  • Recurring Instances not scheduling on its own after the SP4 installation

    Hi, We have installed the BO XI R2  SP4 2 days ago. Some of the recurring instances are not scheduling on its own. Environment : Clustered - 3 servers with CMS running on 2 servers. We did not do the install live. We disabled/stopped all the services

  • Acrobat 8 Pro. Cannot Scroll/Edit if not Online

    PDF files get stuck if I am not online -(the rainbow goes round and round and round).  I am using an iMac and MacBook Air and I need to be able to edit offline. If I am online all actions are instant. Did I install it incorrectly? is there a box I sh

  • Deploying same WAR file multiple times

    I am attempting to deploy the same WAR file with different parameters [Differnt data sources, etc.] Has anyone deployed the exact same war file multiple times? I know one way to do this is to rename the war file, is there a way other than this withou