Question trying to load cifs.ko to my device - Samsung Galaxy S21 FE

I'd like to mount a SMB share on my device so that I can access ROMs on my network share through retroarch.
I've rooted my device, I have Magisk installed, and I was using ADB to try and push the module to places on my device (and having trouble). But I've been barking up the wrong tree since the cifs.ko I have isn't for this kernel. Probably why insmod failed.
This is turning out a lot more complicated than I'd anticipted. I can hook up the share and access via a file browser no problems. I'd anticipated setting up a symlink to an accessible directory, but I read that there was something in the way that android mounts the share that would prevent that from working.
Does anyone have any advice on where to look next? There's no Magisk module I can see that would help me. I'm at a dead end.

Related

Kaiser (Tilt), Android and Debian Issues

I posted this over on the Updated Getting Android and Linux on Kaiser but I think this needs a new thread.
I used http://www.saurik.com/id/10 with his debian.img, busybox, ext2.ko, etc. I'm running ATT Tilt with I believe currently the 1.1 build of Android from 02/17/09 since the screen rotates correctly, calls don't drop, makes me waffles, etc.
I am not new to Linux and will help get this to work as best as I can (not looking for you to do all the work, just need direction):
Here's my issues (besides wifi... another post perhaps)
No internet and "I hate this terminal emulator" = paraphrasing the output:
1.) I can't get bootdeb to run:
"mount: cannot setup loop device: no such file or directory"
I try manually typing it in and I get a "mount usage ... blah blah rtfm, etc"
2.) "chroot: cannot execute /bin/bash: No such file or directory"
you already know I have it there... I've specified it, not, whatever nothing goes. This is saurik's debian image and the file is there...
3.) I've been told to modprobe ext2 first. Well..
with ext2.ko from the post in my /sdcard directory:
Code:
"$ su && cd /sdcard"
"# insmod ext2.ko
insmod: init_module 'ext2.ko' failed (No such file or directory)"
"# modprobe ext2.ko
modprobe: cannot parse modules.dep"
whether or not I use busybox for this or not:
Code:
"# busybox insmod ext2.ko
insmod: cannot insert 'ext2.ko' : unknown symbol in module (-1): No such file or directory"
"# dmesg
ext2: Unknown symbol __might_sleep"
That and the usual incoming call can hang until I reboot, no speakerphone action (my tape adapter in my car now hates me) and wifi. Without wifi, I can't even try telnetting in and getting the mounts to work. But if I can get Debian running, I'm hoping to maybe use ndiswrapper to give me internet.
My ultimate goal is to make a final package for devs and noobs alike to get a ready-made version so we can get the rest of the bugs taken care of.
OK im here. Im wanting debian as well. Ive tried what you have with no luck. So lets hope someone will have a way.
Oh and i hate to ask but do you have a data connection in WinMo before you boot into android? As thats the only way to get it to work.
I've tried that trick but no go. Wifi works fine in LoseMo (i hate you wm6...) and an active connection doesn't survive the 'reboot' into Androidland.
double post somehow
enatefox said:
I've tried that trick but no go. Wifi works fine in LoseMo (i hate you wm6...) and an active connection doesn't survive the 'reboot' into Androidland.
Click to expand...
Click to collapse
What is LoseMo? Never heard of it. That may be the issue then. If you lose the connection when you boot into android it wont connect. I had that issue for awhile. Once i figured it out all was fine. If you dont have a active connection when android starts it will fail to have a connection to data no matter what you do.
enatefox said:
3.) I've been told to modprobe ext2 first. Well..
with ext2.ko from the post in my /sdcard directory:
Code:
"$ su && cd /sdcard"
"# insmod ext2.ko
insmod: init_module 'ext2.ko' failed (No such file or directory)"
"# modprobe ext2.ko
modprobe: cannot parse modules.dep"
whether or not I use busybox for this or not:
Code:
"# busybox insmod ext2.ko
insmod: cannot insert 'ext2.ko' : unknown symbol in module (-1): No such file or directory"
"# dmesg
ext2: Unknown symbol __might_sleep"
Click to expand...
Click to collapse
I get the same thing when I tried it.
Although when I try to run the commands from a script I get the second one if I run it at the command prompt I get no such file or directory
smokestack76 said:
What is LoseMo? Never heard of it. That may be the issue then. If you lose the connection when you boot into android it wont connect. I had that issue for awhile. Once i figured it out all was fine. If you dont have a active connection when android starts it will fail to have a connection to data no matter what you do.
Click to expand...
Click to collapse
Kidding about LoseMo (WinMo)... I don't have a data plan I was talking about wifi.
Hopefully there are more people in on getting this to work. I think we (anyone listening) need to break this down a little and try to isolate individual problems nailed.
My plan:
I'm going to try to work with the emulator and see if I can get the Kaiser blends to run. If not, then the dev phone, lastly the stock FW that comes with the emulator.
If I can mount a fake SD card in it and get debian (first the premade one then ultimately a custom one) to install in the emulator with it's shortcomings then it should work in Haret right?
Please let me know who wants to help me do this-- I know we have the same phones and software but being in IT, I know sometimes the same directions can be interpreted many ways and maybe one will work if we have a large enough group testing it. Let me know.
Well i know wifi doesnt work at all yet. As i dont think there are any drivers for the kaiser and android. Data will only work if you setup the apn settings for your carrier. Not sure about the emulator. I havent tried anything like your idea but sounds good to me. Im going to try it now. Should work like you say But it is a emulator so who knows the outcome lol. Got ya now on loseMo. I was wondering what in the world you were talking about Had roms on my mind again.
ndiswrapper?
Has anyone either on Debian or Android, tried ndiswrapper with the WinMobile driver to see if wifi would work?
Regarding Ndiswrapper, that's what I'm wanting to know. I'm not comfortable with Android's apk format and no idea how or if one could convert a deb or rpm into an apk. And while busybox is fun it can't even mount an image due to module issues at least on smokestack76 and my phones so good look with ndiswrapper modules. I have no idea how to put ndiswrapper on Android and all the experience of 4 laptops behind me on Debian to get it working with that.
I need to boot Debian before attempting ndiswrapper.
Unless you know how to do it in Android.... if you do then we can try another avenue to get Debian running:
On the G1 you need to telnet in to get root access. The builds on our phones seem to give us root but I'm suspicious that it's really a pseudo-root environment and that's the cause of the failure to mount the Debian image. I might be able to try telnetting and mounting Debian remotely in that case. No wifi and no dataplan mean I have no way to confirm this yet.
It will be nice when we get it to work once and back up the install for further development but that's a little ways away.
I have not been able to get Kaiser ports to work in the emulator and the standard Android images to run in Haret... I understand the great lengths the devs have made but I wish there was some slack here.
I tried the emulator and had the same results. Mainly posting here to keep it alive Ive been busy but i will have time to play with this some more this weekend.
Alright, I had my fun with Android but I want to get Debian running on it more than anything. Android is nothing more than a JAVA VM that can be ported to any respectable Linux distro. Since there are serious issues with hardware support for it, I think getting Debian to work should be the priority.
I've got Debian installed on QEMU but can not get it working on HaRET with Kaiser/Tilt. Does anybody know how to get the image to run with HaRET?
Main guide: http://mojo.handhelds.org/node/66
Guide that fills in the gaps: http://blog.gbraad.nl/2008/11/mojos-hasty-distribution-for-use-with.html
HaRET crashes at 100% for my images even though QEMU boots them just fine...
thought id quickly say, u wont get ndiswrapper running on the kaiser. it binds windows desktop infs....not windows mobile.
HaRET crashes at 100% for my images even though QEMU boots them just fine...[/QUOTE]
Do you have the kernel log? can you create the qemu image so it writes to the boot / kernel log a SD card?
Have you consulted the Android devs or their bug tracker? Haret use to do the same thing when booting Android on my phone, so I image they made a kernel tweak somewhere.
Finally, what is the difference between the actual kaiser chipsets and those emulated by qemu? Are the ARM processors the same revision?
http://forum.xda-developers.com/showthread.php?p=6026287

[Q] Rooting the Creative Zio

Hi there!
I'm trying to root Ziio 7 unit I got for a review for PurePC.pl, and so far so good I installed SuperUser app and su and busybox binaries. Now using terminal I can su without any problems. But the thing is, SU only seems to be working in terminal emulator. I've tried using some apps that should use root like ShootMe and ScreenshotIt, SetCPU and they just doesn't work.
ShootMe says "Starting Server failed", plus info that i need to have root access and enabled access to lower graphics (whatever it is).
ScreenshotIt just doesn't work without any information why, and SetCPU FC's after selecting profile. Although it gets me a nice SuperUser dialog, but that's as far as it goes, cause it crashes right after that.
Am I missing something to have a complete root? Interesting thing is that on this device, preferred PATH for executable binaries is /data/busybox/, and not a usual /system/bin. Interestingly, my su binaries refused to work from /data/busybox directory, so I moved them to /system/bin. Rest of the utilities and such are still in /data/busybox, but I don't know if this information is important in any way Have I missed something along the way? Please help. Cheers.
OK, I know why su gave me permission denied when running from /data/busybox. The /data partition was mounted with nosuid. But still the applications such as ShootMe won't work.
I waiting for. If who has a good new. Please tell me to private message.
Have you made any progress on this bagienny?

[advice needed] ADB ROOT

Let me start by first saying that "adb root" is not related to or the same thing as running adb shell then su. adb root is a way to run adb directly in root mode enabling to be able to push/pull files directly to /system, or other write protected directories. So please, lets not get into the whole "just copy to sdcard, mount system and cp file with adb shell." This is not what I am trying to accomplish. Now that that's out of the way, here is my situation. HTC10 Viper 4.4.0 US unlocked firmware. Generally speaking, in the past you could modify the boot.img and edit default.prop and set ro.debuggable=1 and/or ro.secure=0 and repack and flash. Problem solved. This does not seem to be the case now, with this device. I also tried compiling from source adbd from aosp, modified to ignore ro.secure etc... Packed it in the boot.img and reflashed. I get the same results. I get a message on boot about slow charging, and debugging mode is not running on the phone. Tried stopping and starting it, same thing. Can anyone please help me figure out what is going on? I assume HTC has some built in security check that disallows this modification, but im not sure. Thank you in advance.

How to get control of Android 4.4.2

Hello,
I am trying to root my own Android. I was able to get dirty cow exploit running, which allows me to write to files that I should not be to, including files in /system directory. How can I take advantage of that?
I was able to take advantage of binary with setuid, I overwritten it with my binary, which ran setpropes to enable adb over Wifi (setprop service.adb.tcp.port 6565). Otherwise I don't have access to adb, it doesn't work over USB for some reason, but now I lost the binary file.
Apart from that I was able to modify /etc/hosts, which is helpful, but not that groundbreaking.
Version is 4.4.2, kernel 3.0.19. No adb.
What would you recommend to do?
Edit:
A managed to turn on wifi over adb by overriding " /system/bin/fsck_msdos" and plugging in usb. Now I can access adb over wifi. Also reading trough this:
https://forum.xda-developers.com/general/security/dirty-cow-t3484879/page4

Shield TV (2017) with NVE 8.0.0 (Pie) and NFS mounting (and issues with enabled VLAN)

Thanks to rootfan I've been able to finally root Shield TV 2017 16GB with NVIDIA Experience Upgrade 8.0.0. (Pie) hoping I'll be able to mount my LAN NAS media content on it. But to make things more complicated my LAN is VLAN segmented due to security reasons. I know KODI and PLEX have NFS mounting capabilities without rooting but all I could see were devices on the same VLAN and of course my media NAS is not part of it and they're primarily media oriented and you might want to expand this focus . Since I've acquired certain knowledge on how to do enable NFS mounting on Shield TV (on "regular" non-VLAN LAN) I'll share all my findings for all of you interested in making this work. Hopefully/Ultimately I'm seeking for any user experience mounting NFS with VLAN enabled LAN, since I'm not Android expert I don't know if it is currently even possible or not.
Anyway long story short here are my findings regarding mounting NFS shares on Android:
I came across this post https://forum.xda-developers.com/shield-tv/help/automount-cifs-nfs-share-write-access-t3783735 and patched Cifsmanager (https://forum.xda-developers.com/showpost.php?p=53760495&postcount=537).
The thing is it requires SuperSU which of course is not an option since Pie is rooted with Magisk. Luckily Magisk comes with su therefore SuperSU isn't needed.
You might come across info you also need SELinuxModeChanger (https://forum.xda-developers.com/showthread.php?t=2524485) - once again if you used rootfan's rooting image you don't need it as rootfan has already preset SELinux to Permissive. You can check it with issuing getselinux command in terminal (I use Termux app for this).
BusyBox needed - I'm also not quite sure it is needed for NFS mounting to work as Magisk BusyBox doesn't contain mount command but Magisk itself does. I've installed Magisk BusyBox module through rootfan's TWRP for Pie (https://drive.google.com/open?id=1934405D1S0lv52jZMqS-Zny62RIzGWSi - link is in the 1st post of https://forum.xda-developers.com/shield-tv/development/kernel-overclock-kernel-2-22-ghz-t3943079; Make sure you don't mix 7.2.3 and 8.0.0) but I'm not quite sure this was necessary as it does not include mount command which is included in Magisk (https://github.com/topjohnwu/Magisk/blob/master/docs/tools.md). I've also wanted to try sideloading BusyBox Pro from GP but didn't see how it would change anything so I haven't done it.
Regarding https://gist.github.com/aldur/4a3f90a111b71662f056 there seems to be an (root) ownership problem when mounting NFS shares. The solutions is to use su -mm -c "mount command". If you take a look at https://github.com/topjohnwu/Magisk/blob/master/docs/tools.md you'll see -mm stands for --mount-master. I personally haven't tried this as I don't have any non-VLAN shares I could mount.
So far this was all I managed to find about NFS mounting on Shield TV, but haven't found anything regarding mounting VLAN segmented NFS shares.
What makes me suspicious about Android's ability to mount/work with VLAN segmented NFS shares is a fact I can ping NFS server from Shield TV but when I try to mount it I get an error 'No such device'. Therefore I'm kindly asking anyone who has any ideas/knowledge to help me out. Thanks.
PS.
Please don't suggest to use CIFS - I want NFS as it is at least as twice as fast as SAMBA/CIFS.
UPDATE:
Caught some time to explore this thing in detail and found out two very important things:
NFS with VLAN(S) is working in KODI without any problems therefore problem is definitely on Android side;
Magisk BusyBox NDK doesn't have/support mount applet/command and seems like even though Magisk itself has it (mount) issuing lsmod | grep nfs returns nothing; Empty response could be cause by the following - When issued mount -t nfs ... the mount command is looking for the filesystem type of nfs. If it doesn't find it, it returns no such device error. If it does find it, it basically hands off the "mount" to the module; Accordingly I came to a conclusion that mounting nfs share on Shield TV via mount command isn't possible with just Magisk and Magisk BusyBox module installed. I'll try installing/sideloading BusyBox (Pro) from Play Store ...
Hey @allidea Thanks for all the information. Did you get anywhere with this? Just ordered a 2019 shield pro, and I was hoping to mount my NFS share on it as well.
Does Cifsmanager work on Android 8.0 with Magisk? (Assuming no Vlan segmentation)
I stopped digging further as I've stated using Kodi which fulfilled all my needs and is definitely a great and free player with lots of plugins. But from what I could tell problem with NFS on Shield TV originates from it's kernel - it simply wasn't compiled with full mount module / NFS support. Obviously Kodi has some custom built in NFS support independent from kernel but I really didn't go into details with it.
BusyBox (Pro) made no difference as it only added a few more commands not present within Magisk BusyBox module and it even skipped installing mount module as it already found it installed.
Therefore cifsmanager doesn't work on 8.0.0 but not because it's incompatible rather due to kernel missing full mount module.
Hope this helped a bit.

Categories

Resources