ValveSoftware / csgo-osx-linux

Counter-Strike: Global Offensive
http://counter-strike.net
768 stars 68 forks source link

CS2 dedicated server fails to start with workshop map with "Unknown command 'workshop_start_map'" #3529

Open senneschall opened 8 months ago

senneschall commented 8 months ago

Your system information

Ubuntu 22.04.3 LTS

Please describe your issue in as much detail as possible:

Trying to start a linux dedicated server with a workshop map via '+host_workshop_collection ' fails to start the server. The startup stops with the following error message: Unknown command 'workshop_start_map'!

Steps for reproducing this issue:

the server runs with this command ./cs2 -dedicated -game csgo -console -usercon -serverlogging +rcon_connected_clients_allow true +rcon_password <mypw> +sv_logfile 1 +game_type 0 +game_mode 2 +host_workshop_collection 1573939820 +map de_overpass +sv_setsteamaccount <myserverid> -authkey <myauth> -net_port_try 1 +net_public_adr <mypublicip> +ip <mylocalip>

the server fails with this command ./cs2 -dedicated -game csgo -console -usercon -serverlogging +rcon_connected_clients_allow true +rcon_password <mypw> +sv_logfile 1 +game_type 0 +game_mode 2 +host_workshop_collection 1573939820 +workshop_start_map 3070290869 +sv_setsteamaccount <myserverid> -authkey <myauth> -net_port_try 1 +net_public_adr <mypublicip> +ip <mylocalip>

The only difference is that I changed +map de_overpass (working) to +workshop_start_map 3070290869

Snailpower commented 8 months ago

Also encountering this issue when running the server. I get the following error when using the +workshop_start_map:


Network System Initialized Loaded /serverdata/serverfiles/game/bin/linuxsteamrt64/libserver_valve.so, got (nil)

failed to dlopen /serverdata/serverfiles/game/bin/linuxsteamrt64/libserver_valve.so

error=/serverdata/serverfiles/game/bin/linuxsteamrt64/libserver_valve.so: cannot open shared object file: No such file or directory

Loaded libserver_valve.so, got (nil)


FYI I use the -authkey parameter with my key as instructed on

https://developer.valvesoftware.com/wiki/Counter-Strike:_Global_Offensive/Dedicated_Servers#Steam_Workshop

aesdotjs commented 8 months ago

Having the same issue here using +host_workshop_collection and +host_workshop_map and authkey If I use them by hand in the console it responds nothing

senneschall commented 8 months ago

Loaded libserver_valve.so, got (nil)

This error message seems to be unrelated to the workshop maps, I see it also on successfully running servers. Therefore I opened another issue for the missing libserver_valve.so -> #3533

Let's keep this issue about failing to load a workshop map with +workshop_start_map

aesdotjs commented 8 months ago

issue about failing to load a workshop map with

But maybe both issues are related ? If I just load a map with +map it does work.

senneschall commented 8 months ago

Ah, I see. Good point.

Magic8Ballin commented 8 months ago

Loaded libserver_valve.so, got (nil)

This error message seems to be unrelated to the workshop maps, I see it also on successfully running servers. Therefore I opened another issue for the missing libserver_valve.so -> #3533

Let's keep this issue about failing to load a workshop map with +workshop_start_map

I'm experiecing the same issue. The launch option +workshop_start_map is not working in CS2.

brutalcinikola commented 8 months ago

+host_workshop_map mapID +host_workshop_collection collectionId

senneschall commented 7 months ago

+host_workshop_map mapID

This works after the server has started successfully to switch to another map. It doesn't work to set the starting map when launching the server.

GekasD commented 6 months ago

Yeah, would be nice to get that startup parameter back

GekasD commented 5 months ago

UPDATE: A little hacky solution I have right now, not ideal by any means but a solution nonetheless, load an empty map using +map <empty> and then host a workshop map with +host_workshop_map example startup params:

./cs2 -dedicated -port 27015 -usercon -maxplayers 12 +ip 0.0.0.0 +map <empty> +host_workshop_map mapid +game_type 0 +game_mode 1

Keep in mind that this means the server will be in an empty map for a few seconds while downloading the map for the first time.

NOTE: the server cannot have hibernation enabled for this to work, make sure sv_hibernate_on_empty is set to 0 in server.cfg