g2 data.backup

debsparrow

Joined: 2008-03-17
Posts: 8
Posted: Fri, 2012-12-21 01:41

Please fill out the following form and take a look at the linked pages. The more information you supply, the better we can help you. Please post issues about errors using Gallery 2 in the Troubleshooting Forum. Remove this FAQ information from your post before submitting.

Our attempt to post this query came up with a problem and we were asked to submit it via email, including this link, http://gallery.menalto.com/wl/a42e_187806. We have now received an email telling us the query has been whitelisted and to try again.

last Run Details:

Gallery URL = http://richardarmitagecentral.co.uk/main.php
Gallery version = 2.3 core 1.3.0
API = Core 7.54, Module 3.9, Theme 2.6, Embed 1.5
PHP version = 5.2.15 cgi-fcgi
Webserver = Apache mod_fcgid/2.3.6 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635
Database = mysqlt 5.1.52, lock.system=flock
Toolkits = ArchiveUpload, Getid3, LinkItemToolkit, ImageMagick, Thumbnail, Exif, Gd
Acceleration = none/0, none/0
Operating system = Linux gator481.hostgator.com (http://gator481.hostgator.com) 2.6.34.6 #107 SMP Tue Mar 1 18:57:23 CST 2011 i686
Default theme = carbon
gettext = enabled
Locale = en_US
Browser = Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.15) Gecko/20110303 Firefox/3.6.15
Rows in GalleryAccessMap table = 25
Rows in GalleryAccessSubscriberMap table = 67970
Rows in GalleryUser table = 2
Rows in GalleryItem table = 67679
Rows in GalleryAlbumItem table = 456
Rows in GalleryCacheMap table = 0

Our host is Hostgator. We are halfway through our contract so cannot change. We are trying to control our inodes and have a very, very large and growing gallery. The g2 data.backup directory contains just under 55,000 files. Can you advise if it is safe to delete any or all of the contents of this directory? And, if any of its contents are safe to delete, which ones?

Any assistance is appreciated.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Fri, 2012-12-21 02:17

the g2data/backup contains 55,000 files? So you've backed up your DB 55,000 times?
You only need the latest.

Otherwise if it is the g2data/cache directory:
FAQ: How can I clear cached data?

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
debsparrow

Joined: 2008-03-17
Posts: 8
Posted: Fri, 2012-12-21 02:34

Is that what that means? That each time we do a backup, that's recorded in the g2data/backup by creating a file/inode? So, all those files within it are safe to delete? They have nothing to do with the functioning of the gallery? Please tell me that's true because it will be a lovely early Christmas present. Just so we're clear, the g2data/backup directory shows:

-albums
-cache
--derivative
--entity
--module
--theme
-locale
-locks
-plugins_data
-smarty
-tmp

And, so far as I know we've probably, consciously, backed the gallery up twice. Once when we were having problems when it was first set up about 4 years ago and, most recently, when we moved it to another part of the server. Otherwise, we've only been clearing the cache either through a cron job that's set up to clear hourly or through the gallery's maintenance page.

Thanks.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Fri, 2012-12-21 03:58

during install you are allowed to name your storage directory anything you want the default is g2data
if you named yours g2data/backup then that is where gallery stores all items

the directory structure for g2data by default is
g2data/
-albums
-backup
-cache
--derivative
--entity
--module
--theme
-locale
-locks
-plugins_data
-smarty
-tmp

these are all neccessary directories

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
debsparrow

Joined: 2008-03-17
Posts: 8
Posted: Fri, 2012-12-21 04:12

Thanks. I'm going to go back to Hostgator and ask them to explain a few things. We have a g2data directory containing 189563 files and a g2data.backup directory with 54093 files. We also seem to have directories named variations of g2data and g2data/backup. Thanks for your help. Once I've sorted out what's where I might get back to you to make sure of what we're deleting. Part of our trouble is, of course, we're just users and not familiar with how directories are named and whether there's a difference between g2data/backup and g2data.backup.

Again, thanks for your help.

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Fri, 2012-12-21 04:53

you can find which g2data directory your gallery is using by checking gallery2/config.php
all others can be deleted unless they belong to other gallery installations.
Hostgator is generally known as one of the good hosts.

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
debsparrow

Joined: 2008-03-17
Posts: 8
Posted: Fri, 2012-12-21 05:18

Hi. Thanks. We'll do that.

And, yep. They've always been really helpful.

Although, that said, it would have been really helpful if, in their advertising/sales they mention what an inode is and what their limits are. We were looking for a site that would host a large, growing gallery and had never heard of inodes. All we knew about was bandwidth. Now, we're looking over our collective shoulder every time we have pics to upload. They have allowed us latitude, which is good, though.

Thanks again for your help. And, again, once I've got a proper handle on what we're dealing with I'll probably back just to make sure we're not about to delete something vital.

 
Dayo

Joined: 2005-11-04
Posts: 1642
Posted: Fri, 2012-12-21 10:48

Most hosts have a file manager that lets you download or edit files. Use Hostgator's file manager to navigate to your G2 folder. Once there, you will find a file called config.php. Open the file and look for $gallery->setConfig('data.gallery.base. The last folder in the path defined there is the g2data folder your gallery installation is using. The other can be deleted.

In your case, I am sure both g2data/backup and g2data.backup can be safely deleted. However, the path in the config.php file will give you the definitive one to keep.

On inodes, this is standard amongst all hosts and would have been mentioned in the fine print of your agreement. Think about it, the hosts would go under if, the unlimited this and that they offer were really totally unlimited. This is not unethical btw, you can have unlimited this and that as long as you don't cross a limit on something else mentioned in the fine print.

If you do regular backups, you should move these off the webspace if you wish to minimise hosting costs. The alternative is to upgrade your hosting plan if you want to have convenience instead. That is, your site is outgrowing your hosting plan and you have to take some action on this. Deleting the unneeded folders will buy you some time.

--
dakanji.com

 
debsparrow

Joined: 2008-03-17
Posts: 8
Posted: Sat, 2012-12-29 04:02

Hi. Back again. First, thanks Dayo, for the last bit of info. The inode information that's included in a host's fine print is useful. The trouble is, when you don't know the question to ask, you can't really ask the question. Never having heard the word, 'inode' and only aware of things like bandwidth, we didn't think of inodes. Not arguing with the need for limits. Just now having to deal with them. And, yes. I appreciate we're just buying time. Unfortunately, I think the only upgrades available are out of our budget - way out of it.

This is just, I think, a quick question. What's led to this recent issue is that, for various reasons, several parts of the gallery were duplicated. In fact, the entire gallery was duplicated as well as, separately, several of its directories. I've cleared the data however, there's still a duplicated cache directory. At least I think it's duplicated since it was part of the duplicated gallery directory (they're within the g2data.backup directory) Is there some way, before deleting it, I can be sure it's not operating? Should I be looking to make sure it's not included with the $gallery->setConfig('data.gallery.base ? To ensure the data I was deleting was safe to delete I deleted a couple of jpegs and checked they were still in the gallery. Is there a way of doing something similar with what appears to be a duplicated cache?

Thanks.

 
Dayo

Joined: 2005-11-04
Posts: 1642
Posted: Sat, 2012-12-29 07:04

Hi,

As said, the g2data folder in use is the one defined in config.php.
if you do not have $gallery->setConfig('data.gallery.base', '/some/path/to/g2data.backup/'); as the defined storage folder in your active config.php file, just delete the whole g2data.backup directory.

--
dakanji.com

 
debsparrow

Joined: 2008-03-17
Posts: 8
Posted: Sat, 2012-12-29 07:14

Hi Dayo. Thanks. Since the g2data.directory is non-active, I'd expect that the derivative directory would also be non-active. Just needed confirmation.