<div dir="ltr">ok we will search for the error, in the meantime you can delete the layers directly from the db maybe using pgadmin.<div><br></div><div>Hope this helps</div></div><div class="gmail_extra"><br><div class="gmail_quote">2016-06-06 18:39 GMT+02:00 Nic Tait <span dir="ltr"><<a href="mailto:ngtait@gmail.com" target="_blank">ngtait@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Thanks Simone<div><br></div><div>I believe the layers were added through Geoserver by cascading a remote WMS service as a new store, subsequently layers and store were deleted in Geoserver.The main Geonode screen reports the correct number of layers but the deleted layers are still visible in 'Explore Layers'. Geonode appears to function as normal apart from these 'ghost' layers that cannot be deleted.</div><div><br></div><div><br></div><div>Regards</div><div><br></div><div>Nick</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jun 6, 2016 at 8:02 AM, Simone Dalmasso <span dir="ltr"><<a href="mailto:simone.dalmasso@gmail.com" target="_blank">simone.dalmasso@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Could you tell us more on how you loaded the layers?<div><br></div><div>Usually the best workflow is to manage them from within geonode and not directly on geoserver.</div><div><br></div><div>PS, please always include the mailing list as others may benefit.</div></div><div class="gmail_extra"><br><div class="gmail_quote">2016-06-03 13:11 GMT+02:00 <span dir="ltr"><<a href="mailto:ngtait@gmail.com" target="_blank">ngtait@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Thanks Simo<br>
<br>
some of the error log below when I try to delete one layer<br>
<br>
<br>
[Fri Jun 03 03:47:17.378725 2016] [:error] [pid 26607:tid 140391119156992] Internal Server Error: /admin/layers/layer/<br>
[Fri Jun 03 03:47:17.378755 2016] [:error] [pid 26607:tid 140391119156992] Traceback (most recent call last):<br>
<br>
.........<br>
lines of django errrors<br>
.......<br>
<br>
[Fri Jun 03 03:47:17.378816 2016] [:error] [pid 26607:tid 140391119156992] response = receiver(signal=self, sender=sender, **named)<br>
[Fri Jun 03 03:47:17.378818 2016] [:error] [pid 26607:tid 140391119156992] File "/opt/geonode/geonode/geoserver/signals.py", line 36, in geoserver_pre_delete<br>
[Fri Jun 03 03:47:17.378820 2016] [:error] [pid 26607:tid 140391119156992] cascading_delete(gs_catalog, instance.typename)<br>
[Fri Jun 03 03:47:17.378821 2016] [:error] [pid 26607:tid 140391119156992] File "/opt/geonode/geonode/geoserver/helpers.py", line 230, in cascading_delete<br>
[Fri Jun 03 03:47:17.378823 2016] [:error] [pid 26607:tid 140391119156992] workspace, name = layer_name.split(':')<br>
[Fri Jun 03 03:47:17.378825 2016] [:error] [pid 26607:tid 140391119156992] ValueError: too many values to unpack<br>
[Fri Jun 03 03:47:17.387151 2016] [:error] [pid 26607:tid 140391119156992] [remote <a href="http://5.133.21.84:40545" rel="noreferrer" target="_blank">5.133.21.84:40545</a>] mod_wsgi (pid=26607): Exception occurred processing WSGI script '/var/www/geonode/wsgi/geonode.wsgi'.<br>
<br>
.......<br>
more lines of django errors<br>
......<br>
<br>
<br>
Nick<br>
<br>
<quote author='Simo D'><br>
<div><div>Hi, do you have any stacktrace from /var/logs/apache2/error.log of when you<br>
try to delete one layer from the admin console?<br>
<br>
2016-06-02 22:18 GMT+02:00 Stefan Steiniger <<a href="mailto:sstein@geo.uzh.ch" target="_blank">sstein@geo.uzh.ch</a>>:<br>
<br>
> Perhaps the last option may be to check the Database(s) directly, e.g.<br>
> connecting with PgAdmin.<br>
><br>
> stefan<br>
><br>
><br>
> On 02-06-2016 11:58, Nic Tait wrote:<br>
><br>
><br>
> Hello Geonode users,<br>
><br>
><br>
> I added layers to Geonode from an external service and then deleted them<br>
> in Geoserver but they are still visible as empty layers in 'Explore<br>
> Layers'<br>
> and the 'Admin console' within Geonode<br>
><br>
> I deleted the relevant layers , stores and workspace in Geoserver and<br>
> cannot find any other reference in Geoserver and then ran the management<br>
> command:<br>
><br>
> 'python manage.py updatelayers --remove-deleted'<br>
><br>
> which returned '[delete_failed]' for all the layers<br>
><br>
><br>
> Layers are still visible in the admin console but get 'Internal Server<br>
> Error' when trying to delete them this way.<br>
><br>
> Have restarted Geonode with 'sudo service apache2 restart' as well to see<br>
> if that might fix but no luck<br>
><br>
><br>
> Any ideas on how to proceed ?<br>
><br>
> Regards,<br>
><br>
> Nic<br>
><br>
><br>
> _______________________________________________<br>
> geonode-users mailing<br>
</div></div>> listgeonode-users@lists.osgeo.orghttp://<a href="http://lists.osgeo.org/mailman/listinfo/geonode-users" rel="noreferrer" target="_blank">lists.osgeo.org/mailman/listinfo/geonode-users</a><br>
<span>><br>
><br>
><br>
> _______________________________________________<br>
> geonode-users mailing list<br>
> <a href="mailto:geonode-users@lists.osgeo.org" target="_blank">geonode-users@lists.osgeo.org</a><br>
> <a href="http://lists.osgeo.org/mailman/listinfo/geonode-users" rel="noreferrer" target="_blank">http://lists.osgeo.org/mailman/listinfo/geonode-users</a><br>
><br>
><br>
<br>
<br>
--<br>
Simone<br>
<br>
_______________________________________________<br>
geonode-users mailing list<br>
<a href="mailto:geonode-users@lists.osgeo.org" target="_blank">geonode-users@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/geonode-users" rel="noreferrer" target="_blank">http://lists.osgeo.org/mailman/listinfo/geonode-users</a><br>
<br>
</span></quote><br>
Quoted from:<br>
<a href="http://osgeo-org.1560.x6.nabble.com/Deleted-layers-persist-in-Geonode-tp5269594p5269682.html" rel="noreferrer" target="_blank">http://osgeo-org.1560.x6.nabble.com/Deleted-layers-persist-in-Geonode-tp5269594p5269682.html</a><br>
<br>
<br>
_____________________________________<br>
Sent from <a href="http://osgeo-org.1560.x6.nabble.com" rel="noreferrer" target="_blank">http://osgeo-org.1560.x6.nabble.com</a><br>
<br><span><font color="#888888">
</font></span></blockquote></div><span><font color="#888888"><br><br clear="all"><span class="HOEnZb"><font color="#888888"><div><br></div>-- <br><div data-smartmail="gmail_signature">Simone </div>
</font></span></font></span></div>
</blockquote></div><br></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">Simone </div>
</div>