Using File Sync on Android devices

Solved

I'm still new here. I've got 60 Android devices (Ulefone X7 Armor) enrolled and now need to store some files on each device. These are typically manuals and work policy documents which all users need to access.

File Sync seems to be the tool for this, and I have managed to configure the Content Library, upload some files to it and create a File Sync rule targeted on specific devices.

However, I am confused about where the files land on the device.

If I use the default %sdcard% path, I get an immediate error in the device logs - "File synchronization failed".

If I try %shareddata% then the logs claim that the files have synced but I have no idea how to find them.

The MobiControl 'content' tab for the devices says that there are no device files, no matter which destination path I chose.

The File Manager for the devices reports that there is an sdcard directory on the device, but it doesn't contain any files.

The log from the device says:

2023-07-12 21:26:41.000|File saver - /storage/emulated/0/filename.pdf - All Documents_v_1_c2d77f0b-d95c-4fdc-a4f8-9297d749061c.pdf.mrx.tmp|E|DO|[net.soti.comm.asyncfile.f] Exception while writing to file|java.io.FileNotFoundException: /storage/emulated/0/filename.pdf - All Documents_v_1_c2d77f0b-d95c-4fdc-a4f8-9297d749061c.pdf.mrx.tmp: open failed: EACCES (Permission denied)

Once I have discovered how to store the files reliably, I need to understand how I get to them. Some of the devices have a standard user interface, and others have a lockdown screen. So for the latter I need to be able to create a link in the lockdown menu, and for the former I need to be able to access them straight from the home screen.

Should I be able to see the files in the Content Library?

MobiControl version 15.6.3.1018 (Cloud).

I have read every support article I can find, but I'm none the wiser so I hope someone can help.

2 years ago
SOTI MobiControl
ANSWERS
MD
Matt Dermody Diamond Contributor
2 years ago
JK
James Knight
2 years ago

Hi Mark. Android version 10, not 11.

I tried using the %appdata% path and that does appear to have synced the files according to the log, but I still do not know where to find them on the device?

It should be noted that %appdata% is not one of the supported paths listed in the 'create file sync rule' dialog.

Thanks!

RC
Raymond Chan Diamond Contributor
2 years ago

Hi James,

I don't know why you mix up Content Library with File-Sync rule in your description.   They are two different approach for deploying/accessing contents.

If you add your manual/documents in Mobicontrol content library, deployment of such data (whether mandatory push or on-demand) onto the device will be done automatically, and device end-user 's access of such content will be via specific tab in MobiControl device agent app running on the device.

On the other hand, if your manual/documents files need to be opened/read by special reader/viewer app, then you can choose to use file-sync rule to deploy the files onto the devices. Device end-user then need to use file-manager or reader/viewer app to go to the relevant file folder to select the required file to be opened/viewed.   As the tightening scoped-storage permission model architected by Google for recent Android firmware versions means that MobiControl device agent cannot access third-party app's private folders and vice versa, the most sensible choice of device destination folder for file-sync rule will be standard public directory (e.g. %sdcard%/Download or its sub-folder, etc,). Please note that the macro %sdcard% actually refers to internal file-system in Flash memory rather than to external storage on add-on SD card.  Also, the directories referred by macros %shareddata% or %appdata% are private and not accessible by any bundled file manager or add-on third-party apps.

So, you first need to choose whether to use content library approach or to use file-sync rule approach to deployment your document files.

JK
James Knight
2 years ago

Hi Raymond

The reason I mix them up is because a) I am new to the platform, b) there is no documentation that I can find which explains the difference (or how to use SOTI Hub which appears to be a third option) and c) because I spent an hour on the phone yesterday with SOTI "premium" support explaining what I wanted to do, and they told me to use File Sync.

I have searched "Content Library" time and again but can't find anything which explains how to get files into it, and I can't see any reference to it in the portal, so I'd be really grateful if you could please help me to understand how to do it.

Although it sounds like the Content Library is the thing I need to use, it would also be helpful to understand how I would access the files which Matt helped me to store in the appdata directory (or in %sdcard%/Download as mentioned by you). Where if File Manager, for example? I can get to it via the web console but I don't know where to find it on the devices.

Thank you for your help.

James

JK
James Knight
2 years ago

I've looked again. The old style portal shows a 'Content library' tab, and that's where I have put my files.

The storage path is 'C:\MobiControl' because that's what the support agent instructed.

Then I set up a rule to push the files to the devices as described above (again as instructed by Soti).

From what you're saying, anything in the Content Library tab should automagically appear in the content library on the devices? That would make sense, but it doesn't work for me. What else do I need to configure?

Thanks again.

James

RC
Raymond Chan Diamond Contributor
2 years ago

Content library policy is the oldest and least flexible approach among all those currently supported for data file deployment, but it is probably the simplest to configure.   I could not rule out the possibility that you find it too restrictive after successfully trying out the policy as described below.

You seem to have configured the content library root path to be C:\MobiControl on your server host and have already uploaded various content/data files there.  This sounds OK.  Have you created any Content Library policy yet on the leftmost column of the Android  Content-Library tab in your web-console?  The policy should include selected source group/group-tree(s) in content library, the targeted device group/group-tree,  push/on-demand deployment options, etc.

Make sure that the "Assigned Rule" category in the "Configurations" tab of your targeted device in the web-console has the  configured Content-Library policy listed.  Then, go to the MobiControl device agent on the targeted device. Select the content-library tab from the main menu and you should be able to see the selected source tree structure defined in the content-library policy.  Tap on specific data item, and the the file should be opened with registered viewer and displayed on your device screen.

JK
James Knight
2 years ago

Many thanks, Raymond

The policy was the thing which I had not created - again this doesn't seem to be documented and it wasn't immediately obvious.

Having created the policy, the files are pushing nicely to the devices.

I appreciate your help, thank you.

James

Solution
RC
Raymond Chan Diamond Contributor
2 years ago

It's good to know that Content Library policy works for your case now.

The Soti Hub approach that you mentioned is comparatively more advanced introduced some five years ago, and using it can leverage more precise user-group permission & access control of files in supported enterprise repositories such as MS Sharepoint, etc. with a free Soti Hub app.

The more generic File-sync-rule approach recently supports using Xtreme Hub to reduce wasted network bandwidth in content distribution with very big content files and/or large number of geographically clustered devices.  

So, you may need to consider using them if your current content-library approach is not good enough.

JK
James Knight
2 years ago

Thanks Raymond - Content Library works fine for our current requirements :-)

If I need something more complex in the future then I will hook it up with Sharepoint.

Thanks again

G
GPMOD@SOTI
2 years ago

Hi James,

Thanks for posting on SOTI Pulse and thanks Raymond and Matt for responding to the post.

I am glad that you found the solution here. 

Thank you. 


Kind regards,

Technical Support | SOTI Inc. |1.905.624.9828 | support@soti.net | www.soti.net |