View Full Version : Trouble After Server Move
May 29th, 2013, 08:08 PM
I just moved my site and Photopost installation to a new server (same domain name). After moving the database I copied over the entire Photopost folder including the data folder with almost 20,000 images, set the permissions, adjusted the server paths and got into the admin pages to set the new Storage Options. All that went well.
After PhotoPost was running I noticed that the Statistics on the main page were not correct. They showed 1.4GB of Disk Space used when the data folder is 8.2GB and about 2800 photos when there are almost 20,000. I ran a few of the DB Admin rebuild tools without any change but I didn't want to run them all.
What is the best way to rescan or rebuild the newly moved installation so it sees all the photos?
May 29th, 2013, 08:57 PM
Rebuilding images is not going to work if they do not exist on this new server. Your new server says you have 2800 images for 1.4gb of space. Your old server has 20000 and 8.2gb
Running rebuild tools is going to delete images that are not found from your database only lowering your number of photos.
Basically the only way to make sure your photos exist on the new server is to make sure you copy over the entire data folder from the old install to the new one and also copy over the photos table from your old install to the new install.
You can then run a rebuild missing thumbs etc if your missing images but like I said it will delete any images it can not find so try making sure your problem is that you think your copying the entire old data folder over and in reality your not. I know in the past some users found when moving servers that they where not grabbing all the old content. That sounds like the most feasible explanation here.
May 31st, 2013, 11:20 AM
Thanks. The strange thing is that my data folder on the new server is in fact 8.4GB. I verified that by doing a du -hs on the data folder from the command line. That is the same as the data folder on the old server. Yet PhotoPost reports only 1,406.8mb of disk space used.
Since all the photos appear to still be in the data folder I'll try just moving the photos table over from the old server. I'll do that this weekend when I have more time.
The good news is that I still have all the data and database on the old server so I can start from scratch on the new server if I have to.
May 31st, 2013, 01:37 PM
Right but are you looking at the data folder stats or the photo stats. ;)
There are two size amounts in the statistics. The first one the image space used is simply the total amount of the filesize field in the photos table of all photos. The second is the data directory size and thats the one that uses good php dirsize command and is the real size of all photos directories under data. If you only have 2400 photos versus 20000 on the other server then all the photos in the photos table do no exist.
Image Space Used 83.2 mb
Total disk space used by the DATA directory 267.05 mb
We are dealing with absolutes here. No code trickery. The totals given by our program are what is there. It is going to say how many photo entries are in the photos table and the sum of the filesizes of all the photos and then lastly the size of the data directory.
If the program is telling you that you have 2400 photos and 1.4gb of space that is what is there.
May 31st, 2013, 08:00 PM
OK, but all I just did was replace the "photos" table with the one from the old server and everything is working normally. The statistics and galleries now show the correct totals and all 16,000 of my active photos seem to be accessible. Whatever happened I'm just glad it was so easy to fix. Thanks.
Now that it's fixed I'm going to upgrade tomorrow from version 6.1 to 8.31. That's a big jump so hopefully it will go smoothly.
May 31st, 2013, 08:41 PM
Yep I figured you where looking at the filesize total not the data directory total ;) If all you did was replace the photos table then the 2 totals that would have changed by that are the total photos number and the image space used total which are all calculated by the photos table entries. The data directory size is the total that says total space by data directory.
vBulletin® v3.8.1, Copyright ©2000-2014, Jelsoft Enterprises Ltd.