maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Maemo 5 / Fremantle (https://talk.maemo.org/forumdisplay.php?f=40)
-   -   [ANNOUNCE] COMPCACHE on kernel-power (now with notifications) (https://talk.maemo.org/showthread.php?t=76112)

BertvanDorp 2012-05-29 21:10

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
I ran just SwapSet (without swap-to-SD), and noticed the tracker going down as well.

vi_ 2012-05-29 21:25

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
Like I said this all a bit experimental right now. Anyway, the VM settings have been tweaked to:

Code:

echo 3 > /proc/sys/vm/dirty_ratio
echo 3 > /proc/sys/vm/dirty_background_ratio
echo 100 > /proc/sys/vm/dirty_writeback_centisecs
echo 100 > /proc/sys/vm/dirty_expire_centisecs
echo 1024 > /proc/sys/vm/min_free_kbytes
echo 95 > /proc/sys/vm/swappiness
echo 250 > /proc/sys/vm/vfs_cache_pressure
echo 0 > /proc/sys/vm/page-cluster
echo 512 > /sys/block/mmcblk0/queue/nr_requests
echo 512 > /sys/block/mmcblk1/queue/nr_requests
echo 0 > /sys/block/mmcblk0/queue/iosched/slice_idle
echo 0 > /sys/block/mmcblk1/queue/iosched/slice_idle
echo 16 > /sys/block/mmcblk0/queue/iosched/quantum
echo 16 > /sys/block/mmcblk1/queue/iosched/quantum
echo 64 > /sys/block/mmcblk0/queue/iosched/fifo_expire_sync
echo 64 > /sys/block/mmcblk1/queue/iosched/fifo_expire_sync
echo 64 > /sys/block/mmcblk0/queue/iosched/fifo_expire_async
echo 64 > /sys/block/mmcblk1/queue/iosched/fifo_expire_async

  1. Do not use old settings, the min_free_kb is too low and will cause insta-crash when launching camera. This possibly also responsibile for tracker crash, tracker is just more graceful about it.
  2. You ABSOLUTELY MUST remove all traces of swappolube.

I have been using the above with a 128MB ramz. Freemangordon (the coder behind this) calls this unsane and reccomends 64MB max.

Try for yourself, report back.

vi_ 2012-05-29 21:31

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
Quote:

Originally Posted by mr_jrt (Post 1214501)
I'm the chappie who threw together swapset. I've tried the above settings with it and it works awesomely. The settings caused resets under load for me at first, but I realised I still had a very old set of settings in my /etc/default/kernel-power file, and after dumping those all seems well. I might try overclocking again to see if I can get the best of both world...but awesome job for that bit of tuning. I stopped looking at swapset when I realised compcache had awful performance with my current settings, but I might go back to it now and have it automatically swap between vm settings based upon whether you have compcache in use. Might have to add a conflicts with swapolube though...or perhaps just override it? Hmmm...

Yes it MUST overide swappolubes settings. They are the reason ramz performance was blowing goatz.

impeham 2012-05-29 23:19

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
Quote:

Originally Posted by vi_ (Post 1214628)
Like I said this all a bit experimental right now. Anyway, the VM settings have been tweaked to:

Code:

echo 3 > /proc/sys/vm/dirty_ratio
echo 3 > /proc/sys/vm/dirty_background_ratio
echo 100 > /proc/sys/vm/dirty_writeback_centisecs
echo 100 > /proc/sys/vm/dirty_expire_centisecs
echo 1024 > /proc/sys/vm/min_free_kbytes
echo 95 > /proc/sys/vm/swappiness
echo 250 > /proc/sys/vm/vfs_cache_pressure
echo 0 > /proc/sys/vm/page-cluster
echo 512 > /sys/block/mmcblk0/queue/nr_requests
echo 512 > /sys/block/mmcblk1/queue/nr_requests
echo 0 > /sys/block/mmcblk0/queue/iosched/slice_idle
echo 0 > /sys/block/mmcblk1/queue/iosched/slice_idle
echo 16 > /sys/block/mmcblk0/queue/iosched/quantum
echo 16 > /sys/block/mmcblk1/queue/iosched/quantum
echo 64 > /sys/block/mmcblk0/queue/iosched/fifo_expire_sync
echo 64 > /sys/block/mmcblk1/queue/iosched/fifo_expire_sync
echo 64 > /sys/block/mmcblk0/queue/iosched/fifo_expire_async
echo 64 > /sys/block/mmcblk1/queue/iosched/fifo_expire_async

  1. Do not use old settings, the min_free_kb is too low and will cause insta-crash when launching camera. This possibly also responsibile for tracker crash, tracker is just more graceful about it.
  2. You ABSOLUTELY MUST remove all traces of swappolube.

I have been using the above with a 128MB ramz. Freemangordon (the coder behind this) calls this unsane and reccomends 64MB max.

Try for yourself, report back.

i removed swappolube and set these settings. i'll test this from tomorrow to see how it is - but i'll be using the 64mb swap instead of 128 - i think the 128 is too much since most of the time the device is already above 128.

i've resolved the tracker issue - it seems that the problem was somehow related to queen beecon: i've created a new widget which the OS didn't seem to like and by removing it everything's ok now.
i'll check why this widget made a problem.

[DarkGUNMAN] 2012-05-30 07:13

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
Been trying trying settings for a couple of days, along with swap on SDcard partition.. It seems my N900 will reboot after a while when using SD swap - verified on stock kernel and SDswap only, may be due to the fact it is a 1st gen SANDisk 8Gb card and might not be fast enough, so I'm running tests using default eMMC swap and ramzswap.

Using 128mb cache the device was still responsive even during an update using HAM.. I now have it launched as an event.d script.
i will try the new settings and see how it goes, in particular if it affects battery life due to RAM usage instead of eMMC access.

Is it possible to launch this earlier in the boot process, as part of RCS_LATE?

peterleinchen 2012-05-30 07:23

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
Good morning.

Removed swappolube tuning file and all other settings, enabled ramzswap after (hint for DarkGunman:) start on started ke-recv, loaded vi_'s settings.

AND GOT THIS AFTER A FEW MINUTES USING :
Code:

~ $ iostat -m
Linux 2.6.28.10-power50 (delite)        05/30/12        _armv7l_        (1 CPU)

avg-cpu:  %user  %nice %system %iowait  %steal  %idle
          23.49    0.05  17.05  19.12    0.00  40.29

Device:            tps    MB_read/s    MB_wrtn/s    MB_read    MB_wrtn
mmcblk1          84.34        2.02        0.21      2101        222
mmcblk1p1        84.33        2.02        0.21      2101        222
rootfs          137.96        0.15        0.00        157          2
log              0.19        0.00        0.00          0          0
config            6.93        0.00        0.00          0          0
mmcblk0          13.22        0.14        0.01        149          9
mmcblk0p1        0.85        0.01        0.00        15          0
mmcblk0p2        12.35        0.13        0.01        134          9
mmcblk0p3        0.01        0.00        0.00          0          0
rootfs            0.00        0.00        0.00          0          0
log              0.00        0.00        0.00          0          0
config            0.00        0.00        0.00          0          0

And this after/during writing this:
Code:

~ $ iostat -m
Linux 2.6.28.10-power50 (delite)        05/30/12        _armv7l_        (1 CPU)

avg-cpu:  %user  %nice %system %iowait  %steal  %idle
          20.26    0.04  15.47  21.39    0.00  42.84

Device:            tps    MB_read/s    MB_wrtn/s    MB_read    MB_wrtn
mmcblk1        102.14        2.21        0.18      3270        270
mmcblk1p1      102.14        2.21        0.18      3270        270
rootfs          116.65        0.13        0.00        193          2
log              0.13        0.00        0.00          0          0
config            4.87        0.00        0.00          0          0
mmcblk0          9.90        0.11        0.01        167        10
mmcblk0p1        0.59        0.01        0.00        15          0
mmcblk0p2        9.29        0.10        0.01        152        10
mmcblk0p3        0.01        0.00        0.00          0          0
rootfs            0.00        0.00        0.00          0          0
log              0.00        0.00        0.00          0          0
config            0.00        0.00        0.00          0          0

Also it is not as snappy as before.

Keep in mind that I have swap on a swap file on SD (mmcblk1p1).
I dont think this is sane and therefore I will wait for some more testers.

BertvanDorp 2012-05-30 08:22

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
Ran the 'old' settings:
Quote:

echo 3 > /proc/sys/vm/dirty_ratio
echo 3 > /proc/sys/vm/dirty_background_ratio
echo 100 > /proc/sys/vm/dirty_writeback_centisecs
echo 100 > /proc/sys/vm/dirty_expire_centisecs
echo 32 > /proc/sys/vm/min_free_kbytes
echo 95 > /proc/sys/vm/swappiness
echo 666 > /proc/sys/vm/vfs_cache_pressure
echo 0 > /proc/sys/vm/page-cluster
echo 4 > /sys/block/mmcblk0/queue/nr_requests
echo 4 > /sys/block/mmcblk1/queue/nr_requests
Device is still responsive after a day. Tracker runs, camera is able to launch (this didn't work with Swappolube settings and SwapSet), but now I'm getting the message that states I can't send or reviece messages: device memory full.

Trying new settings now. @mr_jrt: including in SwapSet would be great, since it's clearly the only way to get ramz to work properly. You can also set Swappolube as a conflicting package, so users have to choose (does this make sense?).

zimon 2012-05-30 09:12

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
Quote:

Originally Posted by peterleinchen (Post 1214788)
Code:

~ $ iostat -m
Linux 2.6.28.10-power50 (delite)        05/30/12        _armv7l_        (1 CPU)


Where did you get iostat for N900?
dpkg --search `which iostat`

Edit: ah, apt-cache search iostat
-> sysstat

vi_ 2012-05-30 10:02

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
Quote:

Originally Posted by BertvanDorp (Post 1214819)
Ran the 'old' settings:

Device is still responsive after a day. Tracker runs, camera is able to launch (this didn't work with Swappolube settings and SwapSet), but now I'm getting the message that states I can't send or reviece messages: device memory full.

Trying new settings now. @mr_jrt: including in SwapSet would be great, since it's clearly the only way to get ramz to work properly. You can also set Swappolube as a conflicting package, so users have to choose (does this make sense?).

Not really such a great idea, what if someone is using uSD but not ramz and wants swappolube settings?

I would encourage everyone to only use these settings as a start point and try to find what is optimal for the n900. Also, DO NOT USE:

Code:

echo 32 > /proc/sys/vm/min_free_kbytes
It is just too damn low. use this instead:

Code:

echo 1024 > /proc/sys/vm/min_free_kbytes

A good source of info is this

Finally I would not be so hasty to add this to your start up unless you are comfortable with using a rescue console to undo what may go wrong.

don_falcone 2012-05-30 12:03

Re: [ANNOUNCE] COMPCACHE on kernel-power (now with notifications)
 
Indeed 32 may be too little. Otherwise i couldn't explain memory read-only errors during a dpkg run.


All times are GMT. The time now is 17:18.

vBulletin® Version 3.8.8