Skip to main content

I'm working through some remote support issues for macs, and stuck on this one. Mac is remote, and has to use a VPN to connect to the domain. Normally, after the machine joins the domain (no problem - I connect with the VPN and join) I log off as the local user then login as the domain user. Then I create a mobile account and all's well.



However, because the connection to the VPN drops once the local user is logged out, you can not login as a domain user because it can't look it up on the domain.



With Windows, we get around this issue by using "Change User" which doesn't actually log off the local user and doesn't break the VPN connection to the domain. I don't see how to accomplish this on a Mac, and because we support remote users with Macs, we need to be able to set them up on the domain.



One thing I tried was to create a local account using the domain ID/password, then login with it, connect to the VPN/domain, then tick "mobile account" but for that type of account it does not give a mobile option.



I also tried turning on Fast Switching (users) and selecting 'other user' and trying to log in then, but it won't allow it - apparently that breaks the VPN connection too (or perhaps Fast Switching requires an established account).



Thoughts? We just us OS Catalina

Wow, this thread helped me out in a MAJOR way.  Kudo's to everyone involved


Hello, Hope I might get an answer to this older thread. I've followed the steps above and found success a few months ago, however - I now am running into an issue I can't seem to get around. I'm getting an error when trying to create the mobile account. I'll share the steps I am doing to make this possible. 

 

1. Setup & Connect to VPN

2. Set DNS to company IP and domain

3. Bind to the company domain through Users & Groups

4. Open Terminal and run the below script and get the following error. 

For the admin username/password and the 'user to add' username/password, I enter those each in their own quotes due to special characters. Yes, I do not include the '$' in the command either. 

sudo /System/Library/CoreServices/ManagedClient.app/Contents/Resources/createmobileaccount -a "$adminUser" -U "$adminPass" -n "$userToAdd" -p "$userPass"

I then get prompted with the below and enter a quotation mark

dquote> "

I then get prompted for the admin password, and enter that.. Afterwards, I get the below message. 

*** error: "-n username" is a required argument

usage: createmobileaccount -n username [-h homepath] [-P | [-p password]] [[[-a username] [-U password]] | [-D]] [-v] [-V]
-n username : user record name.
-h homepath : user home path; Default is "/Users/<username>".
-p password : user password.
-P : prompt for user password.
-a username : opt SecureToken enabled admin user name.
-U password : opt SecureToken enabled admin user password.
-D : don't prompt for SecureToken enabled admin information.
-v : verbose output.
-V : version.

Examples:
createmobileaccount -n jsmith
createmobileaccount -v -P -n jsmith
createmobileaccount -vxn jsmith -h /Volumes/HD3/jhome

Notes:
- createmobileaccount must run as root.
- If you do not specify a password, the account's cached password will be created during the account's first log in.
- On encyrpted APFS volumes, an existing admin SecureToken user name and password is required in order for this account to be used at the EFI login window.
- External accounts are no longer supported as of 10.15.
- The old FileVault encrypted home directory mechanism (using -e) no longer works in 10.13 or later (but was only removed here in 10.15).

 

I've also tried the command without specifing the userpass (-p) and also tried putting the 'user to add' credentials in front of the admin credentials. 

Any advise would be greatly appreciated. 


Hello, Hope I might get an answer to this older thread. I've followed the steps above and found success a few months ago, however - I now am running into an issue I can't seem to get around. I'm getting an error when trying to create the mobile account. I'll share the steps I am doing to make this possible. 

 

1. Setup & Connect to VPN

2. Set DNS to company IP and domain

3. Bind to the company domain through Users & Groups

4. Open Terminal and run the below script and get the following error. 

For the admin username/password and the 'user to add' username/password, I enter those each in their own quotes due to special characters. Yes, I do not include the '$' in the command either. 

sudo /System/Library/CoreServices/ManagedClient.app/Contents/Resources/createmobileaccount -a "$adminUser" -U "$adminPass" -n "$userToAdd" -p "$userPass"

I then get prompted with the below and enter a quotation mark

dquote> "

I then get prompted for the admin password, and enter that.. Afterwards, I get the below message. 

*** error: "-n username" is a required argument

usage: createmobileaccount -n username [-h homepath] [-P | [-p password]] [[[-a username] [-U password]] | [-D]] [-v] [-V]
-n username : user record name.
-h homepath : user home path; Default is "/Users/<username>".
-p password : user password.
-P : prompt for user password.
-a username : opt SecureToken enabled admin user name.
-U password : opt SecureToken enabled admin user password.
-D : don't prompt for SecureToken enabled admin information.
-v : verbose output.
-V : version.

Examples:
createmobileaccount -n jsmith
createmobileaccount -v -P -n jsmith
createmobileaccount -vxn jsmith -h /Volumes/HD3/jhome

Notes:
- createmobileaccount must run as root.
- If you do not specify a password, the account's cached password will be created during the account's first log in.
- On encyrpted APFS volumes, an existing admin SecureToken user name and password is required in order for this account to be used at the EFI login window.
- External accounts are no longer supported as of 10.15.
- The old FileVault encrypted home directory mechanism (using -e) no longer works in 10.13 or later (but was only removed here in 10.15).

 

I've also tried the command without specifing the userpass (-p) and also tried putting the 'user to add' credentials in front of the admin credentials. 

Any advise would be greatly appreciated. 


Also, update your DNS information to communicate with the respective DC.

System Preferences >> Network >> Select the network connection ex: Wi-Fi >> Advance >> DNS >> Under Search Domain add your DNS entries.  This should work for you


Reply