Xonotic Forums
Minstagib CTF server administration tips - Printable Version

+- Xonotic Forums (https://forums.xonotic.org)
+-- Forum: Support (https://forums.xonotic.org/forumdisplay.php?fid=3)
+--- Forum: Xonotic - Server Administration (https://forums.xonotic.org/forumdisplay.php?fid=16)
+--- Thread: Minstagib CTF server administration tips (/showthread.php?tid=4395)



Minstagib CTF server administration tips - demirulez - 08-16-2013

Hello everyone,

this is my first experience in administering a home dedicated server and I'd like to ask some tips regarding its configuration. Before actually transferring my server on a machine up 24/7 (I still need to buy some more hw components), I'm testing it on my everyday desktop PC (Ubuntu 12.04 x86_64 with Xonotic 0.7.0).

I've already managed to run it and it is visible on WAN side and it's listing correctly on the Xonotic master server list.

My first question is: how could I prevent players to vote for non-ctf maps? Because if that happens, the server switches to another gametype (usually tdm or dm), not ctf.

Second: I don't have a static IP address so i set up a no-ip account and i already test it, working on WAN side, but, in the eventuality that my IP changes, will my old server IP be updated on the Xonotic master server list automatically too?

Thanks in advance Smile


RE: Minstagib CTF server administration tips - Mr. Bougo - 08-16-2013

Hi! Glad you got most of it running already!

To prevent non-ctf maps from being played, don't include them in your maplist! Check the content of the g_maplist cvar in your server console.

Dedicated servers that have their sv_public cvar set to 1 periodically advertises themselves on the master server. There is no need for a static IP for the server to be accessible through the server list. However, if people put your server in their bookmarks, the bookmark entry will not work anymore when the IP is changed. There's not much you can do about that except getting a static IP.


RE: Minstagib CTF server administration tips - demirulez - 08-16-2013

(08-16-2013, 02:41 PM)Mr. Bougo Wrote: Hi! Glad you got most of it running already!

Thanks Smile.

(08-16-2013, 02:41 PM)Mr. Bougo Wrote: To prevent non-ctf maps from being played, don't include them in your maplist! Check the content of the g_maplist cvar in your server console.

Is adding "" to g_maplist cvar in the server.cfg file a faster way to do this? Or is this working only for server side choice? And with server side i mean...will clients still be able to see non-ctf maps when entering "maps" command on the console and vote for them?

(08-16-2013, 02:41 PM)Mr. Bougo Wrote: Dedicated servers that have their sv_public cvar set to 1 periodically advertises themselves on the master server. There is no need for a static IP for the server to be accessible through the server list. However, if people put your server in their bookmarks, the bookmark entry will not work anymore when the IP is changed. There's not much you can do about that except getting a static IP.

But if they bookmark my no-ip unique hostname instead of the current server IP, this will work as workaround, right?


RE: Minstagib CTF server administration tips - Mr. Bougo - 08-17-2013

I think emptying your g_maplist in server.cfg does indeed fill up the maplist with all maps compatible with the current gametype. Give it a try! Launch a server and see what's in g_maplist!

lsmaps and suggestmap only work with maps that are compatible with the gametype. As far as I can tell, they are independant from the maplist, so you can suggest a map that isn't in the maplist (give it a try!) To prevent that, remove the map from the server by moving its pk3 to somewhere it won't be loaded.

If you want to remove an official map, don't edit the original pk3 file. Instead, tell me and I'll explain how to do it properly.

Adding a server from the master server list to your bookmarks doesn't do a reverse IP lookup, and even if it did it wouldn't find your DDNS hostname. They will have to manually bookmark the hostname in order to have a working bookmark.


RE: Minstagib CTF server administration tips - demirulez - 08-17-2013

(08-17-2013, 03:25 AM)Mr. Bougo Wrote: I think emptying your g_maplist in server.cfg does indeed fill up the maplist with all maps compatible with the current gametype. Give it a try! Launch a server and see what's in g_maplist!

lsmaps and suggestmap only work with maps that are compatible with the gametype. As far as I can tell, they are independant from the maplist, so you can suggest a map that isn't in the maplist (give it a try!) To prevent that, remove the map from the server by moving its pk3 to somewhere it won't be loaded.

If you want to remove an official map, don't edit the original pk3 file. Instead, tell me and I'll explain how to do it properly.

Adding a server from the master server list to your bookmarks doesn't do a reverse IP lookup, and even if it did it wouldn't find your DDNS hostname. They will have to manually bookmark the hostname in order to have a working bookmark.

These are my current server settings regarding maps/votes and I'm only using official/standard maps for now: http://paste.ubuntu.com/5995632/.
I have set up g_maplist empty ("") as you can see and entering lsmaps into the server console it lists only compatible ctf-maps, but if I try to list the content of g_maplist with "echo $g_maplist", it returns only the map "courtfun"...why? Huh Note that the server is cycling ctf-maps correctly at the end of each match.


RE: Minstagib CTF server administration tips - Mr. Bougo - 08-17-2013

You don't need to use echo and variable expansion, typing just g_maplist will tell you the contents of the variable.

You say map cycling works fine but g_maplist contains only one map? That's strange. Can you have a look at the server log when a map changes to see if there's any information in there?


RE: Minstagib CTF server administration tips - demirulez - 08-17-2013

(08-17-2013, 05:25 AM)Mr. Bougo Wrote: You don't need to use echo and variable expansion, typing just g_maplist will tell you the contents of the variable.

You say map cycling works fine but g_maplist contains only one map? That's strange. Can you have a look at the server log when a map changes to see if there's any information in there?

Trying just g_maplist in the server console returns: 'g_maplist is "courtfun " [""]' so I think the result is the same as before, also taking a look at the server log when the server picks up a new map (abyss in this case): http://paste.ubuntu.com/5995742/.


RE: Minstagib CTF server administration tips - tZork - 08-17-2013

iirc maplist is only necessary if you want just a subset of maps. as long as you just want to run ctf (but any ctf) maps, all that should be needed if "g_ctf 1" in your server config. As for voting, you could disallow the map vote or use "delete pk3's", basically a pk3 containing a empty file with the same name as the one you wish to "remove" from the server VFS. In this case, any non-ctf map/s. Another option is to (extract) manually edit the .mapinfo files, giving every non ctf one some bogus modeline so it won't be considered.


RE: Minstagib CTF server administration tips - demirulez - 08-18-2013

(08-17-2013, 12:33 PM)tZork Wrote: iirc maplist is only necessary if you want just a subset of maps. as long as you just want to run ctf (but any ctf) maps, all that should be needed if "g_ctf 1" in your server config. As for voting, you could disallow the map vote or use "delete pk3's", basically a pk3 containing a empty file with the same name as the one you wish to "remove" from the server VFS. In this case, any non-ctf map/s. Another option is to (extract) manually edit the .mapinfo files, giving every non ctf one some bogus modeline so it won't be considered.

I added "g_ctf 1" to my server config. Could you please elaborate a bit more about the part for "deleting pk3s"? How can i remove maps to prevent being listed on my server (non-ctf ones)?
My actual maps listed with "maps":
Code:
23 maps found :
           abyss (Q3BSP46 )
      afterslime (Q3BSP46 )
        courtfun (Q3BSP46 ) Courtfun
           dance (Q3BSP46 )
        darkzone (Q3BSP46 ) Darkzone
           drain (Q3BSP46 )
            fuse (Q3BSP46 ) FUSE
            g-23 (Q3BSP46 ) Loading Dock G-23 by Moo
       glowplant (Q3BSP46 )
leave_em_behind (Q3BSP46 ) Leave'em behind
      lightspeed (Q3BSP46 ) Lightspeed by C.Brutail
newtonian-nightmare (Q3BSP46 ) Newtonian Nightmare
    nexballarena (Q3BSP46 )
          oilrig (Q3BSP46 )
      red-planet (Q3BSP46 )
      runningman (Q3BSP46 ) Running Man
   runningmanctf (Q3BSP46 ) Running Man CTF
     silentsiege (Q3BSP46 )
        solarium (Q3BSP46 )
  space-elevator (Q3BSP46 ) Space Elevator
       stormkeep (Q3BSP46 )
     techassault (Q3BSP46 ) techassault
         xoylent (Q3BSP46 )
And those listed with "lsmaps" (only ctf compliant):
Code:
Maps available: abyss courtfun dance lightspeed newtonian-nightmare runningmanctf space-elevator



RE: Minstagib CTF server administration tips - tZork - 08-18-2013

You make a pk3 containing a zero length file with the same filename as the file's you want removed from the VFS. SO for example to delete stormkeep, you would:

Code:
cd /tmp
mkdir maps
touch maps/stormkeep.bsp
zip -r zzz-delete-stormkeep.pk3 maps/*
mv zzz-delete-stormkeep.pk3 ~/.xonotic/data

You can do this for many .bsp's at once and you do not need to provide this pk3 for client d/l, its just necessary on server. Oh and double check the zip command, its been a long time since a did a pk3 on the lunix command line Smile


RE: Minstagib CTF server administration tips - Mr. Bougo - 08-18-2013

Note that you can also use directories whose name end in .pk3dir instead of zip archives.


RE: Minstagib CTF server administration tips - demirulez - 08-18-2013

I did the following and i think it's working out good...

1) I created empty .bsp files for every map not ctf-compatible with his proper name,
2) I zipped them all together in an archive named: removed-maps.pk3,
3) I moved the archive in ~/.xonotic/data

Now, on my server, if I try to call vote a map as a client that is included in the removed-maps.pk3, the server returns that it is not available, instead ctf ones are correctly voted and passed. Seems everything ok, right? Smile


RE: Minstagib CTF server administration tips - tZork - 08-18-2013

Seems like it did it then =)


RE: Minstagib CTF server administration tips - demirulez - 08-19-2013

Well thanks a lot both Mr. Bougo and tZork for your precious tips Smile.
As soon as I can get my server up and running (still need some hw components) I'll publish the link here so you can all test it and hope giving me some feedbacks too.