Running administrative script files on WebSphere Application Server
You can run administrative scripts from within the development environment, without having to switch to the non-graphical command interpreter, WebSphere Application Server wsadmin tool. Use the WebSphere® Application Server Administrative Script Launcher to run administrative script files on WebSphere Application Server. To run script files within the development environment you need to specify the location of your script, the runtime environment to interpret your script, and the security settings; if your script is running against a secured server.
Before you begin
- Define an administrative script file with the appropriate file extensions. A Jython script file requires the .py, .PY, .jy, or .JY file extension. A Jacl script file requires the file extension .jacl.
- For running administrative scripts, the workbench
requires a local installation of WebSphere Application
Server, even if you are running the administrative scripts against
a remote server. The reason is because the workbench uses the administrative
scripting run times that are provided in the libraries of the locally
installed server.Restriction: If the local WebSphere Application Server was installed by a root user and you attempt to run the WebSphere Application Server Administrative Script Launcher while you run the workbench with a non-root user ID, you are going to encounter a similar error message in the console view:
The error occurs because the WebSphere Application Server Administrative Script Launcher attempts to write data into the WebSphere Application Server profile, which can be written to only by the root user. The non-root user does not have the correct file permissions for writing into a root profile.!MESSAGE Error reading configuration: /opt/IBM/WAS_install_directory/profiles/unsecure/configuration/org.eclipse.osgi/.manager/.fileTableLock (Permission denied) !STACK 0 java.io.FileNotFoundException: /opt/IBM/WAS_install_directory/profiles/unsecure/configuration/org.eclipse.osgi/.manager/.fileTableLock (Permission denied)
The workaround is to run the WebSphere Application Server Administrative Script Launcher with a non-root profile. You can select a non-root profile by using the Profile name list available in the WebSphere Application Server Administrative Script Launcher. For more information on creating a non-root profile, see the Creating profiles for non-root users topic available in the WebSphere Application Server documentation.
- Start the local or remote server you want to run your administrative script file against.
About this task
Run administrative script files on WebSphere Application Server.