/efs owner and permissions - Galaxy Ace II Q&A, Help & Troubleshooting

Hello,
I'm on cyanogenMod 12.1 codinap 05/03 I8160P and I restored /efs without owner and permissions. System seems not to be able to read MAC WIFI address as it shows "Unknown" before activating Wifi and "00:00:00:00:00:00" after activating Wifi ... Although address in /efs/wifi/.mac.info seems correct.
Could someone send me his owner / permissions configuration of all files and subfolder in /efs ? Perhaps result of " ls - al".
Thanks in advance

Problem is solved.
I had an ugo=770 instead of 775 on the subfolder /efs/wifi, some process just couldn't read my MAC address in .mac.info

Related

locale execute plug-in / tasker

Hello y'all,
I am trying to write a command-line (in the locale execute plug-in) that will copy a file "/mnt/sdcard/GpsConf/gps.conf" to "/system/etc/gps.conf"
(so that i don't have to "set" the content off that file everytime i flash my SGS with a new custom ROM. It will become a "task" in tasker.)
Who can help??
already tried this:
! cat /mnt/sdcard/GpsConf/gps.conf > /system/etc/gps.conf
The problem (as far as i get it) is that /system/etc is read-only......
?? help ??
Anyone? (10 char]
pbecks1963 said:
Hello y'all,
I am trying to write a command-line (in the locale execute plug-in) that will copy a file "/mnt/sdcard/GpsConf/gps.conf" to "/system/etc/gps.conf"
(so that i don't have to "set" the content off that file everytime i flash my SGS with a new custom ROM. It will become a "task" in tasker.)
Who can help??
already tried this:
! cat /mnt/sdcard/GpsConf/gps.conf > /system/etc/gps.conf
The problem (as far as i get it) is that /system/etc is read-only......
?? help ??
Click to expand...
Click to collapse
You need to mount your /system partition in RW (Read/Write) mode, then remount it in RO (Read Only). I'm not sure what the path's are for the Galaxy S though. It's different than the Motorola Droid X2 (which I am running).

Edit settings.db and replace into file system, please important !

Hello guys
I need your help, i'm working on a mod and a friend said me to modify the file: settings.db located in data/data/com.android.providers.settings/databases/settings.db
I only have to change "1" to "0" in the "secure" tab
for this I used Sql Lite browser for windows 7.
So i did it and saved the database, and then with root explorer replaced with the original settings.db but ....
I entered in a boot loop, why ?
I know for sure the "0" is a secure value, because used in a stock old rom
Why bootloop so? Have I to changed permissions to file?
Can please help me to do it without a new bootloop?
Thanks

[Guide]Set the Straight Talk APN on a (rooted) Stock 4.4.2 AT&T ROM

UPDATE: There is a much simpler solution that anyone can use without learning Linux commanline or file permissions. See this thread for details:
http://forum.xda-developers.com/showpost.php?p=54462957&postcount=13
WARNING: If you do not understand every step of these low-level Linux command-line technical instructions, then do not attempt this method or you may brick your phone! These instructions are written for people who understand android developer tools, Linux command-line tools, and file permissions. If you do not understand these Android development basics, then find another walkthrough.
I got my phone up and running and text messaging, 4G LTE data connectivity, and phone calls worked just fine, however, I noticed I was unable to send and receive MMS messages (picture messaging). I tried every solution I could find on the web for changing the APNs on my rooted LG Optimus G Pro E980, and by trial and error, I discovered the following solution:
The stock Android ROM supplied by AT&T for the Optimus G Pro - Android 4.4.2 (Build E98020G), has disabled the ability to add working APN settings through the system APN settings dialog by defaulting all new APNs to have the (apn) type="default,dun". The settings screen does not let you change this value, so you have to edit the values directly in the SQLite database.
None of the free SQLite-database-editors in the Android market were able to edit the read-only /data/data/com.android.providers.telephony/databases/telephony.db file (after following instructions for editing the APN in the database in the folder where it is stored).
So, using ES File Manager (search for "com.estrongs.android.pop" on google play), I copied it to my SD-Card, copied to my computer and edited it with SQLite Database Browser (a SourceForge project identified as sqlitebrowser).
VERY IMPORTANT: The permissions change when copying the file from your computer to the SDCARD and when copying it from the SDCARD to the /data/data/com.android.providers.telephony/databases/ folder. So, I had to set the permissions back to the original telephony.db permissions & owner. The permissions should match all of the other .db files in the /data/data/com.android.providers.telephony/databases/ folder, like so:
RW-RW----
VERY IMPORTANT:Change the file owner back to "radio" from "root". Change the group back to "radio" from "root". If you do not change the owner and group back to "radio" after you copy the telephony.db file back to the /data/data/com.android.providers.telephony/databases/telephony.db path, the phone.apk process will repeatedly crash until it restarts your phone (and your phone will keep rebooting until you delete the telephony.db file that has incorrect permissions or incorrect owner). To boot, the phone.apk runs under the "radio" group and needs the critical Android OS file: telephony.db to be owned and accessible by the "radio" group.
After creating an APN per Straight Talk's instructions, changing the type field in the carriers (APNs) record stored in the telephony.db, copying over the new telephony.db (and overwriting the original), changing the permissions & owner of the copied file, and rebooting the phone, I was able to send and receive text messages and picture messages (MMS) to myself.
Note: My phone came with the correct "Service Center Address" setting, because it was an AT&T branded phone before I brought it to Straight Talk. However, you may need to change this setting if you came from another carrier with your phone. The correct setting for Straight Talk customers on the AT&T LTE network should be (the same as it is for AT&T customers on an AT&T plan):
Code:
+13123149810
Although the /system/etc/apns-config.xml file has several, misleading APN values in it, this file is not used to store the APN records in Android 4.4.*. Instead, APNs are stored in the /data/data/com.android.providers.telephony/databases/telephony.db SQLite database.
Also, there is a rumor spreading around the internet that you cannot send MMS messages when your WIFI is connected (instead of a 4G LTE connection). That is false: my phone sends and receives MMS messages while the WIFI is connected.​To make it easier for you to change your APN settings on your phone, I have attached my working telephony.db file. It contains only one APN record for Straight Talk on AT&T's LTE network. I deleted all of the other APN records from the database, per Straight Talk's APN instructions.
If you are curious, I also attached the database dump of the attached telephony.db, which was auto-generated by SQLite Database Browser. It is a text file called "telephony-dump.sql".
Hi, I tried this step by step and now my phone does nothing but crash repeatedly. Any way to fix this?
How to unbrick your phone if you missed steps in the instructions
l337m45732 said:
Hi, I tried this step by step and now my phone does nothing but crash repeatedly. Any way to fix this?
Click to expand...
Click to collapse
If you do not understand every step of the above low-level Linux command-line technical instructions, then do not attempt this method or you may brick your phone!
It sounds like a permissions issue - the android operating system is crashing because it does not have permission to read the critical OS file: telephony.db. Did you set the owner, group, and permissions on the telephony.db file correctly? If you are unable to change the permissions back on the telephony.db, then follow the instructions above to fix your problem:
ratkiley said:
VERY IMPORTANT: The permissions change both when copying it to and when copying it from the SD-Card. So, I had to set the permissions back to the original telephony.db permissions & owner, (matching the other .db files in the /data/data/com.android.providers.telephony/databases/ folder):
RW-RW----
VERY IMPORTANT:Change the file owner and group back to "radio" from "root". If you do not change the owner and group back after you copy the file back to the /data/data/com.android.providers.telephony/databases/telephony.db path, the phone.apk process will repeatedly crash until it restarts your phone (and your phone will keep rebooting until you delete the telephony.db file that is owned by "root").
Click to expand...
Click to collapse
If you don't know how to delete the telephony.db file, then you can flash the stock AT&T android Operating System image file to unbrick your phone. There are many tutorials and walkthroughs on this topic on xda developers. This walkthrough is pretty comprehensive:
http://forum.xda-developers.com/showpost.php?p=44983841&postcount=1

[FIX] Error while searching for networks

I have SGH-T999 with official CyanogenMod 11 nightly (20150426).
I tried to do a network search by going into: Settings > Mobile networks > Network operators
After about 2 minutes, it stops with no results shown and the error message: Error while searching for networks.
I tried numerous times and always got the same result.
After searching around, I found this: http://review.cyanogenmod.org/85739
So it looks like it was a known issue and was supposed to be fixed, but obviously was not for me.
What worked for me
I added the single line to /system/build.prop at the end of radio section:
Code:
ro.ril.telephony.mqanelements=6
I then rebooted and it worked and it successfully found networks! I confirmed that this wasn't just a fluke because when I removed the change to build.prop and rebooted, the issue came back.
I used ES File Explorer to edit build.prop but you can use something else.
WARNING: Be careful when modifying the build.prop file as any mistakes can render your system unbootable. Make sure the file has permissions 0644 (rw-r--r--).

LG G4 WiFi Fix - Always all channels on 2.4 GHz

WiFi Fix - always all channels on 2.4 GHz
IMPORTANT:
Only for advanced users!
You are an advanced user if you know exactly what you are doing.
You are an advanced user if you know what to do if something went wrong.
You are NOT an advanced user if you know how to do copy+paste.
You can bring your smartphone into a state, so it no longer works.
I am not responsible for anything. The following instructions are only suggestions.
Hello,
I want to show you a way how you prevent your LG G4 to limit wireless channels to 1-11.
This happens when no SIM card is inserted or if the airplane mode is activated.
You get messages like:
"Some Wi-Fi networks unavailable due to unknown location" (English)
"Einige Wi-Fi-Netzwerke sind wegen des unbekannten Standorts nicht verfügbar" (German)
"Algunas redes Wi-Fi no están disponibles debido a una ubicación desconocida" (Spanish)
I studied the log entries and found a line that said "[LGE_PATCH] For Country code DC. ....".
After a long search in the code I have discovered the place that is responsible for the limitation.
It is located in the wifi-service and it sets the WifiCountryCode to "DC" if your location could not be obtained.
For me living in Germany it should be "DE".
The WifiCountryCode named "wifi_country_code" is stored in the "global" table of "/data/data/com.android.providers.settings/databases/settings.db".
Changing it has no effect as it is overwritten instantly.
So we need to modify the program code of "wifi-service".
According to this post: http://forum.xda-developers.com/showpost.php?p=64636618&postcount=8
this guide seems to work on other models from LG and newer Android versions too.
You have to search for the wifi-service.odex file and replace "DC" with your two-letter country code.
Alter the paths of the instructions if you use another phone than LG G4 with Android 5.1 Lollipop!
The following instructions show how to do it on the LG G4 with Android (5.1) Lollipop.
Prerequisites:
ROOT
USB debugging enabled
Procedere:
Connect your G4 to your computer.
Open the command promt and enter the following lines:
Code:
adb shell
mkdir /sdcard/wifi-service
cp /system/framework/arm64/wifi-service.odex /sdcard/wifi-service/64wifi-service.odex
Now a file named "64wifi-service.odex" is on your internal memory located in the folder "wifi-service".
Copy the file to your computer.
Now you have to edit the file.
Don't use the "editor" on windows, use Notepad++
With Strg+F search for "DDD".
You will find exactly one line that contains this::
"DATE_TIME DBG DC DCM DDD DDFName"
Change the value "DC" to "DE" for example (search the internet for the two-letter country code of your country (ISO 3166-1 alpha-2))
"DATE_TIME DBG DE DCM DDD DDFName"
Save the file.
Delete the file "64wifi-service.odex" on your smartphone.
Copy the edited file from your computer to the folder "wifi-service" on your smartphone.
Go back to the command prompt and type this:
Code:
su
You should see an confirmation promt on your smartphone that asks to grant root rights.
Confirm the message.
The command promt should change from $ to # now.
To verify your rights type this:
Code:
id
You should see "uid=0" etc.
Now type in the following lines (I recommend to execute each row seperately):
Code:
mount -o remount,rw /system
cd /system/framework/arm64
cp wifi-service.odex /sdcard/wifi-service/64wifi-service.odex.bak
rm wifi-service.odex
cd /sdcard/wifi-service
cp 64wifi-service.odex /system/framework/arm64/wifi-service.odex
cd /system/framework/arm64
chown 0:0 wifi-service.odex
chmod 0644 wifi-service.odex
echo "restart device"
Check the outputs. There must be no errors!
After hitting the Enter button the last line should output "restart device".
In the folder "wifi-service" on your internal storage you find the original "wifi-service.odex".
It is named "64wifi-service.odex.bak".
Restart your smartphone now.
As from now it does not matter whether a SIM card is inserted or if the airplane mode is activated.
The WiFi channels are no longer limited to 1-11. You can now always use 12 and 13.
Did the instructions help you?
Please give a "Thanks!"
Thank you
For users who speak German:
I wrote this guide in German at first. You can find it on android-hilfe.de
Title: "LG G4 WLAN Fix - immer alle Kanäle"
http://www.android-hilfe.de/thema/lg-g4-wlan-fix-immer-alle-kanaele.710265/
I am using Ultraedit. Nevertheless I only see a hex file and I can not locate a string: "DCM DDD DDFName" Any suggestions?
It is also passible with your editor.
There are two ways:
1. In HEX mode (default mode)
After hit "Strg + F" enter the string "DDD"
Activate the checkboxes "ASCII suchen" and "Groß-/Kleinschreibung beachten".
You will find excatly one result. (DC is in line 00c6e40h)
2. Deactivate HEX mode (Strg + H)
After hit "Strg + F" enter the string "DDD"
The first result is what you need. (line 10528)
Change "DC" to "DE". Don't change anything else!
Hope I could help.
You are also on V10c? Otherwise line numbers will differ.
Tip:
Make a system.img with "dd" of your current system partition.
If it don't work or you did something wrong you can simply copy it back with "dd".
dominik-p said:
It is also passible with your editor.
There are two ways:
1. In HEX mode (default mode)
After hit "Strg + F" enter the string "DDD"
Activate the checkboxes "ASCII suchen" and "Groß-/Kleinschreibung beachten".
You will find excatly one result. (DC is in line 00c6e40h)
2. Deactivate HEX mode (Strg + H)
After hit "Strg + F" enter the string "DDD"
The first result is what you need. (line 10528)
Change "DC" to "DE". Don't change anything else!
Hope I could help.
You are also on V10c? Otherwise line numbers will differ.
Tip:
Make a system.img with "dd" of your current system partition.
If it don't work or you did something wrong you can simply copy it back with "dd".
Click to expand...
Click to collapse
Thanks for all the help! I switched to notepad ++. Found the entry
Code:
DATE_CLASS DATE_KEY DATE_TIME DBG DE DCM DDD DDFName DEBUG
in line 17126 though. Changed it successfully! Copied successfully to my phone! No effect! Still no channel 13 without sim. Double checked (copy wifi-service.odex to pc) and look for
Code:
DATE_TIME DBG DE DCM
.
It IS in there. Somehow not taking effect? I had problems when doing "chown 0:0 wifi-service.odex" It tells me "read only file system". I did set the owner and permissions with ES File Explorer. TO: root, root and Read, write; read; read.
OK I think you are an advanced user. (aren't you?)
You did it right with your app, but it should be possible with the shell too.
Readonly means you are not "su" in shell or/and did not "mount -o remount,rw /system".
Check su with "id" (uid=0) and mount should output something like this:
Code:
/dev/block/bootdevice/by-name/system /system ext4 [B]rw[/B],seclabel,relatime,data=ordered 0 0
Please check that /system/framework/arm64 has only one file named wifi-service.odex in it.
While testing I got to a point where I had two "wifi-service.odex" files with different file permissions in it.
Post an "ls -l" of the folder please.
After removing the SIM card and rebooting your phone look in the "global" table of settings.db and check that "wifi_country_code" is set to "DE".
Please also use catlog to check if wpa_supplicant sets the CountryCode to DE.
PS: for me it's line 17073 in notepad++ Don't know why lines differ.
Filesize of wifi-service.odex is 3903976 bytes for me. You are also on V10c?
Thanks for this! just fixed my G3 Marshmallow,
I'm using another region rom, and i think sim country is not properly detected.
Thanks for reply.
Didn't know that the G3 has this "problem" too and that my solution works on Android M.
I guess it's not the same line "DATE_TIME DBG DC DCM DDD DDFName"
but also a line with the value "DC"?
dominik-p said:
Thanks for reply.
Didn't know that the G3 has this "problem" too and that my solution works on Android M.
I guess it's not the same line "DATE_TIME DBG DC DCM DDD DDFName"
but also a line with the value "DC"?
Click to expand...
Click to collapse
I just noticed the problem when updating to 6, its another line but very similar:
the full path for the file is /system/framework/oat/arm/wifi-service.odex
Line is 24139
values for the line are "DATE_CLASS DATE_KEY DATE_TIME DATUM_WIDTH DBG DC DCM DD DDD DDFName "
Just changed DC to BR.
Perfect.
Thank you.
dominik-p said:
Perfect.
Thank you.
Click to expand...
Click to collapse
Hello, I know that the thread is quite old, but I have a small problem with the wifi-service.odex file on my phone. Looks scrambled in n++. Is there any setting for n++ that I should use?
My phone is a Le Max2 and I don't have GSM signal at my workplace. The routers are set to automatic and they also use channels 12 and 13.
From what I understand by the commands, you are just pulling the file from system to internal storage, and copying it to the computer, changing it with n++ and copying it back to system. There is no transformation to .jar as I can see...
The file is about 4mb.
Can you provide any help please?
valy_cta said:
Hello, I know that the thread is quite old, but I have a small problem with the wifi-service.odex file on my phone. Looks scrambled in n++. Is there any setting for n++ that I should use?
My phone is a Le Max2 and I don't have GSM signal at my workplace. The routers are set to automatic and they also use channels 12 and 13.
From what I understand by the commands, you are just pulling the file from system to internal storage, and copying it to the computer, changing it with n++ and copying it back to system. There is no transformation to .jar as I can see...
The file is about 4mb.
Can you provide any help please?
Click to expand...
Click to collapse
Hi,
you already created a thread here: https://forum.xda-developers.com/le-max-2/help/wifi-channels-12-13-unable-to-t3773144
Please stay at your own thread for further discussion. This thread here is only for LG devices and the provided fix is only working on some LG devices.
You're right, the odex file looks "scrambled" in Notepad++, but that's no problem. We only had to change one or two letters.
I will answer at your thread "WiFi channels 12 and 13 - unable to see them". (https://forum.xda-developers.com/showthread.php?t=3773144)
For all other users, please read these threads to understand the problem:
WiFi regional problem on Android https://forum.xda-developers.com/wiki/WiFi_regional_problem_on_Android
[GUIDE] WiFi Country Problem Solving for AOSP, MIUI & others https://forum.xda-developers.com/showthread.php?t=2368501
Double post by mistake - slow internet connection
Worked cool on LG G4 Stylus
Just a few "logistics" to comment:
-on some devices/models seems to be that /sdcard is no possible to access. Instead, /storage/emulated/0/ or the real path /data/media/0
-when copying the modified wifi-service file to /system/... folder, step on with a "Permission Denied" message. I was Root and /system was mounted as wr. Finally continued by copying using a root explorer and then continuing in the shell.
-after i rebooted, tried to connect on a channel 13 without sucess. I had plain mode. I put off plain mode, changed the country in wpa_supplicant.conf file and rebooted again. After that, all went good
DarkBader said:
Just a few "logistics" to comment:
-on some devices/models seems to be that /sdcard is no possible to access. Instead, /storage/emulated/0/ or the real path /data/media/0
-when copying the modified wifi-service file to /system/... folder, step on with a "Permission Denied" message. I was Root and /system was mounted as wr. Finally continued by copying using a root explorer and then continuing in the shell.
-after i rebooted, tried to connect on a channel 13 without sucess. I had plain mode. I put off plain mode, changed the country in wpa_supplicant.conf file and rebooted again. After that, all went good
Click to expand...
Click to collapse
Thanks for your feedback!
Would you please share your model number and Android version of your "LG G4 Stylus"?
dominik-p said:
Thanks for your feedback!
Would you please share your model number and Android version of your "LG G4 Stylus"?
Click to expand...
Click to collapse
LG G4 Stylus H635 LL 5.0.2
Thank to you for the good work
Question!
dominik-p said:
Thanks for your feedback!
Would you please share your model number and Android version of your "LG G4 Stylus"?
Click to expand...
Click to collapse
I had a situation i yet did not solve.
Yesterday i went to some friend's house, where before i could not see their wifi network. And i still can not see it ! :0 :0
I know this method worked, because changed the channel on my router to 12 or 13 and i can see them and connect. Also country code show as i changed it in Wpa_Supplicant and in CountryCode in Android.Providers. I also know is not a hidden network, as my friends can see it and connect normally without problem. Also tried with WPS button, and nothing.
.
-As the "problematic" network is a 5G, maybe is something related with this? lack of technology as my phone model is a bit old nowadays?
But what i understood about 5 G, is that they assure backwards compability :/
.
Maybe u see something i am missing?

Categories

Resources