Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> H@H Database problems (initial setup) [Closed/solved/working], ubuntu linux server setup

 
post May 28 2012, 20:59
Post #1
Melkeku



Lurker
Group: Recruits
Posts: 8
Joined: 4-April 12
Level 45 (Artisan)


Hello everyone!

(not sure if the H@H program was made to work on ubuntu, but i was hoping)
im having some problems setting up my H@H server. (well, abviously (IMG:[invalid] style_emoticons/default/wink.gif) )

it is currently running its own virtual server on a VMware computer.
it is running on a home network with one port routed through the FW which is specified in the control panel for H@H servers i am running.

i have currently set up a Ubuntu Linux server for the sole purpose of running H@H.
it is running the latest version (12.04) and has been "upgraded" and updated once it was installed (today).
i have verified that the network is working correctly (had some dns problems earlier).
it has a static internal IP with a route in the firewall for H@H connection.

i have removed the java program that comes with ubuntu and installed "SUN java" through this guide:
wikihow[dot]com/Install-Oracle-Java-on-Ubuntu-Linux

and verified running newest version by checking "java -version": (it is stated in the H@H thread from Tenboro that the server needs JRE version 6 update 24 OR newer)
java version "1.7.0_04"
Java™ SE Runtime Environment (build 1.7.0_04-b20)
Java HotSpot™ 64-Bit Server VM (build 23.0-b21, mixed mode)


the server files for H@H (V1.0.9) was downloaded today and saved in /usr/local/hath
i am logged on to the server with my root user atm. to test everything...
have run chown and chmod on the HATH folder to be on the safe side.

but no matter how much i have tried i get an error message on startup.
havent found anything on this forum or in the FAQ about a similar case (like mine, only ones with fixes that has not worked for me).

this is what happens from maual start of H@H program:

CODE

randomuser@randommachine:/usr/local/hath# java -jar HentaiAtHome.jar
2012-05-28T18:32:52Z [info] Started logging to data/log_out
2012-05-28T18:32:52Z [info] Started logging to data/log_err
2012-05-28T18:32:52Z [info] Hentai@Home 1.0.9 starting up
2012-05-28T18:32:52Z [info]
2012-05-28T18:32:52Z [info] Copyright (c) 2008-2012, E-Hentai.org - all rights reserved.
2012-05-28T18:32:52Z [info] This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL v3 license.
2012-05-28T18:32:52Z [info]
2012-05-28T18:32:52Z [info] Loaded login settings from client_login
2012-05-28T18:32:52Z [info] Connecting to the Hentai@Home Server to register client with ID xxxx...
2012-05-28T18:32:52Z [info] Connecting to rpc.hentaiathome.net...
2012-05-28T18:32:52Z [info] /clientapi.php?clientbuild=68&act=server_stat: Retrieving 66 bytes...
2012-05-28T18:32:52Z [info] Reading Hentai@Home client settings from server...
2012-05-28T18:32:52Z [info] Connecting to rpc.hentaiathome.net...
2012-05-28T18:32:52Z [info] /clientapi.php?clientbuild=68&act=client_login&add=&cid=xxxx&acttime=xxxxxxxxxxx&actkey=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx: Retrieving 283 bytes...
2012-05-28T18:32:52Z [info] Applying settings...
2012-05-28T18:32:52Z [info] Finished applying settings
2012-05-28T18:32:52Z [info] CacheHandler: Initializing database engine...
2012-05-28T18:32:52Z [info] CacheHandler: Loading database from data/hath.db
2012-05-28T18:32:52Z [ERROR] {org.hath.base.CacheHandler.initializeDatabase(CacheHandler.java:180)} CacheHandler: Encountered error reading database.
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)} java.lang.ClassNotFoundException: org.sqlite.JDBC
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at java.net.URLClassLoader$1.run(Unknown Source)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at java.net.URLClassLoader$1.run(Unknown Source)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at java.security.AccessController.doPrivileged(Native Method)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at java.net.URLClassLoader.findClass(Unknown Source)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at java.lang.ClassLoader.loadClass(Unknown Source)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at java.lang.ClassLoader.loadClass(Unknown Source)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at java.lang.Class.forName0(Native Method)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at java.lang.Class.forName(Unknown Source)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at org.hath.base.CacheHandler.initializeDatabase(CacheHandler.java:137)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at org.hath.base.CacheHandler.<init>(CacheHandler.java:93)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at org.hath.base.HentaiAtHomeClient.run(HentaiAtHomeClient.java:109)
2012-05-28T18:32:52Z [ERR] {java.lang.Throwable$WrappedPrintStream.println(Unknown Source)}     at java.lang.Thread.run(Unknown Source)
2012-05-28T18:32:52Z [info]
2012-05-28T18:32:52Z [info] ************************************************************************************************************************************
2012-05-28T18:32:52Z [info] The database could not be loaded.
2012-05-28T18:32:52Z [info] In order to fix this, please do the following:
2012-05-28T18:32:52Z [info] 1. Locate the directory /usr/local/hath/data
2012-05-28T18:32:52Z [info] 2. Delete the file hath.db
2012-05-28T18:32:52Z [info] 3. Rename the file hath.db.bak to hath.db
2012-05-28T18:32:52Z [info] 4. Restart the client again.
2012-05-28T18:32:52Z [info] If this fails to work, just delete the file hath.db and all backups, and restart. The system will then rebuild the database.
2012-05-28T18:32:52Z [info] ************************************************************************************************************************************
2012-05-28T18:32:52Z [info]
2012-05-28T18:32:52Z [ERROR] {org.hath.base.HentaiAtHomeClient.dieWithError(HentaiAtHomeClient.java:268)} Critical Error: Failed to load the database.
2012-05-28T18:32:52Z [info] Shutting down...
2012-05-28T18:32:52Z [info] Your business is appreciated


the problem im having is as you have seen by now related to the DB file.
the problem is, there is no db file, it is never created. even tho im root and i have the privileges to create and modify files in the hath/data folder.
i have several times tried removing the client login and log files. no luck
have tried resetting my "Client Key". no luck.

if anyone can spot any missing links or can get me started somewhere id really much appreciate it!! (IMG:[invalid] style_emoticons/default/smile.gif)



Kind Regards
Melkeku


UPDATE:
a guide on how to install H@H on an Ubuntu server is made in the Wiki, please check it out if you need help
installing H@H on ubuntu

This post has been edited by Melkeku: Jun 2 2012, 23:08
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post May 28 2012, 22:08
Post #2
RichardB73



Casual Poster
***
Group: Members
Posts: 151
Joined: 5-May 12
Level 82 (Champion)


Guess you could try to make an empty file called hath.db and then start the client with the

--force_dirty

Forces a check of the database for errors (as if the database was dirty).
or

--verify_cache

Forces a check of the entire cache. This is the same as --force_dirty, except that the content of each file in the cache is also checked.

command line switch.

Or there is still a problem that doesn't let the client write in the hath/data directory?
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post May 28 2012, 23:10
Post #3
Tenboro

Admin




Do you have the sqlite-jdbc-3.7.2.jar file in that directory?

Also, Java 7 isn't officially supported yet, but it's mostly because it's a buggy piece of shit that makes the GUI derp out for no particular reason.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post May 28 2012, 23:12
Post #4
Melkeku



Lurker
Group: Recruits
Posts: 8
Joined: 4-April 12
Level 45 (Artisan)


@richard

im guessing im to type "--force_dirty" after the filename when staring the server? in thin manner:

java -jar hentaiathome.jar --force_dirty

tried this now, with and without the manual creation of a .db file. no luck :/

QUOTE
Or there is still a problem that doesn't let the client write in the hath/data directory?

wouldn't it be weird if the client was able to write the logs, login info and manually create a db file in the data folder if this was the problem?

ill test a little more, is there any chance i have to manually install an sql program?

from the error message i got on startup:
java.lang.ClassNotFoundException: org.sqlite.JDBC

can this mean it doesnt have a sql program installed?
i will try more tomorrow (since its late here (IMG:[invalid] style_emoticons/default/tongue.gif))

if nothing else works i will try setting up a new linux machine, if that doesnt work or i havent gotten anything else suggested to work i guess ill set up a windows computer or trying another linux distro...

edit:
@tenboro
yes, this file is present in the hath directory (IMG:[invalid] style_emoticons/default/smile.gif) (as well as all the other files from the zip)

ill try downgrading the java first (or second)thing tomorrow, ill post updates as i progress (IMG:[invalid] style_emoticons/default/smile.gif)

thanks so far (IMG:[invalid] style_emoticons/default/smile.gif)

This post has been edited by Melkeku: May 28 2012, 23:21
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post May 29 2012, 01:44
Post #5
RichardB73



Casual Poster
***
Group: Members
Posts: 151
Joined: 5-May 12
Level 82 (Champion)


QUOTE
java -jar hentaiathome.jar --force_dirty


Yes thats what i mean, but i usualy execute the hentaiathomegui.jar file.
Don't know if it makes any difference though.

Lets hope the problem is the java version then.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post May 29 2012, 17:37
Post #6
Melkeku



Lurker
Group: Recruits
Posts: 8
Joined: 4-April 12
Level 45 (Artisan)


i just have to ask this one thing right away,
if it at all possible to run H@H on a "server edition" of linux?
or is it only created for running on a "desktop edition"?

if so thats my problem (IMG:[invalid] style_emoticons/default/tongue.gif) ill research a little more to see if i can get it to work (IMG:[invalid] style_emoticons/default/smile.gif)
(or until i get a confirmed answer from someone)

as you might have noticed from the first post i do not have an ordinary setup at home.
(vmware would ring a bell if you know what it is (IMG:[invalid] style_emoticons/default/smile.gif) )
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post May 29 2012, 21:41
Post #7
Tenboro

Admin




It has both a command-line mode and a GUI mode.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post May 30 2012, 23:28
Post #8
Melkeku



Lurker
Group: Recruits
Posts: 8
Joined: 4-April 12
Level 45 (Artisan)


haven't tested much today (IMG:[invalid] style_emoticons/default/sad.gif) no time...

just throwing this out there:
im guessing the jar files are created to work with sun(oracle) java?
not sure if there is much difference between sun and other java distributions... (tried one called "openjdk" today since it was faster atm.)

if i finally get this working on my server version of ubuntu im making a guide (IMG:[invalid] style_emoticons/default/tongue.gif)
learning a bunch more in this process tho (IMG:[invalid] style_emoticons/default/biggrin.gif)
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post May 31 2012, 23:12
Post #9
Melkeku



Lurker
Group: Recruits
Posts: 8
Joined: 4-April 12
Level 45 (Artisan)


Sorry for double posting this...

i finally got it working!!
got java installed, saved the hath program in another folder and got it working...
was a major pain the place where the sun don't shine, but im happy for now and learned a lot!

thanks both of you for the help!
i will make a guide for those who are interested in setting up an unmanaged Linux Ubuntu (server not deskptop)
i will update this last and first post with the guide when its done (so in a couple days, so check back if you are interested (IMG:[invalid] style_emoticons/default/smile.gif) )

ill send a copy to you too Tenboro if you are interested for the FAQ section for H@H (IMG:[invalid] style_emoticons/default/smile.gif)
my client is finally online and gaining trust (IMG:[invalid] style_emoticons/default/smile.gif) hopefully for a long time to come (IMG:[invalid] style_emoticons/default/smile.gif)

Happy sharing!! and have a nice weekend guys!!



Melkeku out...

User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jun 2 2012, 17:00
Post #10
Hairs Fan



Women body fetishist
******
Group: Members
Posts: 859
Joined: 15-September 08
Level 219 (Ascended)


QUOTE(Melkeku @ May 30 2012, 23:28) *

im guessing the jar files are created to work with sun(oracle) java?
not sure if there is much difference between sun and other java distributions... (tried one called "openjdk" today since it was faster atm.)

Yes, the OpenJDK version of Java 6 doesn't work well with H@H. This probably explain why Java 7 doesn't work well either, as it is based on the OpenJDK code.

QUOTE(Melkeku @ May 31 2012, 23:12) *

ill send a copy to you too Tenboro if you are interested for the FAQ section for H@H (IMG:[invalid] style_emoticons/default/smile.gif)

Adding guides for Linux distros is always a good idea, but the wiki is a better place for such a guide, so you'd better create an article for it on the wiki, and add a link to it in the H@H article.

This post has been edited by Hairs Fan: Jun 2 2012, 17:02
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jun 2 2012, 23:05
Post #11
Melkeku



Lurker
Group: Recruits
Posts: 8
Joined: 4-April 12
Level 45 (Artisan)


QUOTE(Hairs Fan @ Jun 2 2012, 17:00) *

Yes, the OpenJDK version of Java 6 doesn't work well with H@H. This probably explain why Java 7 doesn't work well either, as it is based on the OpenJDK code.

that would pretty much explain it yes (IMG:[invalid] style_emoticons/default/smile.gif)

QUOTE(Hairs Fan @ Jun 2 2012, 17:00) *

Adding guides for Linux distros is always a good idea, but the wiki is a better place for such a guide, so you'd better create an article for it on the wiki, and add a link to it in the H@H article.

Good idea!
didn't think of this when i wrote.
have made a wiki page for installing H@H on ubuntu page and added it to H@H article as well as made some minor updates to the H@H article page (since it linked to the java 7 page which is not working)
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jun 6 2012, 09:04
Post #12
pureyang



Regular Poster
******
Group: Gold Star Club
Posts: 764
Joined: 6-June 12
Level 490 (Dovahkiin)


@OP: I am currently having a similar issue with solaris (EDIT: there is a workaround described there which I think will work for you too)
https://forums.e-hentai.org/index.php?act=S...=0#entry1980264

It seems that java on windows can handle relative paths for includes, but java on solaris will NOT handle relative paths properly.

From the error messages you are getting I believe you are having the same issue as I did. (I had a few more errors because I tried to load the GUI.jar which then tries to load the base file.jar, which then tries to load the sql's .jar Since you set it to load the command live version it has fewer files it cannot find.)

I an guessing/hoping a single jar packaged with all needed components might solve this. (so that hath.jar contains the SQL's jar. And hathGUI contains both hath CL and SQL)
Anyone knows how to convert a multi jar file into a singular jar? (I read you can just unzip and zip them together but what about the manifests include files? or other dependences... will try tomorrow morning, its rather late now)

PS. would be great for us poor folk using commandline if the filename for this was shortened to "hath.jar" and "hathgui.jar".

This post has been edited by mrttao: Jun 6 2012, 21:10
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jun 6 2012, 11:36
Post #13
Rikis



Bringer of Light
********
Group: Gold Star Club
Posts: 3,679
Joined: 7-July 09
Level 500 (Godslayer)


QUOTE(mrttao @ Jun 6 2012, 10:04) *
PS. would be great for us poor folk using commandline if the filename for this was shortened to "hath.jar" and "hathgui.jar".

Doesn't Tab key work?
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jun 6 2012, 17:47
Post #14
pureyang



Regular Poster
******
Group: Gold Star Club
Posts: 764
Joined: 6-June 12
Level 490 (Dovahkiin)


QUOTE(Rikis @ Jun 6 2012, 04:36) *

Doesn't Tab key work?


it works and I use it, its still a lot easier to handle / type at first if its a shorter name.

EDIT: I tried packaging them all together with a modified manifest file, it still crashed on start saying it can't find HentaiAtHome.jar

This post has been edited by mrttao: Jun 6 2012, 20:12
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jul 4 2012, 20:49
Post #15
lovehcomics



Active Poster
*******
Group: Members
Posts: 1,354
Joined: 28-August 09
Level 272 (Godslayer)


Oh heck, I removed the manual installation instructions in that recent topic I posted, and now I see that it's needed. Well, at least you have the instructions here. Essentially download the package using Wget, untar/unbzip it to a folder, and make a link ('ln -s /usr/java/jre1.7.0_05/bin/java' or something like that) to /bin/java. Do NOT get the RPM package. Get the 'bin' file and just extract it. I've used RPM's in Ubuntu but I tested it and unzipping the JRE archive works. (Yes, I know RPM=an archive)

Besides the fact that I'm more familiar with DOS or the command prompt in Windows and it's file system conventions, it's practically identical to what I'd do on a headless Windows system. /bin=like C:\windows\system32 /etc is similar to the registry hives, and so on... But that's more for a more generic newbie guide to Linux for DOS/Windows users and not for these very specific guides we've put together. (IMG:[invalid] style_emoticons/default/wink.gif)

This post has been edited by lovehcomics: Jul 4 2012, 20:55
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

 
post Jul 25 2012, 03:17
Post #16
Thira



Isabella "Ivy" Valentine
********
Group: Members
Posts: 4,239
Joined: 15-November 09
Level 500 (Dovahkiin)


Other one possibility of getting "CacheHandler: Encountered error reading database." here.
If the file in "data" directory (maybe "hath.db-journal" or "hath.db") has read/write error (caused by crush/unexpected shutdown), h@h client spits same error.

If you can't fix even you revived "hath.db", try deleting "hath.db-journal" (or other files in "data" directory).
If you can't delete it, it means the volume has error.
To fix that, try "CHKDSK /F" on the volume.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post


Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 


Lo-Fi Version Time is now: 5th May 2024 - 18:18