Running program at startup [as ordinary user]

Hi,
I want to be able to run a command at system startup as an ordinary, non-priveledged user. In FreeBSD (where I came from before coming to Arch), there is a @reboot directive in crontab, allowing me to set up command in my crontab file to be run at startup, just as any other cronjob (only at startup instead of at a specific time).
The cron that comes with Arch doesn't seem to support the @reboot directive. Is there another simple mechanisms available for ordnary users?
Svein Halvor
Last edited by sveinhal (2008-12-03 22:31:52)

There's a few things you could do. I run all my startup apps in my xinitrc and the like, so I don't need functionality like this.
Possibility 1: Create a "framework" for this. In /etc/rc.local, add something like:
cd /home
for user in *; do
if [ -x "/home/$user/.rc.local" ]; then
su $user -c "/home/$user/.rc.local"
fi
done
Alternatively do the same thing for rc.shutdown.local
Possibility 2: Use a different cron. I think we have 3 floating around somewhere. If not feel free to package one that works to your liking and stick it in the AUR
Possibility 3: Create an /etc/rc.d/ script that drops privileges to your user and runs all the apps you need
... there's lots more I'm sure ...

Similar Messages

  • Running a Java program at startup in Linux

    Hello
    How do I run a Java program at startup in Linux? I know in Windows I can put a .bat file in C:\Windows\Start Menu\Programs\StartUp\ directory, but in Linux I have no idea how it is done.
    Thank you,
    Mihai

    This is really a Linux question, not Java.
    And then it depends on the version of Linux you are using.
    Maybe this will help, otherwise you should try on a forum for your version of Linux.

  • How to run etherape with ordinary user?

    hi
    when run etherape show this massege:
    No capture device found or insufficient privileges.
    Only file replay will be available.
    EtherApe must be run with administrative privileges (e.g. root) to enable live capture.
    Pcap error: no suitable device found
    i create group etherape with this ownership
    ┌─[root@mymind] - [/etc] - [Sat Feb 04, 12:02]
    └─[$] <> groupadd etherape
    ┌─[root@mymind] - [/etc] - [Sat Feb 04, 12:02]
    └─[$] <> chgrp etherape /usr/bin/etherape
    and add my user to this groups
    ┌─[root@mymind] - [/etc] - [Sat Feb 04, 12:02]
    └─[$] <> usermod -G root,network,http,mysql,dbus,mem,bin,daemon,gdm,audio,video,rfkill,wheel,disk,sys,etherape mostafa
    how to run etherape with ordinary user(without root privilege)?
    Last edited by mostafasedaghat (2012-02-03 20:37:44)

    mostafasedaghat wrote:how to run etherape with ordinary user(without root privilege)?
    You can't. It requires root to set network card attributes, which can only be set with administrative priviledges. But it should be no problem to start it with sudo.

  • Can't Run program in Debug Mode

    To: [email protected]
    cc:
    Subject: Can't Run program in Debug Mode
    Has anyone else experienced this problem? We have written a non-express
    program that uses the Express generated services project as a supplier
    plan. However, when we try running this program in debug mode about 50%
    (or more) of the time we abend while Forte is trying to partition the
    application. Since we have many database classes in our Business Model we
    are wondering if Forte is timing out during the partition phase or if the
    server partition is running out of memory . The following error messages
    are produced by Forte. Any suggestions???
    =======================
    Error messages on client:
    =======================
    SYSTEM ERROR: Unable to start the partition testacadprogoffer_CL0_Part1 on
    any
    of the nodes to which it has been assigned. See the remainder of the
    error
    stack for more information.
    Class: qqsp_ResourceException
    Error #: [1602, 593]
    Detected at: qqcf_StandardConfig::LoadRemotePartition at 5
    Last TOOL statement: method overview.StartApplication
    Error Time: Tue Dec 02 12:56:01
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    SYSTEM ERROR: Unable to start partition testacadprogoffer_CL0_Part1 on node
    admin2.
    Class: qqsp_ErrorDescriptor
    Error #: [1602, 592]
    Detected at: qqcf_StandardConfig::LoadRemotePartition at 3
    Error Time: Tue Dec 02 12:56:01
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    SYSTEM ERROR: Lost contact with remote server while trying to load
    partition
    testacadprogoffer_CL0_Part1. Check server log file for more information
    about
    the specific problem.
    Class: qqsp_ResourceException
    Error #: [1301, 102]
    Detected at: qqem_IPartitionAgent::Startup at 5
    Error Time: Tue Dec 02 12:56:01
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    INFORMATION: The connection to the partner was terminated by the
    Communication
    Manager for the reasons below.
    Class: qqsp_DistAccessException
    Detected at: qqdo_PartitionMgr::StopLocation at 1
    Error Time: Tue Dec 02 12:56:00
    Distributed method called: qqrt_ForteExecAgentProxy.LoadPartition!6
    (object name Unnamed) from partition "Forte_Executor", (partitionId =
    F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9, taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9.229]) in application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment CentralEnv
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    INFORMATION: Network partner closed connection. This usually means the
    process at the other end of the wire failed. Please go look there and
    find
    out why.
    Class: qqsp_DistAccessException
    Detected at: qqcm_HoseFSM::ReceivedClose at 2
    Error Time: Tue Dec 02 12:56:00
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    INFORMATION: Received close: Connection aborted (10053).
    Class: qqsp_DistAccessException
    Detected at: qqcm_HoseFSM::ReceivedClose at 1
    Error Time: Tue Dec 02 12:56:00
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    =======================
    Log messages on server:
    =======================
    Attached to manager for node admin2.
    aud Tue Dec 2 09:34:36 : Loading partition testacadprogoffer_cl0_Part2
    built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 09:41:58 : Shutting down partition as requested.
    aud Tue Dec 2 09:41:59 : Unloaded partition testacadprogoffer_cl0_Part2.
    aud Tue Dec 2 09:49:44 : Loading partition testacadprogoffer_cl0_Part2
    built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 10:00:11 : Shutting down partition as requested.
    aud Tue Dec 2 10:00:12 : Unloaded partition testacadprogoffer_cl0_Part2.
    aud Tue Dec 2 10:18:34 : Loading partition testacadprogoffer_cl0_Part3
    built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 10:27:00 : Shutting down partition as requested.
    aud Tue Dec 2 10:27:00 : Unloaded partition testacadprogoffer_cl0_Part3.
    aud Tue Dec 2 10:47:03 : Loading partition
    EvaluateApplRequirementsBO_CL0_Part1 built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 11:09:26 : Shutting down partition due to failure of agent
    owner's partition.
    aud Tue Dec 2 11:09:26 : Shutting down partition as requested.
    aud Tue Dec 2 11:09:26 : Unloaded partition
    EvaluateApplRequirementsBO_CL0_Part1.
    aud Tue Dec 2 12:36:14 : Loading partition testacadprogoffer_CL0_Part1
    built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 12:45:17 : Shutting down partition as requested.
    aud Tue Dec 2 12:45:17 : Unloaded partition testacadprogoffer_CL0_Part1.
    FATAL ERROR: Out of Memory (reason = qqOS_MM_EX_OUT_OF_MEMORY)
    FATAL ERROR: Out of Memory (reason = qqOS_MM_EX_OUT_OF_MEMORY)
    Task 11: qqcm_HoseRecvServiceTask::Run: Caught unexpected exception
    FATAL ERROR: ************* Out of Memory, requested (1K) available (0K)
    Class: qqsp_ResourceException with ReasonCode: SP_ER_OUTOFMEMORY
    Detected at: qqos_MemoryManager
    Error Time: Tue Dec 2 12:49:01
    Exception occurred (locally) on partition "Forte_Executor",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10f3, t
    askId = [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10f3.11]) in application
    "Forte Runtime", pid 14020 on node admin2 in environ
    ment CentralEnv.
    FATAL ERROR: ************* Out of Memory, requested (1K) available (0K)
    Class: qqsp_ResourceException with ReasonCode: SP_ER_OUTOFMEMORY
    Detected at: qqos_MemoryManager
    Error Time: Tue Dec 2 12:48:57
    FATAL ERROR: Out of Memory (reason = qqOS_MM_EX_OUT_OF_MEMORY)
    FATAL ERROR: Out of Memory (reason = qqOS_MM_EX_OUT_OF_MEMORY)
    ERROR: TMgr.RunThread: task cm.Recv failed terminating.
    Probably caused by a FATAL exception.
    David Wilbur email: [email protected]
    University of Windsor phone: 519-253-3000 ext. 2779
    Windsor, Ontario Canada
    -----------------------------------------------

    Hi,
    We have had the same problem in a non-express application
    with a heavy server partition. In our case, the error was not
    systematic, depending on the server workload at the time we
    tried to partition and run.
    The work-around we're using is to put the -fm flags (increasing the x
    parameter to say 30000) in the 'server arguments' of your server
    partition
    properties in the partition workshop. Note that if your server is a Unix
    platform,
    you need to put double-quotes before and after the parenthesis in the -fm
    syntax.
    Hope this helps,
    Vincent Figari
    BTW, what Forte version are you using ?
    On Tue, 2 Dec 1997 13:44:24 -0500 "David Wilbur"<[email protected]>
    writes:
    >
    >
    >
    >
    >
    To: [email protected]
    cc:
    Subject: Can't Run program in Debug Mode
    Has anyone else experienced this problem? We have written a
    non-express
    program that uses the Express generated services project as a supplier
    plan. However, when we try running this program in debug mode about
    50%
    (or more) of the time we abend while Forte is trying to partition the
    application. Since we have many database classes in our Business
    Model we
    are wondering if Forte is timing out during the partition phase or if
    the
    server partition is running out of memory . The following error
    messages
    are produced by Forte. Any suggestions???
    =======================
    Error messages on client:
    =======================
    SYSTEM ERROR: Unable to start the partition
    testacadprogoffer_CL0_Part1 on
    any
    of the nodes to which it has been assigned. See the remainder of
    the
    error
    stack for more information.
    Class: qqsp_ResourceException
    Error #: [1602, 593]
    Detected at: qqcf_StandardConfig::LoadRemotePartition at 5
    Last TOOL statement: method overview.StartApplication
    Error Time: Tue Dec 02 12:56:01
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in
    application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    SYSTEM ERROR: Unable to start partition testacadprogoffer_CL0_Part1 on
    node
    admin2.
    Class: qqsp_ErrorDescriptor
    Error #: [1602, 592]
    Detected at: qqcf_StandardConfig::LoadRemotePartition at 3
    Error Time: Tue Dec 02 12:56:01
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in
    application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    SYSTEM ERROR: Lost contact with remote server while trying to load
    partition
    testacadprogoffer_CL0_Part1. Check server log file for more
    information
    about
    the specific problem.
    Class: qqsp_ResourceException
    Error #: [1301, 102]
    Detected at: qqem_IPartitionAgent::Startup at 5
    Error Time: Tue Dec 02 12:56:01
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in
    application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    INFORMATION: The connection to the partner was terminated by the
    Communication
    Manager for the reasons below.
    Class: qqsp_DistAccessException
    Detected at: qqdo_PartitionMgr::StopLocation at 1
    Error Time: Tue Dec 02 12:56:00
    Distributed method called:
    qqrt_ForteExecAgentProxy.LoadPartition!6
    (object name Unnamed) from partition "Forte_Executor",
    (partitionId =
    F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9, taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9.229]) in
    application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in
    application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    INFORMATION: Network partner closed connection. This usually means
    the
    process at the other end of the wire failed. Please go look there
    and
    find
    out why.
    Class: qqsp_DistAccessException
    Detected at: qqcm_HoseFSM::ReceivedClose at 2
    Error Time: Tue Dec 02 12:56:00
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in
    application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    INFORMATION: Received close: Connection aborted (10053).
    Class: qqsp_DistAccessException
    Detected at: qqcm_HoseFSM::ReceivedClose at 1
    Error Time: Tue Dec 02 12:56:00
    Exception occurred (locally) on partition "Express_cl7_Client",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3,
    taskId =
    [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10e9:0x3.226]) in
    application
    "FTLaunch_cl0", pid 65 on node DWILBUR_NTWS in environment
    CentralEnv.
    =======================
    Log messages on server:
    =======================
    Attached to manager for node admin2.
    aud Tue Dec 2 09:34:36 : Loading partition
    testacadprogoffer_cl0_Part2
    built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 09:41:58 : Shutting down partition as requested.
    aud Tue Dec 2 09:41:59 : Unloaded partition
    testacadprogoffer_cl0_Part2.
    aud Tue Dec 2 09:49:44 : Loading partition
    testacadprogoffer_cl0_Part2
    built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 10:00:11 : Shutting down partition as requested.
    aud Tue Dec 2 10:00:12 : Unloaded partition
    testacadprogoffer_cl0_Part2.
    aud Tue Dec 2 10:18:34 : Loading partition
    testacadprogoffer_cl0_Part3
    built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 10:27:00 : Shutting down partition as requested.
    aud Tue Dec 2 10:27:00 : Unloaded partition
    testacadprogoffer_cl0_Part3.
    aud Tue Dec 2 10:47:03 : Loading partition
    EvaluateApplRequirementsBO_CL0_Part1 built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 11:09:26 : Shutting down partition due to failure of
    agent
    owner's partition.
    aud Tue Dec 2 11:09:26 : Shutting down partition as requested.
    aud Tue Dec 2 11:09:26 : Unloaded partition
    EvaluateApplRequirementsBO_CL0_Part1.
    aud Tue Dec 2 12:36:14 : Loading partition
    testacadprogoffer_CL0_Part1
    built on <unknown>.
    Attached to manager for node admin2.
    aud Tue Dec 2 12:45:17 : Shutting down partition as requested.
    aud Tue Dec 2 12:45:17 : Unloaded partition
    testacadprogoffer_CL0_Part1.
    FATAL ERROR: Out of Memory (reason = qqOS_MM_EX_OUT_OF_MEMORY)
    FATAL ERROR: Out of Memory (reason = qqOS_MM_EX_OUT_OF_MEMORY)
    Task 11: qqcm_HoseRecvServiceTask::Run: Caught unexpected exception
    FATAL ERROR: ************* Out of Memory, requested (1K) available
    (0K)
    Class: qqsp_ResourceException with ReasonCode: SP_ER_OUTOFMEMORY
    Detected at: qqos_MemoryManager
    Error Time: Tue Dec 2 12:49:01
    Exception occurred (locally) on partition "Forte_Executor",
    (partitionId = F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10f3, t
    askId = [F88CCF80-FA5D-11D0-A2F1-DA164885AA77:0x10f3.11]) in
    application
    "Forte Runtime", pid 14020 on node admin2 in environ
    ment CentralEnv.
    FATAL ERROR: ************* Out of Memory, requested (1K) available
    (0K)
    Class: qqsp_ResourceException with ReasonCode:
    SP_ER_OUTOFMEMORY
    Detected at: qqos_MemoryManager
    Error Time: Tue Dec 2 12:48:57
    FATAL ERROR: Out of Memory (reason = qqOS_MM_EX_OUT_OF_MEMORY)
    FATAL ERROR: Out of Memory (reason = qqOS_MM_EX_OUT_OF_MEMORY)
    ERROR: TMgr.RunThread: task cm.Recv failed terminating.
    Probably caused by a FATAL exception.
    David Wilbur email: [email protected]
    University of Windsor phone: 519-253-3000 ext. 2779
    Windsor, Ontario Canada

  • Oracle client 9i doesn't work for windows ordinary user

    Hello All,
    I've installed oracle 9i client on windows xp. Client software works for user belonging to windows administrators group. it doesn't works for ordinary users not belonging to administrators group. Particularly when i run sqlplus from command line i get following error :
    Incorrect environment variable PLUS_DFLT
    Program execution error.
    i also need access to Oracle ODBC driver.
    When i try to configure ODBC source (created by user with administrator privileges) by common user i get following errors :
    The setup routines for Oracle for Oracle in OraHome9i ODBC driver couldn't be loaded due to system error code 5
    Could not load the setup or translator library
    Very appreciate for any help.
    Regards Arkadiusz Masny

    It sounds like the users on the machine do not have access to the Oracle home directory. Check the permissions of the folder by right properties, select the user and check that they have read and then select advanced. Tick the "replace permission entries....." box and apply. This will re apply all user rights in all folders and subfolders. Try again.
    HTH Mark F

  • Launch and hide invisible program at startup

    Hi,
    I have been looking round various forums but cant find an answer. Hopefully someone can help.
    Problem:
    We have 20 computers that all need to run a program at login (Its a 3d render client). We need the program not to appear in the dock so I have edited the .plist file in the package contents thus making the program run without a dock or taskbar. However, the actual program window remains, allowing users to close the program.
    What I need:
    To open the program on startup, be invisible and hide itself.
    I have tried a few scripts that launch it on startup. This works, but the next line doenst work to hide the program. I believe this is because the program is invisible (making it a background task) the finder command to hide or minimise has no effect.
    I have also tried the simple procedure of adding it to startup items and checking "hide".
    Any help would be most appreciated.

    Its a client piece of software that allows 3d images from maxons cinema 4d to be rendered across a network. Under normal circumstances there would be no need to have this program running in the background or for it to be invisible to the dock. However. As everyone logs on in the morning this software starts on their machine. Their first instinct is to close it, which means that if I was to submit a job to the network it would not distribute it to the machines whose window has been closed. I want the software to start but be hidden so it cant be closed.
    The only window that opens is a type of status/console window. So it would say what jobs are currently rendering or which have finished etc.

  • Need help in using [RUN PROGRAM] Activity against a server in another domain

    Hi Experts,
    We have two domains with two way trust enabled. Orch server exists in DomainA and target server exists in DomainB.
    We are trying to execute some scripts(g:IPCONFIG) from orch server to target server using RUN PROGRAM activity. This is  running fine and give expected results, if I give Built-in Administrator credentials in Security Tab. But I'm getting some
    strange values like chinese/japanese language strings, If I use a DomainB/DomainA user (Part of local admin of the target server) in security tab as well as Advanced tab-->Runas.
    Things I tried:
    - DomainA/DomainB user in Security Tab as well as RunAs tab  ---> Strange Strings
    - DomainA/DomainB user in Security Tab and BuiltIn Administrator in RunAs tab  ---> Strange Strings
    - BuiltIn Administrator in Security Tab ---> Expected result
    - BuiltIn Administrator in Security Tab and DomainA/DomainB user in RunAs tab  --> ProgramExitCode = -10xxxxxx
    But our requirement is to run the script on the target server as Domain User(Part of local admin).
    Thanks in Advance
    Thanks and Regards, Narayana Babu

    Hi Experts,
    We have two domains with two way trust enabled. Orch server exists in DomainA and target server exists in DomainB.
    We are trying to execute some scripts(g:IPCONFIG) from orch server to target server using RUN PROGRAM activity. This is  running fine and give expected results, if I give Built-in Administrator credentials in Security Tab. But I'm getting some
    strange values like chinese/japanese language strings, If I use a DomainB/DomainA user (Part of local admin of the target server) in security tab as well as Advanced tab-->Runas.
    Things I tried:
    - DomainA/DomainB user in Security Tab as well as RunAs tab  ---> Strange Strings
    - DomainA/DomainB user in Security Tab and BuiltIn Administrator in RunAs tab  ---> Strange Strings
    - BuiltIn Administrator in Security Tab ---> Expected result
    - BuiltIn Administrator in Security Tab and DomainA/DomainB user in RunAs tab  --> ProgramExitCode = -10xxxxxx
    But our requirement is to run the script on the target server as Domain User(Part of local admin).
    Thanks in Advance
    Thanks and Regards, Narayana Babu

  • Does win8/8.1/10 kill long-running programs automatically as stated in specs? reasons why?

    does win8/8.1/10 kill/end-task long-running programs automatically as stated in specs? how specifically does it detect a locked-up process?
    has this been put into windows 7 at any time to make it similar to windows 8?
    Please supply accurate answers. thank you.
    My understanding the reason for this change was to handle locked-up programs.
    I do have a number of long-running processes. some examples of mine and scenarios for other users:
    simulations on a Workstation or HPC Server
    doing a directory tree walk on a hard disk with >=1TB of data
    reference articles I have found on the subject:
    windows 7
    http://windows.microsoft.com/en-us/windows/exit-program-not-responding#1TC=windows-7
    windows 8
    From some of what I understand, you can also get the "Program Not Responding" or similarly titled dialog box when:
    bug in the source code of the program in question. for instance, while(1){} such as forever loops (win7)
    similar program bug when declaring a function one way but defining it a different way and then calling it (mismatch in function signature) (win7)
    similar to above with DLLs in using MSVCRT*.DLL or other
    (?) can't remember for sure on this, but I think some badly formed calls or it was invalid values or data type mismatch to Win32 API can do this from buggy code. (win7)
    for (x=0; x < 16777216; x++) {your code here...} in other words, large values for loop termination (win7)
    this is a repost of http://answers.microsoft.com/en-us/windows/forum/windows_8-performance/does-win88110-kill-long-running-programs/d35c3c9e-c6f4-4bbf-846a-2041bf2167a0?tm=1427518759476
    here due to a request to do so.

    does win8/8.1/10 kill/end-task long-running programs automatically as stated in specs? how specifically does it detect a locked-up process?
    has this been put into windows 7 at any time to make it similar to windows 8?
    Please supply accurate answers. thank you.
    My understanding the reason for this change was to handle locked-up programs.
    Hi Jim,
    First, I have to admit that I'm not fully understanding the question, If a program is not responding, it means the program is interacting more slowly than usual with Windows, typically could be a confliction of software or hardware resources between
    two programs, lack of system resources, or a bug in the software or drivers. In that case, we can choose to wait or end the program. This design is similiar in Windows 7, Windows 8 and other OS.
    For deeper analysis, system determines whether the system considers that a specified application is not responding using a "IsHungAppWindow function",
    https://msdn.microsoft.com/en-us/library/ms633526.aspx
    And this link also give some explanation: Preventing Hangs in Windows Applicationshttps://msdn.microsoft.com/en-us/library/windows/desktop/dd744765%28v=vs.85%29.aspx?f=255&MSPPError=-2147217396
    While I'm not a developer, to better understand this, I recommend you contact members in the MSDN Forum:
    https://social.msdn.microsoft.com/Forums/en-US/home
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact [email protected]

  • Cannot write the suitable source codes for running program

    I want to write a program that help student to compile program and run program by using some test cases. For the compiled part, i have been wrote it successfully, but for the run part, i cannot pass the test cases to the program for running. Could any ppl help me to find the problem on the followng codes, why the error will on there? how do i change it? Thanks!
    //<!--start get Program Test Case File-->
    java.io.BufferedReader TestCaseBuf = null;
    Connection con = null;
    Statement stmt = null;
    ResultSet rs = null;
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    con = DriverManager.getConnection("jdbc:odbc:compas", "sa", "password");
    stmt = con.createStatement();
    String strSQL = "SELECT testValue FROM TEST_CASE WHERE progID='"+progID+"'";
    stmt = con.createStatement();
    rs = stmt.executeQuery(strSQL);
    try
    while (rs.next())
    TestCaseBuf = new java.io.BufferedReader(new java.io.InputStreamReader(rs.getBinaryStream("testValue")));                         
    finally
    if (rs != null)
         rs.close();
    if (stmt != null)
         stmt.close();
    //<!--end get Program Test Case File-->
    //<!--start run program -->
    String[ ] args2 = new String[ ]
         "java", "-cp", System.getProperty("user.dir"), FileName
    try
         Runtime rt = Runtime.getRuntime();
         Process proc = rt.exec(args2);
         java.io.BufferedReader ireader = new java.io.BufferedReader(new java.io.InputStreamReader(proc.getInputStream()));
         java.io.PrintWriter pwriter = new java.io.PrintWriter(proc.getOutputStream());
    String atestcase = null;
         String line= null;
         try
    while ((atestcase = TestCaseBuf.readLine()) != null) <------------I found that error seems on here!!!!
         pwriter.write(atestcase+"\r");
    pwriter.flush();     
    if (atestcase != null)
              if ((line = ireader.readLine()) != null)
              FileOutput = FileOutput + line +"\r\n";
    else {break; }
         } //while
         catch (java.io.IOException e)
         out.println("[IOException]. Printing Stack Trace");
         e.printStackTrace();
         pwriter.close();
         ireader.close();
    catch (java.io.IOException e)
    out.println("[IOException]. Printing Stack Trace");
    e.printStackTrace();
    //<!--end run program -->

    Whats the error message??
    Just a guess, but could be (without seeing the error) that you've already closed the TestCaseBuf reader by closing the result set, hence when you go to read it, you're reading on closed reader.
    Give this a go...Put the //<!--run program --> code into the result set while loop
    while (rs.next())
    TestCaseBuf = new java.io.BufferedReader(new java.io.InputStreamReader(rs.getBinaryStream("testValue")));
    //<!--start run program -->
    ...some code
    //<!--end run program -->
    } Hard to tell without the error message

  • Trying to run program off network location using GPO with Power shell script.

    Hello All,
    Not much of a script writer. I am giving it a shot.  My issue is that I need to run a application update across our network and I am trying to do it with as little hands on as possible. So I was planning to push a GPO with a power shell script in it
    to run the program with elevated privileges. 
    Little background:
    We are running on a domain and end users do not have admin rights.
    The application is stored on a share on our network that is open to all domain users.
    The installer user name and password is a temp one and will only be valid for the 30 min window when everyone logs in at the beginning of the day.
    So this is what I have so far.
    $username = "USER"
    $password = "PASSWORD"
    $credentials = New-Object System.Management.Automation.PSCredential -ArgumentList @($username,(ConvertTo-SecureString -String $password -AsPlainText -Force))
    Start-Process PSQLv11Patch_Client_x86.msp -Credential ($credentials) -WorkingDirectory \\Server\Folder\Folder1\Folder2\filder3\PSQLv11sp3_x32\
    But for some reason I keep getting :
    Start-Process : This command cannot be run due to the error: The system cannot find the file specified.
    At line:10 char:1
    + Start-Process PSQLv11Patch_Client_x86.msp -Credential ($credentials) -WorkingDir ...
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        + CategoryInfo          : InvalidOperation: (:) [Start-Process], InvalidOperationException
        + FullyQualifiedErrorId : InvalidOperationException,Microsoft.PowerShell.Commands.StartProcessCommand
    Any help you could give would be great.
    Thanks,
    jdfmonkey

    Hi jdfmonkey,
    Has anyone provided an answer to your original question?  I am trying to use Start-Process to launch a process using another logged in user's credentials, and am not able to get it working:
    $cred=Get-Credential
    start-process Process.exe-WorkingDirectoryC:\Scripts-Credential$cred
    I get the same error that you mentioned:
    start-process : This command cannot be run due to the error: The system cannot find the file specified.
    At C:\Scripts\Process.ps1:2 char:1
    + start-process Process.exe -WorkingDirectory C:\Scripts -Credential ...
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        + CategoryInfo          : InvalidOperation: (:) [Start-Process], InvalidOperationException
        + FullyQualifiedErrorId : InvalidOperationException,Microsoft.PowerShell.Commands.StartProcessCommand
    When I leave off the credentials:
    start-processProcess.exe-WorkingDirectoryC:\Scripts
    It works correctly.  Does anyone have a solution to make this work correctly?
    Please ask your own question.  You issue is nothing like the current thread.  You clearly are using a user account that has no access to the folder.  It is a permissions issue.  It is not a scripting issue.
    If you need further help please start your own question.
    ¯\_(ツ)_/¯

  • Can FTP-access to field point log file interrupt the running program?

    Can FTP-access to field point log file interrupt the running program?
    We have a problem where our factory process control program on a Field Pointer suddenly stops the process. We are running the development system on a PC, wich deploys the program on the Field point, with user interface on the PC. Quite often the process stops for no apparent reason. I'm not sure right now if the control program on the Field Point is still running or if it stops. We use FTP from a distant PC (over VPN) directly to the Field Point to check if the process is running, by looking for date and size of log files produced during running process. I've never opened och copied any log file during process run, because this I'm sure this would cause problems for new log entries to be written. But can the mere looking at the log folder via XP-pros ftp-functionality cause the Field Point to have problems writing data to a log file?
    I'm not sure how windows XP pro handles "my network places" when it comes to FTP, it look that it keeps some kind of local copy of the folders, or at least the files opened.
    Next version of the program will have only basic functionality on the Field Point, leaving logging etc. to another program on the PC, but right now we are stuck with this system.
    Ola A

    It turned out that the problem lies in the harware of the production machine, it was not a labiew-program problem at all!
    Ola

  • Running program in the background

    Hi everybody!
    I need to run  program in the background.
    So I need only to change the sy-batch status to 'X'?

    HI,
    if your program is runninn in the Background then the System field SY-BATCH will become 'X' otherwise it will have space ......
    it will not execute the job in the background if you put SY-BATCH = 'X'
    you need to use: Job_open , Job_submit and job_close function modules
    example:
    *Submit report as job(i.e. in background) 
    data: jobname like tbtcjob-jobname value
                                 ' TRANSFER TRANSLATION'.
    data: jobcount like tbtcjob-jobcount,
          host like msxxlist-host.
    data: begin of starttime.
            include structure tbtcstrt.
    data: end of starttime.
    data: starttimeimmediate like btch0000-char1.
    Job open
      call function 'JOB_OPEN'
           exporting
                delanfrep        = ' '
                jobgroup         = ' '
                jobname          = jobname
                sdlstrtdt        = sy-datum
                sdlstrttm        = sy-uzeit
           importing
                jobcount         = jobcount
           exceptions
                cant_create_job  = 01
                invalid_job_data = 02
                jobname_missing  = 03.
      if sy-subrc ne 0.
                                           "error processing
      endif.
    Insert process into job
    SUBMIT zreport and return
                    with p_param1 = 'value'
                    with p_param2 = 'value'
                    user sy-uname
                    via job jobname
                    number jobcount.
      if sy-subrc > 0.
                                           "error processing
      endif.
    Close job
      starttime-sdlstrtdt = sy-datum + 1.
      starttime-sdlstrttm = '220000'.
      call function 'JOB_CLOSE'
           exporting
                event_id             = starttime-eventid
                event_param          = starttime-eventparm
                event_periodic       = starttime-periodic
                jobcount             = jobcount
                jobname              = jobname
                laststrtdt           = starttime-laststrtdt
                laststrttm           = starttime-laststrttm
                prddays              = 1
                prdhours             = 0
                prdmins              = 0
                prdmonths            = 0
                prdweeks             = 0
                sdlstrtdt            = starttime-sdlstrtdt
                sdlstrttm            = starttime-sdlstrttm
                strtimmed            = starttimeimmediate
                targetsystem         = host
           exceptions
                cant_start_immediate = 01
                invalid_startdate    = 02
                jobname_missing      = 03
                job_close_failed     = 04
                job_nosteps          = 05
                job_notex            = 06
                lock_failed          = 07
                others               = 99.
      if sy-subrc eq 0.
                                           "error processing
      endif.
    Thanks
    Sudheer

  • Ios 7.0.2 issue: how to stop running programs

    I am a new iPhone5 user and just installed ios 7.0.2 (maybe I should not have but I did). Now I don't know how to stop running programs. Previously
    I double-clicked the Home button, then saw the icons that represented running programs, then could lightly touch one of them which led to all of them
    showing a X for a potential delete. That does not work now so how do I do it?

    Double click the home button and then swipe up on the app screenshots.

  • Run Program activity not exiting

    I'm running SCOrch 2012 R2 and am having trouble with a runbook hanging. Here are the facts
    My runbook executes a script (the code for which, I have included below) that gets a list of AD users and exports that list to a .csv file. 
    When run manually, from a Powershell window, the script executes and returns the expected file, before returning to the prompt.
    When run through the SCOrch, the script runs fine, with the output file created and the Powershell process exiting.
    The commands I'm using to execute the script manually and through the runbook, are the same (see below) and the run-as accounts are the same.
    The runbook never gets past the step that runs the Powershell script.
    The activity looks like this: 
    Command execution
    Command: cmd.exe /c | C:\Windows\system32\WindowsPowerShell\v1.0\powershell.exe –c "C:\it\getADUserProperties-Parameterized.ps1 -SearchPath 'ou=customer,dc=domain,dc=tld' -DomainName domain.tld | Export-Csv C:\it\userList.csv -NoTypeInformation"
    Run as account credentials specified
    The rest of the options are set to the default values
    The question is, why doesn't the Run Program activity close when powershell.exe exits? I know it won't matter, but here is the script anyway:
    <#
    .Synopsis
    Get Active Directory user list with a user-specified set of properties
    .DESCRIPTION
    Get a list of Active Directory users from a user-specified list of containers (or the root of the domain) and return a user-specified set of attributes.
    This script can connect to non-native domains (domains that the executing computer is not a member of) if DNS is configured properly. If accessing a
    non-native domain, the script will prompt for credentials.
    .NOTES
    Author: Mike Hashemi
    V1 date: 15 August 14
    .LINK
    .PARAMETER DomainName
    Defines which DNS domain to connect to.
    .PARAMETER SearchPath
    Default value = cn=users,dc=domain,dc=tld. This parameter represents the AD to search and can contain multiple values.
    .PARAMETER OutputProperties
    Default value = Name,Enabled. This parameter represents a comma-spearated list of AD attributes to return.
    .EXAMPLE
    .\getADUserProperties-Parameterized.ps1 -DomainName domain.tld
    This example will output the name and enabled status of all users in "cn=users,DC=domain,DC=tld" and below.
    .EXAMPLE
    .\getADUserProperties-Parameterized.ps1 -OutputProperties name,telephoneNumber | Export-Csv C:\userList.csv -NoTypeInformation
    This example will output the name and telephone number of all users in "cn=users,DC=domain,DC=tld" and below. Output will be sent to c:\userList.csv.
    #>
    [CmdletBinding()]
    param(
    [Parameter(Mandatory=$True)]
    [string]$DomainName,
    [string[]]$SearchPath = 'cn=users,DC=domain,DC=tld',
    [string]$OutputProperties = 'Name,Enabled'
    Import-Module ActiveDirectory
    If ((Get-Module ActiveDirectory -ErrorAction SilentlyContinue) –eq $null) {
    Write-Error "This script requires the Powershell Module: 'ActiveDirectory'. Please make sure you've got the correct tools installed."
    Exit
    Else {
    Foreach ($ou in $SearchPath) {
    Try {
    Write-Verbose ("Getting users from {0}." -f $ou)
    Get-ADUser -Filter * -SearchBase $ou -Properties $OutputProperties.Split(",") -Server $DomainName | Select $OutputProperties.Split(",")
    Catch [System.Security.Authentication.AuthenticationException] {
    Write-Output ("Connection failed. Prompting for credentials to {0}" -f $DomainName)
    $cred = Get-Credential -Message "Enter credentials for $DomainName."
    Write-Verbose ("Getting users from {0}. with user: {1}" -f $ou, $cred.Username)
    Get-ADUser -Filter * -SearchBase $ou -Properties $OutputProperties.Split(",") -Server $DomainName -Credential $cred | Select $OutputProperties.Split(",")
    Thanks.

    mhashemi,
    I had a simliar issue as you did where my runbook would run until it got to the "Run .Net Script" Activity and then the Runbook would just stop. What I found was you can not have the command "Exit" in your script. The command "Exit"
    will force the Activity to close and will not output any variables.
    I am not the only one to find this issue.
    Check out the article labeled
    "Run .Net Script (powershell), "exit" and published data" on technet under
    System Center Orchestrator > System Center Orchestrator - General
    (not able to post the link, I am restricted)
    Doesn't sound like there is going to be a fix anytime soon
    Hope this helps
    -Ozarkclay

  • Run Program in background

    Hi
    I know there is a post about this already in the newsgroup but I think I
    need something different.
    I need a way to make my program completely invisible to my users basically
    have it running as a service. I can't for some reason remove the FP in the
    app builder of my toplevel vi, I don't know why. And anyway, would removing
    the FP in the app builder also remove the vi in the taskbar? Does anyone
    know how to do this?
    Thanks
    Jacob Thastrup

    The program is for a Win2K/NT4 enviroment. I have never herd of a Win2K/NT4
    command/program called "Xvfb". Do I need to use a different command or can
    I send the display to another place?
    Thanks
    Jacob Thastrup
    [email protected] (Ricardo Leal) wrote in
    <[email protected]>:
    >Content-Type: text/plain; charset=us-ascii
    >Content-Transfer-Encoding: 7bit
    >
    >Jacob Thastrup wrote:
    >
    >> Hi
    >>
    >> I know there is a post about this already in the newsgroup but I think
    >> I need something different.
    >> I need a way to make my program completely invisible to my users
    >> basically have it running as a service. I can't for some reason remove
    >> the FP in the app builder of my toplevel vi, I don't know why. And
    >> anyway, would removing the FP in the app builder also remove the vi in
    >> the taskbar? Does anyone know how to do this?
    >>
    >> Thanks
    >>
    >> Jacob Thastrup
    >
    >Jacob:
    >
    >I tryied to hide the front panel with labview application builder for
    >linux but it doesn't remove the front panel. I got this
    >in Linux, you must create a virtual frame buffer first and then send the
    >graphical out of labview to this virtual x-window.
    >
    >For create the virtual frame, execute the following command:
    >
    >Xvfb :1 -screen 0 160x120x16 &
    >
    >with this you create a virtual frame buffer of 160x120 and 16 bits, then
    >you must send the application to this x-window:
    >
    >Application -display :1 &
    >
    >With this you can execute a program whithout graphical out and also you
    >can mantain in background with nohup command.
    >
    >
    >
    >--
    >*********************************************************
    >Ricardo Leal Pacheco.
    >e-mail: [email protected]/[email protected]
    >FONO: (09)7111100, 654622.
    >INGENIERIA CIVIL ELECTRONICA U.T.F.S.M
    >*********************************************************
    >
    >
    >
    >--------------25B9B630C9B3D0B8D29F4A83
    >Content-Type: text/html; charset=us-ascii
    >Content-Transfer-Encoding: 7bit
    >
    >
    >
    >Jacob Thastrup wrote:
    >Hi
    >I know there is a post about this already in the newsgroup but I
    >
    >I
    >
    need something different.
    >
    I need a way to make my program completely invisible to my users
    >have it running as a service. I can't for some reason
    >
    >in the
    >
    app builder of my toplevel vi, I don't know why. And anyway, would
    >removing
    >
    the FP in the app builder also remove the vi in the taskbar? Does
    >know how to do this?
    >
    Thanks
    >
    Jacob Thastrup
    >Jacob:
    >I tryied to hide the front panel with labview application builder for
    >linux but it doesn't remove the front panel. I got this
    >
    in Linux, you must create a virtual frame buffer first and then send
    >the graphical out of labview to this virtual x-window.
    >
    For create the  virtual frame, execute the following command:
    >
    Xvfb :1 -screen 0 160x120x16  &
    >
    with this you create a virtual frame buffer of 160x120 and 16 bits,
    >then you must send the application to this x-window:
    >
    Application -display :1  &
    >
    With this you can execute a program whithout graphical out and also
    >you can mantain in background with nohup command.
    >
    >
    >
    >*********************************************************
    >Ricardo Leal Pacheco.
    >e-mail: [email protected]/[email protected]
    >FONO: (09)7111100, 654622.
    >INGENIERIA CIVIL ELECTRONICA U.T.F.S.M
    >*********************************************************

    >
    >--------------25B9B630C9B3D0B8D29F4A83--

Maybe you are looking for

  • Zen Vision:M 30GB recognition problems...Big t

    Hi, 2 days ago i ran into a problem with my Zen. I had to charge it, as the battery was low and had to put some new music on it.. I plugged it into the USB port on my Laptop, where all of it's software is installed. The Zen wasn't recognized. Instead

  • Windows 8.1 Boot Issues

    I have Windows 8.1 Pro with all automatic updates successfully installed, running on: Sabertooth Z77 motherboard GEForce GTX 770 video Intel i7-3770K LGA1155 Xonar DSX PCIE 7.1 audio card Corsair TX850 power 16GB of Corsair Vengeance DDR3 DRAM More t

  • The 'Edit folder' link doesn't appear in content area portlet (URGENT)

    Hi! I made three content areas, and published them as portlets in a page. However, when I enter the page as an authorized user, I don't see the 'Edit folder' link on any content area portlet. But if I enter to any of the content area pages with the s

  • Capture Proof Of Delivery

    Hi, We have a requirement to send notification mails to requester upon arrival and upon delivery of the items for the PO raised. We need to capture the POD post delivery of the items. In the current system they are maintaining them manually. We have

  • WP_PLU vs. WBBDLD

    Hi experts. I have a trouble, I am implementing a Best Practice Retail. At integration of POS and POSDM, in the XI module, the best practice suggest IDOC WBBDLD Assortment List, to update articles changes. I have a lot experience using IDOC WP_PLU fo