<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<atom:link href="http://dev1galaxy.org/extern.php?action=feed&amp;tid=7771&amp;type=rss" rel="self" type="application/rss+xml" />
		<title><![CDATA[Dev1 Galaxy Forum / [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
		<link>http://dev1galaxy.org/viewtopic.php?id=7771</link>
		<description><![CDATA[The most recent posts in [SOLVED] struggling starting auto-cpufreq --daemon.]]></description>
		<lastBuildDate>Tue, 03 Feb 2026 08:47:52 +0000</lastBuildDate>
		<generator>FluxBB</generator>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61788#p61788</link>
			<description><![CDATA[<p>ok I&#039;ll test with the correction, thank you edx.</p><p>I mark this topic as RESOLVED</p>]]></description>
			<author><![CDATA[dummy@example.com (unixuser)]]></author>
			<pubDate>Tue, 03 Feb 2026 08:47:52 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61788#p61788</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61783#p61783</link>
			<description><![CDATA[<p>i have no idea how to avoid that tbh, what i did is reduce the speed/amount the cache buffers fill by implementing dynamic polling, sort of, the current master commit of afreq.sh increases the time of the sleep calls from a fixed 500ms up to 5000ms (5 seconds) if the governor and boost stay stable (say at idle) for at least 5 ticks (5 runs of the tick function), it also reduces the sleep time down by 100ms if there is not a stable state and will keep doing so until every sleep is just 100ms with time going up once there are 5 stable states.</p><p>in my testing the buffers usage went down by 1GB, but i got other daemons that are also written in posix shell and operate in the same type of wait sleep cycle...</p>]]></description>
			<author><![CDATA[dummy@example.com (EDX-0)]]></author>
			<pubDate>Tue, 03 Feb 2026 03:29:14 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61783#p61783</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61767#p61767</link>
			<description><![CDATA[<p>Nice one. Do you know how to avoid that ? Without using zram</p>]]></description>
			<author><![CDATA[dummy@example.com (unixuser)]]></author>
			<pubDate>Mon, 02 Feb 2026 20:58:27 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61767#p61767</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61762#p61762</link>
			<description><![CDATA[<p>did my own digging, it is because of the buffers and caches getting filled by the instances of busybox usleep, i didn&#039;t notice earlier because i also use zram (through <a href="https://github.com/eylles/zram-service)" rel="nofollow">https://github.com/eylles/zram-service)</a> with zstd so i don&#039;t really think of ram usage as all data that goes onto zram is effectively compressed to about 1/4 the size (in average 1/3rd the ram consumption)</p>]]></description>
			<author><![CDATA[dummy@example.com (EDX-0)]]></author>
			<pubDate>Mon, 02 Feb 2026 19:45:10 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61762#p61762</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61745#p61745</link>
			<description><![CDATA[<p>not yet, but I suspect a memory leak from something from afreq</p><div class="codebox"><pre><code>user@~ &gt;&gt;&gt; vmstat
procs -----------memory---------- ---swap-- -----io---- -system-- -------cpu-------
 r  b   swpd   free   buff  cache   si   so    bi    bo   in   cs us sy id wa st gu
 2  0      0 12241312  32060 246648    0    0  3363    46 5112    1  0  1 99  0  0  0
user@~ &gt;&gt;&gt; doas slabtop
doas (user@devx) password: 
user@~ &gt;&gt;&gt; doas pkill afreq
doas (user@devx) password: 
user@~ &gt;&gt;&gt; vmstat
procs -----------memory---------- ---swap-- -----io---- -system-- -------cpu-------
 r  b   swpd   free   buff  cache   si   so    bi    bo   in   cs us sy id wa st gu
 1  0      0 14329644  32228 246996    0    0  1168    17 2130    0  0  1 99  0  0  0</code></pre></div><p>detailed output of pmap :</p><div class="codebox"><pre class="vscroll"><code>2081:   /bin/sh /usr/local/sbin/afreq
     Address Perm   Offset Device   Inode Size  Rss Pss Pss_Dirty Referenced Anonymous KSM LazyFree ShmemPmdMapped FilePmdMapped Shared_Hugetlb Private_Hugetlb Swap SwapPss Locked THPeligible ProtectionKey Mapping
55b965845000 r--p 00000000 103:02 7733880   16   16   4         0         16         0   0        0              0             0              0               0    0       0      0           0             0 dash
55b965849000 r-xp 00004000 103:02 7733880   80   80  20         0         80         0   0        0              0             0              0               0    0       0      0           0             0 dash
55b96585d000 r--p 00018000 103:02 7733880   24   24   6         0         24         0   0        0              0             0              0               0    0       0      0           0             0 dash
55b965863000 r--p 0001d000 103:02 7733880    8    8   8         8          8         8   0        0              0             0              0               0    0       0      0           0             0 dash
55b965865000 rw-p 0001f000 103:02 7733880    4    4   4         4          4         4   0        0              0             0              0               0    0       0      0           0             0 dash
55b965866000 rw-p 00000000  00:00       0    8    8   8         8          8         8   0        0              0             0              0               0    0       0      0           0             0 
55b99787a000 rw-p 00000000  00:00       0  236  116 116       116        116       116   0        0              0             0              0               0    0       0      0           0             0 [heap]
7fa96db3a000 rw-p 00000000  00:00       0   12    8   8         8          8         8   0        0              0             0              0               0    0       0      0           0             0 
7fa96db3d000 r--p 00000000 103:02 7748394  160  160   6         0        160         0   0        0              0             0              0               0    0       0      0           0             0 libc.so.6
7fa96db65000 r-xp 00028000 103:02 7748394 1424 1168  39         0       1168         0   0        0              0             0              0               0    0       0      0           0             0 libc.so.6
7fa96dcc9000 r--p 0018c000 103:02 7748394  344  156   4         0        156         0   0        0              0             0              0               0    0       0      0           0             0 libc.so.6
7fa96dd1f000 r--p 001e1000 103:02 7748394   16   16  16        16         16        16   0        0              0             0              0               0    0       0      0           0             0 libc.so.6
7fa96dd23000 rw-p 001e5000 103:02 7748394    8    8   8         8          8         8   0        0              0             0              0               0    0       0      0           0             0 libc.so.6
7fa96dd25000 rw-p 00000000  00:00       0   52   20  20        20         20        20   0        0              0             0              0               0    0       0      0           0             0 
7fa96dd40000 rw-p 00000000  00:00       0    8    4   4         4          4         4   0        0              0             0              0               0    0       0      0           0             0 
7fa96dd42000 r--p 00000000  00:00       0   16    0   0         0          0         0   0        0              0             0              0               0    0       0      0           0             0 [vvar]
7fa96dd46000 r-xp 00000000  00:00       0    8    8   0         0          8         0   0        0              0             0              0               0    0       0      0           0             0 [vdso]
7fa96dd48000 r--p 00000000 103:02 7748391    4    4   0         0          4         0   0        0              0             0              0               0    0       0      0           0             0 ld-linux-x86-64.so.2
7fa96dd49000 r-xp 00001000 103:02 7748391  160  156   5         0        156         0   0        0              0             0              0               0    0       0      0           0             0 ld-linux-x86-64.so.2
7fa96dd71000 r--p 00029000 103:02 7748391   44   44   1         0         44         0   0        0              0             0              0               0    0       0      0           0             0 ld-linux-x86-64.so.2
7fa96dd7c000 r--p 00034000 103:02 7748391    8    8   8         8          8         8   0        0              0             0              0               0    0       0      0           0             0 ld-linux-x86-64.so.2
7fa96dd7e000 rw-p 00036000 103:02 7748391    4    4   4         4          4         4   0        0              0             0              0               0    0       0      0           0             0 ld-linux-x86-64.so.2
7fa96dd7f000 rw-p 00000000  00:00       0    4    4   4         4          4         4   0        0              0             0              0               0    0       0      0           0             0 
7fffdd501000 rw-p 00000000  00:00       0  132   12  12        12         12        12   0        0              0             0              0               0    0       0      0           0             0 [stack]
                                          ==== ==== === ========= ========== ========= === ======== ============== ============= ============== =============== ==== ======= ====== =========== ============= 
                                          2780 2036 305       220       2036       220   0        0              0             0              0               0    0       0      0           0             0 KB </code></pre></div><p>Nothing suspicious ? </p><p><em>rofl</em></p>]]></description>
			<author><![CDATA[dummy@example.com (unixuser)]]></author>
			<pubDate>Mon, 02 Feb 2026 13:46:39 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61745#p61745</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61726#p61726</link>
			<description><![CDATA[<p>did ya figure it out?</p>]]></description>
			<author><![CDATA[dummy@example.com (EDX-0)]]></author>
			<pubDate>Mon, 02 Feb 2026 02:34:52 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61726#p61726</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61669#p61669</link>
			<description><![CDATA[<p>this is weird because, with afreq on : </p><div class="codebox"><pre><code>user@~ &gt;&gt;&gt; free -h
               total        used        free      shared  buff/cache   available
Mem:            14Gi       3.1Gi        10Gi        12Mi       635Mi        11Gi
Swap:           11Gi          0B        11Gi</code></pre></div><p>without afreq :</p><div class="codebox"><pre><code>user@~ &gt;&gt;&gt; doas pkill afreq
doas (user@devx) password: 
user@~ &gt;&gt;&gt; free -h
               total        used        free      shared  buff/cache   available
Mem:            14Gi       1.1Gi        12Gi        15Mi       638Mi        13Gi
Swap:           11Gi          0B        11Gi</code></pre></div><p>but it is really using 1.8 MiB :</p><div class="codebox"><pre><code>user@~ &gt;&gt;&gt; ps aux | grep afreq
root      2075  0.1  0.0   2780  1884 ?        S    11:24   0:03 /bin/sh /usr/local/sbin/afreq
user      2625  0.0  0.0   4068  2092 pts/2    S+   11:54   0:00 grep afreq</code></pre></div><p>Edit : yeah, with btop tree view I have almost same numbers as yours. So the problem isn&#039;t from afreq BUT the memory increases only when it&#039;s running... Still working on it lol</p>]]></description>
			<author><![CDATA[dummy@example.com (unixuser)]]></author>
			<pubDate>Sat, 31 Jan 2026 12:17:39 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61669#p61669</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61654#p61654</link>
			<description><![CDATA[<p>that is extremely odd</p><p>you can get the PID of the running afreq instance by running <span class="bbc">cat /var/run/afreq/status</span></p><p>with vmrss <a href="https://github.com/ThePrimeagen/vmrss" rel="nofollow">https://github.com/ThePrimeagen/vmrss</a> it says that afreq is using 1.88281 MB of memory</p><p>with btop tree view on the sleep part of the cycle it shows that afreq is using 1.8 MB while the busybox usleep is consuming also 1.8 MB (yes it does prefer busybox usleep when available as that is more reliable than just hoping sleep supports decimals as the system could be using a sleep implementation other than gnu sleep), the busybox usleep program runs every 500 milliseconds so at about 2MB per millisecond it uses 4 MB each second (even tho those are 2 different invocations), so if a program is measuring the memory usage every X seconds then it may get that afreq is using 6 MB times X seconds, say 5 seconds that ought to sum up to 30 MB, tho i dunno if some system monitoring program measures that way, unless this is some shenanigans with the caches...</p><p><span class="postimg"><img src="https://i.imgur.com/bCKmrpR.png" alt="bCKmrpR.png" /></span></p><p>during tick the programs vmstat, tail, awk and others are invocated, they complete so fast that btop could only register vmstat, tail and awk, in the tick step afreq would have a memory footprint of 12MB (i&#039;m ceiling the sum)</p><p><span class="postimg"><img src="https://i.imgur.com/kMcXDIP.png" alt="kMcXDIP.png" /></span></p><p>looking at htop these are the numbers of resource usage for afreq and as far as i know those are in kilobytes</p><p><span class="postimg"><img src="https://i.imgur.com/9NYkJ2s.png" alt="9NYkJ2s.png" /></span></p><p>so i am at a loss of how afreq could balloon all the way to 1960 megabytes on your machine</p>]]></description>
			<author><![CDATA[dummy@example.com (EDX-0)]]></author>
			<pubDate>Fri, 30 Jan 2026 23:10:39 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61654#p61654</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61652#p61652</link>
			<description><![CDATA[<p>I can&#039;t understand why it uses that much. Well I check with fastfetch, free and i3status. Htop shows 1960 mib for afreq</p>]]></description>
			<author><![CDATA[dummy@example.com (unixuser)]]></author>
			<pubDate>Fri, 30 Jan 2026 21:27:58 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61652#p61652</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61648#p61648</link>
			<description><![CDATA[<p>yes powermgmt-base is a dependency tho the afreq.sh repo bundles a copy of on_ac_power for tho whol don&#039;t want to install powermgmt-base or for distros that don&#039;t ship said package, as for the memory usage that is odd, it really shouldn&#039;t use anywhere even close to that amount of memory consumption as it is a shell script after all, how did you got that number for memory consumption? if you check with btop what does it say? i&#039;m not at home rn so cannot check the memory usage on my personal machine.</p>]]></description>
			<author><![CDATA[dummy@example.com (EDX-0)]]></author>
			<pubDate>Fri, 30 Jan 2026 19:29:43 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61648#p61648</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61647#p61647</link>
			<description><![CDATA[<p>@EDX, I had to get powermgmt-base for a dependence, looks like your program is effective, but it uses 2 Gi of ram Oo I don&#039;t know what causes it yet.</p><p>@fanderal, thanks, I&#039;ll check it out</p>]]></description>
			<author><![CDATA[dummy@example.com (unixuser)]]></author>
			<pubDate>Fri, 30 Jan 2026 18:47:37 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61647#p61647</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61641#p61641</link>
			<description><![CDATA[<div class="quotebox"><cite>unixuser wrote:</cite><blockquote><div><p>auto-cpufeq at startup</p></div></blockquote></div><p>Have you tried linux-cpupower from the repo? It&#039;s a CPU scaling tool and starts at boot. Has a conf file in /etc to set governors and/or min/max frequency.</p>]]></description>
			<author><![CDATA[dummy@example.com (fanderal)]]></author>
			<pubDate>Fri, 30 Jan 2026 17:05:16 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61641#p61641</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61631#p61631</link>
			<description><![CDATA[<p>Thanks EDX, I didn&#039;t know afreq, it looks lighter, you did a good work. I think I&#039;ll use it instead... I&#039;m still using elogind by default anyway.</p><p>If anyone was able to start auto-cpufreq I&#039;d like to know.</p>]]></description>
			<author><![CDATA[dummy@example.com (unixuser)]]></author>
			<pubDate>Fri, 30 Jan 2026 12:52:35 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61631#p61631</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61630#p61630</link>
			<description><![CDATA[<p>yeh auto-cpufreq has one of the designs of all time... that and it requiring python for doing something so simple as it is to just write to a handful of locations inside the kernel sysfs among other reasons got me to write an alternative, it is tried and tested in devuan under sysvinit and elogind, have not tried on even more minimal setups like ones lacking elogind so cannot comment there, also i know it isn&#039;t what you want but just putting it out here since i was also unable to get the auto-cpufreq daemon properly running on devuan</p><p><a href="https://github.com/eylles/afreq.sh" rel="nofollow">https://github.com/eylles/afreq.sh</a></p>]]></description>
			<author><![CDATA[dummy@example.com (EDX-0)]]></author>
			<pubDate>Fri, 30 Jan 2026 12:29:11 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61630#p61630</guid>
		</item>
		<item>
			<title><![CDATA[[SOLVED] struggling starting auto-cpufreq --daemon]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=61629#p61629</link>
			<description><![CDATA[<p>Hi there, </p><p>I&#039;m trying to start auto-cpufeq at startup with init.d, but the --daemon option makes it harder than expected. Here is the script (copied from cron startup) :</p><div class="codebox"><pre class="vscroll"><code>#!/bin/bash
# Start/stop auto-cpufreq daemon.
#
### BEGIN INIT INFO
# Provides:          auto-cpufreq
# Required-Start:    $remote_fs $syslog
# Required-Stop:     $remote_fs $syslog
# Should-Start:    
# Should-Stop:      
# Default-Start:     2 3 4 5
# Default-Stop:
# Short-Description: Regular background program processing daemon
### END INIT INFO

PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin
DESC=&quot;auto-cpufreq daemon&quot;
NAME=auto-cpufreqd
DAEMON=/usr/local/bin/auto-cpufreq --daemon
PIDFILE=/var/run/auto-cpufreq.pid
SCRIPTNAME=/etc/init.d/&quot;$NAME&quot;

test -f &quot;$DAEMON&quot; || exit 0 &amp;&amp; echo &quot;exit 0&quot;

. /lib/lsb/init-functions

case &quot;$1&quot; in
start)	log_daemon_msg &quot;Starting auto-cpufreq daemon&quot;
        start_daemon -p $PIDFILE $DAEMON
        log_end_msg $?
	;;
stop)	log_daemon_msg &quot;Stopping auto-cpufreq daemon&quot;
        killproc -p $PIDFILE $DAEMON
        RETVAL=$?
        [ $RETVAL -eq 0 ] &amp;&amp; [ -e &quot;$PIDFILE&quot; ] &amp;&amp; rm -f $PIDFILE
        log_end_msg $RETVAL
        ;;
status)
        status_of_proc -p $PIDFILE $DAEMON $NAME &amp;&amp; exit 0 || exit $?
        ;;
*)	log_action_msg &quot;Usage: /etc/init.d/auto-cpufreq {start|stop|status}&quot;
        exit 2
        ;;
esac
exit 0</code></pre></div><p>auto-cpufreq is is executable and at /usr/local/bin/<br />Looks like it would start without --daemon option. Sorry for infamous mistakes that mustbe in this script <img src="http://dev1galaxy.org/img/smilies/big_smile.png" width="15" height="15" alt="big_smile" /></p>]]></description>
			<author><![CDATA[dummy@example.com (unixuser)]]></author>
			<pubDate>Fri, 30 Jan 2026 12:02:56 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=61629#p61629</guid>
		</item>
	</channel>
</rss>
