You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/active-directory-domain-services/join-ubuntu-linux-vm.md
+19-15Lines changed: 19 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,9 +34,9 @@ To complete this tutorial, you need the following resources and privileges:
34
34
35
35
## Create and connect to an Ubuntu Linux VM
36
36
37
-
If you have an existing Ubuntu Linux VM in Azure, connect to it using SSH, continue on to the next step to start configuring the VM.
37
+
If you have an existing Ubuntu Linux VM in Azure, connect to it using SSH, then continue on to the next step to [start configuring the VM](#configure-the-hosts-file).
38
38
39
-
If you need to create an Ubuntu Linux VM, or want to create a test for use with this article, you can create a VM using one of the following methods:
39
+
If you need to create an Ubuntu Linux VM, or want to create a test VM for use with this article, you can use one of the following methods:
@@ -51,7 +51,7 @@ Once the VM is deployed, follow the steps to connect to the VM using SSH.
51
51
52
52
## Configure the hosts file
53
53
54
-
To make sure that your VM's host name is set correctly for the managed domain, edit the */etc/hosts* file to set the hostname:
54
+
To make sure that your VM's host name is correctly configured for the managed domain, edit the */etc/hosts* file and set the hostname:
55
55
56
56
```console
57
57
sudo vi /etc/hosts
@@ -72,14 +72,15 @@ When done, save and exit the *hosts* file using the `:wq` command of the editor.
72
72
73
73
## Install required packages
74
74
75
-
The VM needs some additional packages to join the VM to the Azure AD DS managed domain. To install and configure these packages, update and install the domain-join tools using `apt-get`:
75
+
The VM needs some additional packages to join the VM to the Azure AD DS managed domain. To install and configure these packages, update and install the domain-join tools using `apt-get`
76
+
77
+
During the Kerberos installation, the *krb5-user* package prompts for the realm name in ALL UPPERCASE. For example, if the name of your Azure AD DS managed domain is *contoso.com*, enter *CONTOSO.COM* as the realm. The installation writes the `[realm]` and `[domain_realm]` sections in */etc/krb5.conf* configuration file. Make sure that you specify the realm an ALL UPPERCASE:
During the Kerberos installation, the *krb5-user* package prompts for the realm name in ALL UPPERCASE. For example, if the name of your Azure AD DS managed domain is *contoso.com*, enter *CONTOSO.COM* as the realm. The installation writes the `[realm]` and `[domain_realm]` sections in */etc/krb5.conf* configuration file. Make sure that you specify the realm an ALL UPPERCASE.
82
-
83
84
## Configure Network Time Protocol (NTP)
84
85
85
86
For domain communication to work correctly, the date and time of your Ubuntu VM must synchronize with the Azure AD DS managed domain. Add your Azure AD DS managed domain's NTP hostname to the */etc/ntp.conf* file.
@@ -123,19 +124,20 @@ Now that the required packages are installed on the VM and NTP is configured, jo
123
124
```
124
125
125
126
If *realm discover* can't find your Azure AD DS managed domain, review the following troubleshooting steps:
127
+
126
128
* Make sure that the domain is reachable from the VM. Try `ping contoso.com` to see if a positive reply is returned.
127
129
* Check that the VM is deployed to the same, or a peered, virtual network in which the Azure AD DS managed domain is available.
128
130
* Confirm that the DNS server settings for the virtual network have been updated to point to the domain controllers of the Azure AD DS managed domain.
129
131
130
-
1. Now initialize Kerberos using the `kinit` command. Make sure that you specify a user who belongs to the *AAD DC Administrators* group. If needed, [add a user account to a group in Azure AD](../active-directory/fundamentals/active-directory-groups-members-azure-portal.md).
132
+
1. Now initialize Kerberos using the `kinit` command. Specify a user that belongs to the *AAD DC Administrators* group. If needed, [add a user account to a group in Azure AD](../active-directory/fundamentals/active-directory-groups-members-azure-portal.md).
131
133
132
-
Again, the Azure AD DS managed domain name must be entered in ALL UPPERCASE. In the following example, the user *[email protected]* is used to initialize Kerberos. Enter your own user that's a member of the *AAD DC Administrators* group:
134
+
Again, the Azure AD DS managed domain name must be entered in ALL UPPERCASE. In the following example, the account named `[email protected]` is used to initialize Kerberos. Enter your own user account that's a member of the *AAD DC Administrators* group:
1. Finally, join the machine to the Azure AD DS managed domain using the `realm join` command. Use the same user account that's a member of the *AAD DC Administrators* group you specified in the previous `kinit` command, such as *[email protected]*.
140
+
1. Finally, join the machine to the Azure AD DS managed domain using the `realm join` command. Use the same user account that's a member of the *AAD DC Administrators* group that you specified in the previous `kinit` command, such as `[email protected]`:
@@ -151,15 +153,15 @@ If your VM can't successfully complete the domain-join process, make sure that t
151
153
152
154
## Update the SSSD configuration
153
155
154
-
One of the packages installed in a previous step was for System Security Services Daemon (SSSD). When a user tries to sign in to a VM using domain credentials, SSSD relays the request to the authentication provider. In this scenario, SSSD uses Azure AD DS to authenticate the request.
156
+
One of the packages installed in a previous step was for System Security Services Daemon (SSSD). When a user tries to sign in to a VM using domain credentials, SSSD relays the request to an authentication provider. In this scenario, SSSD uses Azure AD DS to authenticate the request.
155
157
156
158
1. Open the *sssd.conf* file with an editor:
157
159
158
160
```console
159
161
sudo vi /etc/sssd/sssd.conf
160
162
```
161
163
162
-
1. Comment out the line for *use_fully_qualified_names = True*:
164
+
1. Comment out the line for *use_fully_qualified_names* as follows:
163
165
164
166
```console
165
167
# use_fully_qualified_names = True
@@ -175,11 +177,11 @@ One of the packages installed in a previous step was for System Security Service
175
177
176
178
## Configure user account and group settings
177
179
178
-
With the VM joined to the Azure AD DS managed domain and configured for authentication, there are a few user configuration options to complete. These configuration changes including allowing password-based authentication, and automatically creating home directories on the local VM when domain users first sign in.
180
+
With the VM joined to the Azure AD DS managed domain and configured for authentication, there are a few user configuration options to complete. These configuration changes include allowing password-based authentication, and automatically creating home directories on the local VM when domain users first sign in.
179
181
180
182
### Allow password authentication for SSH
181
183
182
-
By default, users can only sign in to a VM using SSH public key-based authentication. Password-based authentication fails. When you join the VM to an Azure AD DS managed domain, those domain users need to use password-based authentication. Update the SSH configuration to allow password-based authentication as follows.
184
+
By default, users can only sign in to a VM using SSH public key-based authentication. Password-based authentication fails. When you join the VM to an Azure AD DS managed domain, those domain accounts need to use password-based authentication. Update the SSH configuration to allow password-based authentication as follows.
183
185
184
186
1. Open the *sshd_conf* file with an editor:
185
187
@@ -236,11 +238,13 @@ To grant members of the *AAD DC Administrators* group administrative privileges
236
238
%AAD\ DC\ Administrators ALL=(ALL) NOPASSWD:ALL
237
239
```
238
240
241
+
When done, save and exit the editor using the `Ctrl-X` command.
242
+
239
243
## Sign in to the VM using a domain account
240
244
241
245
To verify that the VM has been successfully joined to the Azure AD DS managed domain, start a new SSH connection using a domain user account. Confirm that a home directory has been created, and that group membership from the domain is applied.
242
246
243
-
1. Create a new SSH connection from your console. Use a domain account that belongs to the managed domain using the `ssh -l` command, such as *[email protected]*, and then enter the address of your VM, such as *ubuntu.contoso.com*. If you use the Azure Cloud Shell, use the public IP address of the VM rather than the internal DNS name.
247
+
1. Create a new SSH connection from your console. Use a domain account that belongs to the managed domain using the `ssh -l` command, such as `[email protected]` and then enter the address of your VM, such as *ubuntu.contoso.com*. If you use the Azure Cloud Shell, use the public IP address of the VM rather than the internal DNS name.
0 commit comments