Some installations run the controller as a dedicated user, ubnt in many cases. The script does not check for permissions and can render the controller unusable as the keystore cannot be loaded. The simple hardcoded solution was adding two variables:
UBNT_USER=ubnt
UBNT_GROUP=ubnt
And this addition before the controller is restarted.
Fix permissions
chown ${UBNT_USER}.${UBNT_GROUP} ${KEYSTORE}
Storing the existing permissions during the backup process may be cleaner, but since this variables must be modified before use anyway this method is sufficient.
Some installations run the controller as a dedicated user, ubnt in many cases. The script does not check for permissions and can render the controller unusable as the keystore cannot be loaded. The simple hardcoded solution was adding two variables:
UBNT_USER=ubnt UBNT_GROUP=ubnt
And this addition before the controller is restarted.
Fix permissions
chown ${UBNT_USER}.${UBNT_GROUP} ${KEYSTORE}
Storing the existing permissions during the backup process may be cleaner, but since this variables must be modified before use anyway this method is sufficient.