Error missing object

pietromaestro

Joined: 2014-01-08
Posts: 9
Posted: Tue, 2014-01-14 07:30

Hello,

I have a G2 installation that used to work very well. I haven't been on the site for a while and today, when I try to go to the gallery's URL, I get the following message:

Quote:
Error

Item not found.

Back to the Gallery
Error Detail -
Error (ERROR_MISSING_OBJECT)

in modules/core/classes/GalleryView.class at line 368 (GalleryCoreApi::error)
in modules/core/ShowItem.inc at line 106 (GalleryView::getItem)
in modules/core/ShowItem.inc at line 61 (ShowItemView::getItem)
in modules/core/classes/GalleryView.class at line 293 (ShowItemView::loadTemplate)
in main.php at line 465 (GalleryView::doLoadTemplate)
in main.php at line 104
in main.php at line 88

I can still access admin with the URL: main.php?g2_view=core.SiteAdmin
The gallery is in debug mode (buffered)
It is installed with Joomla 2.5.17 and JFusion 1.8.4-009 Rev ( c2e3d2b1... ). I cannot access the gallery whether JFusion is active or not.

Thanks in advance for your help.

URL de Gallery = http://www.toutlaville.com/mediatheque/main.php
Gallery version = 2.3.1 noyau 1.3.0.1
API = Noyau 7.54, Module 3.9, Thème 2.6, Intégré 1.5
PHP version = 5.3.16 cgi-fcgi
Serveur Web = Apache
Base de données = mysql 5.1.66-0+squeeze1-log, lock.system=flock
Boîtes à outils = ArchiveUpload, Exif, Getid3, ImageMagick, LinkItemToolkit, Thumbnail, Gd, SquareThumb
Accélération = none/0, full/900
Système d'exploitation = Linux web276.media.ha.ovh.net 3.10.11-mutu-grs-ipv6-64 #1 SMP Tue Sep 24 18:07:54 CEST 2013 x86_64
Thème par défaut = matrix
gettext = activé
Langage = fr_FR
Navigateur Web = Mozilla/5.0 (Windows NT 6.3; WOW64; rv:26.0) Gecko/20100101 Firefox/26.0
Lignes dans la table GalleryAccessMap = 27
Lignes dans la table GalleryAccessSubscriberMap = 0
Lignes dans la table GalleryUser = 209
Lignes dans la table GalleryItem = 5024
Lignes dans la table GalleryAlbumItem = 128
Lignes dans la table GalleryCacheMap = 0

PHPInfo Link : http://www.toutlaville.com/phpinfo.php

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Tue, 2014-01-14 13:38

Apparently the error is not visible to anonymous users.
See if you can tell which itemId is missing from the debug output.
try clearing the caches http://www.toutlaville.com/mediatheque/lib/support/

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
pietromaestro

Joined: 2014-01-08
Posts: 9
Posted: Tue, 2014-01-14 14:12

Hi,

Thanks for your answer.

I just cleared the cache as advised.

As an anonymous user, I get the following message:

Quote:
Security Violation
The action you attempted is not permitted.

I can login and use administration back office using the url: http://www.toutlaville.com/mediatheque/main.php?g2_view=core.SiteAdmin

How can I see which itemId is missing from the debug output? I searched for "itemId" and "missing", but I did not find anything.
I've attached the debug output I get when I log in to the gallery.

Thanks!

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Tue, 2014-01-14 14:35

see what the integrity module reports http://codex.galleryproject.org/Gallery2:Modules:integrity

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
pietromaestro

Joined: 2014-01-08
Posts: 9
Posted: Tue, 2014-01-14 15:14

Attached the integrity module report.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Tue, 2014-01-14 15:57

You can try my missing object fix script.

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
pietromaestro

Joined: 2014-01-08
Posts: 9
Posted: Tue, 2014-01-14 16:08

Tried it, get the error in attached file

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Tue, 2014-01-14 16:55

do you have another admin user you could try logging in as?

Or if you can create one in admin and give it a try.

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
pietromaestro

Joined: 2014-01-08
Posts: 9
Posted: Tue, 2014-01-14 17:35

What is the purpose? I can login as admin already.

 
pietromaestro

Joined: 2014-01-08
Posts: 9
Posted: Tue, 2014-01-14 18:02

I logged in with another admin account, but same result when running missingObjectFix.php:

Quote:
Select Album:Error loading album tree for selector, here is the error message: Error (ERROR_PERMISSION_DENIED) : user id: 6 doesn't have permission: core.view for item id: 7

in modules/core/classes/helpers/GalleryUserHelper_simple.class at line 47 (GalleryCoreApi::error)
in modules/core/classes/GalleryCoreApi.class at line 550 (GalleryUserHelper_simple::assertHasItemPermission)
in modules/core/classes/helpers/GalleryItemHelper_simple.class at line 376 (GalleryCoreApi::assertHasItemPermission)
in modules/core/classes/GalleryCoreApi.class at line 1750 (GalleryItemHelper_simple::fetchAlbumTree)
in missingObjectFix.php at line 347 (GalleryCoreApi::fetchAlbumTree)
in missingObjectFix.php at line 236
in missingObjectFix.php at line 31

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Tue, 2014-01-14 19:34
Quote:
user id: 6 doesn't have permission: core.view for item id: 7

user id:6 is the root admin account, and this admin user does not have core.view permissions for id:7 which is the root album.
That is a problem.

try adding core.view permissions for admin:
http://www.toutlaville.com/mediatheque/main.php?g2_view=core.ItemAdmin&g2_subView=core.ItemPermissions&g2_itemId=7

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
pietromaestro

Joined: 2014-01-08
Posts: 9
Posted: Mon, 2014-01-20 09:06

Unfortunately, I can't change permissions, I only can access administration panel.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Mon, 2014-01-20 13:23

do you have access to phpMyAdmin(or similar) for your gallery's database?

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
pietromaestro

Joined: 2014-01-08
Posts: 9
Posted: Mon, 2014-01-20 13:38

Yes, full access to PHPMyAdmin.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Mon, 2014-01-20 13:50
  • in table g2_AccessSubscriberMap sort by g_itemId and note the g_accessListId for g_itemId 7
  • in table g2_AccessMap find that g_accessListId noted from above step
  • for g_userOrGroupId 3(admin group) the g_permission should be 2147483647(core.all all access)

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
pietromaestro

Joined: 2014-01-08
Posts: 9
Posted: Mon, 2014-01-20 14:22

It appears that every table of my database had been duplicated with identical names without capital letters, and that table g2_AccessSubscriberMap was empty! I copied the content of table g2_accesssubscribermap in table g2_AccessSubscriberMap and everything is back to normal and works perfectly!
Any idea about what can have happened?
Anyway, many thanks for your very reactive and efficient help.
Pierre

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Mon, 2014-01-20 14:33

if you moved from windows to *nix - *nix is case sensitive whereas windows is not.
there was a script to help fix that http://codex.galleryproject.org/Downloads:FixLowercaseFilenames

-s
________________________________
All New jQuery Minislideshow for G2/G3