Several errors when starting server

Post here your questions about SFS2X. Here we discuss all server-side matters. For client API questions see the dedicated forums.

Moderators: Lapo, Bax

User avatar
Jihaysse
Posts: 11
Joined: 28 Aug 2021, 12:23

Several errors when starting server

Postby Jihaysse » 16 Oct 2021, 22:06

Hello,
I've finally decided to dive into learning SFS (which looks amazing btw!) but I'm running into an issue.
I've downloaded SFS and ran it (tried as Admin too) but every time my console prints this:

Code: Select all

GRAVE: Echec d'initialisation du composant [Connector[HTTP/1.1-8080]]
org.apache.catalina.LifecycleException: L'initialisation du gestionnaire de protocole a ├®chou├®
        at org.apache.catalina.connector.Connector.initInternal(Connector.java:983)
        at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:136)
        at org.apache.catalina.core.StandardService.initInternal(StandardService.java:533)
        at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:136)
        at org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:1059)
        at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:136)
        at org.apache.catalina.startup.Catalina.load(Catalina.java:584)
        at org.apache.catalina.startup.Catalina.load(Catalina.java:607)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:304)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:474)
        at com.smartfoxserver.v2.http.TomcatServer.start(TomcatServer.java:43)
        at com.smartfoxserver.v2.SmartFoxServer$1.run(SmartFoxServer.java:343)
        at java.lang.Thread.run(Thread.java:748)
Caused by: java.net.BindException: Address already in use: bind
        at sun.nio.ch.Net.bind0(Native Method)
        at sun.nio.ch.Net.bind(Net.java:433)
        at sun.nio.ch.Net.bind(Net.java:425)
        at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223)
        at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
        at org.apache.tomcat.util.net.NioEndpoint.initServerSocket(NioEndpoint.java:230)
        at org.apache.tomcat.util.net.NioEndpoint.bind(NioEndpoint.java:213)
        at org.apache.tomcat.util.net.AbstractEndpoint.bindWithCleanup(AbstractEndpoint.java:1124)
        at org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:1137)
        at org.apache.coyote.AbstractProtocol.init(AbstractProtocol.java:574)
        at org.apache.coyote.http11.AbstractHttp11Protocol.init(AbstractHttp11Protocol.java:74)
        at org.apache.catalina.connector.Connector.initInternal(Connector.java:980)
        ... 16 more


Code: Select all

GRAVE: Impossible de cr├®er le sokcet d'arr├¬t du serveur ├á l'adresse [localhost] et au port [8005] (port de base [8005] et offset [0])java.net.BindException: Address already in use: JVM_Bind
        at java.net.DualStackPlainSocketImpl.bind0(Native Method)
        at java.net.DualStackPlainSocketImpl.socketBind(DualStackPlainSocketImpl.java:106)
        at java.net.AbstractPlainSocketImpl.bind(AbstractPlainSocketImpl.java:387)
        at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:190)
        at java.net.ServerSocket.bind(ServerSocket.java:390)
        at java.net.ServerSocket.<init>(ServerSocket.java:252)
        at org.apache.catalina.core.StandardServer.await(StandardServer.java:584)
        at org.apache.catalina.startup.Catalina.await(Catalina.java:721)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:667)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:344)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:475)
        at com.smartfoxserver.v2.http.TomcatServer.start(TomcatServer.java:43)
        at com.smartfoxserver.v2.SmartFoxServer$1.run(SmartFoxServer.java:343)
        at java.lang.Thread.run(Thread.java:748)

oct. 16, 2021 11:46:34 PM org.apache.coyote.AbstractProtocol pause
INFOS: Le gestionnaire de protocole ["http-nio-8080"] est mis en pause
oct. 16, 2021 11:46:34 PM org.apache.coyote.AbstractProtocol pause
INFOS: Le gestionnaire de protocole ["https-jsse-nio-8443"] est mis en pause
oct. 16, 2021 11:46:34 PM org.apache.catalina.core.StandardService stopInternal
INFOS: Arrêt du service [Catalina]
oct. 16, 2021 11:46:34 PM org.apache.coyote.AbstractProtocol stop
INFOS: Arrêt du gestionnaire de protocole ["http-nio-8080"]
oct. 16, 2021 11:46:34 PM org.apache.coyote.AbstractProtocol destroy
INFOS: Destruction du gestionnaire de protocole ["http-nio-8080"]
oct. 16, 2021 11:46:34 PM org.apache.coyote.AbstractProtocol stop
INFOS: Arrêt du gestionnaire de protocole ["https-jsse-nio-8443"]
oct. 16, 2021 11:46:34 PM org.apache.coyote.AbstractProtocol destroy
INFOS: Destruction du gestionnaire de protocole ["https-jsse-nio-8443"]


Here is the last log in boot.log:
16 oct. 2021 | 23:46:20,069 | INFO | main | bootLogger | | SmartFoxServer 2X
16 oct. 2021 | 23:46:20,070 | INFO | main | bootLogger | | BitSwarmEngine version: 3.71.0 { main }
16 oct. 2021 | 23:46:20,071 | INFO | main | bootLogger | | System Info:
Processor(s): 16
VM Max. memory: 3786MB
os.name: Windows 10
os.arch: amd64
os.version: 10.0
java.version: 1.8.0_232
java.vendor: AdoptOpenJDK
java.vendor.url: http://java.oracle.com/
java.vm.specification.version: 1.8
java.vm.version: 25.232-b09
java.vm.vendor:
java.vm.name: OpenJDK 64-Bit Server VM
java.io.tmpdir: C:\Users\jsseg\AppData\Local\Temp\
Default charset: UTF-8

16 oct. 2021 | 23:46:20,144 | INFO | main | bootLogger | | Network Info:
Card: Software Loopback Interface 1
->127.0.0.1
->0:0:0:0:0:0:0:1
Card: Microsoft 6to4 Adapter
Card: Bluetooth Device (Personal Area Network)
->fe80:0:0:0:c0e7:2993:96de:f9f2%eth0
Card: WAN Miniport (IPv6)
Card: Microsoft IP-HTTPS Platform Adapter
Card: WAN Miniport (PPTP)
Card: Realtek RTL8852AE WiFi 6 802.11ax PCIe Adapter
->192.168.0.31
->2a02:2788:804:1fd:0:0:0:3
->2a02:2788:804:1fd:7d67:8274:928:cdb0
->2a02:2788:804:1fd:5082:8b5c:1f53:3357
->fe80:0:0:0:7d67:8274:928:cdb0%wlan0
Card: WAN Miniport (Network Monitor)
Card: WAN Miniport (PPPOE)
Card: Microsoft Wi-Fi Direct Virtual Adapter #2
->fe80:0:0:0:c1fd:c68a:2266:a663%wlan1
Card: Microsoft Teredo Tunneling Adapter
Card: WAN Miniport (L2TP)
Card: Microsoft Wi-Fi Direct Virtual Adapter
->fe80:0:0:0:9cf6:9eb6:c74b:6f66%wlan2
Card: Realtek PCIe GbE Family Controller
->fe80:0:0:0:a9d1:75c:5cfb:ab18%eth3
Card: Microsoft Kernel Debug Network Adapter
Card: WAN Miniport (SSTP)
Card: WAN Miniport (IP)
Card: WAN Miniport (IKEv2)
Card: Realtek PCIe GbE Family Controller-WFP Native MAC Layer LightWeight Filter-0000
Card: Realtek PCIe GbE Family Controller-QoS Packet Scheduler-0000
Card: Realtek PCIe GbE Family Controller-WFP 802.3 MAC Layer LightWeight Filter-0000
Card: Realtek RTL8852AE WiFi 6 802.11ax PCIe Adapter-WFP Native MAC Layer LightWeight Filter-0000
Card: Realtek RTL8852AE WiFi 6 802.11ax PCIe Adapter-Virtual WiFi Filter Driver-0000
Card: Realtek RTL8852AE WiFi 6 802.11ax PCIe Adapter-Native WiFi Filter Driver-0000
Card: Realtek RTL8852AE WiFi 6 802.11ax PCIe Adapter-QoS Packet Scheduler-0000
Card: Realtek RTL8852AE WiFi 6 802.11ax PCIe Adapter-WFP 802.3 MAC Layer LightWeight Filter-0000
Card: Microsoft Wi-Fi Direct Virtual Adapter-WFP Native MAC Layer LightWeight Filter-0000
Card: Microsoft Wi-Fi Direct Virtual Adapter-Native WiFi Filter Driver-0000
Card: Microsoft Wi-Fi Direct Virtual Adapter-QoS Packet Scheduler-0000
Card: Microsoft Wi-Fi Direct Virtual Adapter-WFP 802.3 MAC Layer LightWeight Filter-0000
Card: WAN Miniport (IP)-WFP Native MAC Layer LightWeight Filter-0000
Card: WAN Miniport (IP)-QoS Packet Scheduler-0000
Card: WAN Miniport (IPv6)-WFP Native MAC Layer LightWeight Filter-0000
Card: WAN Miniport (IPv6)-QoS Packet Scheduler-0000
Card: WAN Miniport (Network Monitor)-WFP Native MAC Layer LightWeight Filter-0000
Card: WAN Miniport (Network Monitor)-QoS Packet Scheduler-0000
Card: Microsoft Wi-Fi Direct Virtual Adapter #2-WFP Native MAC Layer LightWeight Filter-0000
Card: Microsoft Wi-Fi Direct Virtual Adapter #2-Native WiFi Filter Driver-0000
Card: Microsoft Wi-Fi Direct Virtual Adapter #2-QoS Packet Scheduler-0000
Card: Microsoft Wi-Fi Direct Virtual Adapter #2-WFP 802.3 MAC Layer LightWeight Filter-0000

16 oct. 2021 | 23:46:20,148 | INFO | main | bootLogger | | Session manager ready: com.smartfoxserver.bitswarm.sessions.DefaultSessionManager@75437611
16 oct. 2021 | 23:46:20,285 | INFO | main | bootLogger | | TCP Selector opened
16 oct. 2021 | 23:46:20,290 | INFO | main | bootLogger | | UDP Selector opened
16 oct. 2021 | 23:46:20,292 | INFO | main | bootLogger | | AcceptSelector opened
16 oct. 2021 | 23:46:20,292 | INFO | main | bootLogger | | DatagramChannel cache size: 80
16 oct. 2021 | 23:46:20,295 | WARN | main | bootLogger | | Was not able to bind socket: { 0.0.0.0:9933, (Tcp) }
16 oct. 2021 | 23:46:20,302 | INFO | main | bootLogger | | Added bound udp socket --> 127.0.0.1:9933
16 oct. 2021 | 23:46:20,303 | INFO | main | bootLogger | | Controller started: com.smartfoxserver.v2.controllers.v290.SystemReqController
16 oct. 2021 | 23:46:20,303 | INFO | Scheduler1-thread-1 | bootLogger | | Scheduler started: scheduler
16 oct. 2021 | 23:46:20,303 | INFO | main | bootLogger | | Controller started: com.smartfoxserver.v2.controllers.v290.ExtensionReqController
16 oct. 2021 | 23:46:20,303 | INFO | main | bootLogger | | Controller started: com.smartfoxserver.v2.controllers.v290.SmasherReqController
16 oct. 2021 | 23:46:20,304 | INFO | main | bootLogger | | SocketWriter v3 started (TCP pool size: 3, UDP pool size: 3
16 oct. 2021 | 23:46:20,305 | INFO | main | bootLogger | | Security Manager started
16 oct. 2021 | 23:46:20,306 | INFO | main | bootLogger | | DatagramReader started
16 oct. 2021 | 23:46:20,306 | INFO | main | bootLogger | | IOHandler: com.smartfoxserver.v2.protocol.SFSIoHandler@387a8303
16 oct. 2021 | 23:46:20,307 | INFO | main | bootLogger | | SocketReader started
16 oct. 2021 | 23:46:20,307 | INFO | main | bootLogger | | SocketAcceptor initialized
16 oct. 2021 | 23:46:20,307 | INFO | main | bootLogger | | [[[ ===--- Boot sequence complete ---=== ]]]


Should I worry about these errors?
Using telnet localhost 9933 or 8080 works so I guess my ports are open.
EDIT: Quick question, how can I see (and edit) the MMORoomDemo.jar extension? Importing the .jar project into Eclipse IDE doesn't let me read the .java file (only .class that I can't read). Thank you!)

Thank you for your time! I greatly appreciate it.
Kind regards
User avatar
Lapo
Site Admin
Posts: 23008
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: Several errors when starting server

Postby Lapo » 18 Oct 2021, 13:02

Hi,
the two errors are essentially the same and they tell you that Tomcat (the embedded web-server) is not able to bind port 8080.

It looks like SFS2X is already running. Maybe you chose to run the server as a Windows Service, which means that the server is already up and running in the background.

My suggestion is to open a new browser tab and check the address http://localhost:8080, you should see the SFS2X welcome page :)
EDIT: Quick question, how can I see (and edit) the MMORoomDemo.jar extension? Importing the .jar project into Eclipse IDE doesn't let me read the .java file (only .class that I can't read). Thank you!)

You need to import the source .java files we provide together with the example.
Create a new Java project in Eclipse, then create a package in the src/ folder matching the one declared in the java file, and finally import the java file in that package.

Cheers
Lapo
--
gotoAndPlay()
...addicted to flash games

Return to “SFS2X Questions”

Who is online

Users browsing this forum: Google [Bot], Thomasea and 53 guests