yashsingh1/xdaforums huggingface dataset:
[Redmi Note 2 Android Development] jajk:
[MENTION=228200]fossean[/MENTION] Yes there were some strange things going on with the tiny commands. Originally the mkswap / swapon commands were not present due to the primitive stock version of BB. Updating BB added and made these commands work. I don't know why I revisited this as swap has always worked for me (with tiny commands) but the outcome is good if it helps others that were denied the joys of having swap:)

[MENTION=5850987]DarthJabba9[/MENTION] Not so if you installed BB from my updater that

automatically creates symlinks

to all included commands. You must like typing full paths since I remember you chose not to install the symlinks. Why haven't you questioned why I disabled batterywarning or something obvious like that?

Always one that has to swim upstream:rolleyes:
[Redmi Note 2 Android Development] DarthJabba9:
Not at all. I prefer not to have a ton of symlinks, and I prefer to use bash aliases. I was simply pointing out that the command will fail if there is no symlink - and I don't think everyone is going to use your install script for busybox. It is straightforward enough to prepend "busybox" to this command in an init.d script - and it only needs to be done once. On the other hand, there may be any number of reasons why someone might want or need to use a different version of busybox, or to install it in a different way (e.g., by just copying it over). Presumably you want your solutions to be easily accessible to everyone, without them having to use your busybox install script...

Hmm ... I don't see any upstream swimming here. It is trivial (only takes 1 line)

for i in $(busybox --list -full); do eval alias ${i}=\"busybox ${i}\"; done; unset i

to automatically create (in bashrc) aliases for all existing BB applets , which automatically become available to all terminal programs running bash. This doesn't involve installing a ton of symlinks which might then be broken if one installs a different version of busybox. Of course the bash aliases are not available when called in a script, especially one that doesn't use bash for its shebang (which is why one just needs to

add one word

to the script - that doesn't seem so hard!).
[Redmi Note 2 Android Development] Migueliyo98:
It´s necessary to do steps 2, 3 and 4? Or I can skip this ones and works perfectly?
[Redmi Note 2 Android Development] jajk:
[MENTION=5850987]DarthJabba9[/MENTION] Chill - I was having you on. The audience (I hope) is technical enough to make their own choices and understand there is more than one possibility. If I try to account for every possible scenario, this thread would become unreadable.

[MENTION=6242714]Migueliyo98[/MENTION] You can just load the boot.img and it will function but not up to the potential it creates.

Example: The boot.img by itself gets rid of MIUI's complicated swap drive manipulation so that you can implement your own. If you do not implement your own (via an init.d script), you end up with a less than ideal system running no swap drive and stupidly high stock LMK settings. This will lead to apps being killed off regularly which, apart from being annoying, is not too good on battery either.

So the answer is do at least the perfservscntbl.txt edit and the example init.d script as shown (copy and paste) otherwise you will not get benefits on offer.
[Redmi Note 2 Android Development] jerryshaw12:
You should be MIUI dev to make MIUI good :laugh:
[Redmi Note 2 Android Development] jajk:
This one is for the more adventurous.....don't use this one unless you are O.K with the loss of most logging.

714-10 uploaded.

Changelog:

Disable logd

Disable Dumpstate

Change loglevel from 6 > 0

This disables the core Android logging services which is different to 714-9 which disables added Xiaomi/Mediatek logging/spying - the logs are sent to Xiaomi (if they can) and include a lot of activity reporting such as what media files you have opened, porno sites you have visited etc.

If you want to know what services are running from the boot process, in terminal, type getprop Then look at init.svc.xxx and see what is labelled as Running

If you flash a stock boot.img, the list of what is running will grow substantially;)

[MENTION=6150156]jerryshaw12[/MENTION] I almost vomit when browsing official MIUI sites. So how about no - ritualized ass kissing is not my scene:eek:
[Redmi Note 2 Android Development] Sleepy_Augie:
[MENTION=5952980]jajk[/MENTION] You sure no more aosp versions? I reinstalled my backup of miui, but found it less satisfactory than aosp.
[Redmi Note 2 Android Development] jajk:
And again for the insane crazy delirious adventurous MIUI 714-11 is posted.

Changelog:

disable debuggerd

disable debuggerd64

disable init.trace.rc completely

Who really needs that stuff anyway?

[MENTION=7150090]Sleepy_Augie[/MENTION] What MIUI version would you like to be converted to the AOSP version? i.e. do you want the AOSP version of 714-9, 10, or 11? I assume you are on a 1.8x version, not the 1.95 one?

Edit: AOSP_18x-11 is up. [MENTION=7150090]Sleepy_Augie[/MENTION] You can be one of the adventurous.

This is the same as MIUI version 11 but with MIUI bits deleted and keeps the kernel from AOSP 1.83 whatever that was???

Adjust your init.d scripts to take advantage of latest changes when moving to this version. What applies to MIUI equally applies to AOSP when running these images.
[Redmi Note 2 Android Development] Sleepy_Augie:
[MENTION=5952980]jajk[/MENTION] thanks! Using your boot image now. I am on 1.83 but once vova updates past 2.0, I'm going to update. (Might be placebo, but I feel like your boot images always fix the glitchy-ness that use to occur on aosp).
[Redmi Note 2 Android Development] jajk:
[MENTION=7150090]Sleepy_Augie[/MENTION] Wrong thread for placebos:)

Latest version performs like a racehorse providing you have a good init.d script. Try this exactly as it is if you have a 2GHz cpu and are running fairly clean AOSP or MIUI: (Requires updated Busybox with symlinks to BB commands otherwise full path to BB commands must be added)

#!/system/bin/sh

# Tweak CPU Governor
echo 806000 > /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq
echo 85 > /sys/devices/system/cpu/cpufreq/interactive/go_hispeed_load
echo 95 403000:80 806000:85 1326000:90 1625000:95 1950000:99 > /sys/devices/system/cpu/cpufreq/interactive/target_loads
echo 31000 > /sys/devices/system/cpu/cpufreq/interactive/timer_rate
echo 8000 > /sys/devices/system/cpu/cpufreq/interactive/min_sample_time
echo 5000 > /sys/devices/system/cpu/cpufreq/interactive/above_hispeed_delay
echo 10000 > /sys/devices/system/cpu/cpufreq/interactive/timer_slack

#Tweak LMK
echo 2048,4096,8192,16384,24576,32768 > /sys/module/lowmemorykiller/parameters/minfree ### In MB= 8,16,32,64,96,128 MIUI Default: 72,90,108,126,219,317

#Enable zram
echo 536870912 > /sys/block/zram0/disksize ### 536870912 = 512MB 1073741824 = 1GB
/system/xbin/mkswap /dev/block/zram0
/system/xbin/swapon /dev/block/zram0

#Tweak VM
echo 300 > /proc/sys/vm/dirty_expire_centisecs
echo 500 > /proc/sys/vm/dirty_writeback_centisecs

# Tweak IO Scheduler
echo deadline > /sys/block/mmcblk0/queue/scheduler
echo 256 > /sys/block/mmcblk0/queue/read_ahead_kb

#Tweak Entropy
echo 512 > /proc/sys/kernel/random/read_wakeup_threshold
echo 1024 > /proc/sys/kernel/random/write_wakeup_threshold

#Tweak for wifi router connection issues
echo 1 > /proc/sys/net/ipv6/conf/wlan0/disable_ipv6

# Disable debugging on some modules
echo "0" > /sys/module/alarm_dev/parameters/debug_mask;
echo "0" > /sys/module/alarmtimer/parameters/debug_mask;
echo "0" > /sys/module/binder/parameters/debug_mask;
echo "0" > /sys/module/earlysuspend/parameters/debug_mask;
echo "0" > /sys/module/sbsuspend/parameters/sbsuspend_debug_mask;
echo "0" > /sys/module/snd/parameters/debug;

#FSTRIM
fstrim /data
fstrim /system
fstrim /cache
[Redmi Note 2 Android Development] Sleepy_Augie:
Is this bit only for fstrim functionality?
[Redmi Note 2 Android Development] DarthJabba9:
Yes.
[Redmi Note 2 Android Development] jajk:
And mkswap and swapon which are provided by BB as opposed to tiny_mkswap and tiny_swapon which are self-contained commands provided by stock ROM.
[Redmi Note 2 Android Development] DarthJabba9:
Mea culpa ...
[Redmi Note 2 Android Development] jajk:
Skinny Pro image added for Redmi Note 3 based on 7.2.50 ROM.

Only difference between this and Redmi Note 2 version is it does not disable Fingerprint services.

This is a work in progress with 1 tester. Anyone with a RN3 is welcome to join in.
[Redmi Note 2 Android Development] jajk:
714-12 for MIUI is up.

Reverts some fstab changes - no evidence of benefit so out they go.

Disabled some more lines for non-existent devices.

Maybe some more things I can't remember.

I would like to know if anyone else is running these last versions successfully???? It is pretty brutal to kill off almost all logging / debugging but it works perfectly for me at least.

Tell me what it has broken for you if anything.
[Redmi Note 2 Android Development] sil_rain:
i use latest verisons. all is ok, find no issues. Will try your 12 verison. Thanks for your work man
[Redmi Note 2 Android Development] Sleepy_Augie:
[MENTION=5952980]jajk[/MENTION] the latest aosp version boot image you made is giving more performance, but I'm noticing more reboots. I am sure it is something on my end (probably some exposed stuff), but I have no idea what the conflict is. Number of reboots in a day is steadily increasing. Idk, just reporting my experiences with a new-ish version.

Edit: on a different note, L speed [root] looks tempting, and many of the tweaks look relevant, if a little vague (wuts liquid smooth ui?). Would any of these tweaks be able to be integrated into the boot.img? Even without integrating into boot, is this app worth using (placebo or no?)?
[Redmi Note 2 Android Development] jajk:
[MENTION=4765043]sil_rain[/MENTION] Good to get feedback thanks. Sometimes there is zero feedback for extended periods so I have no clue if it is useful or not to keep advancing or whether I have parted ways with the audience.

[MENTION=7150090]Sleepy_Augie[/MENTION] My boot.img doesn't cause the reboots - they have always been there in the AOSP ROM.

My philosophy is to never embed tweaks that belong in the init.d realm and to never use an app to do what a simple edit can do. Using my boot.img, you can "embed" any and all desirable looking tweaks into your own init.d script or build.prop - how cool is that:good:

I have uploaded the ramdisk init script files for 714-12 (initrd714-12 folder) so anyone can see what the edits are without having to download and unpack or install the boot.img.

All straight disabling edits are obvious by the ### characters. Some edits have involved shifting contents between files which is not so obvious and some are deletions of entire files that have become or always were redundant. Some edits are rearranging just to get better readability. If you can spot any more redundancy in these files, I would love to know.
[Redmi Note 2 Android Development] jajk:
It is ironic that I am the only one that cannot get zram to work - not that I want or need it but now I am getting angry:mad:

For those that have happily working zrams, how about trying another twist on the theme:

There are 3 versions of files for mkswap, swapon and swapoff in our ROMs

1. In /system/bin we have tiny_mkswap, tiny_swapon and tiny_swapoff. These are problematic and don't work most of the time.

2. In /system/xbin/busybox we have mkswap, swapon and swapoff. This is what the example init.d script uses and seems to have no problems.

3. In /system/bin/toolbox we have mkswap, swapon and swapoff. These files have generally not been tested and offer different switches to the busybox variants.

If you change the init.d script to use the toolbox versions, it will look like this (no need to add the path to toolbox):

#Enable zram (no zram set by default, enable first 4 lines if 1 zram required, all 7 lines if 2 zram required)
#echo 40 > /proc/sys/vm/swappiness
#echo 268435456 > /sys/block/zram0/disksize # for single zram: 536870912 = 512MB (for non-prime version) 1073741824=1GB (for prime version)
#mkswap /dev/block/zram0
#swapon /dev/block/zram0
#echo 268435456 > /sys/block/zram1/disksize # for 2 zrams: 268435456 = 256MB (for non-prime version) 536870912 = 512MB (for prime version)
#mkswap /dev/block/zram1
#swapon /dev/block/zram1

Once it is established that all still works, try adding the -p switch to swapon as follows:

#swapon -p 2 /dev/block/zram0
#swapon -p 2 /dev/block/zram1

The -p switch adjusts priority between 0 and 32767 giving another method of controlling how zram is getting used. It may or may not be useful but the function is there to be played with;)

I am playing with another mod that increases the number of cached apps permissible before they start getting killed - it looks like the default is 12 apps and 24 system services which explains why apps still get killed when plenty of memory is still available. I need feedback on what you experience in regards to this to see if it is worthwhile or not????
[Redmi Note 2 Android Development] DarthJabba9:
This is what I have always used ( /system/bin/mkswap; /system/bin/swapon ) and it has always worked for me.
[Redmi Note 2 Android Development] jajk:
[MENTION=5850987]DarthJabba9[/MENTION] There is already an inherent path to toolbox so /system/bin is not strictly needed unless busybox commands have symlinks and then it gets more complicated to ensure you are using one version and not the other. That was the main reason I repackaged a Busybox installer to not create symlinks;)

Have you tried playing with the priority switch?
[Redmi Note 2 Android Development] DarthJabba9:
Just like making things unambiguous if there is any danger of ambiguity. No, I haven't played with the priority switch. .
[Redmi Note 2 Android Development] brento285:
Hello , i have installed miui bet so far 8.1.3.0 stabile and i whant install this custom boot image, whic i have to install, thanks in advance, i m italian user, sorry for my bad english

Inviato dal mio Redmi Note 2 utilizzando Tapatalk
[Redmi Note 2 Android Development] DarthJabba9:
Skinny_Pro_7112_Tweaked-v24.img

or

Skinny_Pro_7112_Tweaked-v23.img
[Redmi Note 2 Android Development] brento285:
Ok, can I falsh whit twrp, That gap between the two files

Inviato dal mio Redmi Note 2 utilizzando Tapatalk
[Redmi Note 2 Android Development] jajk:
[MENTION=7105515]brento285[/MENTION] Yes, flash with TWRP. Copy to sdcard then reboot to TWRP. Select from "image" instead of "zip", select the skinnyboot.img and then the "boot" partitition. No need for wipes, just reboot and you are on your way.
[Redmi Note 2 Android Development] brento285:
I just installed, hopefully better battery, can I do anything else x increase life span?

Inviato dal mio Redmi Note 2 utilizzando Tapatalk
[Redmi Note 2 Android Development] rafix96:
Hi, i installed skinny boot and brightness fix but autobrightness still not working... What can i do?

Wysłane z mojego Redmi Note 2 przy użyciu Tapatalka
[Redmi Note 2 Android Development] jajk:
[MENTION=7105515]brento285[/MENTION] Yes, read the O.P and work through the recommendations doing regular TWRP backups along the way so you can undo any mishaps.
[Redmi Note 2 Android Development] jajk:
I screwed up a bit with the zram support..... V24 skinny boots are withdrawn but there is no necessity to reload v23 if you are on v24 - no harm will come to your device.

What I did not notice is that Android will not enable an IO scheduler for zram (which stands to reason if you think about it) so setting the scheduler to Deadline etc. is pointless - it gets ignored. I have removed the relevant lines from boot.img and 01_init script so we are back at v23 basically.

The idea of running 2 zrams instead of 1 is unaffected by the above oversight.
[Redmi Note 2 Android Development] Iliyena:
I were thinking it were a bit odd when I first saw those lines added, but no errors and you always check up on things you've implemented. Made me think it were/using a combination of the RAM and a bit internal storage to make a database for the compressed data-chunks or such. Good info online is really scarce for this as we have concluded ;)
[Redmi Note 2 Android Development] ragilcepot:
hey [MENTION=5952980]jajk[/MENTION] i have a kind of unique question, what are the least cores that we can begin with ? i'm moving to iphone 6s, because i'm having a ton of work and iphone just suits me better for business functionality. so, mainly this phone will be for personal calls and texts, and just to listen to music.

what's your recommendation ? no youtube, no gapps, no application at all except for core applications and stellio music player.

and also your thoughts for the clock of cpu and gpu as well. thanks in advance :good:
[Redmi Note 2 Android Development] jajk:
[MENTION=5022570]ragilcepot[/MENTION] Skinny boot defaults to 5 cores which is what I use but I also throttle the cpu freq down to 1781MHz. The combination gives a maximum power consumption of almost exactly 50% compared to no limits. Going to 4 cores starts to affect things like boot time but is still almost unnoticeable when running basic apps - I would not go lower than this. Dropping to 1625MHz is also O.K Going lower starts to make the governor respond in a very chunky way since it has very few options left to choose from. So basically, I am recommending 4 cores @ 1625MHz as a battery miser setting that doesn't punish you too much;)

Turn off GPU boost but leave the freq limit unchanged - the GPU governor doesn't scale up aggressively in its stock form and won't run at max unless it really has to when running games etc.
[Redmi Note 2 Android Development] ragilcepot:
could it go lower at cpu cores and cpu clock ? i am trying to maximize the battery life since i only play music regularly, not even play video or open a photo. no games, no streaming music via the like of spotify app or joox, every music stored offline on my sdcard, not even a single google app. i think 4 cores at 1625 would be "too much" to just play music and making a phone call, i reckon :confused:
[Redmi Note 2 Android Development] jajk:
[MENTION=5022570]ragilcepot[/MENTION] Edit the init.d script and test what works for you - that is the beauty of Skinny boot - the power remains in your hands;) Playing audio requires 1 cpu running occasionally at 806MHz when buffering.
[Redmi Note 2 Android Development] jajk:
Busybox1.26-2_arm64.zip uploaded.

This uses osm0sis binaries but installer does not symlink busybox commands. This avoids version conflicts with other commands of the same name that already occur in the ROM.
[Redmi Note 2 Android Development] DarthJabba9:
1183000 mhz and 2 cores (and max GPU set at 299000 mhz) should be enough for all that
[Redmi Note 2 Android Development] Adam Hui:
Just a bit OT, but what's the differences. I've been using old cheap chinese RN 4g Dior (latest lineage nougat w/ latest goog security patch) for my job, ol bussiness & m-banking. Sometimes sends some critical sensitive security infos from different locations.

Think the safety at the net is about what to do & what not & the knife will keeps sharper regarding how u treat it.
[Redmi Note 2 Android Development] cukierkas:
[MENTION=5952980]jajk[/MENTION], thanks, your busybox works without problems and on Kate, Mm.
[Redmi Note 2 Android Development] ragilcepot:
i have fooled around iphone before i even touched android. so i know what i need for my needs. it's not about security, tho. i said "funcionality". it's easier to do business contact, email-ing, also facetime-ing, using apple than android, imo.

it's just like the old time, that blackberry is a phone for business. since it doesn't exist anymore, iphone is the way to go.

ah, plus, if i touch any android, i will spend more time tweaking anything about it than being productive :D
[Redmi Note 2 Android Development] jajk:
Skinny_Pro_7112_Tweaked-v25.img posted.

This is suitable for all MIUI7.5.x and MIUI8 ROMs. (not suitable for MIUI7.0.x or 7.1.x ROMs)

Changes:

Cherry picks from Android 7.1.1

# From 7.1.1: Disable auto-scaling of scheduler tunables with hotplug.
# The tunables will vary across devices in unpredictable ways if allowed to scale with cpu cores.
write /proc/sys/kernel/sched_tunable_scaling 0 ### default 1

# From 7.1.1: active FIFO threads will never be in BG
write /dev/cpuctl/bg_non_interactive/cpu.rt_runtime_us 10000 ### default 700000

Reversions:

Do not set readahead for eMMc memory to 512kB - memory is sufficiently fast to not require a larger buffer.

### write /sys/block/mmcblk0/queue/read_ahead_kb 512 ### default 128

So we now have cherry-picks from Android 6.0 and 7.1.1 which is likely to be as close as we will ever get to an up-to-date O.S:rolleyes:

Sadly, the cherry-picks came from my Moto G 2013 that is running happily on AOSP 7.1.1.

.....Even sadder is the fact that Pixel Launcher is rubbish and was the first thing to go.
[Redmi Note 2 Android Development] Iliyena:
Sure the eMMc memory it's fast enough, but in rare cases the buffer will really bump a small bit of reading to crazy speeds, won't ever happen with default values I think. Will never be noticeable to the user though, but read speeds can get ways over 100MB/s during a small session of pure reading. Might just be in synthetic testing but I want the synthetic values to mean something ;)

Nova Launcher ALL the way for me since a few years. The looks is very easy to change. The gestures are great on bigger screens/one handed use. The backups are great for streamlining between devices/ROMs ;) Almost never kill my screens with the power-button since getting it.
[Redmi Note 2 Android Development] jajk:
[MENTION=7442305]Iliyena[/MENTION] A phone is unlikely to be used in a way that would benefit from the larger buffers except for running benchmarks. Synthetic benchmarks can lead you away from the real world;)

Bigger is not always better with cache and buffer size settings and can lead to lower performance and more battery use (in the real world). A lot of the tweak settings still kicking around at present are obsolete legacy from a time long ago. It provides a source of entertainment (at least for me) to see supposed "developers" recycling the same old rubbish and getting a large fan base for their efforts.
[Redmi Note 2 Android Development] DarthJabba9:
Placebos work! :D
[Redmi Note 2 Android Development] jajk:
[MENTION=5850987]DarthJabba9[/MENTION] O.K I will include them in further builds:good:
[Redmi Note 2 Android Development] DarthJabba9:
:eek: Correction - placebos work on Qualcomm chipsets :p
[Redmi Note 2 Android Development] jajk:
[MENTION=5850987]DarthJabba9[/MENTION] Placebos birthplace was on Qualcomm based phones - of course they work with Qualcomm chipsets. It is MTK's fault for not making their chipsets compatible with Qualcomm placebo tweaks, just as it is their fault for not updating the operating systems for all manufacturers that fail to support their own product beyond the day of sale:rolleyes:
[Redmi Note 2 Android Development] DarthJabba9:
Now, we are speaking the same language! :D No placebos for RN2 please! I think Skinny Boot is more than sufficient for MTK...
[Redmi Note 2 Android Development] asusm930:
can the second line be applied through a script in su.d?

edit; tried it out and it works through a script

goat damn, my redmi note 4 MTK feels a lot more fluid and faster applying those two lines. what the f**k

KUDOS FOR YOU
[Redmi Note 2 Android Development] jajk:
[MENTION=2078083]asusm930[/MENTION] Make sure you collect the whole three cherry picks then. This one has been included in skinny boot for a while so was not mentioned as being new and it started to be seen in some Android 6.0

# Create cgroup mount points for process groups
mkdir /dev/cpuctl
mount cgroup none /dev/cpuctl cpu
chown system system /dev/cpuctl
chown system system /dev/cpuctl/tasks
chmod 0666 /dev/cpuctl/tasks
write /dev/cpuctl/cpu.shares 1024
# Cherry pick 7.1.1:
[B] write /dev/cpuctl/cpu.rt_runtime_us 950000 ### default 800000[/B]
write /dev/cpuctl/cpu.rt_period_us 1000000

It takes an RN4 user to give feedback on an RN2 thread:rolleyes:

Are you changing the line syntax to something like:

echo 950000 > /dev/cpuctl/cpu.rt_runtime_us