[SOLVED] Root folder showing "Login to your account" and no root album, even after I have logged in !

KGF

Joined: 2013-01-16
Posts: 4
Posted: Wed, 2013-01-16 18:45

This server has been working for a long time, but now it is not. The root album is not showing up, showing 'Login to your account", but I am logged in. The URL shown after login is

/main.php?g2_view=core.UserAdmin&g2_subView=core.UserLogin&g2_return=main.php&g2_returnName=album

I can go directly from this page to site admin. Also, I can go to almost any album if I know the item id (main.php?g2_itemId=39335) This album should be displayed on the root album. Mysqlchk does not show any errors. Mdstat shows no errors, and there is plenty of free space.

Could this be a permissions issue ? I am a site admin, I can see the admin pages, such as this system info. Can you even change the permissions of the root album ?
I looked in the mySQL database, ChildEntity table, and 39335 does seem to point back at g_id 7, which I believe is the root album. I get the same response if I manually type "example.com/main.php?g2_itemId=7"
I've deleted the user sessions, database cache and optimized the database.

Your help is greatly appreciated !
Thanks
Kevin


Gallery version = 2.1.2 core 1.1.0.2
PHP version = 5.2.0 apache2handler
Webserver = Apache/2.2.3 (Linux/SUSE)
Database = mysqlt 5.0.26, lock.system=flock
Toolkits = ArchiveUpload, Dcraw, Getid3, NetPBM, Thumbnail
Acceleration = full/3600, full/3600
Operating system = Linux photos 2.6.18.2-34-default #1 SMP Mon Nov 27 11:46:27 UTC 2006 i686
Default theme = matrix
Locale = en_US
Browser = Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20100101 Firefox/15.0.1

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Wed, 2013-01-16 19:20

the root album is main.php?g2_itemId=7

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
KGF

Joined: 2013-01-16
Posts: 4
Posted: Wed, 2013-01-16 19:42

Thanks for your response !
Having searched for an answer, I am not surprised that you were the one to respond. You are quite active. Thanks !

Yes, I found that in the documentation regarding the database scheme that the root album is g_id=7. [url]http://codex.gallery2.org/Database_Schema_(G2)[/url]
But why doesn't it load when I log in ? It also doesn't load when others log in, but perhaps someone sees it. Don't know...
When I put it in manually, I am redirected to a page that shows

Login to your account
Welcome, Photo Administrator!

with this URL
/main.php?g2_view=core.UserAdmin&g2_subView=core.UserLogin&g2_return=main.php&g2_returnName=album

The "Login" line is with a grey background, which I think is where the album info should be ?

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Wed, 2013-01-16 19:49

can you edit the permissions for that album? main.php?g2_view=core.ItemAdmin&g2_subView=core.ItemPermissions&g2_itemId=7

it seems maybe the view rights have been removed.

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
KGF

Joined: 2013-01-16
Posts: 4
Posted: Thu, 2013-01-17 03:11

No, I can't. but the error is very interesting !
In reading the schema doc, I saw where 6 is a special admin user, and 7 is the special root album. Interesting that user 6 doesn't't have permission. Is this something an admin user other than 6 could have done ?
And of course, how do I fix it? I'm thinking it is something I'll need to do at the MySQL console ?
Thanks for your help.

Security Violation

The action you attempted is not permitted.

Back to the Gallery
Error Detail -
Error (ERROR_PERMISSION_DENIED) : user id: 6 doesn't have permission: core.edit for item id: 7

in modules/core/classes/helpers/GalleryUserHelper_simple.class at line 60 (GalleryCoreApi::error)
in modules/core/classes/GalleryCoreApi.class at line 495 (GalleryUserHelper_simple::assertHasItemPermission)
in modules/core/ItemPermissions.inc at line 399 (GalleryCoreApi::assertHasItemPermission)
in modules/core/ItemAdmin.inc at line 147 (ItemPermissionsView::loadTemplate)
in modules/core/classes/GalleryView.class at line 317 (ItemAdminView::loadTemplate)
in main.php at line 386 (GalleryView::doLoadTemplate)
in main.php at line 87
in main.php at line 80
in /srv/www/htdocs/cvs/main.php at line 3

System Information
Gallery version 2.1.2
PHP version 5.2.0 apache2handler
Webserver Apache/2.2.3 (Linux/SUSE)
Database mysqlt 5.0.26
Toolkits NetPBM
Operating system Linux photos 2.6.18.2-34-default #1 SMP Mon Nov 27 11:46:27 UTC 2006 i686
Browser Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20100101 Firefox/15.0.1

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Thu, 2013-01-17 03:20

1st make sure the owner of item 7 is 6 in g2_Item

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
KGF

Joined: 2013-01-16
Posts: 4
Posted: Tue, 2013-03-12 21:31

I ended up using mysql to set all albums to one known good access list, then edited through the UI from there. This solved the problem for me.