[HOWTO][4.2]Now there's an app for that. Enable Multiple Users in Android

Thenetstriker

Senior Member
Jul 24, 2008
163
104
0
I've tried to enable the multi user function on my Sony Xperia T with CyanogenMod 10.2, but every time I try to create a new user I get the following error in Logcat:

Code:
08-28 13:11:12.234: E/AndroidRuntime(6717): FATAL EXCEPTION: Thread-570
08-28 13:11:12.234: E/AndroidRuntime(6717): java.lang.NullPointerException
08-28 13:11:12.234: E/AndroidRuntime(6717): 	at android.os.Parcel.readException(Parcel.java:1437)
08-28 13:11:12.234: E/AndroidRuntime(6717): 	at android.os.Parcel.readException(Parcel.java:1385)
08-28 13:11:12.234: E/AndroidRuntime(6717): 	at android.os.IUserManager$Stub$Proxy.createUser(IUserManager.java:311)
08-28 13:11:12.234: E/AndroidRuntime(6717): 	at android.os.UserManager.createUser(UserManager.java:386)
08-28 13:11:12.234: E/AndroidRuntime(6717): 	at com.android.settings.users.UserSettings.createTrustedUser(UserSettings.java:365)
08-28 13:11:12.234: E/AndroidRuntime(6717): 	at com.android.settings.users.UserSettings.access$1700(UserSettings.java:74)
08-28 13:11:12.234: E/AndroidRuntime(6717): 	at com.android.settings.users.UserSettings$11.run(UserSettings.java:578)
08-28 13:11:12.234: W/ActivityManager(636):   Force finishing activity com.android.settings/.SubSettings
How can I solve this error?

Edit: I found a solution for this problem. Some of my apps where not installed properly, so the error occured in Settings.java while copying the app data to the new User. I just reinstalled the apps and then it worked.
 
Last edited:

xforce3

New member
Sep 19, 2013
1
0
0
Cannot go back to primary user

Hi all, first post here!

I have a Samsung Galaxy Note (N7000) running Cyanogen 4.3 (most recent nightly build) and successfully managed to increase the max number of users and to create/remove users using the Terminal Emulator. All additional users seem to work correctly, each with their own appdata.

One minor issue: I found that the only way to switch from primary to another user is pressing the power menu to bring up the list of additional users, and from there it works correctly (the "switch user" tile in the quick settings panel doesn't appear to work at all).

One bigger issue: once in a secondary user it seems impossible to switch to any other user, simply because the power menu does not show any user. There is an option (for primary) in settings>buttons>power menu called "profile switcher", but the "buttons" item has disappeared for the secondary users (disabled?). With this, I am left with having to reboot the phone whenever I need to switch away from a secondary user. Someone in this forum mentioned that the lock screen needs to be in landscape... I can rotate the desktop (with Nova) or the drawer, but cannot find out how to rotate the lockscreen (even with auto-rotate on).

Any idea?;)

Last, I downloaded the "user management" application mentioned in the forum, but when loading it appears blank (no user detected) so no chance to use the options to switch or remove (only "create" works, in sense that a new user is added, but won't show in the app).

Other than this thanks a million to all contributors!

Cheers!
 
Last edited:

MJBBRU

Member
Jun 1, 2013
12
1
0
Bruinisse
Not working on GT p5100

Hi there,

I tried to enable multi user in the terminal window. After then a new line appeared in Settings menu.
After I press "Add User" the screen goes black and says "Settings has stopped."
So for me this is not working. I also tried the app but it does the same.

I'm running Android 4.2.2 on a rooted Samsung GT-P5100
Basebaned-version: P5100XXDMG1
 

Rayan

Senior Member
Feb 24, 2004
1,969
273
0
Baja
Same goes with the LG G2 (D801). I got to the point of enabling the multi user feature, but when I try to create a user under Terminal, it errors out. User Management app does not work either (blank screen). I disabled the crippled Guest Mode on the g2 but still no go.

On my Galaxy Note it works incredibly well though.

Anyone?

Sent from my LG-D801 using Tapatalk
 

giosico

New member
Jul 15, 2012
4
0
0
Not working on HTC1X CM10.2 or G Nexus2 4.3

I tried the following terminal commands on both my Android 4.3 phones, one crashed, one just returned back to the terminal. All commands were successful except the last one.

My HTC One X is running CynogenMod 10.2 nightly from 10 Nov 2013. It rebooted on the last command with no change.
My Samsung Galaxy Nexus is running ASOP 4.3. It just returned to the terminal after the last command with no change.

I was using this terminal app on the device itself. "Android Terminal Emulator Jack Palevich"

Here are the commands
su
pm get-max-users (results = 1)
setprop fw.max_users 3
pm create-user Guest
I hope that helps.
 

petesimon

Senior Member
Aug 5, 2013
84
26
0
Oklahoma
www.facebook.com
works!

it works on Jiayu G4 Advanced phone, with android 4.2.1.
I ran these commands in adb shell (terminal emulator app also okay):
Code:
adb shell
su
pm get-max-users
setprop fw.max_users 5
pm create-user Guest
setprop lockscreen.rot_override true
other good commands to run after you create one or more users to show details about users' names, files, possible email passwords, etc ...
replace # with the right user number. I used "10" so it might be the number for the second user (first user after the owner).
Code:
pm list users
ls -la /data/user
ls -la /data/system/users
ls -la  /data/system/users/#
more /data/system/users/#.xml
sqlite3 /data/system/users/#/accounts.db
[INDENT].tables
SELECT * FROM accounts;
.exit
[/INDENT]
get the sqlite3 static arm binary (mirror link)

added these to /system/build.prop file for permanent effect after reboots. Use a buildprop editor from google play store:
Code:
fw.max_users 5
lockscreen.rot_override = true
and reboot.

On the lockscreen, tilt the screen landscape style and there should be at least two circular user icons at the bottom under the keypad. Pick one and enter any unlock code and go Menu > System Settings > Users and change user properties. Problem: some data is shared among accounts, so all users see all gallery photos, music and files store on the internel and external sdcard's :eek: What's the deal here?




*EDIT* -- Better method with Xposed Framework and Modaco Toolkit module in this post here

*note: the tablet/phone device needs root access. some sqlite commands take from this blog.
 
Last edited:

petesimon

Senior Member
Aug 5, 2013
84
26
0
Oklahoma
www.facebook.com
Hi there,

I tried to enable multi user in the terminal window. After then a new line appeared in Settings menu.
After I press "Add User" the screen goes black and says "Settings has stopped."
So for me this is not working. I also tried the app but it does the same.

I'm running Android 4.2.2 on a rooted Samsung GT-P5100
Basebaned-version: P5100XXDMG1
Howdy. Have you tried "SwitchMe" app? https://play.google.com/store/apps/details?id=fahrbot.apps.switchme&hl=en

---------- Post added at 02:54 PM ---------- Previous post was at 02:43 PM ----------

Wouldn't it be great if you can set it up so when the phone boots, it comes up with a screen like Window 7's where you choose a user.
It does come up with a screen showing multiple users' avatars as small circular icons at the bottom of my screen. I just have to hold the device in landscape orientation for 2 seconds, press on an avatar and unlock the device based on that user's lock preference. :D Have you figured this out for your devices? See my post #169 on page 17.
http://forum.xda-developers.com/showpost.php?p=48305732&postcount=169
 

petesimon

Senior Member
Aug 5, 2013
84
26
0
Oklahoma
www.facebook.com
Hello Petesimon,
Just tried Switchme App. App looks fine but my language settings also changed after rebooting my device.
Howdy Bru.
Awh bummer! :eek: On which device again? There must be some rc script, xml file or other text file that can be edited to change multi user behavior. But I'm only brave to edit system files on my linux computer, not my phone. Maybe hire some Minions (despicable me) to data mine inside your phone. :silly:
 
Last edited:

petesimon

Senior Member
Aug 5, 2013
84
26
0
Oklahoma
www.facebook.com
Xposed framework, and Modaco Tookit app

For the devices that have trouble with command line hack or multi user simply does not seem to work right, then this multi user via Xposed Framework and Modaco Toolkit could work, and very nicely/easily. No tilt to landscape needed, just hold power button until you see the popup menu. Follow instructions carefully, and it should work for most phones with Android 4.2.x +. It works on my Jiayu G4A chinese phone.

Be sure to add this line to your /system/build.prop file:
Code:
fw.max_users 3
Download Xposed from here.

Download Modaco Tookit from here.

After setting up and installing, then reboot.



More photos: http://imgur.com/a/DwnpW/embed#0

* Need "root" of course
 
Last edited:

Rayan

Senior Member
Feb 24, 2004
1,969
273
0
Baja
For the devices that have trouble with command line hack or multi user simply does not seem to work right, then this multi user via Xposed Framework and Modaco Toolkit could work, and very nicely/easily. No tilt to landscape needed, just hold power button until you see the popup menu. Follow instructions carefully, and it should work for most phones with Android 4.2.x +. It works on my Jiayu G4A chinese phone.

Download Xposed from here.

Download Modaco Tookit from here.



More photos: http://imgur.com/a/DwnpW/embed#0

* Need "root" of course
Thanks but nope, I tried that before and it does not work...

Cheers

Sent from my LG-D801 using Tapatalk
 

Quantenkosmos

Member
Aug 4, 2010
10
2
0
works under KitKat

Hello,
just have to say that this method / App also works on KitKat Android 4.4.
I tried the latest KitKat OmniROM 4.4.2 Nightly, where only one user was standard...
Now I have more again :victory: Thx.
 

id74em8

Senior Member
Oct 21, 2013
310
102
73
If anybody wants to try this in android 4.1.2, the codes are:

su
getprop fw.max_users [shows the maximum users enabled]
setprop fw.max_users <any number above 2. Mine is 4>
pm create-user <desired username here>