简体   繁体   English

在Debian Server上安装Hibernate3时遇到问题

[英]Having issues installing Hibernate3 on Debian Server

I am attempting to install Hibernate3 onto my linux server but I'm having a hard time figuring out what to do to get it to work. 我试图将Hibernate3安装到我的linux服务器上,但是我很难确定如何使它工作。 I have tried the following: 我尝试了以下方法:

  • copy required jars into a folder and called the folder via " java -classpath etc. " and got 将所需的jar文件复制到一个文件夹中,并通过“ java -classpath etc. ”调用该文件夹,并得到

java -classpath /home/mcmaster/javalibs/* -jar craftbukkit.jar Error: Could not find or load main class .home.mcmaster.javalibs.dom4j-1.6.1.jar java -classpath / home / mcmaster / javalibs / * -jar craftbukkit.jar错误:找不到或加载主类.home.mcmaster.javalibs.dom4j-1.6.1.jar

  • load the java command while calling only the core hibernate which resulted in normal class not found error 仅调用核心休眠模式时加载Java命令,这导致找不到普通类错误
  • on a whim installed to system java lib location with no affect 一时兴起,安装到系统java lib位置,没有任何影响
  • used apt-get to install libhibernate3-java with no change 使用apt-get to install libhibernate3-java无需更改apt-get to install libhibernate3-java
  • I have attempted to export $CLASSPATH=~/javalibs which has all the required jars 我尝试export $CLASSPATH=~/javalibs具有所有必需jar的export $CLASSPATH=~/javalibs

I'm literally pulling my hair out as an intermediate java user trying to learn some more advanced things(to me). 我实际上是作为中级Java用户试图向我学习一些更高级的知识的。

Here's the error I'm getting when trying to call the Session Class: 这是尝试调用会话类时遇到的错误:

Caused by: java.lang.ClassNotFoundException: org.hibernate.Session 引起原因:java.lang.ClassNotFoundException:org.hibernate.Session

Looks like you forgot the quotation marks. 好像您忘记了引号。 Try java -classpath '.:/home/mcmaster/javalibs/*' -jar craftbukkit.jar (as seen on wikipedia ). 尝试java -classpath '.:/home/mcmaster/javalibs/*' -jar craftbukkit.jar (如Wikipedia所示 )。

EDIT: I am guessing that craftbukkit.jar is executable. 编辑:我猜想craftbukkit.jar是可执行的。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM