LHammonds Posted October 21, 2019 Share Posted October 21, 2019 EDIT (2019-10-24): Build 155 has fixed the high CPU usage issue noted below. I recently installed 7 Days to Die on a dedicated Ubuntu Server 18.04.3 LTS (documenting steps here) and have seen it consistently taking around 60% of the CPU all the time even when no players are connected. Is this normal? Is there something I need to change? Here is a sample of the top command which is fairly typical. There are currently 2 people online right now but if I only looked at the htop monitoring tool, I wouldn't really see a difference regarding CPU if there was nobody connected or 4 connected. top - 17:30:58 up 6 days, 7:12, 1 user, load average: 3.24, 3.26, 3.11 Tasks: 185 total, 2 running, 107 sleeping, 0 stopped, 0 zombie %Cpu(s): 37.4 us, 18.0 sy, 0.1 ni, 44.5 id, 0.1 wa, 0.0 hi, 0.0 si, 0.0 st KiB Mem : 8168476 total, 357480 free, 5835256 used, 1975740 buff/cache KiB Swap: 1048500 total, 883380 free, 165120 used. 2033344 avail Mem PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 26992 sdtd 20 0 5703696 3.116g 62208 R 187.5 40.0 168:12.34 7DaysToDie+ 9772 sdtd 20 0 4989164 2.263g 31628 S 87.5 29.0 3323:35 7DaysToDie+ Graphics Info # lspci -nnk | grep VGA -A1 00:0f.0 VGA compatible controller [0300]: VMware SVGA II Adapter [15ad:0405] Subsystem: VMware SVGA II Adapter [15ad:0405] Kernel driver in use: vmwgfx Network adapter # lspci -nnk | grep net -A2 02:00.0 Ethernet controller [0200]: Intel Corporation 82545EM Gigabit Ethernet Controller (Copper) [8086:100f] (rev 01) Subsystem: VMware PRO/1000 MT Single Port Adapter [15ad:0750] Kernel driver in use: e1000 CPU Info: # lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Byte Order: Little Endian CPU(s): 4 On-line CPU(s) list: 0-3 Thread(s) per core: 1 Core(s) per socket: 1 Socket(s): 4 NUMA node(s): 1 Vendor ID: GenuineIntel CPU family: 6 Model: 79 Model name: Intel(R) Xeon(R) CPU E5-2620 v4 @ 2.10GHz Stepping: 1 CPU MHz: 2099.998 BogoMIPS: 4199.99 Hypervisor vendor: VMware Virtualization type: full L1d cache: 32K L1i cache: 32K L2 cache: 256K L3 cache: 20480K NUMA node0 CPU(s): 0-3 Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts mmx fxsr sse sse2 ss syscall nx rdtscp lm constant_tsc arch_perfmon pebs bts nopl xtopology tsc_reliable nonstop_tsc cpuid aperfmperf pni pclmulqdq ssse3 fma cx16 sse4_1 sse4_2 movbe popcnt aes xsave avx hypervisor lahf_lm 3dnowprefetch epb pti dtherm ida arat pln pts RAM info: # free -h total used free shared buff/cache available Mem: 7.8G 5.6G 285M 13M 1.9G 1.9G Swap: 1.0G 160M 863M Kernel info: # uname -a Linux srv-7dtd 4.15.0-65-generic #74-Ubuntu SMP Tue Sep 17 17:06:04 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux Thanks, LHammonds Link to comment Share on other sites More sharing options...
SylenThunder Posted October 22, 2019 Share Posted October 22, 2019 Something interesting is that in your HTOP information up there, it's showing the client using 46.75% CPU, yet shows the system at 37.4% for users. It is curious though, as the issue may be the number of cores. I've heard of a few people running into a similar issue with their VM's that only have 2-4 cores. My server with 24 cores sits around 25% CPU idle with one a16 server, two a17 servers, and two a18 servers running and just a couple of people online. The highest I've seen it with a lot of activity on the servers is about 53%. These CPU % numbers are not per-instance, but for the entire server machine. So under capacity, I'm seeing almost the same total system CPU time that you have posted above for near idle. Except that I'm running five server instances. Link to comment Share on other sites More sharing options...
LHammonds Posted October 22, 2019 Author Share Posted October 22, 2019 I run a lot of virtual servers (across many Nutanix and ESXi hosts) including many high-use database and application servers but none of them even come close to the amount of CPU usage that 7dtd is using for 2 instances (even when nobody is online). 6,500 MHz being used is ridiculous. I have a large database application spread out over 8 servers and all of them together are only using about 2,000 MHz when servicing 100 clients. There has to be something I'm doing wrong with the server but I just do not see where I have it mis-configured. If this is "normal" then I will be shutting it down as soon as I'm done testing it out. LHammonds Link to comment Share on other sites More sharing options...
LHammonds Posted October 24, 2019 Author Share Posted October 24, 2019 I noticed the release notes for Alpha 18 build 155 and noticed this line: Dedicated servers using large amounts CPU when idle So I updated the server and now I am seeing much better performance after 7dtd starts and settles down (no players connected): top - 11:31:04 up 2 days, 8:00, 2 users, load average: 0.06, 0.27, 0.49 Tasks: 180 total, 1 running, 103 sleeping, 0 stopped, 0 zombie %Cpu(s): 2.5 us, 0.3 sy, 0.0 ni, 97.2 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st KiB Mem : 8168488 total, 128192 free, 3135580 used, 4904716 buff/cache KiB Swap: 1048500 total, 971700 free, 76800 used. 4734960 avail Mem PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 3928 sdtd 20 0 5259720 2.717g 63412 S 11.6 34.9 1:30.84 7DaysToDie+ 12920 root 20 0 44076 3912 3268 R 0.7 0.0 0:00.06 top 1216 root 20 0 1187216 17380 5608 S 0.3 0.2 4:43.75 fail2ban-s+ 15782 root 20 0 0 0 0 I 0.3 0.0 0:24.63 kworker/3:1 1 root 20 0 225352 5836 4184 S 0.0 0.1 0:03.43 systemd Once some players connect tonight, I will try and remember to update this post with stats under a small load. EDIT: With 3 players connected, I so see a marginal (and expected) increase in CPU usage but it certainly is not bad. top - 20:06:13 up 2 days, 16:35, 1 user, load average: 0.79, 0.91, 0.75 Tasks: 174 total, 1 running, 97 sleeping, 0 stopped, 0 zombie %Cpu(s): 11.2 us, 1.4 sy, 0.0 ni, 87.4 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st KiB Mem : 8168488 total, 579948 free, 3500628 used, 4087912 buff/cache KiB Swap: 1048500 total, 974260 free, 74240 used. 4363432 avail Mem PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 3928 sdtd 20 0 5679048 3.062g 66052 S 50.5 39.3 141:57.46 7DaysToDie+ 4466 root 20 0 0 0 0 I 0.3 0.0 0:08.19 kworker/0:1 1 root 20 0 225352 5844 4184 S 0.0 0.1 0:03.66 systemd 2 root 20 0 0 0 0 S 0.0 0.0 0:00.02 kthreadd 4 root 0 -20 0 0 0 I 0.0 0.0 0:00.00 kworker/0:+ Thanks TFP! LHammonds Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.