yashsingh1/xdaforums huggingface dataset:
[Android Software/Hacking General [Developers Only]] Nephatiu:
Strange, because all of mine do, I learned it that way long ago and as you can see in edits of the above post I made: All su installerscripts do it too. Even the "Build your own ROM" thread says to do it. :p

And sorry, stating you've been using UNIX for 25 years means nothing. I've been using it for about the same time, and by that I don't mean only end-user stuff like Linux and BSD. Android's way of working, although on a Linux microkernel, stands far from the way UNIXsystems are supposed to work. Most of Android is even trying to fork that Linuxkernel to act differently than it should, so even though it resembles, it has little to compare. Android doesn't even use a 'su' to do things 'root', only we do on rooted phones. :p So any way of doing it is external and the first su in '/system/xbin' would be already one too many. :p

And even if we did compare it to Linux or UNIX, it wouldn't be my first system-file which should be accessible to everybody and wasn't. I think I even symlinked the actual Linux 'su' several times in the past on broken installations, and Android's standard subsystem almost couldn't be a more broken Linux-installation, so... ;p

Grtz,

~ Nephatiu

EDIT:

After some research, I found out that the su in /bin is there, because it's the apps that require root that run su, so it depends on which root app you run as to where that app goes to look for 'su'. Pre Froyo, every root-app always looked in '/system/bin' because that used to be it's default folder. Since Froyo everybody was told to move it to '/system/xbin/', for most apps would change to using it from that location (as it's a much safer directory, so not to hurt the underlying Linux). Problem was that although most apps would look in both dirs (going to xbin first), there are a few apps that only check 1 dir. So it was adapted to both locations, with the symlink in the riskier directory 'bin' and the actual file in the safer directory 'xbin', so that all root tools (no matter where they looked) would still work fine.

Now, in one of these explanations I encountered someone saying that Titanium Backup uses 'su' from '/system/bin', but I haven't tested that one yet. Since you are sure you don't have su in you '/system/bin' dir, maybe you could enlighten me if that's true or not, Almighty2. :p I expect if this actually was true, they'd already updated this by now, in which case we'll never know, of course... ;p

And Linux is an OS to me, I don't think it should all come from the same source to be an OS, it's all systematic, it's all operating my pc, and it's all running on a heart named Linux, so it's an Operating System named Linux to me. :p As one would say that WinAmp is Windows, even though that it actually has nothing to do with Microsoft, or aside from running on it even with Windows itself. But we could discuss semantics all day long like this. :p I didn't even mean Linux the OS with my "Linux tutorials" though, rather than the docs for tools that run in Linux. Even man-db is more wrong than right.

Grtz,

~ Nephatiu
[Android Software/Hacking General [Developers Only]] Almighty2:
The thing is that on Unix or Unix -like machines, you will notice that each binary is only shown once in /bin, /sbin, /usr, /sbin so there really is no point in having the binary there more than once as it will always use the first one it finds so adding the second one will only waste space. All the modded stock roms I've seen only have su in /system/xbin but ofcourse that's on Motorola phones, anything else is a different issue since the other devices have the s-on and s-off issue too. I mean think about it, if you install Superuser or SuperSU, it will update the su binary which you can install directly or via recovery, it only will update one of the binaries and not both unless they have something there to figure out where it is in the binary tree. In your example, /system/xbin would actually be the second su since for whatever command you issue, it would try /system/bin first and then if it fails, it will head to /system/xbin. Android is more like a scaled down version of the entire Linux so there wouldn't be all the same stuff you see in the full blown Linux as there would not be enough storage to fit everything anyways, otherwise there won't be things like busybox. Linux might be end-user stuff but BSD is not end-user as it's what's used for servers powering the internet and is where TCP/IP came from. Besides, what you have said so far means nothing since like I said, you're not even willing to run su in the terminal mode to see who is right or wrong and using your Root.fs provided, it doesn't even allow running su as BS somehow is not allowing the user to su.

And just saw your updated post, I never used anything before froyo as far as Android goes. In any case, /system/xbin/su without a su anywhere else works fine for Link2SD, Lucky Patcher, Root Explorer, ROM Manager Pro, Titanium Backup, Root Toolbox, among other apps. The reason I know where su is, is because I always check all the directories for different files to see where the files are between 4 different devices everytime I update things like busybox, su and such.

As far as a OS, I am talking about the product since Linux is really just the kernel and it's up to the packagers to package it as one product for you to use which is the reason that those who run RedHat won't really have the same thing as those who run something like debian as they are all basically packaged together and the userland is whatever the packager wants to package it as since the userland tools and binaries are not going to be identical between different Linux distributions. If you compare it to *BSD, all the BSD's are packaged by one source so you wouldn't have FreeBSD in different distributions. WinAmp is not a good comparison as WinAmp is nothing more than a application that runs under Windows that came from nullsoft which is part of AOL.
[Android Software/Hacking General [Developers Only]] Nephatiu:
First of all, I'm not willing? Why wouldn't I? I'm sure you're correct, though, so that would prove nothing of what I said. :p You are right that xbin takes preference nowadays, I confirmed it even in my answer...

Anyway, Usually apps call just for the main 'su'. But apparently there are apps that look for su on it's actual location,... So they would probably have the full '/system/xbin/su ...' in there code. Older apps (probably nearly none, seeing Froyo was and has been long ago now) would have this set as '/system/bin/su', and to make them backwards compatible, 'su' is symlinked in 'bin'.

So it's actually up to you if you place the second (symlinked or not) 'su' in '/system/bin', it's recommended, but not truly necessary.

Normal Unix-based OS' 'su'-files usually reside in '/bin', though... ;) Hence my taking it as normal when I learned it.

Thanks, I'm glad everything worthy works with the 'xbin'-folder, but then again, now that I've learned the reason behind the 2 'su's, I can't help but find that pretty normal. :p You could maybe have problems with very old Android apps which ask root in 'bin', but then again, the file would have aged that much already, there's probably a newer alternative that does work with 'xbin', if the said aged app would even run on JB/KK ;p

You obviously didn't get the comparison I was trying to make there, cause WinAmp's being doesn't have to be anything to still make my point there. It could have been an icon, for all the statement cares, if it was an icon which would only work on windows, of course. And since icons only for windows don't really exist, but there's no WinAmp for Linux, it was a pretty straight forward comparison... I call WinAmp and everything that is typical Windows "Windows apps".Translated out of my language it's even said that "WinAmp is Windows." because it runs on it. And in the same manner is everything gnu also Linux, since it runs on Linux.

And that point of view, as you will, is an opinion, not a fact, so you can't prove me wrong on it, you can only state your own vision on it, which is that Linux is no OS. I also respect that.

So, I'll end this with 3 things:

1. You were right about the xbin normally being enough for root in Android. I honestly didn't know why exactly the 'bin' symlink was there before I looked it up just now.

2. Even though it's not necessary, the 'system/bin/su' symlink has nothing to do with BlueStacks in particular, since it's recommended in other stuff as well.

And 3. Sorry for maybe suggesting you had a closed mind some posts ago. The sentence didn't actually had that ring to it in my head, and no offense was intended there, but still, my apologies. ;)

Grtz,

~ Nephatiu
[Android Software/Hacking General [Developers Only]] Nephatiu:
k, didn't know the order, but since /bin is the original UNIX-dir, /system/bin sounds logical to follow first. /system/xbin just was invented to be able to break more without breaking the entire OS. :p

You would have to create a fake /system/xbin/su dir and file to be able to symlink an Ubuntu-mounted Root.fs, because at that point it's in another directory syntax, but it's possible to create a symlink, instead of a second su. But on Android /system/ mounts space doesn't mean that much, imho, then again, I don't think 35kB ever bothered me, though, 100 su's would still just be 3.4mB. ;p And again, multiple 'su's is a risc on most Unix-based systems, I'll grant you that, but that's because the system uses that executable for it's own root access stuff... Android however does not need 'su' for it's own background root stuff. This is done in a more secure way, so you could put 'su' in every dir you could find and still have no problems. (Except for maybe some sort of OCD. ;p)

I have a full armel Linux chroot running on my main device, which is completely symlinked to the actual root of my Android (making it feel as if Android is installed in an actual Linux). That would complain and maybe even stop working, but Android would live on... ;p

Yeah, well, I can only tell you what I read when looking it up,... I didn't invent the way, I just learned to do it this way, and since it doesn't harm and doesn't really take any space, even if it's the full 'su', I don't really see why I should stop preventing what maybe will never happen. ;p

Grtz,

~ Nephatiu
[Android Software/Hacking General [Developers Only]] Almighty2:
Where did you even read where programs look for su as hardcoded locations based on the version of Android? I thought the entire reason su was placed in /system/xbin is because if you use a stock ROM, you will see /system/xbin is virtually a empty directory while /system/bin is where the shipping userland tools are. Things should be kept simple since it's easier maintaining one file rather than a bunch of them. The instructions for rooting BS won't work for me because portable ubuntu only runs on 32 bit Windows and not when one is running 64 bit Windows. I think you just learned to do it a certain way not because you invented it but you just followed how others did it and those people probably did it that way because they thought it was correct but then, on the devices I use which had rooted stock ROMs, they all have su in /system/xbin and no where else as there was even a time when updating Superuser broke root access on the Motorola Xoom and basically it required pushing a good copy provided on xda to /system/xbin. Reading is one thing but hackers will always experiment and try to break things on purpose and so far, every root app has worked fine from a single /system/xbin/su from 2.2 to 4.1.2. And like I said before, some Samsung phones have su in /sbin which is completely outside of /system. That's the difference between actually experimenting and just reading and reading will tell you all sorts of things but the only way to see results is to actually experiment with it and see what happens and so far on 4 devices + BS, all root apps works fine with /system/xbin/su. In fact, remember it's the SuperUser app that is supposed to install su anyways and I'm sure it has a default location of where it wants it. Many people that root only go as far as using root apps and not actually use shell on the device anyways since only real unix users will use that. su for all we know will probably work from any of the two locations as long as things work as there are some places that says on Motorola when doing the root hack manually to put su in /system/bin while the rooted stock ROMs available on xda has it in /system/xbin. Maybe the reason for the xbin is because like I said earlier /system/bin is what the stock ROM ships with and putting stuff you add on your own in a more empty directory makes it easier if something goes wrong since you won't be accidentally removing stuff that is part of the ROM. Android x86 which is another Android emulator has su in /system/xbin which is where their developer even said it's located when I searched earlier. In any case, no one has gotten SuperSU working with BS yet, SuperSU works better usually because Superuser is more buggy at times.
[Android Software/Hacking General [Developers Only]] Nephatiu:
I really don't get this... I just tried it and it worked fine from my first attempt. I'll upload the Root.fs with SuperSU and it's su libraries right now. ;)

EDIT: I did it the Portable Ubuntu way, though, not inside Android itself, that didn't work. ;)

While SuperSU'ing my BS Root.fs I also just found out SuperSU is the only Superuser app up 'till now which even makes 3 copies of 'su' in 3 different folders. :D What's your answer to that? :cowboy:

Anyway, although I admit installing SuperSU was way different than installing the other 2 Superuser apk's (dunno about any others), but it wasn't that hard figuring out what to do, though. I'll update the How-To in the OP later today as well, so you can see what I did to get it working.

Grtz,

~ Nephatiu ;)
[Android Software/Hacking General [Developers Only]] Almighty2:
I almost thought you managed to get SuperSU installing the su binary when SuperSU is ran inside BS. Where did you get the su binary though since it seems like BS needs the x86 version of the binary, atleast that's what it seems like when downloading Superuser to extract. Can you include the stock Launcher as well since it seems like doesn't hurt to have two Launcher's.

What location did SuperSU put the su in if there are three locations since I know SuperSU when checking for a existing su, it checks only /system/bin and /system/xbin.

I can understand how you can get the .apk's for SuperSU and the 2 Superuser's but I always thought the su binary was downloaded rather than being part of the apk itself. Besides, for the root method for BS, the downloaded zip file does have a system subdirectory with the apk and su binary but where did you get the su binary for Koush's Superuser and SuperSU?

I found the zip for SuperSU v1.6.9 here:

http://download.chainfire.eu/365/SuperSU/UPDATE-SuperSU-v1.69.zip

Tried extracting the su and sending it to /system/xbin and chmod 4755 on it but ran SuperSU and it still asks to update the su binary and it says installation failed.
[Android Software/Hacking General [Developers Only]] Nephatiu:
I actually just edited the other Root.fs with CWM as Superuser inside Portable Ubuntu, and it's already uploading for 20 mins now, so the launcher's are still the same, sorry for that.

Well, It's not 3 directories, it's 2, but it's 3 files. '/system/xbin/su', '/system/xbin/daemonsu' and '/system/bin/.etc/.su'. :p

They're not inside the apk itself, but they are in the flashable CWMrecovery zip-file. ;) They are cleverly hidden under a folder named "/x86". ;)

And the 'busybox.x86' that you needed to rename to 'busybox.armeabi' and replace back into the 'Superuser.apk' before, with SuperSU it's now called '/assets/supersu.x86.png'. ;p There's a chattr.x86.png as well, so I did that one as well, just to be sure. ;p

Also, there are a few more files needed from the zip. I'll update my How-To when the file finishes uploading. ;)

EDIT: Which has been done. ;p

Grtz,

~ Nephatiu
[Android Software/Hacking General [Developers Only]] Almighty2:
Any chance you can grab just the stock launcher from the stock Root.fs in C:\ProgramData\BlueStacksSetup\runtimedata_0.8.1.3 051.zip.

Now, that's weird. I just looked on devices that I installed SuperSU v1.69 on and the only thing other than the apk it installs is /system/xbin/su, there is no /system/daemonsu or /system/bin/.etc/.su.

I know they are inside the flashable CWMrecovery zip-file for SuperSU, atleast for the v1.69 zip-file, there are only two files in /x86, su and chattr, I don't see those files with any extensions in the file UPDATE-SuperSU-v1.69.zip which is the official zip file other than the apk.

There is a chance we might be looking at different zip files as there is no assets subdirectory, the closest thing is /common which has a Superuser.apk inside. Interesting on the png files since png files would be graphic files which are similar to jpg's.
[Android Software/Hacking General [Developers Only]] Nephatiu:
-> There you go. <- ;)

Indeed, because the v1.69 zip should normally install them. Dunno about earlier versions. It should be '/system/xbin/daemonsu', though. ;p

There are 2 files in x86, you jut need 1, the 'su', but there is an assets directory in the Superuser.apk, when you open it with 7zip. ;)

Grtz,

~ Nephatiu
[Android Software/Hacking General [Developers Only]] Almighty2:
Thanks for the launcher apk extracted file in advance.

/system/xbin/daemonsu is only used for Android 4.3+ as discussed in common/install-recovery.sh and common/Superuser.apk/assets/install-recovery.sh. Where did you even find the '/system/bin/.etc/.su' file?
[Android Software/Hacking General [Developers Only]] Nephatiu:
ui_print "- Placing files"
mkdir /system/bin/.ext
cp $BIN/su /system/xbin/daemonsu
cp $BIN/su /system/xbin/su
cp $BIN/su /system/bin/.ext/.su
cp $COM/Superuser.apk /system/app/Superuser.apk
cp $COM/install-recovery.sh /system/etc/install-recovery.sh
cp $COM/99SuperSUDaemon /system/etc/init.d/99SuperSUDaemon

Chainfire's own zip instructions... :silly:

Grtz,

~ Nephatiu ;)
[Android Software/Hacking General [Developers Only]] Almighty2:
Interesting, what file is that in since I searched through the entire archive and inside the apk and even the zip inside the apk, something tells me the third file might be for the OTA Survival mode which I think is one feature the other Superuser's don't have that allows one to remain rooted even after a OTA update.
[Android Software/Hacking General [Developers Only]] Almighty2:
BlueStacks 0.8.2.3018 has just been released...
[Android Software/Hacking General [Developers Only]] robertkjr3d:
portable_ubuntu hang

i get hung-up on Windows 8.1 64bit... Anybody else get stuck on the splash screen of the Portable_ubuntu? The splash screen comes up, and then it hangs. I was going smoothly along instructions-set #2, but then got stuck there. I turned off my 'windows-defender' and my 'windows-firewall', and it still does not run.
[Android Software/Hacking General [Developers Only]] robertkjr3d:
Answering my own question: Partially. I got this answer from the 'Portable Ubuntu Remix' crowd. https://sourceforge.net/p/portableubuntu/discussion/858610/thread/c67356c8/ They are saying, you cannot run it on a 64bit windows, including mine. Yet the instructions included refer to copying it to a "program files (x86)".

Edit: In this same thread there are multiple people with the same issue. Many also mentioning that the original instructions should be altered. I would even add: 'Who still has a 32bit machine?' hehe... All of mine have been relegated to the consignment shops. Anyway, I will try Falcon's post: http://xdaforums.com/showthread.php?p=35977551&highlight=portable#post35977551
[Android Software/Hacking General [Developers Only]] SaidJan:
I have the same problem, what's the solution?
[Android Software/Hacking General [Developers Only]] Makarboy:
I cannot uninstall bluestacks, I have windows 8, when I try to uninstall it in control panel, it closes. I have done every step in thie post and now i cannot reinstall it. I have registry errors during installation.:crying:

EDIT: I fixed with microsoft fix, THANKS
[Android Software/Hacking General [Developers Only]] mobile-freak:
Hello everybody,

i've installed BlueStacks yesterday and i want to root it now. What is the easiest way to root?

I see a lot of methods and so on, most of them had virus included.

It would be great if someone can help.
[Android Software/Hacking General [Developers Only]] LuckyColdJohnson:
I dont think this works anymore. It wont let us root it and enjoy this on our PC's...Hopefully the OP can help us out a little.

I would be willing to donate.
[Android Software/Hacking General [Developers Only]] reeper250:
Same here :(

I've deleted all the files and folders in C drive plus deleted all BlueStacks registry values as well as done a "Forced Uninstall" through Revo Uninstall Pro... Tried various installation packaged of BlueStacks; offline, online, beta versions, etc. None have worked...

It works on my desktop PC but not on my laptop...
[Android Software/Hacking General [Developers Only]] hertsjoatmon:
Hi all, just getting in to Android emulation since my Note 8.0 was stolen. After looking at the various options I decided to go with Andy to start with last night as it looked easy to run and edit, was free and didnt require me to download any apps etc daily.

Installation was easy and I had the VM running with 3GB of RAM and 64Mb for video and 2 Cores on my Surface Pro 2 (i5 4200). It all ran OK but it really is a resource hog! my CPU was at a minimum about 55% loaded. When I ran AnTuTu with in Android I got a score of 18246 which is inline with a Galaxy S3 but I was expecting more. Anomoly 2 seems to run ok on it though.

[edit] this was running at 1280 x 768 windowed.

Does Bluestacks run better than Andy interms of performance?

Ideally I'd like to run Android natively via a bootable USB 3 thumb drive but haven't found a solution I'm comfortable with yet. Console OS looks interesting but is a while off yet and I'm still getting my head round Android x86.
[Android Software/Hacking General [Developers Only]] storo1975:
Does this still work?

Does this still work for the latest version?

I tried downloading the root files from method one but it says due to too much traffic its been disabled
[Android Software/Hacking General [Developers Only]] mohazia:
I don't know. U tell me that have Gpu accelerator dose bs had gpu accelerator? , my answer is bluestacks don't have.

That's y I will take a look on that later.
[Android Software/Hacking General [Developers Only]] kianty99:
1- Now delete ur root.fs & data.s* from %programdata%\bluestacks
2- Extract data.s* from the archeive @ %programdata%\bluestackssetup on %programdata%\bluestacks

what did you mean for "data.s*"? maybe folder Data.sparsefs? and which archive contains the other data.s*?

thanks
[Android Software/Hacking General [Developers Only]] mohazia:
I was away from my computer, you can do

Reset your android by

1- Download "Root_MOD.rar", "initrd.rar" and "Data_Org.rar" from HERE

2- Extract them on "%programdata%\BlueStacks\Android"

you did.

--------------------------------------------------------------edited

this method not working

there is other method I'm now test it based on adb command

adb connect 127.0.0.1:5555

adb -s 127.0.0.1:5555 uninstall *ending*

adb -s 127.0.0.1:5555 uninstall *arket*pdater*

I'm not sure about the second methods
[Android Software/Hacking General [Developers Only]] mohazia:
should I say you have to run command "%programfiles%\BlueStacks\HT-Quite.exe" (for WinX86) or "%programfiles(x86%\BlueStacks\HT-Quite.exe" (for WinX64) before replace your files
[Android Software/Hacking General [Developers Only]] qiangqiang101:
Great! Now I can't reinstall after i follow your guide, and uninstalled BS.:(
[Android Software/Hacking General [Developers Only]] qiangqiang101:
Installer close automatically when I install, i tried open as administrator also not working, it close on "Preserving user data" after the welcome screen. No error pop-up when closing.