Re: [hlds_linux] Kernel Options and Clocksource
okay, i compiled the kernel, and I see all of them. you think i should use tsc or hpet? there are opinions for both throughout the list it seems. On Sat, Mar 7, 2009 at 1:25 PM, listac...@lvwnet.com wrote: So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource I think you meant available_clocksource not current_clocksource ? Yes, already corrected myself TYVM ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 02:45 PM 3/8/2009, Ben B wrote: okay, i compiled the kernel, and I see all of them. you think i should use tsc or hpet? there are opinions for both throughout the list it seems. TSC is fast to read because it lives in the CPU.. HPET lives off somewhere behind a bridge, so reading it requires an ioport read Use TSC if you're on intel hardware and HPET if you're on AMD hardware. On Sat, Mar 7, 2009 at 1:25 PM, listac...@lvwnet.com wrote: So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource I think you meant available_clocksource not current_clocksource ? Yes, already corrected myself TYVM ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 02:45 PM 3/8/2009, Ben B wrote: okay, i compiled the kernel, and I see all of them. you think i should use tsc or hpet? there are opinions for both throughout the list it seems. TSC is fast to read because it lives in the CPU.. HPET lives off somewhere behind a bridge, so reading it requires an ioport read Use TSC if you're on intel hardware and HPET if you're on AMD hardware. On Sat, Mar 7, 2009 at 1:25 PM, listac...@lvwnet.com wrote: So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource I think you meant available_clocksource not current_clocksource ? Yes, already corrected myself TYVM ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
I feel like such a linux nub... how do you set your clocksource? On Fri, Mar 6, 2009 at 11:56 PM, The Universes ad...@theuniverses.comwrote: Do you think dropping it down to 500HZ is a better choice or do you suggest something else? If yes, does 500HZ still maintain 500FPS? Thanks! Gary Stanley wrote: At 10:33 PM 3/6/2009, The Universes wrote: I'm running 4 32 man TF2 servers at 500fps (66 tick) and I'm wondering if having kernel at 1000HZ (not tickless) with PREEMPT is necessary? Is that putting unnecessary strain on my CPU (Q9300)? My second question is if you guys use HPET as your clocksource $ cat /sys/devices/system/clocksource/clocksource0/available_clocksource tsc hpet acpi_pm jiffies $ cat /sys/devices/system/clocksource/clocksource0/current_clocksource tsc 1000hz kernels make nanosleep() expensive to call.. on a core2quad calling usleep (which calls nanosleep) nanosleep: 6157 cycles That's alot of cpu time. Cranking up HZ makes interrupts fire so often, so you get more accurate sleep behavior.. TSC lives on the CPU, so calling it is fairly cheap. HPET lives off somewhere on a bridge, so you need to go out to PCI land to read it. HPET is a decent choice, but overall the fastest one is TSC. Would you recommend changing that to HPET? I'm basically trying to lower CPU usage so it doesnt shoot up to 90% sometimes. Thanks, Dan ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
cat hpet /sys/devices/system/clocksource/clocksource0/current_clocksource Ben B wrote: I feel like such a linux nub... how do you set your clocksource? On Fri, Mar 6, 2009 at 11:56 PM, The Universes ad...@theuniverses.comwrote: Do you think dropping it down to 500HZ is a better choice or do you suggest something else? If yes, does 500HZ still maintain 500FPS? Thanks! Gary Stanley wrote: At 10:33 PM 3/6/2009, The Universes wrote: I'm running 4 32 man TF2 servers at 500fps (66 tick) and I'm wondering if having kernel at 1000HZ (not tickless) with PREEMPT is necessary? Is that putting unnecessary strain on my CPU (Q9300)? My second question is if you guys use HPET as your clocksource $ cat /sys/devices/system/clocksource/clocksource0/available_clocksource tsc hpet acpi_pm jiffies $ cat /sys/devices/system/clocksource/clocksource0/current_clocksource tsc 1000hz kernels make nanosleep() expensive to call.. on a core2quad calling usleep (which calls nanosleep) nanosleep: 6157 cycles That's alot of cpu time. Cranking up HZ makes interrupts fire so often, so you get more accurate sleep behavior.. TSC lives on the CPU, so calling it is fairly cheap. HPET lives off somewhere on a bridge, so you need to go out to PCI land to read it. HPET is a decent choice, but overall the fastest one is TSC. Would you recommend changing that to HPET? I'm basically trying to lower CPU usage so it doesnt shoot up to 90% sometimes. Thanks, Dan ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
The Universes wrote: cat hpet /sys/devices/system/clocksource/clocksource0/current_clocksourc You mean: echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource Taavi ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
Oops, thats right. Taavi wrote: The Universes wrote: cat hpet /sys/devices/system/clocksource/clocksource0/current_clocksourc You mean: echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource Taavi ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. (And yes, I know you don't need to run 1000 server fps on CS:S to get a good smooth game, or 500 server fps on TF2, but our server has the spare cycles. And let's face it, for server ops this game is ALL about attracting players to your servers and since with GSP advertising etc. many players are convinced they have to be on a 100 tick 1000fps counterstrike server to be on a good server.. well you get the idea) I also use isolcpus= on the kernel cmdline to set aside processor cores for the high-demand games. The cores our TF2 games run on are the only processes allowed to execute on those cores. All hardware IRQ service is pinned to specific other cores by disabling irqbalance and programming the smp_affinity for each valid numeric IRQ. http://kbase.redhat.com/faq/docs/DOC-15596 Cheers On Fri, Mar 6, 2009 at 11:56 PM, The Universes ad...@theuniverses.comwrote: Do you think dropping it down to 500HZ is a better choice or do you suggest something else? If yes, does 500HZ still maintain 500FPS? Thanks! Gary Stanley wrote: At 10:33 PM 3/6/2009, The Universes wrote: I'm running 4 32 man TF2 servers at 500fps (66 tick) and I'm wondering if having kernel at 1000HZ (not tickless) with PREEMPT is necessary? Is that putting unnecessary strain on my CPU (Q9300)? My second question is if you guys use HPET as your clocksource $ cat /sys/devices/system/clocksource/clocksource0/available_clocksource tsc hpet acpi_pm jiffies $ cat /sys/devices/system/clocksource/clocksource0/current_clocksource tsc 1000hz kernels make nanosleep() expensive to call.. on a core2quad calling usleep (which calls nanosleep) nanosleep: 6157 cycles That's alot of cpu time. Cranking up HZ makes interrupts fire so often, so you get more accurate sleep behavior.. TSC lives on the CPU, so calling it is fairly cheap. HPET lives off somewhere on a bridge, so you need to go out to PCI land to read it. HPET is a decent choice, but overall the fastest one is TSC. Would you recommend changing that to HPET? I'm basically trying to lower CPU usage so it doesnt shoot up to 90% sometimes. Thanks, Dan ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit:
Re: [hlds_linux] Kernel Options and Clocksource
So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Oops... that is supposed to be: # cat /sys/devices/system/clocksource/clocksource0/available_clocksource ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
i just have jiffies in as an available clocksource... there a way to get htpet and tsc? On Sat, Mar 7, 2009 at 8:34 AM, Gary Stanley g...@velocity-servers.netwrote: At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 12:47 PM 3/7/2009, Ben B wrote: i just have jiffies in as an available clocksource... there a way to get htpet and tsc? TSC should be always be available as a clocksource, unless something is seriously wrong with your setup. Actually, a normal kernel will panic if TSC isn't compiled into the kernel :P On Sat, Mar 7, 2009 at 8:34 AM, Gary Stanley g...@velocity-servers.netwrote: At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 12:47 PM 3/7/2009, Ben B wrote: i just have jiffies in as an available clocksource... there a way to get htpet and tsc? TSC should be always be available as a clocksource, unless something is seriously wrong with your setup. Actually, a normal kernel will panic if TSC isn't compiled into the kernel :P On Sat, Mar 7, 2009 at 8:34 AM, Gary Stanley g...@velocity-servers.netwrote: At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
dont ask me, this is how it was when i found it. So if I compile my own kernel, it should have them clocksources? On Sat, Mar 7, 2009 at 11:01 AM, Gary Stanley g...@velocity-servers.netwrote: At 12:47 PM 3/7/2009, Ben B wrote: i just have jiffies in as an available clocksource... there a way to get htpet and tsc? TSC should be always be available as a clocksource, unless something is seriously wrong with your setup. Actually, a normal kernel will panic if TSC isn't compiled into the kernel :P On Sat, Mar 7, 2009 at 8:34 AM, Gary Stanley g...@velocity-servers.net wrote: At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 01:12 PM 3/7/2009, Ben B wrote: dont ask me, this is how it was when i found it. So if I compile my own kernel, it should have them clocksources? What's the motherboard? is it a virtual machine? On Sat, Mar 7, 2009 at 11:01 AM, Gary Stanley g...@velocity-servers.netwrote: At 12:47 PM 3/7/2009, Ben B wrote: i just have jiffies in as an available clocksource... there a way to get htpet and tsc? TSC should be always be available as a clocksource, unless something is seriously wrong with your setup. Actually, a normal kernel will panic if TSC isn't compiled into the kernel :P On Sat, Mar 7, 2009 at 8:34 AM, Gary Stanley g...@velocity-servers.net wrote: At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 01:12 PM 3/7/2009, Ben B wrote: dont ask me, this is how it was when i found it. So if I compile my own kernel, it should have them clocksources? What's the motherboard? is it a virtual machine? On Sat, Mar 7, 2009 at 11:01 AM, Gary Stanley g...@velocity-servers.netwrote: At 12:47 PM 3/7/2009, Ben B wrote: i just have jiffies in as an available clocksource... there a way to get htpet and tsc? TSC should be always be available as a clocksource, unless something is seriously wrong with your setup. Actually, a normal kernel will panic if TSC isn't compiled into the kernel :P On Sat, Mar 7, 2009 at 8:34 AM, Gary Stanley g...@velocity-servers.net wrote: At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource I think you meant available_clocksource not current_clocksource ? -Original Message- From: hlds_linux-boun...@list.valvesoftware.com [mailto:hlds_linux- boun...@list.valvesoftware.com] On Behalf Of Gary Stanley Sent: 07 March 2009 18:40 To: Half-Life dedicated Linux server mailing list; Half-Life dedicated Linux server mailing list Subject: Re: [hlds_linux] Kernel Options and Clocksource At 01:12 PM 3/7/2009, Ben B wrote: dont ask me, this is how it was when i found it. So if I compile my own kernel, it should have them clocksources? What's the motherboard? is it a virtual machine? On Sat, Mar 7, 2009 at 11:01 AM, Gary Stanley g...@velocity-servers.netwrote: At 12:47 PM 3/7/2009, Ben B wrote: i just have jiffies in as an available clocksource... there a way to get htpet and tsc? TSC should be always be available as a clocksource, unless something is seriously wrong with your setup. Actually, a normal kernel will panic if TSC isn't compiled into the kernel :P On Sat, Mar 7, 2009 at 8:34 AM, Gary Stanley g...@velocity- servers.net wrote: At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe
Re: [hlds_linux] Kernel Options and Clocksource
Duno about the mobo, but it's not a virtual. It's Q9400, 4gig ram, 64 bit Centos 5.2 On Sat, Mar 7, 2009 at 11:40 AM, Gary Stanley g...@velocity-servers.netwrote: At 01:12 PM 3/7/2009, Ben B wrote: dont ask me, this is how it was when i found it. So if I compile my own kernel, it should have them clocksources? What's the motherboard? is it a virtual machine? On Sat, Mar 7, 2009 at 11:01 AM, Gary Stanley g...@velocity-servers.netwrote: At 12:47 PM 3/7/2009, Ben B wrote: i just have jiffies in as an available clocksource... there a way to get htpet and tsc? TSC should be always be available as a clocksource, unless something is seriously wrong with your setup. Actually, a normal kernel will panic if TSC isn't compiled into the kernel :P On Sat, Mar 7, 2009 at 8:34 AM, Gary Stanley g...@velocity-servers.net wrote: At 08:27 AM 3/7/2009, listac...@lvwnet.com wrote: I feel like such a linux nub... how do you set your clocksource? On any fairly recent 2.6-series kernel you can put this right on the kernel boot commandline: clocksource=$whatever like clocksource=hpet or clocksource=tsc so that it is set at boot. The echoing of available options into the /sys entry is valid as well, ie: # echo hpet /sys/devices/system/clocksource/clocksource0/current_clocksource but is more of a post-boot type thing. That's not bad, necessarily. You can use it to change the clocksource post-boot. This is useful if you are experimenting with different ones because you can change the clocksource without rebooting. So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource you'll get something like this back (but it will vary from system to system): tsc jiffies hpet acpi_pm Someone else asked whether running a 500Hz timer resolution will allow you to get a stable 500 server fps. I'm not going to say it is impossible, but I will say that *I* have yet to find a server machine (server-class hardware) that would let me get 500fps with a 500Hz kernel. I was able to get it running on a test machine. I've only ever been able to get 500 server fps with a 1000Hz or tickless kernel, and setting fps_max to 600 or higher. Entirely possible I'm just not doing it right though. But what I do works, so I keep doing it. :) Setting fps_max to 600 usually gets me around 490-496 server fps. CPU utilization for the core a full 30-slot server runs on is usually around 60-65% on a 2.5GHz Harpertown but it does briefly peak higher at times. This is under F10 x86_64 with a stock 2.6.27 kernel (which I'm pretty sure is built dynamic/tickless) and I can get ~1000 server fps out of it for our CS:S games by setting fps_max to 2000. I'm using clocksource=hpet currently, but have considered experimenting with tsc since I've read that there are some recent userspace optimizations in glibc for it on x86_64 which may be of benefit. That only happens if the binaries are x86_64. ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux -- From Ben B. (Goerge) ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
So to get a list of which clocksources your hardware has available: # cat /sys/devices/system/clocksource/clocksource0/current_clocksource I think you meant available_clocksource not current_clocksource ? Yes, already corrected myself TYVM ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
Its not the timing that wastes the CPU time. You can't lower it with that. 90% is absolutly normal for such a big server. 2009/3/7 The Universes ad...@theuniverses.com: I'm running 4 32 man TF2 servers at 500fps (66 tick) and I'm wondering if having kernel at 1000HZ (not tickless) with PREEMPT is necessary? Is that putting unnecessary strain on my CPU (Q9300)? My second question is if you guys use HPET as your clocksource $ cat /sys/devices/system/clocksource/clocksource0/available_clocksource tsc hpet acpi_pm jiffies $ cat /sys/devices/system/clocksource/clocksource0/current_clocksource tsc Would you recommend changing that to HPET? I'm basically trying to lower CPU usage so it doesnt shoot up to 90% sometimes. Thanks, Dan ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
Would changing to HPET help at all? ServerAlex wrote: Its not the timing that wastes the CPU time. You can't lower it with that. 90% is absolutly normal for such a big server. 2009/3/7 The Universes ad...@theuniverses.com: I'm running 4 32 man TF2 servers at 500fps (66 tick) and I'm wondering if having kernel at 1000HZ (not tickless) with PREEMPT is necessary? Is that putting unnecessary strain on my CPU (Q9300)? My second question is if you guys use HPET as your clocksource $ cat /sys/devices/system/clocksource/clocksource0/available_clocksource tsc hpet acpi_pm jiffies $ cat /sys/devices/system/clocksource/clocksource0/current_clocksource tsc Would you recommend changing that to HPET? I'm basically trying to lower CPU usage so it doesnt shoot up to 90% sometimes. Thanks, Dan ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 10:33 PM 3/6/2009, The Universes wrote: I'm running 4 32 man TF2 servers at 500fps (66 tick) and I'm wondering if having kernel at 1000HZ (not tickless) with PREEMPT is necessary? Is that putting unnecessary strain on my CPU (Q9300)? My second question is if you guys use HPET as your clocksource $ cat /sys/devices/system/clocksource/clocksource0/available_clocksource tsc hpet acpi_pm jiffies $ cat /sys/devices/system/clocksource/clocksource0/current_clocksource tsc 1000hz kernels make nanosleep() expensive to call.. on a core2quad calling usleep (which calls nanosleep) nanosleep: 6157 cycles That's alot of cpu time. Cranking up HZ makes interrupts fire so often, so you get more accurate sleep behavior.. TSC lives on the CPU, so calling it is fairly cheap. HPET lives off somewhere on a bridge, so you need to go out to PCI land to read it. HPET is a decent choice, but overall the fastest one is TSC. Would you recommend changing that to HPET? I'm basically trying to lower CPU usage so it doesnt shoot up to 90% sometimes. Thanks, Dan ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
At 10:33 PM 3/6/2009, The Universes wrote: I'm running 4 32 man TF2 servers at 500fps (66 tick) and I'm wondering if having kernel at 1000HZ (not tickless) with PREEMPT is necessary? Is that putting unnecessary strain on my CPU (Q9300)? My second question is if you guys use HPET as your clocksource $ cat /sys/devices/system/clocksource/clocksource0/available_clocksource tsc hpet acpi_pm jiffies $ cat /sys/devices/system/clocksource/clocksource0/current_clocksource tsc 1000hz kernels make nanosleep() expensive to call.. on a core2quad calling usleep (which calls nanosleep) nanosleep: 6157 cycles That's alot of cpu time. Cranking up HZ makes interrupts fire so often, so you get more accurate sleep behavior.. TSC lives on the CPU, so calling it is fairly cheap. HPET lives off somewhere on a bridge, so you need to go out to PCI land to read it. HPET is a decent choice, but overall the fastest one is TSC. Would you recommend changing that to HPET? I'm basically trying to lower CPU usage so it doesnt shoot up to 90% sometimes. Thanks, Dan ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux
Re: [hlds_linux] Kernel Options and Clocksource
Do you think dropping it down to 500HZ is a better choice or do you suggest something else? If yes, does 500HZ still maintain 500FPS? Thanks! Gary Stanley wrote: At 10:33 PM 3/6/2009, The Universes wrote: I'm running 4 32 man TF2 servers at 500fps (66 tick) and I'm wondering if having kernel at 1000HZ (not tickless) with PREEMPT is necessary? Is that putting unnecessary strain on my CPU (Q9300)? My second question is if you guys use HPET as your clocksource $ cat /sys/devices/system/clocksource/clocksource0/available_clocksource tsc hpet acpi_pm jiffies $ cat /sys/devices/system/clocksource/clocksource0/current_clocksource tsc 1000hz kernels make nanosleep() expensive to call.. on a core2quad calling usleep (which calls nanosleep) nanosleep: 6157 cycles That's alot of cpu time. Cranking up HZ makes interrupts fire so often, so you get more accurate sleep behavior.. TSC lives on the CPU, so calling it is fairly cheap. HPET lives off somewhere on a bridge, so you need to go out to PCI land to read it. HPET is a decent choice, but overall the fastest one is TSC. Would you recommend changing that to HPET? I'm basically trying to lower CPU usage so it doesnt shoot up to 90% sometimes. Thanks, Dan ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux ___ To unsubscribe, edit your list preferences, or view the list archives, please visit: http://list.valvesoftware.com/mailman/listinfo/hlds_linux