How to run a graphical application from STAF

  • Grant McCord

    Grant McCord - 2012-10-18

    Hello all,

    I am trying to run a graphical application from STAF but am running into an issue where it won't display anything in the active user session.

    > gnome-mplayer
    opens the gnome player application

    >staf local process start command "gnome-mplayer"  RETURNSTDOUT RETURNSTDERR WAIT
    does not. States it cannot open display.

    Anyone done anything like this and how did you solve it?


  • Grant McCord

    Grant McCord - 2012-10-18

    If i kill STAFProc  - then restart it , the command then works. Seems to have something to do with how STAFProc is started. Looks like it needs to be started from the session which will receive the program command - very close to how Windows works.

  • Sharon Lucas

    Sharon Lucas - 2012-10-18

    Right, it has to do with if you are starting STAFProc as a Windows service.  If so, when configuring this, did you select the logon option 'Local System' and check 'Interact with Desktop' so that commands run via STAF can interact with the desktop?  This is mentioned in section "11. Starting STAFProc during system reboot", sub-section "11.3 Windows" in the STAF Installation Guide at

    When starting STAFProc manually after logging on, this issue won't occur.


Log in to post a comment.