显示连接http://localhost/web项目rw失败

博客指出http://localhost/web项目rw连接失败问题,解决办法是重新注册IIS。具体操作是打开.net工具,输入aspnet_regiis -i ,完成操作后问题可解决。

显示连接http://localhost/web项目rw失败

再注册IIS即可

开.net工具,输入aspnet_regiis -i

可以了

[root@yfw ~]# cd /etc/systemd/system [root@yfw system]# #!/bin/bash [root@yfw system]# # deploy-openfire.sh [root@yfw system]# [root@yfw system]# OPENFIRE_HOME=/opt/openfire [root@yfw system]# USER=openfire [root@yfw system]# [root@yfw system]# pkill -f openfire || true [root@yfw system]# [root@yfw system]# rm -rf $OPENFIRE_HOME/embedded-db/* [root@yfw system]# rm -rf $OPENFIRE_HOME/work/* [root@yfw system]# rm -rf $OPENFIRE_HOME/temp/* [root@yfw system]# [root@yfw system]# cat > $OPENFIRE_HOME/conf/openfire.xml << 'EOF' > <?xml version="1.0" encoding="UTF-8"?> > <jive> > <adminConsole> > <port>9090</port> > <securePort>9091</securePort> > </adminConsole> > <locale>en</locale> > <setup>true</setup> > </jive> > EOF [root@yfw system]# [root@yfw system]# chown -R $USER:$USER $OPENFIRE_HOME/{conf,logs,embedded-db} [root@yfw system]# [root@yfw system]# $OPENFIRE_HOME/bin/start.sh Using Java: /usr/lib/jvm/java-17-openjdk/bin/java Java Version: openjdk version "17.0.1" 2021-10-19 LTS OpenJDK Runtime Environment 21.9 (build 17.0.1+12-LTS) OpenJDK 64-Bit Server VM 21.9 (build 17.0.1+12-LTS, mixed mode, sharing) Classpath: /opt/openfire/lib/activation-1.1.jar:/opt/openfire/lib/apache-el-9.0.107.jar:/opt/openfire/lib/apache-jsp-9.0.107.jar:/opt/openfire/lib/asm-9.8.jar:/opt/openfire/lib/asm-commons-9.8.jar:/opt/openfire/lib/asm-tree-9.8.jar:/opt/openfire/lib/bcpg-jdk18on-1.78.1.jar:/opt/openfire/lib/bcpkix-jdk18on-1.78.1.jar:/opt/openfire/lib/bcprov-jdk18on-1.78.1.jar:/opt/openfire/lib/bcutil-jdk18on-1.78.1.jar:/opt/openfire/lib/caffeine-3.2.0.jar:/opt/openfire/lib/checker-qual-3.33.0.jar:/opt/openfire/lib/common-image-3.9.4.jar:/opt/openfire/lib/common-io-3.9.4.jar:/opt/openfire/lib/common-lang-3.9.4.jar:/opt/openfire/lib/commons-codec-1.15.jar:/opt/openfire/lib/commons-dbcp2-2.9.0.jar:/opt/openfire/lib/commons-ip-math-1.32.jar:/opt/openfire/lib/commons-lang3-3.18.0.jar:/opt/openfire/lib/commons-logging-1.2.jar:/opt/openfire/lib/commons-pool2-2.9.0.jar:/opt/openfire/lib/commons-text-1.10.0.jar:/opt/openfire/lib/dom4j-2.1.4.jar:/opt/openfire/lib/dwr-3.0.2-RELEASE.jar:/opt/openfire/lib/ecj-3.33.0.jar:/opt/openfire/lib/error_prone_annotations-2.18.0.jar:/opt/openfire/lib/failureaccess-1.0.1.jar:/opt/openfire/lib/guava-32.0.1-jre.jar:/opt/openfire/lib/hsqldb-2.7.1.jar:/opt/openfire/lib/httpclient-4.5.13.jar:/opt/openfire/lib/httpcore-4.4.13.jar:/opt/openfire/lib/i18n-5.0.2.jar:/opt/openfire/lib/imageio-bmp-3.9.4.jar:/opt/openfire/lib/imageio-core-3.9.4.jar:/opt/openfire/lib/istack-commons-runtime-3.0.11.jar:/opt/openfire/lib/j2objc-annotations-2.8.jar:/opt/openfire/lib/jakarta.activation-1.2.2.jar:/opt/openfire/lib/jakarta.annotation-api-1.3.5.jar:/opt/openfire/lib/jakarta.transaction-api-1.3.3.jar:/opt/openfire/lib/jakarta.xml.bind-api-2.3.3.jar:/opt/openfire/lib/jansi-1.18.jar:/opt/openfire/lib/javax.activation-api-1.2.0.jar:/opt/openfire/lib/javax.mail-1.6.2.jar:/opt/openfire/lib/jaxb-api-2.3.1.jar:/opt/openfire/lib/jaxb-runtime-2.3.3.jar:/opt/openfire/lib/jaxen-1.2.0.jar:/opt/openfire/lib/jcip-annotations-1.0.jar:/opt/openfire/lib/jcl-over-slf4j-2.0.9.jar:/opt/openfire/lib/jetty-ee-12.0.24.jar:/opt/openfire/lib/jetty-ee8-annotations-12.0.24.jar:/opt/openfire/lib/jetty-ee8-apache-jsp-12.0.24.jar:/opt/openfire/lib/jetty-ee8-nested-12.0.24.jar:/opt/openfire/lib/jetty-ee8-plus-12.0.24.jar:/opt/openfire/lib/jetty-ee8-security-12.0.24.jar:/opt/openfire/lib/jetty-ee8-servlet-12.0.24.jar:/opt/openfire/lib/jetty-ee8-webapp-12.0.24.jar:/opt/openfire/lib/jetty-ee8-websocket-jetty-api-12.0.24.jar:/opt/openfire/lib/jetty-ee8-websocket-jetty-common-12.0.24.jar:/opt/openfire/lib/jetty-ee8-websocket-jetty-server-12.0.24.jar:/opt/openfire/lib/jetty-ee8-websocket-servlet-12.0.24.jar:/opt/openfire/lib/jetty-http-12.0.24.jar:/opt/openfire/lib/jetty-io-12.0.24.jar:/opt/openfire/lib/jetty-jmx-12.0.24.jar:/opt/openfire/lib/jetty-jndi-12.0.24.jar:/opt/openfire/lib/jetty-plus-12.0.24.jar:/opt/openfire/lib/jetty-security-12.0.24.jar:/opt/openfire/lib/jetty-server-12.0.24.jar:/opt/openfire/lib/jetty-servlet-api-4.0.6.jar:/opt/openfire/lib/jetty-session-12.0.24.jar:/opt/openfire/lib/jetty-util-12.0.24.jar:/opt/openfire/lib/jetty-websocket-core-common-12.0.24.jar:/opt/openfire/lib/jetty-websocket-core-server-12.0.24.jar:/opt/openfire/lib/jetty-xml-12.0.24.jar:/opt/openfire/lib/jmdns-1.0.jar:/opt/openfire/lib/jsmpp-2.3.10.jar:/opt/openfire/lib/json-20231013.jar:/opt/openfire/lib/jspecify-1.0.0.jar:/opt/openfire/lib/jsr305-3.0.2.jar:/opt/openfire/lib/jtds-1.3.1.jar:/opt/openfire/lib/jzlib-1.1.3.jar:/opt/openfire/lib/libidn-1.35.jar:/opt/openfire/lib/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar:/opt/openfire/lib/log4j-api-2.20.0.jar:/opt/openfire/lib/log4j-core-2.20.0.jar:/opt/openfire/lib/log4j-slf4j2-impl-2.20.0.jar:/opt/openfire/lib/mssql-jdbc-9.4.1.jre11.jar:/opt/openfire/lib/mysql-connector-j-8.2.0.jar:/opt/openfire/lib/netty-all-4.1.118.Final.jar:/opt/openfire/lib/netty-buffer-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-dns-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-haproxy-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-http2-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-http-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-memcache-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-mqtt-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-redis-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-smtp-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-socks-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-stomp-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-xml-4.1.118.Final.jar:/opt/openfire/lib/netty-common-4.1.118.Final.jar:/opt/openfire/lib/netty-handler-4.1.118.Final.jar:/opt/openfire/lib/netty-handler-proxy-4.1.118.Final.jar:/opt/openfire/lib/netty-handler-ssl-ocsp-4.1.118.Final.jar:/opt/openfire/lib/netty-resolver-4.1.118.Final.jar:/opt/openfire/lib/netty-resolver-dns-4.1.118.Final.jar:/opt/openfire/lib/netty-resolver-dns-classes-macos-4.1.118.Final.jar:/opt/openfire/lib/netty-resolver-dns-native-macos-4.1.118.Final-osx-aarch_64.jar:/opt/openfire/lib/netty-resolver-dns-native-macos-4.1.118.Final-osx-x86_64.jar:/opt/openfire/lib/netty-transport-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-classes-epoll-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-classes-kqueue-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-native-epoll-4.1.118.Final-linux-aarch_64.jar:/opt/openfire/lib/netty-transport-native-epoll-4.1.118.Final-linux-riscv64.jar:/opt/openfire/lib/netty-transport-native-epoll-4.1.118.Final-linux-x86_64.jar:/opt/openfire/lib/netty-transport-native-kqueue-4.1.118.Final-osx-aarch_64.jar:/opt/openfire/lib/netty-transport-native-kqueue-4.1.118.Final-osx-x86_64.jar:/opt/openfire/lib/netty-transport-native-unix-common-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-rxtx-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-sctp-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-udt-4.1.118.Final.jar:/opt/openfire/lib/ojdbc11-23.7.0.25.01.jar:/opt/openfire/lib/ons-23.7.0.25.01.jar:/opt/openfire/lib/oraclepki-23.7.0.25.01.jar:/opt/openfire/lib/orai18n-23.7.0.25.01.jar:/opt/openfire/lib/postgresql-42.7.7.jar:/opt/openfire/lib/rsi-23.7.0.25.01.jar:/opt/openfire/lib/shaj-0.5.jar:/opt/openfire/lib/simplefan-23.7.0.25.01.jar:/opt/openfire/lib/sitemesh-2.5.0.jar:/opt/openfire/lib/slf4j-api-2.0.9.jar:/opt/openfire/lib/startup.jar:/opt/openfire/lib/taglibs-standard-impl-1.2.5.jar:/opt/openfire/lib/taglibs-standard-spec-1.2.5.jar:/opt/openfire/lib/tinder-2.1.0.jar:/opt/openfire/lib/txw2-2.3.3.jar:/opt/openfire/lib/ucp-23.7.0.25.01.jar:/opt/openfire/lib/xdb-23.7.0.25.01.jar:/opt/openfire/lib/xmppserver-5.0.2.jar:/opt/openfire/lib/xpp3-1.1.4c.0.jar Starting OpenFire... OpenFire started (PID 1108946) Check logs: tail -f /opt/openfire/logs/nohup.out [root@yfw system]# echo "查看日志: tail -f $OPENFIRE_HOME/logs/nohup.out" 查看日志: tail -f /opt/openfire/logs/nohup.out [root@yfw system]# tail -f /opt/openfire/logs/nohup.out at java.base/java.lang.reflect.ReflectAccess.newInstance(ReflectAccess.java:128) at java.base/jdk.internal.reflect.ReflectionFactory.newInstance(ReflectionFactory.java:347) at java.base/java.lang.Class.newInstance(Class.java:645) at org.jivesoftware.openfire.starter.ServerStarter.start(ServerStarter.java:92) at org.jivesoftware.openfire.starter.ServerStarter.main(ServerStarter.java:56) Caused by: java.sql.SQLException: ConnectionManager.getConnection() failed to obtain a connection after 11 attempts. The exception from the last attempt is as follows: java.sql.SQLException: Check JDBC properties; data source was not be initialised at org.jivesoftware.database.DbConnectionManager.getConnection(DbConnectionManager.java:204) at org.jivesoftware.openfire.XMPPServer.verifyDataSource(XMPPServer.java:1010) ... 11 more Error starting the server. Please check the log files for more information.
11-16
[root@yfw ~]# cd /etc/systemd/system [root@yfw system]# sudo rm /opt/openfire/lib/mysql-connector-j-8.2.0.jar rm: cannot remove '/opt/openfire/lib/mysql-connector-j-8.2.0.jar': No such file or directory [root@yfw system]# ls -l /opt/openfire/conf/database.properties -rw-r--r-- 1 openfire openfire 405 Nov 15 12:41 /opt/openfire/conf/database.properties [root@yfw system]# pkill -f openfire [root@yfw system]# [root@yfw system]# sudo rm -rf /opt/openfire/work/* [root@yfw system]# sudo rm -rf /opt/openfire/temp/* [root@yfw system]# cat /opt/openfire/conf/openfire.xml <?xml version="1.0" encoding="UTF-8"?> <jive> <adminConsole> <port>9090</port> <securePort>9091</securePort> </adminConsole> <locale>en</locale> <setup>true</setup> </jive> [root@yfw system]# /opt/openfire/bin/start.sh Using Java: /usr/lib/jvm/java-17-openjdk/bin/java Java Version: openjdk version "17.0.1" 2021-10-19 LTS OpenJDK Runtime Environment 21.9 (build 17.0.1+12-LTS) OpenJDK 64-Bit Server VM 21.9 (build 17.0.1+12-LTS, mixed mode, sharing) Classpath: /opt/openfire/lib/activation-1.1.jar:/opt/openfire/lib/apache-el-9.0.107.jar:/opt/openfire/lib/apache-jsp-9.0.107.jar:/opt/openfire/lib/asm-9.8.jar:/opt/openfire/lib/asm-commons-9.8.jar:/opt/openfire/lib/asm-tree-9.8.jar:/opt/openfire/lib/bcpg-jdk18on-1.78.1.jar:/opt/openfire/lib/bcpkix-jdk18on-1.78.1.jar:/opt/openfire/lib/bcprov-jdk18on-1.78.1.jar:/opt/openfire/lib/bcutil-jdk18on-1.78.1.jar:/opt/openfire/lib/caffeine-3.2.0.jar:/opt/openfire/lib/checker-qual-3.33.0.jar:/opt/openfire/lib/common-image-3.9.4.jar:/opt/openfire/lib/common-io-3.9.4.jar:/opt/openfire/lib/common-lang-3.9.4.jar:/opt/openfire/lib/commons-codec-1.15.jar:/opt/openfire/lib/commons-dbcp2-2.9.0.jar:/opt/openfire/lib/commons-ip-math-1.32.jar:/opt/openfire/lib/commons-lang3-3.18.0.jar:/opt/openfire/lib/commons-logging-1.2.jar:/opt/openfire/lib/commons-pool2-2.9.0.jar:/opt/openfire/lib/commons-text-1.10.0.jar:/opt/openfire/lib/dom4j-2.1.4.jar:/opt/openfire/lib/dwr-3.0.2-RELEASE.jar:/opt/openfire/lib/ecj-3.33.0.jar:/opt/openfire/lib/error_prone_annotations-2.18.0.jar:/opt/openfire/lib/failureaccess-1.0.1.jar:/opt/openfire/lib/guava-32.0.1-jre.jar:/opt/openfire/lib/hsqldb-2.7.1.jar:/opt/openfire/lib/httpclient-4.5.13.jar:/opt/openfire/lib/httpcore-4.4.13.jar:/opt/openfire/lib/i18n-5.0.2.jar:/opt/openfire/lib/imageio-bmp-3.9.4.jar:/opt/openfire/lib/imageio-core-3.9.4.jar:/opt/openfire/lib/istack-commons-runtime-3.0.11.jar:/opt/openfire/lib/j2objc-annotations-2.8.jar:/opt/openfire/lib/jakarta.activation-1.2.2.jar:/opt/openfire/lib/jakarta.annotation-api-1.3.5.jar:/opt/openfire/lib/jakarta.transaction-api-1.3.3.jar:/opt/openfire/lib/jakarta.xml.bind-api-2.3.3.jar:/opt/openfire/lib/jansi-1.18.jar:/opt/openfire/lib/javax.activation-api-1.2.0.jar:/opt/openfire/lib/javax.mail-1.6.2.jar:/opt/openfire/lib/jaxb-api-2.3.1.jar:/opt/openfire/lib/jaxb-runtime-2.3.3.jar:/opt/openfire/lib/jaxen-1.2.0.jar:/opt/openfire/lib/jcip-annotations-1.0.jar:/opt/openfire/lib/jcl-over-slf4j-2.0.9.jar:/opt/openfire/lib/jetty-ee-12.0.24.jar:/opt/openfire/lib/jetty-ee8-annotations-12.0.24.jar:/opt/openfire/lib/jetty-ee8-apache-jsp-12.0.24.jar:/opt/openfire/lib/jetty-ee8-nested-12.0.24.jar:/opt/openfire/lib/jetty-ee8-plus-12.0.24.jar:/opt/openfire/lib/jetty-ee8-security-12.0.24.jar:/opt/openfire/lib/jetty-ee8-servlet-12.0.24.jar:/opt/openfire/lib/jetty-ee8-webapp-12.0.24.jar:/opt/openfire/lib/jetty-ee8-websocket-jetty-api-12.0.24.jar:/opt/openfire/lib/jetty-ee8-websocket-jetty-common-12.0.24.jar:/opt/openfire/lib/jetty-ee8-websocket-jetty-server-12.0.24.jar:/opt/openfire/lib/jetty-ee8-websocket-servlet-12.0.24.jar:/opt/openfire/lib/jetty-http-12.0.24.jar:/opt/openfire/lib/jetty-io-12.0.24.jar:/opt/openfire/lib/jetty-jmx-12.0.24.jar:/opt/openfire/lib/jetty-jndi-12.0.24.jar:/opt/openfire/lib/jetty-plus-12.0.24.jar:/opt/openfire/lib/jetty-security-12.0.24.jar:/opt/openfire/lib/jetty-server-12.0.24.jar:/opt/openfire/lib/jetty-servlet-api-4.0.6.jar:/opt/openfire/lib/jetty-session-12.0.24.jar:/opt/openfire/lib/jetty-util-12.0.24.jar:/opt/openfire/lib/jetty-websocket-core-common-12.0.24.jar:/opt/openfire/lib/jetty-websocket-core-server-12.0.24.jar:/opt/openfire/lib/jetty-xml-12.0.24.jar:/opt/openfire/lib/jmdns-1.0.jar:/opt/openfire/lib/jsmpp-2.3.10.jar:/opt/openfire/lib/json-20231013.jar:/opt/openfire/lib/jspecify-1.0.0.jar:/opt/openfire/lib/jsr305-3.0.2.jar:/opt/openfire/lib/jtds-1.3.1.jar:/opt/openfire/lib/jzlib-1.1.3.jar:/opt/openfire/lib/libidn-1.35.jar:/opt/openfire/lib/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar:/opt/openfire/lib/log4j-api-2.20.0.jar:/opt/openfire/lib/log4j-core-2.20.0.jar:/opt/openfire/lib/log4j-slf4j2-impl-2.20.0.jar:/opt/openfire/lib/mssql-jdbc-9.4.1.jre11.jar:/opt/openfire/lib/mysql-connector-java-5.1.49.jar:/opt/openfire/lib/netty-all-4.1.118.Final.jar:/opt/openfire/lib/netty-buffer-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-dns-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-haproxy-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-http2-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-http-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-memcache-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-mqtt-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-redis-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-smtp-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-socks-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-stomp-4.1.118.Final.jar:/opt/openfire/lib/netty-codec-xml-4.1.118.Final.jar:/opt/openfire/lib/netty-common-4.1.118.Final.jar:/opt/openfire/lib/netty-handler-4.1.118.Final.jar:/opt/openfire/lib/netty-handler-proxy-4.1.118.Final.jar:/opt/openfire/lib/netty-handler-ssl-ocsp-4.1.118.Final.jar:/opt/openfire/lib/netty-resolver-4.1.118.Final.jar:/opt/openfire/lib/netty-resolver-dns-4.1.118.Final.jar:/opt/openfire/lib/netty-resolver-dns-classes-macos-4.1.118.Final.jar:/opt/openfire/lib/netty-resolver-dns-native-macos-4.1.118.Final-osx-aarch_64.jar:/opt/openfire/lib/netty-resolver-dns-native-macos-4.1.118.Final-osx-x86_64.jar:/opt/openfire/lib/netty-transport-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-classes-epoll-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-classes-kqueue-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-native-epoll-4.1.118.Final-linux-aarch_64.jar:/opt/openfire/lib/netty-transport-native-epoll-4.1.118.Final-linux-riscv64.jar:/opt/openfire/lib/netty-transport-native-epoll-4.1.118.Final-linux-x86_64.jar:/opt/openfire/lib/netty-transport-native-kqueue-4.1.118.Final-osx-aarch_64.jar:/opt/openfire/lib/netty-transport-native-kqueue-4.1.118.Final-osx-x86_64.jar:/opt/openfire/lib/netty-transport-native-unix-common-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-rxtx-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-sctp-4.1.118.Final.jar:/opt/openfire/lib/netty-transport-udt-4.1.118.Final.jar:/opt/openfire/lib/ojdbc11-23.7.0.25.01.jar:/opt/openfire/lib/ons-23.7.0.25.01.jar:/opt/openfire/lib/oraclepki-23.7.0.25.01.jar:/opt/openfire/lib/orai18n-23.7.0.25.01.jar:/opt/openfire/lib/postgresql-42.7.7.jar:/opt/openfire/lib/rsi-23.7.0.25.01.jar:/opt/openfire/lib/shaj-0.5.jar:/opt/openfire/lib/simplefan-23.7.0.25.01.jar:/opt/openfire/lib/sitemesh-2.5.0.jar:/opt/openfire/lib/slf4j-api-2.0.9.jar:/opt/openfire/lib/startup.jar:/opt/openfire/lib/taglibs-standard-impl-1.2.5.jar:/opt/openfire/lib/taglibs-standard-spec-1.2.5.jar:/opt/openfire/lib/tinder-2.1.0.jar:/opt/openfire/lib/txw2-2.3.3.jar:/opt/openfire/lib/ucp-23.7.0.25.01.jar:/opt/openfire/lib/xdb-23.7.0.25.01.jar:/opt/openfire/lib/xmppserver-5.0.2.jar:/opt/openfire/lib/xpp3-1.1.4c.0.jar Starting OpenFire... OpenFire started (PID 1129553) Check logs: tail -f /opt/openfire/logs/nohup.out [root@yfw system]# [root@yfw system]# # 实时观察日志 [root@yfw system]# tail -f /opt/openfire/logs/nohup.out DEBUG: User = openfire DEBUG: Current dir = /opt/openfire DEBUG: OPENFIRE_HOME = /opt/openfire DEBUG: Java executable = /usr/lib/jvm/java-17-openjdk/bin/java openjdk version "17.0.1" 2021-10-19 LTS OpenJDK Runtime Environment 21.9 (build 17.0.1+12-LTS) OpenJDK 64-Bit Server VM 21.9 (build 17.0.1+12-LTS, mixed mode, sharing) DEBUG: Launching OpenFire... Database setup or configuration error: Please verify your database settings and check the logs/openfire.log file for detailed error messages. java.lang.IllegalArgumentException: java.sql.SQLException: ConnectionManager.getConnection() failed to obtain a connection after 11 attempts. The exception from the last attempt is as follows: java.sql.SQLException: Check JDBC properties; data source was not be initialised at org.jivesoftware.openfire.XMPPServer.verifyDataSource(XMPPServer.java:1020) at org.jivesoftware.openfire.XMPPServer.start(XMPPServer.java:666) at org.jivesoftware.openfire.XMPPServer.<init>(XMPPServer.java:221) at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77) at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499) at java.base/java.lang.reflect.ReflectAccess.newInstance(ReflectAccess.java:128) at java.base/jdk.internal.reflect.ReflectionFactory.newInstance(ReflectionFactory.java:347) at java.base/java.lang.Class.newInstance(Class.java:645) at org.jivesoftware.openfire.starter.ServerStarter.start(ServerStarter.java:92) at org.jivesoftware.openfire.starter.ServerStarter.main(ServerStarter.java:56) Caused by: java.sql.SQLException: ConnectionManager.getConnection() failed to obtain a connection after 11 attempts. The exception from the last attempt is as follows: java.sql.SQLException: Check JDBC properties; data source was not be initialised at org.jivesoftware.database.DbConnectionManager.getConnection(DbConnectionManager.java:204) at org.jivesoftware.openfire.XMPPServer.verifyDataSource(XMPPServer.java:1010) ... 11 more Error starting the server. Please check the log files for more information.
最新发布
11-16
帮我检查我的context.xml文件有什么问题吗,为啥重启服务报错<?xml version="1.0" encoding="UTF-8"?> <!-- Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. --><!-- The contents of this file will be loaded for each web application --><Context> <!-- Default set of monitored resources. If one of these changes, the --> <!-- web application will be reloaded. --> <WatchedResource>WEB-INF/web.xml</WatchedResource> <WatchedResource>${catalina.base}/conf/web.xml</WatchedResource> <!-- Uncomment this to disable session persistence across Tomcat restarts --> <!-- <Manager pathname="" /> --> <!-- <Resource auth="Container" driverClassName="com.mysql.jdbc.Driver" factory="aia.encrypt.EncryptedDataSourceFactory" name="jdbc/ibotWrite" password="MHTV7bXwrOX6rWFVdkJ8cA==" type="javax.sql.DataSource" url="jdbc:mysql://10.200.11.14:3306/ibot?characterEncoding=utf-8&autoReconnect=true&useSSL=false&rewriteBatchedStatements=true" username="sid_rob_dev"/> <Resource auth="Container" driverClassName="com.mysql.jdbc.Driver" factory="aia.encrypt.EncryptedDataSourceFactory" name="jdbc/ibotRead" password="MHTV7bXwrOX6rWFVdkJ8cA==" type="javax.sql.DataSource" url="jdbc:mysql://10.200.11.14:3306/ibot?characterEncoding=utf-8&autoReconnect=true&useSSL=false&rewriteBatchedStatements=true" username="sid_rob_dev"/> --> <Resource auth="Container" driverClassName="com.mysql.jdbc.Driver" factory="aia.encrypt.EncryptedDataSourceFactory" name="jdbc/ibotWrite" password="1E6AaBTvL4gewmlGQzSr7A==" type="javax.sql.DataSource" url="jdbc:mysql://aclsh-sit-pdb-sdi-rw.rwlb.rds.aliyuncs.com:3306/ibot?characterEncoding=utf-8&autoReconnect=true&useSSL=false&rewriteBatchedStatements=true" username="sid_pdb_rob_sit"/> <Resource auth="Container" driverClassName="com.mysql.jdbc.Driver" factory="aia.encrypt.EncryptedDataSourceFactory" name="jdbc/ibotRead" password="1E6AaBTvL4gewmlGQzSr7A==" type="javax.sql.DataSource" url="jdbc:mysql://aclsh-sit-pdb-sdi-rw.rwlb.rds.aliyuncs.com:3306/ibot?characterEncoding=utf-8&autoReconnect=true&useSSL=false&rewriteBatchedStatements=true" username="sid_pdb_rob_sit"/> <!--ICSP--> <Resource auth="Container" driverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver" factory="aia.encrypt.EncryptedDataSourceFactory" name="jdbc/icsp_ngs" password="BvnrCQlhRWLIMGBgxWARbg==" type="javax.sql.DataSource" url="jdbc:sqlserver://chot3r8csts02.aia.biz:1433;DatabaseName=ICSP;sendStringParametersAsUnicode=false" username="STCAOICSP" maxActive="100" minIdle="1" validationQuery = "select 1" /> <!--NB Sourth DB --> <Resource auth="Container" driverClassName="com.ibm.as400.access.AS400JDBCDriver" factory="aia.encrypt.EncryptedDataSourceFactory" name="jdbc/iRobot_NBS" password="b0sla9+mB+bC4tdKr8VV0A==" type="javax.sql.DataSource" url="jdbc:as400://aiash.aia.biz;naming=system" username="UCAOST" maxTotal="100" maxIdle="10" maxWait="-1" testWhileIdle="true" timeBetweenEvictionRuns="360000" minEvictableIdleTimeMillis="720000" testOnBorrow="true"/> <!--NB North DB--> <Resource auth="Container" driverClassName="com.ibm.as400.access.AS400JDBCDriver" factory="aia.encrypt.EncryptedDataSourceFactory" name="jdbc/iRobot_NBN" password="F1vOGpVuPJ5yHQH5SDIifQ==" type="javax.sql.DataSource" url="jdbc:as400://aiash.aia.biz;naming=system" username="UCAONT" maxTotal="100" maxIdle="10" maxWait="-1" testWhileIdle="true" timeBetweenEvictionRuns="360000" minEvictableIdleTimeMillis="720000" testOnBorrow="true"/> </Context>
08-13
解释让文件路径的方法正常运行:package main import "github.com/gin-gonic/gin" func main() { r := gin.Default() //r.LoadHTMLGlob("templates/*")//这样引用,需在相对路径下(终端中调至) //r.LoadHTMLGlob("response/templates/*") //可直接运行 //文件路径,加载单个 r.LoadHTMLFiles("response/template/index.html") //r.LoadHTMLFile(nse/templates/index.html") r.GET("/", func(c *gin.Context) { c.HTML(200, "index.html", map[string]any{ "title": "hanhanhahahahahha", }) }) r.Run(":8080") } ,运行结果:GOROOT=D:\soft\go\go1.24.5 #gosetup GOPATH=C:\Users\32312\go #gosetup D:\soft\go\go1.24.5\bin\go.exe build -o C:\Users\32312\AppData\Local\JetBrains\GoLand2025.1\tmp\GoLand\___go_build_2_html_go.exe D:\go_project\gin_study\response\2.响应html.go #gosetup C:\Users\32312\AppData\Local\JetBrains\GoLand2025.1\tmp\GoLand\___go_build_2_html_go.exe #gosetup [GIN-debug] [WARNING] Creating an Engine instance with the Logger and Recovery middleware already attached. [GIN-debug] [WARNING] Running in "debug" mode. Switch to "release" mode in production. - using env: export GIN_MODE=release - using code: gin.SetMode(gin.ReleaseMode) [GIN-debug] GET / --> main.main.func1 (3 handlers) [GIN-debug] [WARNING] You trusted all proxies, this is NOT safe. We recommend you to set a value. Please check https://pkg.go.dev/github.com/gin-gonic/gin#readme-don-t-trust-all-proxies for details. [GIN-debug] Listening and serving HTTP on :8080 2025/08/10 16:15:04 [Recovery] 2025/08/10 - 16:15:04 panic recovered: GET / HTTP/1.1 Host: 127.0.0.1:8080 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7 Accept-Encoding: gzip, deflate, br, zstd Accept-Language: zh-CN,zh;q=0.9,en;q=0.8,en-GB;q=0.7,en-US;q=0.6 Cache-Control: max-age=0 Connection: keep-alive Sec-Ch-Ua: "Not;A=Brand";v="99", "Microsoft Edge";v="139", "Chromium";v="139" Sec-Ch-Ua-Mobile: ?0 Sec-Ch-Ua-Platform: "Windows" Sec-Fetch-Dest: document Sec-Fetch-Mode: navigate Sec-Fetch-Site: none Sec-Fetch-User: ?1 Upgrade-Insecure-Requests: 1 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/139.0.0.0 Safari/537.36 Edg/139.0.0.0 open gin_study/response/templates/index.html: The system cannot find the path specified. D:/soft/go/go1.24.5/src/html/template/template.go:368 (0xcd90fe) Must: panic(err) C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/render/html.go:71 (0xcd8f25) HTMLDebug.loadTemplate: return template.Must(template.New("").Delims(r.Delims.Left, r.Delims.Right).Funcs(r.FuncMap).ParseFiles(r.Files...)) C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/render/html.go:61 (0xcdc077) HTMLDebug.Instance: Template: r.loadTemplate(), C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/context.go:971 (0xd0e1cd) (*Context).HTML: instance := c.engine.HTMLRender.Instance(name, obj) D:/go_project/gin_study/response/2.响应html.go:15 (0xd209ec) main.func1: c.HTML(200, "index.html", map[string]any{ C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/context.go:185 (0xd1758e) (*Context).Next: c.handlers[c.index](c) C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/recovery.go:102 (0xd1757b) CustomRecoveryWithWriter.func1: c.Next() C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/context.go:185 (0xd166c4) (*Context).Next: c.handlers[c.index](c) C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/logger.go:249 (0xd166ab) LoggerWithConfig.func1: c.Next() C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/context.go:185 (0xd15b11) (*Context).Next: c.handlers[c.index](c) C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/gin.go:644 (0xd155a0) (*Engine).handleHTTPRequest: c.Next() C:/Users/32312/go/pkg/mod/github.com/gin-gonic/gin@v1.10.1/gin.go:600 (0xd150c9) (*Engine).ServeHTTP: engine.handleHTTPRequest(c) D:/soft/go/go1.24.5/src/net/http/server.go:3301 (0xaeceed) serverHandler.ServeHTTP: handler.ServeHTTP(rw, req) D:/soft/go/go1.24.5/src/net/http/server.go:2102 (0xaddc64) (*conn).serve: serverHandler{c.server}.ServeHTTP(w, w.req) D:/soft/go/go1.24.5/src/runtime/asm_amd64.s:1700 (0x89b400) goexit: BYTE $0x90 // NOP [GIN] 2025/08/10 - 16:15:04 | 500 | 22.5977ms | 127.0.0.1 | GET "/"
08-12
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值