yashsingh1/xdaforums huggingface dataset:
[Samsung Galaxy Nexus] Khrushy:
They wouldn't affect or over-write what you're setting with the scheduler tweaks - they're writing settings to separate files entirely. I personally write those VM settings in my init.d as well and it causes no conflict.

You shouldn't need to edit anything in the file at all - just set your desired scheduler using f.Ku, put the init.d file in the appropriate place with the right permissions and you're good to go.

Just for interest sake, what are the VM settings being set to in your ROM?
[Samsung Galaxy Nexus] J-Hop2o6:
Ok. Will try the original iosetting copy without messing with it. And my vm values are (in the order of my last post): 90/55/20/0/2048/0 .. I'm not too sure how it affects my rom tho.

EDIT: Still not changing/sticking after reboot. Whats the problem?
[Samsung Galaxy Nexus] stevensoaj:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

@ Osm0sis I modified your 950iosettings script to just include the general queue tweaks and it lowered my SD writes from an average of 10+ mb/s to about 3mb/s. Now, I was not on Franco kernel at the time, but are you sure these values are actually improving performance? (I'm not trying to be a jerk, I'm just curious)

Maguro | SlimBean 4.2.2 | AK Cylon 010
[Samsung Galaxy Nexus] Controvrsy046:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

Can anyone provide a script that I can try please?

Sent from my Galaxy Nexus
[Samsung Galaxy Nexus] Khrushy:
Not sure what the problem is - so going to go with the laundry list of usual things to check:

1. script is in etc/init.d/ folder with rwx/r-x/-r-x (755) permissions.

2. Clear the data on f.Ku, Trickster, Performance control, etc - anything that might have "set on boot" settings which are over-writing the script again. (Remember to re-select your desired scheduler in f.Ku afterwards)

3. Rename the sysctrl file (and any others) in init.d to disable them - you can just change it to sysctrl.bak - it shouldn't break anything - and that occasionally causes issues for some.

4. Redownload the script - don't open it at all - and just place it in the init.d folder and set the correct permissions. Maybe you're using a crazy text editor to check and it's screwing the formatting.

5. Dance naked in the rain with a bucket on your head. I prefer a metal one, although some people swear by plastic.

Failing that, not sure sorry.

---------- Post added at 03:32 AM ---------- Previous post was at 03:30 AM ----------

Read back over the last 5 to 10 or so pages - there's tons of info including where to get the all-in-one script and what-not. I'm not going to link it because, honestly, it's not that hard to find.
[Samsung Galaxy Nexus] funkyblue04:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

I'm getting constant slow downs Eg coming back from sleep and unlocking.

Can also be slow to respond to home button.

Using CM 10.1 M2 and r366. What could be causing this?
[Samsung Galaxy Nexus] Khrushy:
What's your current uptime? What governor/scheduler are you using? Anything else we should know about about?

Just by itself the problem is a bit vague.
[Samsung Galaxy Nexus] J-Hop2o6:
That's weird. #3 (changing sysctrl to sysctrl.bak) worked! But I looked inside of it and don't see how that causes 950iosettings not to work. Thx krushy and osmosis for that solution. Still confused about it tho.
[Samsung Galaxy Nexus] Controvrsy046:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

[/QOUTE]

---------- Post added at 03:32 AM ---------- Previous post was at 03:30 AM ----------

[/COLOR]

Read back over the last 5 to 10 or so pages - there's tons of info including where to get the all-in-one script and what-not. I'm not going to link it because, honestly, it's not that hard to find.[/QUOTE]

Then it's probably best to not answer my question at all. I asked because I have done my reading and don't understand the scripts yet so I was asking for help on the topic. These forums are about helping people that might not have the same amount of knowledge on said topic, not about making them feel like idiots.

Sent from my Galaxy Nexus
[Samsung Galaxy Nexus] osm0sis:
What we did there we did mostly by the feel of it. Some lately were done with benchmarks but honestly we weren't seeing much difference. Please tell us the values for the general queue tweaks that your kernel defaults to so we can see what's up.

Actually, believe it or not, this is a franco.Kernel development thread, not the init.d helpdesk, so I'm sorry to say but if you can't figure it out and can't get it working then it's not our problem and you should go ask in a Q&A thread or stop trying to use our test scripts. What we're doing here is testing for advanced users who can provide useful feedback.
[Samsung Galaxy Nexus] J-Hop2o6:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

Any reason why sysctrl was the cause of iosettings not working osmosis?
[Samsung Galaxy Nexus] osm0sis:
If it's not directly messing with the settings we are I don't know why they couldn't co-exist. Good to know that sometimes they can't though. Sort of confirmed a suspicion of mine.
[Samsung Galaxy Nexus] Khrushy:
You posted a single sentence question, with no background information what-so-ever. Nothing as to what you're trying the scripts for, nothing about your setup, nothing about your level of knowledge or what you've tried already, and nothing about what you're trying to learn, if anything, from it.

I'm sorely lacking in the mind reading department, so I said read the last few pages. That would usually result in one of two things:

1) You go and read and then come back with some more specific questions - That's fine. We can then stop guessing as to what you're looking for and what you know and go from there.

2) You crack the ****s at me for not bothering to read your mind, and I can safely choose to ignore you.

Everyone in this thread is doing so from their own time. If you want to know something from them then do the right thing and be clear about what it is, explain what your own knowledge of the topic is so that answers can be tailored to that level, and overall just remember to be polite.
[Samsung Galaxy Nexus] malaroth:
[KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

I've implemented that vm script I shared awhile back with cache pressure at 200 and a couple other tweaks, dirty_expire_centisecs lowered and such. I think the play store updates is a scapegoat for other underlying issues but agree we have to fix all the schedulers not just one or two and Bork the others. As always I'll continue to tweak and screw around with variables till I stumble on another gem. Good work to all that have been helping figure this out. I think that we haven't seen Franco because he sees us working our own stuff out rather than whining for him to fix it like the newer models. :thumbup: osm0sis pkGnex gingerbread Rey
[Samsung Galaxy Nexus] Khrushy:
Just to throw it out there, these are the VM settings I've been using lately.

# vm settings

echo 20 > /proc/sys/vm/dirty_ratio

echo 10 > /proc/sys/vm/dirty_background_ratio

echo 200 > /proc/sys/vm/dirty_expire_centisecs

echo 500 > /proc/sys/vm/dirty_writeback_centisecs

echo 30 > /proc/sys/vm/swappiness

echo 300 > /proc/sys/vm/vfs_cache_pressure

I really like the low dirty ratio with cfq, and the higher cache pressure and low, but not zero swappiness seem to be playing well together. I did try swappiness all the way up at 50 for a bit, but that was definitely not as good. I can't tell any difference between 10, 20 and 30, so I've ended up leaving it at 30.

Haven't really tooled around with the writeback values too much. I lowered them when I first set up the vm settings, but then never really played with them enough to find a sweet spot (from my understanding, those values should have a smaller effect than the others anyway).

Edit: Actually, if people want, I can just link up my io script on dropbox for people to check out. It sets everything I currently use: governor, scheduler, io tweaks, queue tweaks, VM settings, cpu min/max, fast charge and TCP avoidance. Possibly something else too, but I can't be bothered checking right now.
[Samsung Galaxy Nexus] JBNex:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

Are there different optimized VM settings for different io schedulers?
[Samsung Galaxy Nexus] arhung:
This vm setting is for cfq only??
[Samsung Galaxy Nexus] malaroth:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

Vm settings are not scheduler specific. It's virtual memory settings.

---------- Post added at 05:50 AM ---------- Previous post was at 05:48 AM ----------

Yeah krushy I wouldn't mind looking at your script. Couple things I wanna check out and definitely want that fast charge. I'll link you my vm settings and I hadn't played with swappiness but I will
[Samsung Galaxy Nexus] Khrushy:
There we go.

https://www.dropbox.com/s/uh9wwqks6p3dmkw/900io.txt

A few things to note before anyone goes and just copies it for their own use or whatever.

It sets the Governor to interactive, along with the interactive sweet spot settings. That's probably unnecessary now, because I think Franco made them default in 366 - anyway.

Scheduler set to cfq, but that's easy for you to change. It applies the tweaks for all the schedulers like the all-in-one of Malaroth's, whom I pretty much copypasta'd that entire section from ^^ (I usually comment out the unused ones, but I'll leave them non-commented for this).

Min CPU is set to 192. Max to 1.2ghz.

TCP avoidance is set to Westwood.

My colour profile is pretty bright compared to most (I set it that way to offset the auto-brightness feature, which seems to err on the side of dark on my GNex)

The fast charge setting gets over-written by a lot of "set on boot" programs. To get it to stick properly as part of the init.d I had to freeze Performance control in AOKP,

And, the rest you can most easily see for yourself anyway I think.
[Samsung Galaxy Nexus] AdrianE46:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

Concerning your stated autobrightness issue, you can try velis autobrightness. Works great for me.

And thanks for the upload, btw. :)

Sent from my Galaxy Nexus.
[Samsung Galaxy Nexus] stevensoaj:
Sure thing! How can I see those values?

Edit:

Nevermind, found them.

nr_requests 128

read_ahead_kb 256

rq_affinity 1

nomerges 0

rotational 0

iostats 1
[Samsung Galaxy Nexus] osm0sis:
Thanks! AK Cylon still? Okay. Try read_ahead_kb 512, iostats 0 in the init.d but leave nr_requests at 128. Then see if you're still seeing the reduced speeds you reported before. :good:
[Samsung Galaxy Nexus] stevensoaj:
I just flashed the new version, AK 014. I'm going to check if the values are still the same on this one, rerun antutu to test the speeds, then I'll apply the values you suggested. I'll edit this post with the results. :good:

Edit:

Average write speed from 4 tests: 11.45mb/s

After applying the script, average from 4 tests: 11.625mb/s

So this time, it was actually slightly higher after the script. Maybe nr_requests is the cause? Or rq_affinity, I commented that one out too because you didn't say to apply anything.

Here's the script I used, in case you want to see it. It's just the top part of yours, with everything commented out except the values you said to apply.

#!/system/bin/sh
# chmod -R 755 /system/etc/init.d

# wait for android os
until [ `pidof com.android.systemui` != "" ]; do
sleep 1
done;
sleep 25;

# general queue tweaks
#echo 1024 > /sys/block/mmcblk0/queue/nr_requests;
echo 512 > /sys/block/mmcblk0/queue/read_ahead_kb;
#echo 2 > /sys/block/mmcblk0/queue/rq_affinity;
#echo 1 > /sys/block/mmcblk0/queue/nomerges;
#echo 0 > /sys/block/mmcblk0/queue/rotational;
echo 0 > /sys/block/mmcblk0/queue/iostats;
[Samsung Galaxy Nexus] osm0sis:
Oh you still had nomerges at 1 and nr_requests at 1024? That's not even close to my latest version and that's almost definitely what was crippling your sh*t. :p

rq_affinity defaults to 1, and 2 only works on newer kernel revisions (N7, N4, N10), so setting it to 2 actually just keeps it at 1 on the GN. rotational also defaults to 0 so nothing to worry about with either of those.

Try the latest values please:

# general queue tweaks
echo 512 > /sys/block/mmcblk0/queue/nr_requests;
echo 512 > /sys/block/mmcblk0/queue/read_ahead_kb;
echo 2 > /sys/block/mmcblk0/queue/rq_affinity;
echo 0 > /sys/block/mmcblk0/queue/nomerges;
echo 0 > /sys/block/mmcblk0/queue/rotational;
echo 0 > /sys/block/mmcblk0/queue/iostats;

If the writes are poor then change nr_requests back to 128 and try again please. Thanks for your help. :)
[Samsung Galaxy Nexus] stevensoaj:
No wonder! I think I actually grabbed that script from maraloth's sig. How can I get to yours? (You don't have to answer that, it's probably been posted before and I can find it when I search through the thread in a bit.)

I just uncommented all the values, changed them to the updated ones, and now I'm averaging 11.9mb/s. :highfive:

Guess that's not why franco.kernel seems to have much lower write speeds then. Hmm...
[Samsung Galaxy Nexus] osm0sis:
Nice! On to the vm tweaks then. ;)

Also worth noting AK has a few other schedulers we don't, like fiops by default, sio, and others, but that shouldn't matter too much if ours are tweaked correctly. Franco has some different vm stuff going on that I'm looking into now while we take a break from cfq.

Oh, and http://d-h.st/users/osm0sis :good:

Edit: Only difference between AK Cylon and f.K r366 vm settings is the vfs cache pressure. Franco set to 1, AK is at 100, Franco used to have it at 300 back in r315 until sometime between then and r364.

Here are our settings to test based on what they were in the early r3xx vs other kernels/ROMs vs now:

/proc/sys/vm/dirty_background_ratio 10 or 5

/proc/sys/vm/dirty_writeback_centisecs 500 or 0

/proc/sys/vm/vfs_cache_pressure 100, 300, or 1
[Samsung Galaxy Nexus] stevensoaj:
He just started a new version with a new base. It only has noop, deadline, sio, and cfq and only has 4 frequency slots at the moment.

Anyway, let me know if you want me to check some values on this kernel so that we can compare. :highfive:

Ha, you ninja edited. Guess we don't need to compare values after all, you already have them!

---------- Post added at 12:22 PM ---------- Previous post was at 12:15 PM ----------

Guess I can just make a separate init.d script and echo those values on boot? I'll test them on AK and see what the difference is.

For the record, here's the defaults for AK

dirty_background_ratio: 50

dirty_writeback_centisecs: 1000

vfs_cache_pressure: 40

I guess AK changed the defaults on this new release.
[Samsung Galaxy Nexus] osm0sis:
Ah must have. I got the 100 from Cylon. Guess AK is all over the map with the vm settings too..

"Light" reading: https://www.kernel.org/doc/Documentation/sysctl/vm.txt :p
[Samsung Galaxy Nexus] grognaz:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

any news on the sdcard write slowdown after installing 366 to 1mb/s ?
[Samsung Galaxy Nexus] Schneewitzchen:
AW: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

Here is something imoseyon thinks about the values:

http://www.imoseyon.com/2011/01/sysctl-tweaking-for-faster-longer.html?m=1

I'm running his tweaks for dirty ratio, dirty background ratio, vfs cache pressure and your latest queue and deadline settings!

Dunno if it's just a placebo but they feel better than Franco's stock for me!

Btw I'm running stock rom.
[Samsung Galaxy Nexus] Raijin:
Is there any way to disable the Franco's stronger app cleaner of memory? Or set it like stock. I mean, the system that closes the apps with lower priority.

Time ago I had problems with WhatsApp, receiving messages later, until I put a script in Init.d. Now I think Gmail is the same, because I have sent a mail from another account to the one that is configured on my phone.

I was in launcher, but no push notification, and in webmail in my PC the message is received correctly. Even when I enter the Gmail app in phone.

The notification is shown later.
[Samsung Galaxy Nexus] Khrushy:
So I was slutting around in the Fancy Kernel thread and then went on a reading chain regarding that kernel's -dismount command, which led to the TRIM command, which led to this thread regarding bad SD card performance on the GNex:

http://xdaforums.com/showthread.php?t=1971852

You could give that a go perhaps?
[Samsung Galaxy Nexus] Fenvarien:
I tested the vm stuff yesterday. IMHO a vfs_cache_pressure of 50 works really good. Thanks for sharing your script, Khrushy!

Here are my current vm settings:

echo 20 > /proc/sys/vm/dirty_ratio
echo 10 > /proc/sys/vm/dirty_background_ratio
echo 200 > /proc/sys/vm/dirty_expire_centisecs
echo 500 > /proc/sys/vm/dirty_writeback_centisecs
echo 30 > /proc/sys/vm/swappiness
echo 50 > /proc/sys/vm/vfs_cache_pressure
[Samsung Galaxy Nexus] denvro:
Hi,

I'm new to the Galaxy Nexus and it's ROMs and kernels. I come from a Galaxy S2 running CM10 and siyah kernel. Just flashed CM10.1 to my Nexus (because i love this rom), can i use Franco's kernel with it? Already flashed r366 (with fastboot) but then my phone wouldn't boot, so went back to stock CM kernel. Would love to try this kernel, because it looks very (c)lean, and tweakable.

Kind Regards,

Dennis
[Samsung Galaxy Nexus] reysonance:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

You should be able to, I'm currently running the same combination in fact.
[Samsung Galaxy Nexus] Khrushy:
Hey man, welcome. You can definitely use this kernel, it just depends which version of Android your CM 10.1 is based on (Check in Settings / About Phone).

4.2.2 based -> Franco 366

4.2 or 4.2.1 based -> Franco 364

Both are linked in the first post. AFAIK, CM 10.1 has been updated to 4.2.2 hasn't it?

Cheers
[Samsung Galaxy Nexus] reysonance:
Re: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

Yep, 4.2.2 is merged in the Feb 15-16 build or something... So it's odd it doesn't boot.
[Samsung Galaxy Nexus] denvro:
Yes, CM10.1 is 4.2.2. Just flashed r366 again, and it's booting right now :good:

Time to play around with some settings now :D, any tips?
[Samsung Galaxy Nexus] Khrushy:
For the most part the defaults are pretty good - those defaults are the result of a lot of hard work and testing by many of the guys in this thread.

I'd suggest just using it for a couple of days and seeing how you like it, and keep an eye on the thread - there's a lot of discussion of all sorts of various settings going on right now that can teach a lot if you're interested in following it.
[Samsung Galaxy Nexus] Angelakaro:
R: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

I tried it sometimes ago without solving. Only after i flashed AK kernel my SD performance became optimal again. It's something related to kernel,i'm sure. Maybe franco is already working on it

Inviato dal mio Galaxy Nexus
[Samsung Galaxy Nexus] osm0sis:
I'm assuming you didn't try our general tweaks either? No problem with AndroBench results here anymore. Look back to the ones I posted to stevensoaj. If you can't figure that out roll back to r365 since it doesn't have nomerges enabled either, then please report back on your findings.
[Samsung Galaxy Nexus] Angelakaro:
R: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

Now i'm testing AK and also i'm having bootloop switching to another kernel (maybe i'll need to reflash system) and since AK seems good enough ,i'll come back here when a new build is released. Sorry,i 'm not complaining :p

I hope i won't be burned alive to be a traitor ;)

Inviato dal mio Galaxy Nexus
[Samsung Galaxy Nexus] osm0sis:
I wasn't accusing you of complaining or being a traitor. I am asking for your help in troubleshooting. Please try r365 and see if it resolves your write speed issues.
[Samsung Galaxy Nexus] pkgnex:
I have to respectively disagree with Khrushy on this one. You may be referring to Android's built in low-memory killer min-free settings. Franco himself has been all over the map on these in the past. If you are increasing anything besides the last value too high, you can run into the problems you describe. I'll follow up later with more info (may take a day or two because I'm getting slammed at work), but you can google Android minfree and find some reading. Basically, the numbers go from most active and in-use apps and services to less active ones, and finally to unused empty ones. The last number is where you can most easily increase the value to keep more ram available and not kill too many processes that you may not really want to.
[Samsung Galaxy Nexus] Angelakaro:
R: [KERNEL][GPL][GN] franco.Kernel r366 -&gt; 4.2.2 | r364 -&gt; 4.2 | r300 -&gt; 4.1

I know,i was only joking! However i'm going to try it now,wait some minutes..

Inviato dal mio Galaxy Nexus

---------- Post added at 01:00 PM ---------- Previous post was at 12:46 PM ----------

Tried r365 with antutu ,SD card performance is perfect (8.7 mbps write and 16.6 mbps read).

Do you know why i have to reflash ROM to switch back from AK to franco?

Inviato dal mio Galaxy Nexus

---------- Post added at 01:06 PM ---------- Previous post was at 01:00 PM ----------

2nd test: 9.8 mbps with 22.5 mbps.

Inviato dal mio Galaxy Nexus
[Samsung Galaxy Nexus] Khrushy:
What Os is getting at is the fact it's probably because no_merges = 1 in 366 by default. After further testing that's been generally acclaimed as a Bad Idea.

By flashing 365 you went back to no_merges = 0, which is a much better plan.
[Samsung Galaxy Nexus] pkgnex:
This should kick off some good discussion, and maybe help some people out. Attached is a init.d script I have been running for a long time that I have found to work well for the VM, minfree, and kernel entropy settings.

Even better, where possible, I have documented the Android or Linux default values, so it may help frame the VM discussion. My experience is that the guys who developed android are pretty smart, so large deviation from the defaults should be viewed with skepticism... although sometimes they do work well... just need a lot of verification to make sure!
[Samsung Galaxy Nexus] osm0sis:
Franco has toyed with lmk in the past but as far as I know we've been running stock JB defaults for it since 4.2, and it's generally performed better than any custom tuning we tried.
[Samsung Galaxy Nexus] pkgnex:
Fair enough. I like increasing the last value to purge empty apps earlier, but I agree that android default works fine.

Maybe the VM values will be of some value to the recent discussions at least?

BTW, I'm sure someone will point out that swappiness does nothing with franco kernel... You can set it to 0 or omit it. I just leave it at 20 in case i run a swap-enabled kernel and forget to reset the value. I don't particularly like running a lot of swap even when it's available, but setting swappiness to a low non-zero number at least makes it so I'm not completely throwing my swap space away, so to speak.
[Samsung Galaxy Nexus] osm0sis:
I seemed to recall Francisco saying that before but I was playing with it anyway. Despite that I thought 30 did something nice but I guess that could just be placebo. ;)
[Samsung Galaxy Nexus] Khrushy:
Just to clarify, I was talking about the inbuilt Android low-mem killer.

oom_kill_allocating_task is the command to set whether it just simply kills the task that calls the low mem situation, or whether it uses heuristics to work out which task of all those active in memory is the best to kill.

I haven't really played with minfree mem myself - I've just got mine set at the default it came with of 2048k, so no input from me there.