[Oxyd] [16.1] Scenario not properly running on Linux

Bugs that are actually features.
User avatar
Mylon
Filter Inserter
Filter Inserter
Posts: 525
Joined: Sun Oct 23, 2016 11:42 pm
Contact:

[Oxyd] [16.1] Scenario not properly running on Linux

Post by Mylon »

Observed behavior: Custom commands do not work. Game crashes on a second player joining.

To recreate:

Start a scenario in Windows.
Save game.
Transfer save to linux headless server.
Start server.
Connect to server (as client)
Custom commands (e.g. "/tag MyTag") no longer work. Game reports unknown command.
Second player joining causes server to crash.
Attachments
factoriorpg.zip
Scenario file
(2.75 MiB) Downloaded 96 times
factorio-current.log
(19.93 KiB) Downloaded 101 times
Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: [16.1] Scenario not properly running on Linux

Post by Oxyd »

Hi, I don't see a crash in the log you provided. Is it the correct log or am I missing something?
User avatar
Klonan
Factorio Staff
Factorio Staff
Posts: 5284
Joined: Sun Jan 11, 2015 2:09 pm
Contact:

Re: [16.1] Scenario not properly running on Linux

Post by Klonan »

Oxyd wrote:Hi, I don't see a crash in the log you provided. Is it the correct log or am I missing something?
There is a script error where global data that is present in the script.dat is nil, it seems that none of the Lua script is being initialised
I_IBlackI_I
Long Handed Inserter
Long Handed Inserter
Posts: 73
Joined: Wed Feb 20, 2013 6:57 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by I_IBlackI_I »

Code: Select all

 691.067 Error MainLoop.cpp:1010: Exception at tick 40761: Error while running event level::on_player_created (ID 24)
/opt/factorio/factorio/data/core/lualib/silo-script.lua:181: attempt to index field 'silo_script' (a nil value)
 691.067 Error ServerMultiplayerManager.cpp:95: MultiplayerManager failed: "Error while running event level::on_player_created (ID 24)
/opt/factorio/factorio/data/core/lualib/silo-script.lua:181: attempt to index field 'silo_script' (a nil value)"
 691.067 Info ServerMultiplayerManager.cpp:693: mapTick(40761) changing state from(InGame) to(Failed)
 691.067 Info GlobalContext.cpp:649: Waiting for child processes to exit: 
 691.426 Info ServerMultiplayerManager.cpp:141: Quitting multiplayer connection.
 691.426 Info ServerMultiplayerManager.cpp:693: mapTick(4294967295) changing state from(Failed) to(Closed)
 691.426 Info HttpSharedState.cpp:54: Downloading https://multiplayer.factorio.com/remove-game/463566
 691.530 Info HttpSharedState.cpp:127: Status code: 200
 691.530 Info UDPSocket.cpp:206: Closing socket
 691.530 Info UDPSocket.cpp:236: Socket closed
 691.530 Info UDPSocket.cpp:206: Closing socket
 691.539 Info UDPSocket.cpp:206: Closing socket
 691.539 Info UDPSocket.cpp:236: Socket closed
 691.541 Goodbye
Does seem like there is an error and it started shutting down straight after.
User avatar
Mylon
Filter Inserter
Filter Inserter
Posts: 525
Joined: Sun Oct 23, 2016 11:42 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Mylon »

Additionally, here is the save file I made using the scenario, before I uploaded it to the linux sever and started the server. As my player had already been created, I doubt it would allow any other player to join.
Attachments
factoriorpg45-v016 time test.zip
(2.22 MiB) Downloaded 112 times
Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Oxyd »

I_IBlackI_I wrote:Does seem like there is an error and it started shutting down straight after.
As it should when it encounters an error. Just making sure I'm not missing anything here.
I_IBlackI_I
Long Handed Inserter
Long Handed Inserter
Posts: 73
Joined: Wed Feb 20, 2013 6:57 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by I_IBlackI_I »

Yeah I guess that doesn't count as a crash. When you are playing a game on a server and you suddenly lose connection / server stops responding most people assume it crashed instead of gracefully shut down because it encountered an error.
Apologies.
Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Oxyd »

I'm having no luck reproducing this. I've tried loading your scenario on the Windows version of 0.16.2, saving it and then hosting the save on a Linux server. When I connect, I get the rules dialog and I can use /tag just fine. Also, connecting a second player works just fine.

So is this still an issue in .2? Do I need to create the save in some specific way? What I've been doing is Play → Scenario → Create, and then Save Game and copy the save. Also the save you posted here works in the exact same way for me.
User avatar
Mylon
Filter Inserter
Filter Inserter
Posts: 525
Joined: Sun Oct 23, 2016 11:42 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Mylon »

I just tested this in 16.2 and the problem still occurs. I'm going to try hosting on my own (via windows zip) and see what happens. I noticed Redmew's server (also known for being heavy on the scenario script) was running 100% vanilla so there may be a problem with their scenario as well.

The steps you described are what I'm doing. Not sure why we're getting different results.
I_IBlackI_I
Long Handed Inserter
Long Handed Inserter
Posts: 73
Joined: Wed Feb 20, 2013 6:57 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by I_IBlackI_I »

Would trying to get this error to occur while running heavy mode help you?
User avatar
Mylon
Filter Inserter
Filter Inserter
Posts: 525
Joined: Sun Oct 23, 2016 11:42 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Mylon »

I just tested this running a windows zip in headless mode and the scenario works properly.
Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Oxyd »

I_IBlackI_I wrote:Would trying to get this error to occur while running heavy mode help you?
No, heavy mode will not be relevant to this.
Mylon wrote:I just tested this running a windows zip in headless mode and the scenario works properly.
Did you use the Windows zipped version to create the file and then hosted it on Linux as usual, or did you host the game on Windows directly?
User avatar
Mylon
Filter Inserter
Filter Inserter
Posts: 525
Joined: Sun Oct 23, 2016 11:42 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Mylon »

Sorry, I should have clarified. I used my steam install to create the save file, then transferred it to a windows standalone (the zip download) to host as server using that. This produced a server with a working scenario.

I wonder perhaps if the problem could be a permissions error? Maybe the linux user does not have permissions to create the currently_playing directory and that's why the script isn't loading?

Edit: I checked and the temp/currently-playing directory is populated with my script files, but they don't seem to be loaded and running in the linux server.
Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Oxyd »

The game should complain about permission errors if it encounters any. But just to be sure, could you try running the server from a fresh install?
User avatar
Mylon
Filter Inserter
Filter Inserter
Posts: 525
Joined: Sun Oct 23, 2016 11:42 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Mylon »

I'm seeing massive desyncs on all servers running scenario scripts in 16.2, including the server running my scenario. I'd rather wait until that issue is resolved.
User avatar
Mylon
Filter Inserter
Filter Inserter
Posts: 525
Joined: Sun Oct 23, 2016 11:42 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Mylon »

Update:

I can't seem to recreate this. Even on the same server using a different tool the scenario runs properly. This appears to be some form of configuration problem with the server.
User avatar
Mylon
Filter Inserter
Filter Inserter
Posts: 525
Joined: Sun Oct 23, 2016 11:42 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Mylon »

Update: Admin says he removed the scenario folder and now it works.
User avatar
Mylon
Filter Inserter
Filter Inserter
Posts: 525
Joined: Sun Oct 23, 2016 11:42 pm
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Mylon »

The problem started happening again. Game log says it was applying a migration and saving and peeking at the save shows the freeplay control.lua instead of the scenario lua.

I was able to resolve the issue by emptying the save folder. I guess the game doesn't like having ~20 save files in the save folder?
Rseding91
Factorio Staff
Factorio Staff
Posts: 14334
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Rseding91 »

Mylon wrote:The problem started happening again. Game log says it was applying a migration and saving and peeking at the save shows the freeplay control.lua instead of the scenario lua.

I was able to resolve the issue by emptying the save folder. I guess the game doesn't like having ~20 save files in the save folder?
That shouldn't be an issue. I have 239 saves in my save folder and it works just fine.
If you want to get ahold of me I'm almost always on Discord.
Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: [Oxyd] [16.1] Scenario not properly running on Linux

Post by Oxyd »

Mylon wrote:The problem started happening again. Game log says it was applying a migration and saving and peeking at the save shows the freeplay control.lua instead of the scenario lua.
That's very curious. If it starts happening again, could you send the entire scenarios and saves folders? Looks like something in them confuses the game somehow. In fact, it would be helpful of you to just back up the broken installation before trying to repair it, so that we can then take a good look at the broken state.
Post Reply

Return to “Not a bug”