[GeoNode-users] Trouble with AuthAdmin/UpdateLayers/SyncGeofence

Paige Lott paige.lott.gis at gmail.com
Mon Jun 10 07:46:47 PDT 2019


Geonode Version: 2.8.2
Geoserver Version:  2.13-SNAPSHOT

Hi Geonode Users,

I'm extremely new to Geonode/Geoserver and I've been working on this
problem for a while now and haven't been able to figure out what I'm doing
wrong.  Thought I'd post to see if anyone else had run into this particular
error.  My install was done following the install guide on the docs for Ubuntu
16.04
<http://docs.geonode.org/en/master/tutorials/install_and_admin/geonode_install/#>.
Thank you for any help you can provide.

-Paige

Whenever I login to Geoserver:
WARN [geofence.cache] -
org.geoserver.geofence.cache.CachedRuleReader$NoAuthException: Can't auth
user [admin]


Whenever I try and run updatelayers to make the layers added in geoserver
visible in geonode, I get the error message below:

Python:
JSONField implementation is: <class 'jsonfield.fields.JSONField'>
Inspecting the available layers in GeoServer ...
Found 1 layers, starting processing
Could not retrieve GeoFence Rules count.
Could not retrieve GeoFence Rules count.
Stopping process because --ignore-errors was not set and an error was found.
Traceback (most recent call last):
  File "manage.py", line 31, in <module>
    execute_from_command_line(sys.argv)
  File
"/home/geo/Envs/geonode/local/lib/python2.7/site-packages/django/core/management/__init__.py",
line 354, in execute_from_command_line
    utility.execute()
  File
"/home/geo/Envs/geonode/local/lib/python2.7/site-packages/django/core/management/__init__.py",
line 346, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File
"/home/geo/Envs/geonode/local/lib/python2.7/site-packages/django/core/management/base.py",
line 394, in run_from_argv
    self.execute(*args, **cmd_options)
  File
"/home/geo/Envs/geonode/local/lib/python2.7/site-packages/django/core/management/base.py",
line 445, in execute
    output = self.handle(*args, **options)
  File
"/home/geo/Envs/geonode/src/geonode/geonode/geoserver/management/commands/updatelayers.py",
line 124, in handle
    execute_signals=True)
  File "/home/geo/Envs/geonode/src/geonode/geonode/geoserver/helpers.py",
line 630, in gs_slurp
    layer.set_permissions(perm_spec)
  File "/home/geo/Envs/geonode/src/geonode/geonode/security/models.py",
line 205, in set_permissions
    sync_geofence_with_guardian(self.layer, perms, user=geofence_user)
  File "/home/geo/Envs/geonode/src/geonode/geonode/decorators.py", line 48,
in wrapper
    return func(*args, **kwargs)
  File "/home/geo/Envs/geonode/src/geonode/geonode/security/utils.py", line
448, in sync_geofence_with_guardian
    _update_geofence_rule(layer.name, layer.workspace, service, user=_user)
  File "/home/geo/Envs/geonode/src/geonode/geonode/security/utils.py", line
592, in _update_geofence_rule
    raise RuntimeError(msg)
Exception: ('Failed to process fisheries_mgmt_points_evw',
RuntimeError('Could not ADD GeoServer User \'admin_geonode\' Rule for Layer
u\'agfc_fisheries_mgmt_points_evw\': \'u\'<!DOCTYPE
html><html><head><title>Apache Tomcat/8.0.32 (Ubuntu) - Error
report</title><style type="text/css">H1
{font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;}
H2
{font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;}
H3
{font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;}
BODY
{font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B
{font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;}
P
{font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A
{color : black;}A.name {color : black;}.line {height: 1px;
background-color: #525D76; border: none;}</style> </head><body><h1>HTTP
Status 404 - </h1><div class="line"></div><p><b>type</b> Status
report</p><p><b>message</b> <u></u></p><p><b>description</b> <u>The
requested resource is not available.</u></p><hr class="line"><h3>Apache
Tomcat/8.0.32 (Ubuntu)</h3></body></html>\'\'',))

Geoserver:
 WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules.json] in DispatcherServlet with name
'dispatcher'
 WARN [geofence.rest] - INVALIDATING CACHE
 WARN [geofence.cache] - Forcing cache invalidation
 WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules.json] in DispatcherServlet with name
'dispatcher'
 WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules/count.json] in DispatcherServlet with name
'dispatcher'
 WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules.json] in DispatcherServlet with name
'dispatcher'
 WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules] in DispatcherServlet with name 'dispatcher'


I've tried running sync_geofence to see if that would resolve anything but
I also receive an error when running that command.

Python:
JSONField implementation is: <class 'jsonfield.fields.JSONField'>
Synchronizing permissions for layer 1/1:
geonode:agfc_fisheries_mgmt_points_evw
Could not retrieve GeoFence Rules count.
Could not retrieve GeoFence Rules count.
('Unexpected error:', <type 'exceptions.RuntimeError'>)
perm_spec is {u'users': {u'admin_geonode': [u'view_resourcebase',
u'download_resourcebase', u'change_resourcebase_metadata',
u'change_resourcebase', u'delete_resourcebase',
u'change_resourcebase_permissions', u'publish_resourcebase',
u'change_layer_data', u'change_layer_style']}, u'groups': {}}

Geoserver:
 WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules.json] in DispatcherServlet with name
'dispatcher'
WARN [geofence.rest] - INVALIDATING CACHE
WARN [geofence.cache] - Forcing cache invalidation
WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules.json] in DispatcherServlet with name
'dispatcher'
WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules/count.json] in DispatcherServlet with name
'dispatcher'
WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules.json] in DispatcherServlet with name
'dispatcher'
WARN [servlet.PageNotFound] - No mapping found for HTTP request with URI
[/geoserver/rest/geofence/rules] in DispatcherServlet with name 'dispatcher'

The url for my geoserver for the geofence rule is at
/geoserver/geofence/rest/rules , does this mean I have the wrong version of
geoserver installed with geonode or is there a way to change where this is
pointing?  Any help is extremely appreciated.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geonode-users/attachments/20190610/582eb3e6/attachment-0001.html>


More information about the geonode-users mailing list