# Common Issues in Android Enrollment

1. “Certificate error occurred” 
--------------------------------

### Description

After entering the server name on the Hexnode app and clicking **Next**, a dialog window shows the message “Certificate error occurred”.

![Error message says Certificate error occurred](https://cdn.hexnode.com/mobile-device-management/help/wp-content/uploads/2021/12/Screenshot_20211220-131051-512x1024.png)

### Probable Causes 

- Case 1: Date and time are not set correctly on the device.
- Case 2: Incorrect server name was entered
- Case 3: Device is missing critical security updates

### Solutions 

Case 1: Make sure you’ve set the time and date on the device correctly. Then, you may restart the device to ensure the change is applied throughout the device. You may also reconfigure the date and time settings from the **Settings** app on the device by going to **System > Date and time**.

Case 2: Retry enrollment with the correct server name.

Case 3: It is recommended to keep your Android devices updated with the latest security patches. You can check and install updates by opening the **Settings** app and going to  **System > Advanced > System updates**.

2. “Network error occurred” 
----------------------------

### Description 

After entering the server name on the Hexnode app and clicking **Next**, a dialog window shows the message “Network error occurred”.

![Error message says Network error occurred](https://cdn.hexnode.com/mobile-device-management/help/wp-content/uploads/2021/12/Screenshot_20211202-123125-512x1024.png)

### Probable Causes

- Device is not connected to the internet.
- Other network issues or connection timed out.

### Solutions

- Check the device-end network connectivity.
- For authenticated enrollments, check if the connected domain service is up and operational.

3. “Unknown error occurred” 
----------------------------

### Description 

After entering the server name on the Hexnode app and clicking **Next**, a dialog window shows the message “Unknown error occurred”.

![Error message shows Unknown error occurred](https://cdn.hexnode.com/mobile-device-management/help/wp-content/uploads/2021/12/Screenshot_20211202-123001-512x1024.png)

### Probable Cause

Incorrect server name or some advanced enrollment error.

### Solution

Retry enrollment with the correct server name.

4. “Invalid server. Make sure you enter a valid portal name in the ‘server’ field” 
-----------------------------------------------------------------------------------

### Description 

After entering the server name on the Hexnode app and clicking **Next**, a dialog window shows the message “Invalid server. Make sure you enter a valid portal name in the ‘server’ field”.

![Error message says Invalid server](https://cdn.hexnode.com/mobile-device-management/help/wp-content/uploads/2021/12/Screenshot_20211202-123055-512x1024.png)

### Probable Causes

- Case 1: Clicking **Next** without entering the server name.
- Case 2: Incorrect server name.

### Solution

Retry enrollment with the correct server name.

5. “Trouble connecting to server” 
----------------------------------

### Description 

After entering the server name on the Hexnode app and clicking **Next**, a dialog window shows the message “Trouble connecting to server”.

### Probable Cause 

An attempt to establish a connection with the server got disrupted.

### Solutions

- Check for network connectivity issues.
- Retry after some time.

6. “Device limit reached! Please contact your administrator!” 
--------------------------------------------------------------

### Description 

This error appears while enrolling the device after granting the app permissions.

### Probable Causes 

- Case 1: You have reached the maximum number of devices you can enroll under your license.
- Case 2: Your license has expired.

### Solutions 

Case 1: Check the number of devices allowed to enroll as per your current plan. The total number of enrolled devices should not exceed the total device licenses in your subscription under **Admin > License**.

Case 2: Verify your license and subscription status on your portal under **Admin > License**.

7. “Your device is not authorized to be enrolled. Please contact the administrator to know more.” 
--------------------------------------------------------------------------------------------------

### Description 

After entering the server name on the Hexnode app and clicking **Next**, a dialog window shows the message “Your device is not authorized to be enrolled. Please contact the administrator to know more”.

![The error message says device is not authorized to be enrolled](https:2021/12/Screenshot_20211221-045048-512x1024.png)

### Probable Causes 

- Enrollment settings in the portal restrict Android device enrollment.
- Enrollment settings in the portal restrict enrollment only to pre-enrolled devices.

### Solutions 

On your portal, navigate to **Admin > Enrollment** and make appropriate changes as follows –

1. Under the **Enrollment Restrictions** section, **Android** should be checked to allow enrollment of Android devices.
2. The option **Pre-approved Device only** should be unchecked if you are enrolling a new device.

[![Configuring Enrollment Restrictions under Enrollment in Admin tab of Hexnode UEM console.](https:2021/12/Enrollment-Restrictions-under-Enrollment-in-Admin-tab-of-Hexnode-UEM.png)](https:2021/12/Enrollment-Restrictions-under-Enrollment-in-Admin-tab-of-Hexnode-UEM.png "Enrollment Restrictions under Enrollment in Admin tab of Hexnode UEM")

8. Having trouble granting permissions. 
----------------------------------------

### Description 

Unexpected behavior on attempting to grant device permissions like the toggle button is not working or selections are redirecting to unrelated settings page.

### Probable Cause 

This error has been observed in a few devices having vendor customized OS and might be resulted from the difference in the Settings app configurations.

### Solution 

Please grant the required permissions manually. The special permissions required by Hexnode are –

- Device administration
- Usage access
- Draw over apps
- Write systems settings
- Notification access
- Allow app installation

On Android 10, you can find these settings under the **Special app access** page under **Apps & Notifications** in **Settings** app. Grant permission for the Hexnode app from there by selecting and enabling each of the special access permissions.

<https:2021/12/granting-permissions.mp4>

9. “You are not authorized to enroll any devices with Hexnode MDM. Please contact your administrator if you have received an enrollment request.” 
--------------------------------------------------------------------------------------------------------------------------------------------------

### Description 

This error shows up on submitting the credentials for authenticated enrollments.

![Error message reads you are not authorized to enroll](https:2021/12/Screenshot_20211221-050226-512x1024.png)

### Probable Causes 

- Attempt to sync with the associated domain failed
- Self-enrollment is disabled for the domain
- Incorrect user credentials

### Solution 

Check and enable ‘Self Enrollment’ for the connected domain. You can check if enrollment is allowed for the particular domain by navigating to the **Admin** tab and selecting the sub-tab corresponding to your domain service provider (e.g., Google Workspace, Active Directory etc.). The domain must be listed in the following window. Click on the settings icon ![Settings gear icon](https:2021/12/Screen-Shot-2021-12-02-at-3.00.35-PM.png) and select **Enable Self-enroll**.

![Select the sub-tab corresponding to the domain service provider](https:2021/12/Active-Directory-domains-in-Admin-tab-of-Hexnode-UEM.png)

10. Not able to grant notification access for Hexnode app
---------------------------------------------------------

### Description 

Unexpected behaviour when trying to enable **Notification access** on the app permissions page of the Hexnode agent app during enrollment.

![Enabling notification access in the Hexnode app permissions page](https:2024/06/App-permissions-page-of-Hexnode-app.png "App permissions page of Hexnode app")

Toggling the option redirects us to the **Device & app notifications** page in the Settings app (**Settings** > **Notifications** > **Privacy** > **Device & app notifications**). Here, the ‘Allow notification access’ option must be enabled for the Hexnode app for notification access to be provided. But the option was found to be greyed out.

![Allow notification access option is disabled under the Device & app notifications page of the Hexnode app](https:2024/06/Not-able-to-grant-notification-access-for-the-Hexnode-app.png "Not able to grant notification access for the Hexnode app")

### Probable Cause

This error occurs when the APK version of the Hexnode app is installed on Android devices running versions 13 and above. Android 13+ devices may have device settings restricted for apps when they are installed from unknown sources.

### Solution

1. Tap on the Hexnode app icon in the **Device & app notifications** page of the agent app to be taken to its **App info** page.
2. On the **App info** page, Android provides an overflow icon at the top right, which, when clicked, gives you the ‘Allow restricted settings’ option. Allowing the option lets us enable the notification access option.

![Select the Allow restricted settings option from the Hexnode App info page.](https:2024/06/App-info-page-of-the-Hexnode-agent-app.png "App info page of the Hexnode agent app")

On certain Android devices, the ‘Allow restricted settings’ option may not be visible on the App info page. In such cases, the user should go back to the **Device & app notifications** page of the agent app and tap the greyed-out ‘Allow notification access’ setting. This results in the restricted setting dialog popping-up.

![Restricted setting pop-up](https:2024/06/Restricted-setting-pop-up.png "Restricted setting pop-up")

By clicking **OK** and reverting back to the **App info** page, the overflow icon with the ‘Allow restricted settings’ option will be visible, which the user can enable. Once the option is enabled, the user is allowed to set the ‘Allow notification access’ option in the **Device & app notifications** page.

![Allow notification access option can be enabled in the Device & app notifications page](https:2024/06/Grant-notification-access-for-the-Hexnode-app.png "Grant notification access for the Hexnode app")

Enable the option and return to the Hexnode app permissions page to enable notification access and continue the enrollment process.

11. “Unable to complete enrollment. Please contact your administrator for assistance.” 
---------------------------------------------------------------------------------------

### Description 

This error occurs when enrolling a device in Android Enterprise as a [Device Owner](https://www.hexnode.com/mobile-device-management/help/how-to-enroll-a-device-as-device-owner-using-hexnode-mdm/) or as a [Work Profile on Company-Owned Device](https://www.hexnode.com/mobile-device-management/help/how-to-enroll-a-device-in-android-enterprise-as-work-profile-on-company-owned-device/) using the Android Enterprise Enrollment Profile.

[![Error message displayed while enrolling the device in Android Enterprise using the Enrollment Profile](https:2024/10/Error-message-shown-during-device-enrollment-in-Android-Enterprise-using-the-Enrollment-Profile.png "Error message shown during device enrollment in Android Enterprise using the Enrollment Profile")](https:2024/10/Error-message-shown-during-device-enrollment-in-Android-Enterprise-using-the-Enrollment-Profile.png)

### Probable Cause 

The enrollment profile must remain assigned in the Hexnode UEM portal during the device enrollment process. Deleting the profile before the device completes enrollment will result in this error.

### Solution 

Users can contact your IT admin for help. The enrollment profile might have been accidentally deleted during the enrollment process or intentionally deleted to stop the enrollment. They can assist in resolving the issue.

IT admins should ensure the enrollment profile remains assigned in the Hexnode UEM portal until the enrollment process is fully completed. If this error occurs, you will need to create a new enrollment profile, assign it as the default profile. The users should restart the enrollment process from the beginning.