SRCDS Steam group


Request: 1000 FPS kernel .config
#1
I would like to see 1000 FPS kernel configs posted here.

Post several samples of your game server's responses to "stats" command while you've got 10 players or bots on the server. Then attach your kernel .config file in the post. There are probably several variations how to achieve 1000 FPS game server, so all input is good. Also the system specifications are probably good to mention.

I've seen server admins posting about having "1000 FPS" servers, although all they've done is change the kernel to 1000 Hz. I've also seen servers which claim to be 1000 FPS, but the FPS starts to fluctuate when players join there. That's why I want to see sample of "stats" commands to verify that server admins really have 1000 FPS config.

The idea of this thread is to get rid of those unnecessary tutorial threads, which are hard to verify to be reliable. Server admins could have some other non-related configurations in their kernels which prevent having 1000 FPS game server or something similar. Full .config is reliable way to ensure that there are server admins using certain kernel configure, which provides 1000 FPS game server.

The best we could achieve with this thread is some sort of shell script that modifies kernel configurations after server admins have done their own optimizations on it. The necessary modifications are usually simple one-line modifications to the kernel configuration file ".config", so the shell script could be even simple set of search-and-replace commands.

Here are reliable ways to check what is the kernel config for the active kernel:
Code:
# Method 1, the most reliable method.
zcat /proc/config.gz
Code:
# Method 2., somewhat reliable - make sure you use the real kernel file name
# Change directory to where your extracted kernel source files are
cd /usr/src/linux/
# Replace /boot/vmlinuz-2.6.26-1000fps with the kernel file you are running
./scripts/extract-ikconfig /boot/vmlinuz-2.6.26-1000fps
There are also other methods, which include looking up some file under /boot/ or directly looking at the kernel source directory's .config file. These methods are not that reliable though, because server admins forget all the time that they've made changes to the active kernel, but they are still actually running different kernel etc.
Reply
#2
I'm probably not going to use any of the kernels posted here. I know what I'm doing and given the resources, I could compile a whatever-FPS kernel I want. Unfortunately for me, the resources (=hardware) is the problem. Anyway, I can still see what kind of configurations other server admins have set to their kernels and draw best of them for some future projects.

Then this thread also is probably more likely to get facts straight than bunch of copy&pasted tutorials, because I see mystical instructions in many 1000 FPS tutorials. In my opinion 1000 Hz is not needed for 1000 FPS kernel (note: this is my unverified opinion). Also modifying jiffies.h as instructed by Nitoxys (rewrite on our board) seems also unnecessary.

I've got 100 Hz kernel - with very heavy MySQL stuff running on it - but I still time to time hit some 900+ FPS. I don't see it necessary for the kernel to check 1000 times per second that the most CPU heavy process, ie. srcds, still wants all the CPU resources it can get; 100 times per second should be enough. Dynamic tick (dyntick) kernel should also work, because dyntick kernel can scale up to the optimal state corresponding to the used CPU resources. Can anyone confirm these by posting a working 1000 FPS .config with either 100 Hz or dynamic ticks enabled?

Modifying jiffies.h is something I don't understand at all. Take a look at the original code:
Code:
#elif HZ >= 384 && HZ < 768
# define SHIFT_HZ       9
#elif HZ >= 768 && HZ < 1536
# define SHIFT_HZ       10
#else
# error You lose.
#endif
Here the code checks whether the HZ, which is defined in param.h as
Code:
# define HZ             CONFIG_HZ       /* Internal kernel timer frequency */
is between 768 and 1536. If you're going to change the CONFIG_HZ, which is defined in the "make menuconfig" at "kernel timer frequency" section, to the maximum 1000 Hz, then the value is between 768 - 1536, so no need to patch jiffies.h for that. Then even if you change somewhat illogically the USER_HZ to 1500, which is higher than the internal kernel timer, you're still between the boundaries of 768 to 1536. I don't understand why jiffies.h should be patched to handle the case where any of the HZ definitions would be over 1536 because they're never set so high.

Maybe with these thoughts we can start demystifying secrets of the 1000 FPS kernel. I hope to see noob server admins posting results for their 1000 FPS game servers that they never thought they'd have.
Reply
#3
Code:
# Method 1, the most reliable method.
zcat /proc/config.gz

I am using ubuntu and i dont have the config.gz. am i missing something or does ubuntu name it something different
Reply
#4
helixo Wrote:I am using ubuntu and i dont have the config.gz. am i missing something or does ubuntu name it something different
You're not missing anything. It's Ubuntu's "fault". Ubuntu's default kernel doesn't have CONFIG_IKCONFIG_PROC set. That's why you don't have that special file. It's nothing to worry about, though. You can get reliable information from your kernel by using the method 2. Make sure you double-check which kernel you're running if you're going to use method 2. Otherwise you end up posting some configs here that you're not actually even using.

BTW, here are the definitions from the Documentation for the according configuration parameters.
Code:
+------------------------------------ Kernel .config support ------------------------------------+
  ¦ CONFIG_IKCONFIG:                                                                               ¦
  ¦                                                                                                ¦
  ¦ This option enables the complete Linux kernel ".config" file                                   ¦
  ¦ contents to be saved in the kernel. It provides documentation                                  ¦
  ¦ of which kernel options are used in a running kernel or in an                                  ¦
  ¦ on-disk kernel.  This information can be extracted from the kernel                             ¦
  ¦ image file with the script scripts/extract-ikconfig and used as                                ¦
  ¦ input to rebuild the current kernel or to build another kernel.                                ¦
  ¦ It can also be extracted from a running kernel by reading                                      ¦
  ¦ /proc/config.gz if enabled (below).                                                            ¦
Code:
+----------------------- Enable access to .config through /proc/config.gz -----------------------+
  ¦ CONFIG_IKCONFIG_PROC:                                                                          ¦
  ¦                                                                                                ¦
  ¦ This option enables access to the kernel configuration file                                    ¦
  ¦ through /proc/config.gz.                                                                       ¦

I think these both are by default enabled in the mainline kernel. I'm not sure why Ubuntu doesn't have it (_PROC one) in theirs. If the first option is not enabled, then not even the method 2 works, but I'd be surprised if that was the case.
Reply
#5
Here is mine

jiffies.h edited to #elif HZ >= 1536 && HZ < 3072
Param.h edited to 1500

I have tried dfferent vatiations of both, this is the combo that ive found to be most stable/less cpu for my system

and hpet=force kernel option


Attached Files
.txt   config.txt (Size: 74.02 KB / Downloads: 206)
Reply
#6
HBS|Ryan Wrote:Here is mine

jiffies.h edited to #elif HZ >= 1536 && HZ < 3072
Param.h edited to 1500

I have tried dfferent vatiations of both, this is the combo that ive found to be most stable/less cpu for my system

and hpet=force kernel option

Which bit of param.h have you edited to 1500 ?
Reply
#7
user_hz to 1500 from 100
Reply
#8
I dont have a config to contribute but there seems to be a bit of buzz around these forums for good and stable 1000fps server. Id like to say Ive been using an unmodified Ubuntu server edition kernel that can run srcds straight out of the box with good results.

The following is on a dual core E8200 @ 2.66GHz with 2 GB of ram and with 14 bots on the server.

Code:
CPU   In    Out   Uptime  Users   FPS    Players
60.00 4405.88 15027.63      13     1  995.02      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
60.00 4438.00 14705.93      13     1  993.05      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
60.00 4481.96 14370.63      13     1  993.05      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
58.50 4543.95 13983.30      13     1  995.02      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
58.50 4613.46 13642.58      14     1  995.02      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
58.50 4644.44 13284.39      14     1  994.04      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
58.50 4711.49 12868.48      14     1  995.02      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
56.00 4803.66 12424.23      14     1  994.04      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
56.00 4875.88 12146.60      14     1  994.04      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
56.00 4906.74 11852.24      14     1  994.04      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
56.00 4976.56 11310.66      14     1  995.02      15
] rcon stats
CPU   In    Out   Uptime  Users   FPS    Players
54.75 5145.18 10620.90      14     1  993.05      15
Reply
#9
Forsaken, thanks!

This is what I've been waiting. There's big fuzz about "1000 FPS .config", which is brought up every time when other server admins on this board ask how they could achive better performance on their server. Now it's easy to tell them to install Ubuntu.

Can you post the exact version number, output of "uname -a" and just for perfection the .config for the kernel?

In the future on every thread where people ask how they can achieve 1000 FPS, I will guide them to your post instead of the "1000 FPS tutorial" thread. Actually the 1000 FPS tutorial thread should be replaced by your post.

Big thanks. We can stop buzzing about mystical hi-performance kernels only achievable by real good kernel configuration experts.

We'll lock this thread after your following post because it's so perfect answer to any "How do I get 1000 FPS?" question.
Reply
#10
Fps isn't everything.
In fact all fps above 100 is not necessary as all world updates only
happen 100 times per second anyway (on a 100tick server).
Therefore you could cap the fps_max at 100+ and still you won't notice any differences.

Consistency and latency is more important imo.


Btw. After kernel 2.6.22.something there is easy to get them run ~1000 fps on smp systems I think.
Before that on single core systems i definitely needed it to get more fps.

If you don't care about anything else than to get 1000fps you can of course run default ubuntu server.
But I'd recommend "apt-get install linux-rt" for real time latency.
This is the easy way of doing it.
"the box said 'requires windows xp or better'. so i installed linux"
Linux Ubuntu 9.04 Server 2.6.30-vanilla #1 SMP PREEMPT x86_64
Reply
#11
Linux desktop 2.6.24-19-generic

As for the .config the way I understand it, ubuntu doesnt use one. They do some things a bit strange but Ive been fairly content with the switch from debian.

This is the server edition just to clarify. Having someone install ubuntu to get 1000fps may or may not work I havent tried the desktop edition. Also I havent tried this on different hardware so I'd be interested to see if others get the expected results.

Quote:In fact all fps above 100 is not necessary as all world updates only happen 100 times per second
You may be right but this I find hard to believe. Im not intimately familiar with the Source engine but as I understand it intrapolation is based off of the locations of entities at given times and estimating what happens in between those snapshots. Its obvious that data coming in happens at non deterministic times and is likely associated with a timestamp. Whether that timestamp is based on the snapshot or the arrival of the data is unknown to me but if its independent of the snapshot, then I could see higher fps increasing the accuracy of intrapolation.

If what you say is true then why do server hosting companies not cap the fps on their standard servers? It would decrease cpu load and allow for more servers on one CPU. Even the lowest end servers Ive seen is at least 500 fps.
Reply
#12
I did an experiment on full 24 slot tf2 servers, and a full 24 slot css server.

In real-time, i changed rcon fps_max to 150, 350, 550, 750, 950, 1050, verified the changes in rcon status, and NO ONE was noticing a difference.

I let each FPS setting run for 10 minutes.

I even asked a couple players if they noticed any changes, and told them when I was changing fps.

So I just think it's kind of silly people are doing all this to get their fps to as close to 1000 as possible.
Reply
#13
Forsaken Wrote:If what you say is true then why do server hosting companies not cap the fps on their standard servers? It would decrease cpu load and allow for more servers on one CPU. Even the lowest end servers Ive seen is at least 500 fps.
I'm not 100% sure of it. I could be wrong...
300fps or 1000fps makes no big difference in cpu usage, so they use a higher fps because IT SELLS more.
"the box said 'requires windows xp or better'. so i installed linux"
Linux Ubuntu 9.04 Server 2.6.30-vanilla #1 SMP PREEMPT x86_64
Reply
#14
@CSS: Just because one person managed to get 1000 FPS with a generic kernel doesn't mean everyone can. My installation of Ubuntu doesn't get 1000 FPS out of the box... It depends on the server itself. Should this "replace" the other tutorial? No, that would be silly as not everyone will be able to achieve 1000 FPS out of the box. Should it be along side it? Definitely. Also frankly the "buzzing" about 1000 FPS by only "real good kernel configuration experts" is a dumb thing to say. It was easy before, and now even easier now with a tutorial, to achieve what "real good kernel configuration experts" can achieve.
realchamp Wrote:
Hazz Wrote:Has someone helped you on these forums? If so, help someone else
Mooga Wrote:OrangeBox is a WHORE.
Reply
#15
One person managed to get 1000 FPS with Ubuntu's server edition, which means everybody else can get it too.

The buzz about "tweaking kernel configs" etc. is going strong on this forum. I asked many times for server admins to post their 1000 FPS .config on other threads and by PM. Nobody replied or shared their config because they wanted to keep their hard-to-achieve configs for themselves. Anyway the same server admins kept saying how they've got 1000 FPS game server and how much trouble they went through to get it.

Now we've got several .configs on this thread and as a great BONUS we've learned that Ubuntu's server edition does 1000 FPS out-of-the-box. It was long road to get here. I've had to push server admins to get them share their good .configs for common use. I'm still hoping Forsaken goes through the trouble and extracts the kernel config setup from the Ubuntu server edtion. Then we can definitely say there's no special magic in having 1000 FPS server.

People don't need to be Linux experts to be able to install Ubuntu server edition or find a server hoster which provides Ubuntu server edition as a default install. However, people need to be experts to be able to recompile and install Linux kernel without making the whole system unbootable. That's why it's better to tell everybody to use Ubuntu's server edition if possible.

From my point of view this thread has filled its meaning. We've got several 1000 FPS configs here and the ultimate solution of Ubuntu's server edition for everybody. Some of the posts are also going unrelated (janne, no offense, but your posts make no sense), so it's better to just wait for Forsaken's last post including the .config and then lock this thread. Maybe then sticky this or maybe I put it in my signature.
Reply


Forum Jump:


Users browsing this thread: 5 Guest(s)