Smartfox restart issue

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

Moderators: Lapo, Bax

fSid
Posts: 2
Joined: 11 Apr 2012, 13:19

Smartfox restart issue

Postby fSid » 11 Apr 2012, 13:29

Hi,

I have installed SFS2x on a linux system but it doesn't restart when I restart it using the admin panel. I have to manually launch SFS again. Same problem is coming on my local server, the server don't restart and I have to start the standalone service.

Can someone help in resolving the issue?
User avatar
rjgtav
Posts: 2813
Joined: 19 Apr 2009, 11:31
Location: Lisbon, Portugal

Re: Smartfox restart issue

Postby rjgtav » 11 Apr 2012, 16:41

Hello.
Please first make sure that you're running the latest SFS2X Final Release 2.0.1. Does the server boot correctly for the first time? If so, please check for any error in the boot logs from the server (from the smartflox.log file under [SFS2X Installation Folder]\SFS2X\logs) when you try to restart it.
Skills: SFS Pro, SFS2X, AS2.0/AS3.0, Java, HTML5/CSS3/JS, C#
Portfolio: https://rjgtav.wordpress.com/
SFS Tutorials: http://sfs-tutor.blogspot.com/ - Discontinued. Some examples may be bugged.
fSid
Posts: 2
Joined: 11 Apr 2012, 13:19

Re: Smartfox restart issue

Postby fSid » 12 Apr 2012, 09:25

I am running the latest version and it starts perfectly if I start the service manually but when I use restart button from admin panel, the server shuts down instead of restarting

This is the last msg in the log file

Code: Select all

03 Apr 2012 | 07:18:44,368 | INFO  | :::SFSRestarter::: | v2.util.SFSRestart |     | Process restarted: java.lang.UNIXProcess@108137c9
03 Apr 2012 | 07:18:48,553 | INFO  | Thread-2 | entities.managers.SFSZoneManager |     | BuddyList saveAll...
03 Apr 2012 | 07:18:48,585 | WARN  | SFS2X ShutdownHook | v2.core.SFSShutdownHook |     | SFS2X is shutting down. The process may take a few seconds...
03 Apr 2012 | 07:18:48,798 | INFO  | Thread-3 | entities.managers.SFSBannedUserManager |     | BanUser data saved.
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: Smartfox restart issue

Postby Lapo » 13 Apr 2012, 10:36

1- what OS do you use exactly?
2- you can restart the server via command line using ./sfs2x-service restart

thanks
Lapo
--
gotoAndPlay()
...addicted to flash games
Alekz
Posts: 8
Joined: 24 Oct 2012, 17:43

Re: Smartfox restart issue

Postby Alekz » 06 Nov 2012, 17:12

I'm having the same problem.
And beside it occurs in the restart server, it also occurres when I put a extension extending redbox.
The crappy part is that it's not returning any error messages.
Alekz
Posts: 8
Joined: 24 Oct 2012, 17:43

Re: Smartfox restart issue

Postby Alekz » 06 Nov 2012, 17:32

The problem with the extension I've just fixed, I was forgetting to put the redbox files together with the extension.
The restarting issue I still don't have a clue. And it's only when done by the restart in the admin panel.
User avatar
rjgtav
Posts: 2813
Joined: 19 Apr 2009, 11:31
Location: Lisbon, Portugal

Re: Smartfox restart issue

Postby rjgtav » 06 Nov 2012, 21:30

Hi,

This is a quite old topic. What server version are you running? Have you updated to the latest 2.3.0 patch?
And what OS are you running?
If you restart using the ./sfs2x-service restart command, as suggested by Lapo, does it work with no problems?
Skills: SFS Pro, SFS2X, AS2.0/AS3.0, Java, HTML5/CSS3/JS, C#
Portfolio: https://rjgtav.wordpress.com/
SFS Tutorials: http://sfs-tutor.blogspot.com/ - Discontinued. Some examples may be bugged.
grookier
Posts: 26
Joined: 28 Sep 2016, 10:40

Re: Smartfox restart issue

Postby grookier » 18 Jul 2019, 11:47

Hello, i know this is a VERY old thread but I find the same problem.

If I restart smartfoxserver from the admin panel I get the following error, and it doesn't restart:

Code: Select all

18 Jul 2019 | 13:40:07,109 | INFO  | SFSWorker:Ext:1 | Extensions |     | {Admin}: Restarting SmartFoxServer...
18 Jul 2019 | 13:40:07,110 | WARN  | SFSWorker:Ext:1 | smartfoxserver.v2.SmartFoxServer |     | *** SERVER RESTARTING ***
18 Jul 2019 | 13:40:07,111 | WARN  | SocketWriter-1 | bitswarm.core.SocketWriter |     | SocketWriter thread interrupted: Thread[SocketWriter-1,5,main]
18 Jul 2019 | 13:40:07,111 | WARN  | SocketWriter-2 | bitswarm.core.SocketWriter |     | SocketWriter thread interrupted: Thread[SocketWriter-2,5,main]
18 Jul 2019 | 13:40:07,111 | WARN  | SocketWriter-3 | bitswarm.core.SocketWriter |     | SocketWriter thread interrupted: Thread[SocketWriter-3,5,main]
18 Jul 2019 | 13:40:07,112 | WARN  | SocketReader | bitswarm.core.SocketReader |     | Problems in SocketReader main loop: java.lang.InterruptedException: sleep interrupted, Thread: Thread[SocketReader,5,main]
18 Jul 2019 | 13:40:07,113 | WARN  | SocketReader | bitswarm.core.SocketReader |     | java.lang.InterruptedException: sleep interrupted
   java.lang.Thread.sleep(Native Method)
   com.smartfoxserver.bitswarm.core.SocketReader.run(SocketReader.java:173)
   java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
   java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
   java.lang.Thread.run(Thread.java:748)

18 Jul 2019 | 13:40:10,145 | INFO  | SFSWorker:Ext:1 | bitswarm.sessions.DefaultSessionManager |     | Session removed: { Id: 1, Type: DEFAULT, Logged: Yes, IP: 46.231.38.39:51899 }
18 Jul 2019 | 13:40:10,659 | INFO  | :::SFSRestarter::: | v2.util.SFSRestart |     | Process restarted: java.lang.UNIXProcess@71619915
18 Jul 2019 | 13:40:11,164 | WARN  | SFS2X ShutdownHook | v2.core.SFSShutdownHook |     | SFS2X is shutting down. The process may take a few seconds...
18 Jul 2019 | 13:40:11,165 | INFO  | Thread-2 | entities.managers.SFSZoneManager |     | BuddyList saveAll...
18 Jul 2019 | 13:40:11,173 | INFO  | Thread-3 | entities.managers.SFSBannedUserManager |     | BanUser data saved.



Restarting from the terminal with this command: ./sfs2x-service restart it works correctly.

I'm using SmartFoxServer 2X (2.13.1)
OS Ubuntu 18.04.1 LTS
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: Smartfox restart issue

Postby Lapo » 18 Jul 2019, 14:52

Hi,
the warnings in the logs are expected and they are not indicative of a restart problem.
(Those messages are simply the socket threads shutting down)

Additionally I've tried installing a copy of SFS2X 2.13 on Ubuntu 18.04 and I can't reproduce the issue.
I am starting up the server with ./sfs2x-service start and restarting it via the remote Admin.

Thanks
Lapo

--

gotoAndPlay()

...addicted to flash games
grookier
Posts: 26
Joined: 28 Sep 2016, 10:40

Re: Smartfox restart issue

Postby grookier » 19 Jul 2019, 08:00

So you don't have any advice for me?

I would like to do some tests but I wouldn't know how to do it.

From console the restart works correctly, but doesnt works from admin panel.

I thnk that the same file we use from the console is called from the admin panel, there should be the same problems.

Could it be something related to permits?
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: Smartfox restart issue

Postby Lapo » 19 Jul 2019, 08:46

Hi,
without any specific errors and without the ability to recreate the problem it's not easy to guess what might be going on.

If you are running in a cloud environment I would suggest to try installing SFS2X from scratch on a new virtual server (with the same OS) and see if it works for you, as I've done. If that's the case then maybe there is some specific issue on your current setup, though I can't imagine what it might be.

I thnk that the same file we use from the console is called from the admin panel, there should be the same problems.

What file are you referring to?

Also a couple more questions:
When you launch the server the first time, are you using the sfs2x-service command?
Did you modify the sfs2x-service script?
Have you checked your system logs (under /var/log/...) for errors (at the time of the restart)?

Could it be something related to permits?

It seems unlikely, because the AdminTool acts with the same set of permissions of the user that launched the server.

Thanks
Lapo

--

gotoAndPlay()

...addicted to flash games
grookier
Posts: 26
Joined: 28 Sep 2016, 10:40

Re: Smartfox restart issue

Postby grookier » 22 Jul 2019, 08:52

What file are you referring to?

I mean script.
If the script used by the console is the same one that calls the "restart" button from the admin panel.

When you launch the server the first time, are you using the sfs2x-service command?

For the first time i'm using

Code: Select all

./sfs2x-service start &


Have you checked your system logs (under /var/log/...) for errors (at the time of the restart)?

I don't seem to notice anything strange, can you advise me which file to check?
User avatar
Lapo
Site Admin
Posts: 23026
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: Smartfox restart issue

Postby Lapo » 22 Jul 2019, 09:48

You don't need the "&" at the end of the command, though I am not sure it will make a difference. You can try.

I mean script.
If the script used by the console is the same one that calls the "restart" button from the admin panel.

No it isn't. Because the restart must work in different scenarios:
1) A server running as a standard process
2) A server running as service in the background

I don't seem to notice anything strange, can you advise me which file to check?

No, unfortunately as I am not able to reproduce the problem.
Are there are any error messages in your system logs at the time of the attempted restart? If so what are they?

Thanks
Lapo

--

gotoAndPlay()

...addicted to flash games
grookier
Posts: 26
Joined: 28 Sep 2016, 10:40

Re: Smartfox restart issue

Postby grookier » 22 Jul 2019, 13:06

I tried to remove the & symbol, but the problem is not solved.

I can't find any errors related to smartfoxserver in any log file.

Unfortunately at the moment I don't have a server available to replicate my current configuration.

I'll write a script to restart sfs2

Thanks for your help

Return to “SFS2X Questions”

Who is online

Users browsing this forum: No registered users and 73 guests