Dedicated Server on UbuntuServer 14.04 does't start w/o log

Find multiplayer games.
Tools/scripts to run a dedicated server.
hringriin
Manual Inserter
Manual Inserter
Posts: 4
Joined: Mon Apr 04, 2016 3:16 pm
Contact:

Dedicated Server on UbuntuServer 14.04 does't start w/o log

Post by hringriin »

Hello there,

I am running a virtual UbuntuServer machine running 14.04.

I want to run factorio as a headless server on that machine. I tried it according to the wiki and some information I found on this board.

I un-tar-ed the tarball to /opt/factorio, the init-script to /opt/factorio-init and the updater to /opt/factorio-updater.

I adjusted the config of the init script accordint to its readme and followed all instructions there, as I did with the main wiki page, too.

So now I copied a savegame to /opt/factorio/saves/.

If I try to start the server via the init-script the output is the following:

Code: Select all

># /etc/init.d/factorio start
Still not running, waiting a while longer...
Failed to start, aborting.
If I try to start the server itself w/o the init-script, I get the following output.

Code: Select all

>$ /opt/factorio/bin/x64/factorio --start-server hringriin
   0.000  Error Util.cpp:58: There is no package core in /usr/share/factorio
I was not able to find any log or some information what is going on here.

I'd be happy if someone could help me.


Regards
hringriin
Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: Dedicated Server on UbuntuServer 14.04 does't start w/o log

Post by Oxyd »

hringriin wrote:

Code: Select all

>$ /opt/factorio/bin/x64/factorio --start-server hringriin
   0.000  Error Util.cpp:58: There is no package core in /usr/share/factorio
Well, it's looking for the game files in /usr/share/factorio, but you installed it in /opt/factorio. What's in your /opt/factorio/config/config.ini? You – or that script – have probably changed read-data in config.ini to point to /usr/share/factorio, which is why the game is so confused. Changing read-data to /opt/factorio should fix it.
hringriin
Manual Inserter
Manual Inserter
Posts: 4
Joined: Mon Apr 04, 2016 3:16 pm
Contact:

Re: Dedicated Server on UbuntuServer 14.04 does't start w/o log

Post by hringriin »

Oxyd wrote:Well, it's looking for the game files in /usr/share/factorio, but you installed it in /opt/factorio. What's in your /opt/factorio/config/config.ini? You – or that script – have probably changed read-data in config.ini to point to /usr/share/factorio, which is why the game is so confused. Changing read-data to /opt/factorio should fix it.
I copied the default_config.ini from my Windows machine. The section path looks like this

Code: Select all

[path]
read-data=__PATH__system-read-data__
write-data=__PATH__system-write-data__
Should I edit those variables directly to specific paths or should I try to find it's declaration and initialisation anywhere else?

EDIT:

Changing those values to /opt/factorio does not make a difference. The error message changed, though.

EDIT 2:

Changing those values to /opt/factorio/data shows different behaviour

Code: Select all

>$ /opt/factorio/bin/x64/factorio --start-server hringriin01
   0.000 2016-04-04 19:37:20; Factorio 0.12.29 (Build 17931, linux64, headless)
   0.062 Operating system: Linux (Ubuntu 14.04)
   0.062 Program arguments: "/opt/factorio/bin/x64/factorio" "--start-server" "hringriin01" 
   0.062 Read data path: /opt/factorio/data/.
   0.062 Write data path: /opt/factorio/data/.
   0.062 Binaries path: /opt/factorio/bin
   0.073 Running in headless mode
   0.075 Loading mod core 0.0.0 (data.lua)
   0.078 Loading mod base 0.12.29 (data.lua)
   0.461 Factorio initialised
   0.462 Info Router.cpp:507: Router peerID(65535) shutting down.
   0.462 Info Router.cpp:534: Router state -> Disconnected
   0.462 Info MultiplayerManager.cpp:912: networkTick(0) mapTick(-1) changing state from(Ready) to(PreparedToHostGame)
   0.462 Info MultiplayerManager.cpp:912: networkTick(0) mapTick(-1) changing state from(PreparedToHostGame) to(CreatingGame)
   0.462 Loading map /opt/factorio/data/saves/hringriin01
   0.482 Error MultiplayerManager.cpp:109: MultiplayerManager failed: "Opening zip /opt/factorio/data/saves/hringriin01 failed"
   0.482 Info MultiplayerManager.cpp:912: networkTick(0) mapTick(-1) changing state from(CreatingGame) to(InitializationFailed)
   0.482 Error Main.cpp:344: Couldn't load the game for MP: Opening zip /opt/factorio/data/saves/hringriin01 failed
The thing now is, that factorio looks for the savegame in /opt/factorio/data/saves, and obviously there is no savegame.


Regards
hringriin
hringriin
Manual Inserter
Manual Inserter
Posts: 4
Joined: Mon Apr 04, 2016 3:16 pm
Contact:

Re: Dedicated Server on UbuntuServer 14.04 does't start w/o log

Post by hringriin »

So I gambled with those config files multiple hours without any success. It would be awesome, if the headless tarball would contain a config.ini with default values.

If someone might provide his or her config.ini for the headless server, I'd be very thankful. I'd also be thankful for every other advice what possibly is going wrong here. I doubt that only the two paths are causing those problems.


Regards
hringriin
daniel34
Global Moderator
Global Moderator
Posts: 2761
Joined: Thu Dec 25, 2014 7:30 am
Contact:

Re: Dedicated Server on UbuntuServer 14.04 does't start w/o log

Post by daniel34 »

hringriin wrote:The thing now is, that factorio looks for the savegame in /opt/factorio/data/saves, and obviously there is no savegame.
Upload a savegame and you are good to go. And don't forget the .zip at the end of the savegame name when calling it with --start-server.
hringriin wrote:So I gambled with those config files multiple hours without any success. It would be awesome, if the headless tarball would contain a config.ini with default values.

If someone might provide his or her config.ini for the headless server, I'd be very thankful. I'd also be thankful for every other advice what possibly is going wrong here. I doubt that only the two paths are causing those problems.


Regards
hringriin
I'm not sure why you had so many problems with setting up a config.ini.

I just download the headless tarball, extract it to a folder and start factorio with --start-server save.zip.
If there is no config file, it will automatically create a default one in the config folder.
Default config
Note that read-data and write-data are set to be relative to the executable, so you can move the factorio folder around later and it will still work without problems (all files are stored inside the factorio folder), like the windows zip version.
quick links: log file | graphical issues | wiki
hringriin
Manual Inserter
Manual Inserter
Posts: 4
Joined: Mon Apr 04, 2016 3:16 pm
Contact:

Re: Dedicated Server on UbuntuServer 14.04 does't start w/o log

Post by hringriin »

daniel34 wrote:
hringriin wrote:The thing now is, that factorio looks for the savegame in /opt/factorio/data/saves, and obviously there is no savegame.
Upload a savegame and you are good to go. And don't forget the .zip at the end of the savegame name when calling it with --start-server.
hringriin wrote:So I gambled with those config files multiple hours without any success. It would be awesome, if the headless tarball would contain a config.ini with default values.

If someone might provide his or her config.ini for the headless server, I'd be very thankful. I'd also be thankful for every other advice what possibly is going wrong here. I doubt that only the two paths are causing those problems.


Regards
hringriin
I'm not sure why you had so many problems with setting up a config.ini.

I just download the headless tarball, extract it to a folder and start factorio with --start-server save.zip.
If there is no config file, it will automatically create a default one in the config folder.
Default config
Note that read-data and write-data are set to be relative to the executable, so you can move the factorio folder around later and it will still work without problems (all files are stored inside the factorio folder), like the windows zip version.

The following after the read_data and write_data variables did the trick

Code: Select all

/../../data
/../..
Embarassing ...

And no, it did not create a config.ini by itself ...


Thank you very much!


Regards
hringriin
Post Reply

Return to “Multiplayer / Dedicated Server”