Thursday March 10, 2011 Postgres scheint das mit den Datentypen ja recht eng zu sehen - ich hab' ein JForum neu aufgesetzt (Tomcat 6, Postgresql 8.4), und melde mich an, und bekomme Folgendes zu sehen:
For detailed error information, please see the HTML source code, and contact the forum Administrator.
org.postgresql.util.PSQLException: ERROR: operator does not exist: character varying = integer
Hint: No operator matches the given name and argument type(s). You might need to add explicit type casts.
Position: 237
Da ist eine Typkonversion wohl nicht erfolgt.
Problematisch ist das Lesen der Moderatoren-Liste für das Forum, also in
WEB_INF/config/database/generic/generic_queries.sql:
ForumModel.getModeratorList = SELECT g.group_id AS id, g.group_name AS name \
FROM jforum_groups g, jforum_roles r, jforum_role_values rv, jforum_roles r2 \
WHERE g.group_id = r.group_id \
AND r.role_id = rv.role_id \
AND r.name = 'perm_moderation_forums' \
AND rv.role_value = ? \
AND r2.name = 'perm_moderation' \
AND r2.group_id = g.group_id
Eine dieser Typkonversionen muss falsch sein.
Schaun wir doch mal in
WEB_INF/config/database/postgresql/postgresql.sql:
In der Kategorie
# #############
# ForumModel
# #############
ForumModel.lastGeneratedForumId = SELECT CURRVAL('jforum_forums_seq');
trage ich nach:
ForumModel.getModeratorList = SELECT g.group_id AS id, g.group_name AS name \
FROM jforum_groups g, jforum_roles r, jforum_role_values rv, jforum_roles r2 \
WHERE g.group_id = r.group_id \
AND r.role_id = rv.role_id \
AND r.name = 'perm_moderation_forums' \
AND rv.role_value = CAST ( ? AS VARCHAR(255) ) \
AND r2.name = 'perm_moderation' \
AND r2.group_id = g.group_id
Und, nach 'nem Tomcat-Neustart (sicher ist sicher....) geht alles.
Also fehlte der Typecast.
Friday February 11, 2011 Tja, gegenüber Windows 2000 scheint sich ja bei Vista (und dann auch Windows 7) die Behandlung von Batch-Umgebungsvariablen geändert zu haben....
Szenario: Ich habe einen JBoss, der zusammen mit fertig konfigurierter Anwendung auf einen Windows-Rechner gepackt werden, und dort direkt out-of-the-Box laufen soll. Unter Windows 2000 läuft das auch prima.
Unter Vista (Business, 32bit, SP1) führe ich die gleichen Schritte aus, die unter Windows 2000 zum Erfolg führen:
C:\WebDienst\jboss-5.1.0.GA\bin>service.bat install
Service JBoss Application Server 5.1 installed
C:\WebDienst\jboss-5.1.0.GA\bin>service.bat start
C:\WebDienst\jboss-5.1.0.GA\bin>
Sieht ja gut aus, kein Gemecker.
Also per Webbrowser auf den Port 8080 verbunden - nüscht. Und das Start-Log im Verzeichnis C:\WebDienst\jboss-5.1.0.GA\bin?
Starting JBoss Application Server 5.1 [2011-02-11 14:41:24]
Calling C:\WebDienst\jboss-5.1.0.GA\bin\run.conf.bat
JAVA_HOME is not set. Unexpected results may occur.
Set JAVA_HOME to the directory of your local JDK to avoid this message.
Also gut. Dann setze ich halt JBOSS_HOME und JAVA_HOME auf meine Verzeichnisse. Also flugs in die Systemsteuerung,
Systemsteuerung>System und Wartung>System>Erweiterte Systemeinstellungen>Erweitert>Umgebungsvariablen...>Systemvariablen - mittlerweile kenne ich mich ja sogar in der Vista-Systemsteuerung aus.


Und starte den -tatsächlich vorhandenen- Dienst neu.
Siehe da: Er läuft! Und im Task-Manager verbraucht auch der Java-Prozeß schön Rechenleistung.

Aber nö, wieder keine Verbindung. Blick in's Server-Log zeigt:
Starting JBoss Application Server 5.1 [2011-02-11 15:10:47]
Calling C:\WebDienst\jboss-5.1.0.GA\bin\run.conf.bat
===============================================================================JBoss Bootstrap Environment
JBOSS_HOME: C:\WebDienst\jboss-5.1.0.GA
JAVA: C:\WebDienst\jre1.5.0_22\bin\java
JAVA_OPTS: -Dprogram.name=run.bat -Xrs
CLASSPATH: ;C:\WebDienst\jboss-5.1.0.GA\bin\run.jar
===============================================================================
15:10:48,289 INFO [ServerImpl] Starting JBoss (Microcontainer)...
15:10:48,290 INFO [ServerImpl] Release ID: JBoss [The Oracle] 5.1.0.GA (build: SVNTag=JBoss_5_1_0_GA date=200905221053)
15:10:48,290 INFO [ServerImpl] Bootstrap URL: null
15:10:48,290 INFO [ServerImpl] Home Dir: C:\WebDienst\jboss-5.1.0.GA
15:10:48,290 INFO [ServerImpl] Home URL: file:/C:/WebDienst/jboss-5.1.0.GA/
15:10:48,290 INFO [ServerImpl] Library URL: file:/C:/WebDienst/jboss-5.1.0.GA/lib/
15:10:48,292 INFO [ServerImpl] Patch URL: null
15:10:48,292 INFO [ServerImpl] Common Base URL: file:/C:/WebDienst/jboss-5.1.0.GA/common/
15:10:48,292 INFO [ServerImpl] Common Library URL: file:/C:/WebDienst/jboss-5.1.0.GA/common/lib/
15:10:48,297 INFO [ServerImpl] Server Name: default
15:10:48,297 INFO [ServerImpl] Server Base Dir: C:\WebDienst\jboss-5.1.0.GA\server
15:10:48,297 INFO [ServerImpl] Server Base URL: file:/C:/WebDienst/jboss-5.1.0.GA/server/
15:10:48,297 INFO [ServerImpl] Server Config URL: file:/C:/WebDienst/jboss-5.1.0.GA/server/default/conf/
15:10:48,298 INFO [ServerImpl] Server Home Dir: C:\WebDienst\jboss-5.1.0.GA\server\default
15:10:48,298 INFO [ServerImpl] Server Home URL: file:/C:/WebDienst/jboss-5.1.0.GA/server/default/
15:10:48,298 INFO [ServerImpl] Server Data Dir: C:\WebDienst\jboss-5.1.0.GA\server\default\data
15:10:48,298 INFO [ServerImpl] Server Library URL: file:/C:/WebDienst/jboss-5.1.0.GA/server/default/lib/
15:10:48,298 INFO [ServerImpl] Server Log Dir: C:\WebDienst\jboss-5.1.0.GA\server\default\log
15:10:48,298 INFO [ServerImpl] Server Native Dir: C:\WebDienst\jboss-5.1.0.GA\server\default\tmp\native
15:10:48,298 INFO [ServerImpl] Server Temp Dir: C:\WebDienst\jboss-5.1.0.GA\server\default\tmp
15:10:48,298 INFO [ServerImpl] Server Temp Deploy Dir: C:\WebDienst\jboss-5.1.0.GA\server\default\tmp\deploy
15:10:48,994 INFO [ServerImpl] Starting Microcontainer, bootstrapURL=file:/C:/WebDienst/jboss-5.1.0.GA/server/default/conf/bootstrap.xml
15:10:49,817 INFO [VFSCacheFactory] Initializing VFSCache [org.jboss.virtual.plugins.cache.CombinedVFSCache]
15:10:49,820 INFO [VFSCacheFactory] Using VFSCache [CombinedVFSCache[real-cache: null]]
15:10:50,165 INFO [CopyMechanism] VFS temp dir: C:\WebDienst\jboss-5.1.0.GA\server\default\tmp
15:10:50,167 INFO [ZipEntryContext] VFS force nested jars copy-mode is enabled.
15:10:51,485 INFO [ServerInfo] Java version: 1.5.0_22,Sun Microsystems Inc.
15:10:51,485 INFO [ServerInfo] Java Runtime: Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_22-b03)
15:10:51,485 INFO [ServerInfo] Java VM: Java HotSpot(TM) Client VM 1.5.0_22-b03,Sun Microsystems Inc.
15:10:51,485 INFO [ServerInfo] OS-System: Windows Vista 6.0,x86
15:10:51,486 INFO [ServerInfo] VM arguments: -Dprogram.name=run.bat -Xrs -Djava.endorsed.dirs=C:\WebDienst\jboss-5.1.0.GA\lib\endorsed
15:10:51,520 INFO [JMXKernel] Legacy JMX core initialized
15:10:53,440 INFO [ProfileServiceBootstrap] Loading profile: ProfileKey-AT-3a4822[domain=default, server=default, name=default]
15:10:55,683 INFO [WebService] Using RMI server codebase: http://127.0.0.1:8083/
15:11:02,686 INFO [NativeServerConfig] JBoss Web Services - Stack Native Core
15:11:02,686 INFO [NativeServerConfig] 3.1.2.GA
15:11:03,301 INFO [AttributeCallbackItem] Owner callback not implemented.
15:11:13,325 INFO [LogNotificationListener] Adding notification listener for logging mbean "jboss.system:service=Logging,type=Log4jService" to server org.jboss.mx.server.MBeanServerImpl@831a91[ defaultDomain='jboss' ]
15:11:33,670 ERROR [ProfileDeployAction] Failed to add deployment: admin-console.war
org.jboss.deployers.spi.DeploymentException: Error populating deployment vfsfile:/C:/WebDienst/jboss-5.1.0.GA/server/default/deploy/admin-console.war/
at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49)
at org.jboss.deployers.structure.spi.helpers.AbstractStructureBuilder.populateContext(AbstractStructureBuilder.java:86)
at org.jboss.deployers.structure.spi.helpers.AbstractStructuralDeployers.determineStructure(AbstractStructuralDeployers.java:89)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineStructure(MainDeployerImpl.java:1004)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineDeploymentContext(MainDeployerImpl.java:440)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:390)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:300)
at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.addDeployment(MainDeployerAdapter.java:86)
at org.jboss.system.server.profileservice.repository.ProfileDeployAction.install(ProfileDeployAction.java:61)
at org.jboss.system.server.profileservice.repository.AbstractProfileAction.install(AbstractProfileAction.java:53)
at org.jboss.system.server.profileservice.repository.AbstractProfileService.install(AbstractProfileService.java:361)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
at org.jboss.system.server.profileservice.repository.AbstractProfileService.activateProfile(AbstractProfileService.java:306)
at org.jboss.system.server.profileservice.ProfileServiceBootstrap.start(ProfileServiceBootstrap.java:271)
at org.jboss.bootstrap.AbstractServerImpl.start(AbstractServerImpl.java:461)
at org.jboss.Main.boot(Main.java:221)
at org.jboss.Main$1.run(Main.java:556)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.OutOfMemoryError: Java heap space
at java.util.zip.ZipEntry.initFields(Native Method)
at java.util.zip.ZipEntry.(Unknown Source)
at java.util.zip.ZipFile$3.nextElement(Unknown Source)
at java.util.zip.ZipFile$3.nextElement(Unknown Source)
at org.jboss.virtual.plugins.context.zip.ZipEntryContext.initEntries(ZipEntryContext.java:491)
at org.jboss.virtual.plugins.context.zip.ZipEntryContext.ensureEntries(ZipEntryContext.java:619)
at org.jboss.virtual.plugins.context.zip.ZipEntryContext.checkIfModified(ZipEntryContext.java:773)
at org.jboss.virtual.plugins.context.zip.ZipEntryContext.getChild(ZipEntryContext.java:817)
at org.jboss.virtual.plugins.context.zip.ZipEntryHandler.createChildHandler(ZipEntryHandler.java:191)
at org.jboss.virtual.plugins.context.AbstractVirtualFileHandler.structuredFindChild(AbstractVirtualFileHandler.java:684)
at org.jboss.virtual.plugins.context.zip.ZipEntryHandler.getChild(ZipEntryHandler.java:165)
at org.jboss.virtual.plugins.context.DelegatingHandler.getChild(DelegatingHandler.java:107)
at org.jboss.virtual.VirtualFile.getChild(VirtualFile.java:481)
at org.jboss.virtual.VFSUtils.getManifest(VFSUtils.java:252)
at org.jboss.virtual.VFSUtils.addManifestLocations(VFSUtils.java:185)
at org.jboss.deployers.vfs.plugins.structure.VFSStructureBuilder.applyContextInfo(VFSStructureBuilder.java:210)
at org.jboss.deployers.structure.spi.helpers.AbstractStructureBuilder.populateContext(AbstractStructureBuilder.java:82)
at org.jboss.deployers.structure.spi.helpers.AbstractStructuralDeployers.determineStructure(AbstractStructuralDeployers.java:89)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineStructure(MainDeployerImpl.java:1004)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineDeploymentContext(MainDeployerImpl.java:440)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:390)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:300)
at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.addDeployment(MainDeployerAdapter.java:86)
at org.jboss.system.server.profileservice.repository.ProfileDeployAction.install(ProfileDeployAction.java:61)
at org.jboss.system.server.profileservice.repository.AbstractProfileAction.install(AbstractProfileAction.java:53)
at org.jboss.system.server.profileservice.repository.AbstractProfileService.install(AbstractProfileService.java:361)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
15:11:40,940 ERROR [ProfileDeployAction] Failed to add deployment: console-mgr.sar
org.jboss.deployers.spi.DeploymentException: Exception determining structure: AbstractVFSDeployment(console-mgr.sar)
at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49)
at org.jboss.deployers.structure.spi.helpers.AbstractStructuralDeployers.determineStructure(AbstractStructuralDeployers.java:85)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineStructure(MainDeployerImpl.java:1004)
at org.jboss.deployers.plugins.main.MainDeployerImpl.determineDeploymentContext(MainDeployerImpl.java:440)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:390)
at org.jboss.deployers.plugins.main.MainDeployerImpl.addDeployment(MainDeployerImpl.java:300)
at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.addDeployment(MainDeployerAdapter.java:86)
at org.jboss.system.server.profileservice.repository.ProfileDeployAction.install(ProfileDeployAction.java:61)
at org.jboss.system.server.profileservice.repository.AbstractProfileAction.install(AbstractProfileAction.java:53)
at org.jboss.system.server.profileservice.repository.AbstractProfileService.install(AbstractProfileService.java:361)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
at org.jboss.system.server.profileservice.repository.AbstractProfileService.activateProfile(AbstractProfileService.java:306)
at org.jboss.system.server.profileservice.ProfileServiceBootstrap.start(ProfileServiceBootstrap.java:271)
at org.jboss.bootstrap.AbstractServerImpl.start(AbstractServerImpl.java:461)
at org.jboss.Main.boot(Main.java:221)
at org.jboss.Main$1.run(Main.java:556)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.OutOfMemoryError: Java heap space
at java.lang.AbstractStringBuilder.expandCapacity(Unknown Source)
at java.lang.AbstractStringBuilder.append(Unknown Source)
at java.lang.StringBuilder.append(Unknown Source)
at org.jboss.virtual.plugins.context.AbstractVirtualFileHandler.initPath(AbstractVirtualFileHandler.java:419)
at org.jboss.virtual.plugins.context.AbstractVirtualFileHandler.getPathName(AbstractVirtualFileHandler.java:220)
at org.jboss.virtual.plugins.context.AbstractVirtualFileHandler.readLocalPathName(AbstractVirtualFileHandler.java:260)
at org.jboss.virtual.plugins.context.AbstractVirtualFileHandler.getLocalPathName(AbstractVirtualFileHandler.java:244)
at org.jboss.virtual.plugins.context.zip.ZipEntryContext.initEntries(ZipEntryContext.java:583)
at org.jboss.virtual.plugins.context.zip.ZipEntryContext.ensureEntries(ZipEntryContext.java:619)
at org.jboss.virtual.plugins.context.zip.ZipEntryContext.checkIfModified(ZipEntryContext.java:773)
at org.jboss.virtual.plugins.context.zip.ZipEntryContext.getChild(ZipEntryContext.java:817)
at org.jboss.virtual.plugins.context.zip.ZipEntryHandler.createChildHandler(ZipEntryHandler.java:191)
at org.jboss.virtual.plugins.context.AbstractVirtualFileHandler.structuredFindChild(AbstractVirtualFileHandler.java:684)
at org.jboss.virtual.plugins.context.zip.ZipEntryHandler.getChild(ZipEntryHandler.java:165)
at org.jboss.virtual.plugins.context.DelegatingHandler.getChild(DelegatingHandler.java:107)
at org.jboss.virtual.VirtualFile.getChild(VirtualFile.java:481)
at org.jboss.deployers.vfs.plugins.structure.explicit.DeclaredStructure.determineStructure(DeclaredStructure.java:64)
at org.jboss.deployers.vfs.plugins.structure.StructureDeployerWrapper.determineStructure(StructureDeployerWrapper.java:73)
at org.jboss.deployers.vfs.plugins.structure.VFSStructuralDeployersImpl.doDetermineStructure(VFSStructuralDeployersImpl.java:196)
at org.jboss.deployers.vfs.plugins.structure.VFSStructuralDeployersImpl.determineStructure(VFSStructuralDeployersImpl.java:142)
at org.jboss.deployers.vfs.spi.structure.StructureContext.determineChildStructure(StructureContext.java:294)
at org.jboss.deployers.vfs.spi.structure.helpers.AbstractCandidateStructureVisitor.visit(AbstractCandidateStructureVisitor.java:157)
at org.jboss.virtual.plugins.vfs.helpers.WrappingVirtualFileHandlerVisitor.visit(WrappingVirtualFileHandlerVisitor.java:62)
at org.jboss.virtual.plugins.context.AbstractVFSContext.visit(AbstractVFSContext.java:361)
at org.jboss.virtual.plugins.context.AbstractVFSContext.visit(AbstractVFSContext.java:306)
at org.jboss.virtual.VFS.visit(VFS.java:421)
at org.jboss.virtual.VirtualFile.visit(VirtualFile.java:437)
at org.jboss.deployers.vfs.spi.structure.helpers.AbstractStructureDeployer.addChildren(AbstractStructureDeployer.java:334)
at org.jboss.deployers.vfs.spi.structure.helpers.AbstractStructureDeployer.addAllChildren(AbstractStructureDeployer.java:316)
at org.jboss.deployers.vfs.plugins.structure.jar.JARStructure.determineStructure(JARStructure.java:174)
at org.jboss.deployers.vfs.plugins.structure.StructureDeployerWrapper.determineStructure(StructureDeployerWrapper.java:73)
at org.jboss.deployers.vfs.plugins.structure.VFSStructuralDeployersImpl.doDetermineStructure(VFSStructuralDeployersImpl.java:196)
15:11:50,228 ERROR [ScopedProfileServiceController] Error installing to Deploy: name=ProfileKey@af8b32[domain=default, server=default, name=applications] state=Start mode=On Demand requiredState=Installed
15:11:55,028 ERROR [STDERR] Failed to boot JBoss:
OutOfMemory? Der JBoss bekommt doch in der run.conf.bat Speicher-Parameter gesetzt?
Moment. Da wird auch das JAVA-Home gesetzt, was auch ganz am Anfang gesetzt wird.
Also mal ein Test. Ich ergänze in der run.bat mal die wichtigen Zeilen aus der run.conf.bat:
Vorher:
@echo off
rem -------------------------------------------------------------------------
rem JBoss Bootstrap Script for Windows
rem -------------------------------------------------------------------------rem $Id: run.bat 88978 2009-05-16 18:18:45Z alex.loubyansky@jboss-DOT-com $
@if not "%ECHO%" == "" echo %ECHO%
Jetzt:
@echo off
rem -------------------------------------------------------------------------
rem JBoss Bootstrap Script for Windows
rem -------------------------------------------------------------------------
set "JAVA_HOME=..\..\jre1.5.0_22"
set "JAVA_OPTS=-Xms128M -Xmx512M -XX:MaxPermSize=256M"
set "JAVA_OPTS=%JAVA_OPTS% -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000"
set "JAVA_OPTS=%JAVA_OPTS% -Dorg.jboss.resolver.warning=true"
@if not "%ECHO%" == "" echo %ECHO%
Und den Dienst neu starten.
Verbindung auf den Konfigurierten Web-Port: Klappt.
Neustart des Rechners: Überlebt.
Geht!
Jetzt noch in's InnoSetup packen, und dann klappts.
Ach ja - alles, was ich so per cmd getan habe, habe ich als Administrator gemacht.
Memo an mich selbst:
Windows Vista oder Windows 7 kennen auch 'nen
>sudo sh (also cmd als Administrator ausführen):

In der Suchen-Box im Startmenü "cmd" 'rein, und dann per <ctrl>-<shift>-<enter> starten. Dialog wegklicken, fertig.
Gefunden auf und Dank an:
HowtoGeek
| « May 2012 | ||||||
| Sun | Mon | Tue | Wed | Thu | Fri | Sat |
|---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 | 31 | ||
| Today | ||||||
Today's Page Hits: 1409