Tuesday, October 19, 2010

PVSS as service (automated scripts) - part 3

This is part 3 of a tutorial.
(...for the first part of the tutorial, go here)
(...for the second part of the tutorial, go here)
    No UI from the console
    Okay, so you have your project running as a service. While it may be a service, so it will provide some background functionality, it doesn't always mean that you won't need to do some engineering on it. And in order to do some engineering, you will need a UI. And for that, you may get off with connecting from a workstation directly to the server you automated. But some servers will only be seen by other servers, not workstation. So you will need other tools to access the internal data of PVSS. The most often used tool would be (of course) the PARA tool (para being short for parametrization... or para-metering... whichever you fancy more). However, if you are used to starting the para or the gedi tools from the PVSS console, you may notice that it's not possible to start them in the classic way anymore if the PMON is started as a network service. When starting a UI manager, it will run, the console will show it in green (working status), but you won't see any window with the actual UI.

    So what can you do? Well, you could use the command line and call the PVSS00ui.exe, having a look at how the tools are called internally. For instance, this is how you would call the para tool.
PVSS00ui.exe -m para -proj YOUR_PROJECT_NAME
    As a result, you will notice that the PARA is started, because its window should become visible. But it will not be related to the para you may have in your project's configuration. So, no status correlation between the PARA in the PVSS console and the PARA running in the window behind it.

    It would be nice to have a shortcut on the desktop if you are going to use this often. And while you're at it, consider adding a more distinguishable icon for the tool you are providing. Keep in mind that you need to repeat the process for each separate tool and also for each separate project you are using. So if you're going to create shortcuts, make sure you know which shortcut leads to which project.

   Fun with the features
   In the end, here's an idea for having fun, just like you used to in 8th 5th grade, but it only works for server systems, where several users can be logged in at the same time (locally, or remotely). And it only works if you do not install the project as a service. Say your buddy is opening a PVSS console and starts the project. You can log in using a different user account on the same Windows Server machine by Remote Desktop and open your own console. Now, because he opened it first, he has the handle to the PMON that opened all the ports, so any UI you will start, will be opened on his account. Just imagine the fun you can have. As a result, I'm still not sure whether this is a bug or a feature :-)

No comments:

Post a Comment