Skip to end of metadata
Go to start of metadata

Update

The FlleWave Companion is available again in the Play Store and FileWave 14.5.1 should has addressed this.


If the version of FileWave is below 14.5.1 and the temporary workaround was used, then to disable the temporary configuration re-edit the settings_custom.py file adding the following:

/usr/local/filewave/django/filewave/settings_common.py
settings.USE_EMM_COMPANION_APP = True

Once saved, run the following commands:

/usr/local/filewave/python/bin/python /usr/local/filewave/django/manage.pyc emm_fix_default_policy
/usr/local/filewave/python/bin/python /usr/local/filewave/django/manage.pyc emm_sync_now




Temporary Workaround - No longer required

The below is no longer required, but has been left to help identify setups that were adapted.


In early May 2021, one of the APIs used in FileWave EMM Companion Application was deprecated by Google.  This change was initially announced for end-of August, but was enacted early, and subsequently caused the FileWave Companion app to be removed from the Play Store.

As the EMM Companion Application is part of the current enrollment process, enrolling Android EMM devices with FileWave will not complete as a result of this change.

While we are working on adapting the EMM Companion Application to the new APIs, you can execute the following workaround to enroll EMM devices with FileWave. (FileWave 14.1.2, FileWave 14.2.2)

/usr/local/filewave/python/bin/python /usr/local/filewave/django/manage.pyc apply_patch
curl -o /usr/local/filewave/django/android/management/commands/emm_fix_default_policy.py https://fwdl.filewave.com/emm/emm_fix_default_policy.py
# check settings (see below)
fwcontrol server restart
/usr/local/filewave/python/bin/python /usr/local/filewave/django/manage.pyc emm_fix_default_policy

This change will configure FileWave to no longer require the EMM Companion Application and enrollment can complete.

This is a temporary  solution until a new version of the EMM Companion Application will be reviewed and published on the Google Play Store.

The following features will be limited or not available:

  • Some inventory fields will not be reported, or reported but less accurately
  • Geo-fencing will not be possible


Like any patch, restart services after running apply_patch !



In case running the script produces a long stack trace with googleapiclient.errors.HttpError: error 429: the script is not coping with Google rate limit. The best solution is to wait roughly one minute and run the script again (/usr/local/filewave/python/bin/python /usr/local/filewave/django/manage.pyc emm_fix_default_policy) to send the updated policy to the next batch of devices.


As any other patch for FileWave 14.1.2 and 14.1.3, patch tool changes related to the scheduler requires additional modifications ; FileWave 14.1.4 and 14.2.2 already contain them:

The scheduler uses a different redis configuration to change APN priority.

edit

/usr/local/filewave/django/filewave/settings_common.py

replace

HUEY = {
    'name': 'filewave',
    'huey_class': 'huey.RedisHuey',
    'serializer': huey_helpers.FileWaveSerializer(),
    'immediate': False,
    'utc': SCHEDULER_USE_UTC,
    'consumer': {
        'workers': 4,
    },
}

with

from redis import ConnectionPool

HUEY = {
    'name': 'filewave-huey',
    'huey_class': 'huey.PriorityRedisHuey',
    'serializer': huey_helpers.FileWaveSerializer(),
    'immediate': False,
    'utc': SCHEDULER_USE_UTC,
    'connection': {'connection_pool': ConnectionPool(
            host='127.0.0.1',
            port=6379,
            max_connections=100
        )
    },
    'consumer': {
        'workers': 4,
    },
}

(Don't forget the

from redis import ConnectionPool

)

Then restart services.


We also recommend to flush redis after restarting services:

 /usr/local/sbin/redis-cli FLUSHALL

If you forget this steps, you will see:

  NotImplementedError: Task priorities are not supported by this storage.

in logs.


check settings_custom.py and remove any file-based cache.

We used to set file-based cache for some customers having lock issues, but this file-based cache is incompatible with redis cache's new configuration.

So if you see errors like:

line 30, in delete_redis_value   File "/usr/local/filewave/python/lib/python3.7/site-packages/django_redis/__init__.py", 
line 15, in get_redis_connection    
raise NotImplementedError("This backend does not support this feature") NotImplementedError: This backend does not support this feature 


check settings_custom.py and check if there is anything like

settings.CACHE= ...
'BACKEND':'django.core.cache.backends.filebased.FileBasedCache',

And remove the whole block

  • No labels