Linux Control Panel (LCoP) Document
1. Introduction
This document give you some useful configuration and using about LCoP. LCoP is the Control Panel based on Web in Booyo Linux. But it supports the feature to operate CIM/WBEM client so we'll use them in many fields.
2. Requirement
- WEB-Container : To running LCoP, you have to install the web-container such as Apache-Tomcat and JBOSS but this document only use the apache-tomcat-5.5.23.
- ANT : It is a powerful tool for use of compiling and running codes based on JAVA.
- LCoP source : You can get LCoP codes by OpenDRIM SVN.
3. Directory
LCoP is consist of bin, core src, and www.
- bin : It contains some utilities for running LCoP.
- src : It contains the main code in Control Panel.
- www : It must deploy on web container such as tomcat and contains full of the class file, library, jsp, and so on. first of all, LCoP makes use of AJAX library which makes netapp Inc. for supporting the web. This library supports the WEB based UI which operates on server side. Of course, we have already contained it to WEB-INF's lib directory.
4. Compile
If you compile about LCoP src, Please use the following command, $ant
[root@localhost LCoP]# ant
Buildfile: build.xml
init:
[mkdir] Created dir: /Devel/workspace/LCoP/www/WEB-INF/classes
compile:
[javac] Compiling 126 source files to /Devel/workspace/LCoP/www/WEB-INF/classes
...
...
[javac] Note: Recompile with -Xlint:deprecation for details.
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
[javac] 100 warnings
[mkdir] Created dir: /Devel/workspace/LCoP/www/WEB-INF/classes/conf
[copy] Copying 1 file to /Devel/workspace/LCoP/www/WEB-INF/classes/conf
[copy] Copying 1 file to /Devel/workspace/LCoP/www
[copy] Copying 157 files to /Devel/workspace/LCoP/www/WEB-INF/classes/LCoP/resource
BUILD SUCCESSFUL
Total time: 14 seconds
[root@localhost LCoP]#
If you clean the LCoP binary, Please use the following command, $ant clean.
[root@localhost LCoP]# ant clean Buildfile: build.xml clean: [delete] Deleting directory /Devel/workspace/LCoP/www/WEB-INF/classes [delete] Deleting: /Devel/workspace/LCoP/www/shadow BUILD SUCCESSFUL Total time: 0 seconds [root@localhost LCoP]#
5. Deploy
At first, you install the tomcat and LCoP code which locates in www directory is deployed in there. And you must create the deployment name as follows, "panel". Because its name is dependent on servlet context.
[root@localhost webapps]# pwd /root/apache-tomcat/webapps [root@localhost webapps]# ls ROOT balancer jsp-examples panel servlets-examples tomcat-docs webdav [root@localhost webapps]# cd panel/ [root@localhost panel]# ll drwxr-xr-x 3 root root 4096 8월 10 14:18 WEB-INF -rw-r--r-- 1 root root 454 8월 10 01:20 admin.xml -rw-r--r-- 1 root root 422 8월 9 23:47 adminHost.xml drwxr-xr-x 2 root root 4096 8월 9 00:11 css drwxr-xr-x 2 root root 4096 8월 9 00:11 img -rw-r--r-- 1 root root 289 8월 9 00:00 index.jsp drwxr-xr-x 2 root root 4096 8월 9 00:11 login -rw-r--r-- 1 root root 174 8월 9 23:44 sample.xml -rw-r--r-- 1 root root 431 8월 9 23:44 sampleHost.xml -rw-r--r-- 1 root root 0 8월 9 18:21 shadow [root@localhost panel]#
And then, you must modify the conf.properties file to match your deploy directory. Be careful! If name of directory contains the dot(.), you DONOT show the LCoP screen.
[root@localhost conf]# pwd /root/apache-tomcat/webapps/panel/WEB-INF/classes/conf [root@localhost conf]# cat conf.properties BASE_PATH=/root/apache-tomcat/webapps/panel/ USER_CONFIG=/root/apache-tomcat/webapps/panel/ SHADOW=/root/apache-tomcat/webapps/panel/shadow
6. Test
At first, you start up tomcat as following.
[root@localhost bin]# pwd /root/apache-tomcat/bin [root@localhost bin]# ./startup.sh Using CATALINA_BASE: /root/apache-tomcat Using CATALINA_HOME: /root/apache-tomcat Using CATALINA_TMPDIR: /root/apache-tomcat/temp Using JRE_HOME: /usr/lib/jvm/java-1.5.0-sun-1.5.0.10 [root@localhost bin]#
and then, put the address "http://localhost:8080/panel" on firefox.
if you occoured error message like this
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
javax.servlet.ServletException: Servlet execution threw an exception
root cause
java.lang.AbstractMethodError: org.apache.xerces.dom.DocumentImpl.getXmlStandalone()Z
com.sun.org.apache.xalan.internal.xsltc.trax.DOM2TO.setDocumentInfo(DOM2TO.java:373)
com.sun.org.apache.xalan.internal.xsltc.trax.DOM2TO.parse(DOM2TO.java:127)
com.sun.org.apache.xalan.internal.xsltc.trax.DOM2TO.parse(DOM2TO.java:94)
com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transformIdentity(TransformerImpl.java:663)
com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:709)
com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:313)
nextapp.echo2.webrender.output.XmlDocument.render(XmlDocument.java:100)
nextapp.echo2.webcontainer.WindowHtmlService.service(WindowHtmlService.java:105)
nextapp.echo2.webcontainer.NewInstanceService.service(NewInstanceService.java:76)
nextapp.echo2.webrender.WebRenderServlet.process(WebRenderServlet.java:273)
nextapp.echo2.webrender.WebRenderServlet.doGet(WebRenderServlet.java:179)
javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
note The full stack trace of the root cause is available in the Apache Tomcat/5.5.25 logs.
the xerces is downloaded and set up, it can solve.
#tar xczf xerces-J-bin-x.x.x.tar.gz #cd xerces-xxxx #cp *.jre JAVA_HOME/jre/lib/ext
and then test "http://localhost:8080/panel"
Thu Nov 20 15:37:20 2008
Hong, Sang-Hyun
shhong@lgnsys.com, ibmmsx2@gmail.com
