| 
| 
| 配置J2EE(v1.4.02)和Cloudscape(10.0) |  
| 时间:2014-05-04 10:03:49  来源:不详  作者:佚名 |  
| 
 | 首先我们来配置J2EE, 版本的,地址我提取出来了
 
 | 去Sun公司下载J2SDK,和J2SDKE 
 
 | E,其实,我们可以下载那个集成 
 
 | 
 
 | 这个版本集成了它们两 目录名字为J2EE_SDK)的jd
 
 | 个,其中的J2SDK在安装后的J2E k目录。
 
 | E_SDK文件夹(我定义的那个安装 
 
 | 
 
 | 配置J2EE的环境变量比较简单,我们可以先来设置两个变量,我设置的如下: | 
 
 | 添加path为:%J2EE_HO 
 | ME%bin;:%J2DK_HOME%bin; 
 | 
 
 | 检查CLASSPATH值,没有则新建。先 %J2EE_HOME%libJ2EE.jar;
 
 | 给默认值:“.“; value是:.; 然后添加 
 
 | 
 
 | 在开始菜单中启动J2EE,菜单项为st http://localhost:port/index.html 其
 , 因为如果有http服务器如IIS,它占用
 8000吧~
 
 | art default server, 启动成功后,向地址栏输入: 中的port是你安装时设置的端口号,我设置的为8000
 80,而如果有Tomcat,占用8080,按照惯例,就给他
 
 
 | 
 
 
 
 | 其实人家IBM说的很清 经有点儿落伍了,另外,那
 
 | 楚了,下面我摘取一下原文(前 个人也不怎么会用环境变量 :-)
 
 | 天我从网上找的那篇文章说实话已 
 
 | 
 
 
 | You can use Cloudscape’s sysinf products. Once you have the bin dire
 typing the following command in a co
 
 | o tool to check the versions of Cloudscape ctory in your PATH, you can run sysinfo by
 mmand window:
 
 | 
 
 
 | The sysinfo script s class path, and executes
 
 | ets the appropriate environm the sysinfo program.
 
 | ent variables, including 
 
 | 
 
 
 | You can use the ij t the bin directory in you
 following:
 
 | ool to connect to a Cloudsca r PATH, you can execute the
 
 
 | pe database. Once you have ij command by typing the
 
 
 | 
 
 
 | The ij script sets u ij program.
 
 | p environment variables like 
 
 | class path and executes the 
 
 | 
 
 | To create a database with ij, ty 
 | pe the following command: 
 | 
 | ij> connect ’jdbc:cloudscape:testdb;create=true’; | 
 
 
 | This command creates the databas populates the system tables. You can
 command line. When you are ready to
 
 | e called testdb in the current directory and then execute any SQL statements from the ij
 leave ij, type:
 
 | 
 
 
 
 | See the IBM Cloudsca running ij.
 
 | pe Tools and Utilities Guide 
 
 | for more information on 
 
 | 
 
 | -------------------- ----------------
 
 | ---------------------------- 
 
 | ---------------- 
 
 | 
 
 | Manually setting environment var 
 | iables and paths 
 | 
 
 | If you cannot run th must complete certain st
 set your environment and
 
 | e scripts for the Cloudscape eps manually. The following
 run the tools manually.
 
 | tools and utilities, you topics show how to manually
 
 
 | 
 
 | The installation pro software was installed;
 document refers to that
 
 | gram asked you to choose a b we recommended that you name
 directory as the Cloudscape
 
 | ase directory where the it Cloudscape_10. This
 base directory.
 
 | 
 
 | If you do not plan to use the sc directory and your operating system
 called CLOUDSCAPE_INSTALL and set it
 directory. For example, if you insta
 CLOUDSCAPE_INSTALL to c:Cloudscape_
 
 | ripts in the frameworks/embedded/bin supports it, create an environment variable
 s value to the path of the Cloudscape base
 lled the product in c:Cloudscape_10, set
 10:
 
 | 
 
 | set CLOUDSCAPE_INSTALL=c:Cloudscape_10 | 
 
 | The JVM (compiler or instructions about locat
 class path is a list of
 applications in order to
 
 | interpreter) needs to know ion) of every class file nee
 the class libraries needed b
 run your program.
 
 | the path (operating system ded by your application. The
 y the JVM and other Java
 
 
 | 
 
 | There are two ways to set the cl CLASSPATH environment variable perma
 environment variable temporarily, yo
 command window. Alternatively, you c
 option, which means specifying the c
 application and the JVM.
 
 | ass path. You can set the operating system’s nently or temporarily. If you set the
 u must set it each time you open a new
 an set the class path with the runtime
 lass path at the time you start your Java
 
 
 | 
 
 | In most development s CLASSPATH environment
 help you set your class
 ks/embedded/bin director
 script every time you op
 
 | environments, it works best variable temporarily. Clouds
 path this way; they are foun
 y or the frameworks/NetworkS
 en a new command window.
 
 | to set the operating system’ cape provides some scripts to
 d in theframewor
 erver/bin directory. Run a
 
 
 | 
 
 | For example, you can 
 | set your class path as foll 
 | ows: 
 | 
 
 | set CLASSPATH=%CLOUDSCAPE_INSTAL PE_INSTALL%libcstools.jar;%CLASSPA
 
 | L%libcs.jar; %CLOUDSCA TH%
 
 | 
 
 | To manually run the or shell:
 
 | sysinfo utility, type the fo 
 
 | llowing in a command window 
 
 | 
 
 | java com.ihost.cs.tools.sysinfo | 
 
 | To manually run the ij utility, shell:
 
 | type the following in a command window or 
 
 | 
 
 | java com.ihost.cs.tools.ij | 
 | ij> connect 'jdbc:cloudscape:testdb;create=true'; | 
 
 
 | When you are finished running th 
 | e ij utility, type: 
 | 
 
 
 | 其实很简单,他说建议 CLOUDSCAPE_HOME, 然后说
 这样就可以执行里面的bat
 :lib中的那些jar文件,我
 
 | 你加一个变量为Cloudscape_ins 加入一个path,为%CLOUDSCAPE_
 文件了,就是sysinfo,ij。然
 就不详细写了。然后就可以运行
 
 | tall, 值为安装目录,我建立的是 HOME%frameworksembeddedbin
 后又加入到CLASSPATH中的如下值
 这些工具了。
 
 | 
 
 
 
 | 设置好了上面的Classp 有可能你的Classpath没有
 合吗? 如果不一样,则你
 
 | ath,那么我们就可以做下面的 设置好,你看一下cmd后中的set
 设置不对
 
 | 例子了;如果出现class找不到, 命令出来的结果,看与你设置的符
 
 
 | 
 
 | Output Cloudscape 10.0 version i 
 | nformation 
 | 
 
 | C:>java com.ihost.cs.tools.sysinfo------------------ Java Information ------------------Java Version:  1.4.2_04Java Vendor:   Sun Microsystems Inc.Java home:    C:Program FilesJavaj2re1.4.2_04Java classpath: .;E:Program FilesJ2EE_SDKlibJ2EE.jar;E:Program FilesIBMCloudscape_10.0libcs.jar;E:Program FilesIBMCloudscape_10.0libcstools.jar;E:Program FilesIBMCloudscape_10.0libcsnet.jar;E:Program FilesJ2EE_SDKjdklibtools.jar;E:Program FilesJ2EE_SDKjdklibdt.jar;OS name:     Windows XPOS architecture: x86OS version:   5.1Java user name: tsuijyJava user home: D:SettingsJava user dir:  C:--------- Cloudscape Information --------[E:Program FilesIBMCloudscape_10.0libcs.jar] 10.0.1.0 beta - (29729)[E:Program FilesIBMCloudscape_10.0libcstools.jar] 10.0.1.0 beta - (29729)[E:Program FilesIBMCloudscape_10.0libcsnet.jar] 10.0.1.0 beta - (29729)----------------------------------------------------------------------- Locale Information ----------------------------------------------------------------------- | 
 
 | C:>java com.ihost.cs.tools.ijij version 10.0 (c) 1997, 2004 IBM Corp.ij> | 
 
 | Used without additional argument libraries, outputting the libraries
 shown below:
 
 | s, the -cp option tests for all Cloudscape it can find as well as the ones it cannot, as
 
 
 | 
 
 | C:>java com.ihost.cs.tools.sysinfo -cpTesting for presence of all Cloudscape-related libraries; typically, only some are needed.For a list of possible arguments, type java com.ihost.cs.tools.sysinfo -cp argsFOUND IN CLASS PATH: | 
 
 | Cloudscape embedd 
 | ed engine library (cs.jar) 
 | 
 | Cloudscape Networ 
 | k Server library (csnet.jar) 
 | 
 | Cloudscape tools 
 | library (cstools.jar) 
 | 
 | Cloudscape Client found.)
 
 | libraries (db2jcc.jar)  ( 
 
 | com.ibm.db2.jcc.DB2Driver not 
 
 | 
 
 | E:Program FilesIBMCloudscape_10.0demoprogramssimple>java com.ihost.cs.tools.sysinfo -cp SimpleApp.classFOUND IN CLASS PATH: | 
 
 | user-specified class (SimpleApp) | 
 | SUCCESS: All Cloudsc 
 | ape related classes found in 
 | class path. 
 | 
 |  |  |  |