Executing Container Login Scripts
Articles and Tips: qna
01 Dec 2001
Q.
I'm issuing a tree command from my server's login script. Any ideas how to have it run container login scripts in the other tree? (I've setup a proof of concept for OnDemand in a disparate tree, but I need it to authenticate and run the login scripts of the production tree.)
Login Script Leslie in Luxembourg
A.
Dear Leslie: Typically only the container script where the first user object exists will run automatically (in addition to user/default and profile scripts). You can use the "include" command (http://www.novell.com/documentation/lg/noclienu/ noclienu/data/h1tb56sc.html#h1tb56sc) to execute the script of another container. Just be sure to issue a tree command prior to the include command in order to set the focus to the correct tree.
Also, you typically don't run the tree command from the login script because the tree-command only authenticates the user who's executing the script to the specified tree. No login script will be executed, nor will there be any variables read from the second tree. Instead, you run LOGINW32.EXE from the login script, as shown in the following example:
@loginw32.exe treename/.robert.novell /tr
This will execute the Login process for a second instance and gives you the advantage that the login script / variables will be executed. The treename is the name of the tree you login against and instead of specifying the name (.robert.novell), you can use all possible login script variables, so the user who logs in does not even have to specify the context.
Last but not least, you specify "/tr" which tells the login process to use this login instance as a tree login, like in the good old days when VLMs where used. In this instance, we get from the CMD the login variables and during the initialization of the login process, we check if the /tr command has been processed. If that is the case, we skip the default_profile and turn over all information from the CMD line.
Another option in this context is the "/cont" parameter, which then avoids the second login to show the GUI.
Hopefully these two suggestions will help you out.
* Originally published in Novell AppNotes
Disclaimer
The origin of this information may be internal or external to Novell. While Novell makes all reasonable efforts to verify this information, Novell does not make explicit or implied claims to its validity.