Upgraded from v2.42 - 3.03: Images vanish, database damaged
Well, like the user who reported this problem: http://www.photopost.com/forum/class...2-5-3-2-a.html, I tried to upgrade from 2.42 to 3.03 over the weekend. In fact, when it ended up broken and screwed up the first time, I restored from my backup, double-checked everything and tried again. But in the end the results were the same.
Here is a detailed list (with examples) of the problems I found after the upgrade to a classifieds system that was running fine before:
Images associated with each classified through the bigimage columns in the product table (i.e. the ad image and thumbnail and any additional images but NOT those that were embedded in the BODY of the ad using UBB Code) had all disappeared after the upgrade. That means I get no image thumbnails anywhere in the classifieds. I have attached an example of what my category page now looks like for categoory 31.
I note here that during this upgrade the script tries to move ad-associated images from the classifieds/data/ad# directories into "Thumb" and "Large sub-directories INSIDE the /data/ad# directories; but it does not do the same things with the category level data directories. It's the names of images in the category-level directories that seem to be damaged here. The script seems to be messing up image names. Here's an example of the way the image names in the category 31 data directory looks after the upgrade:
mysql> select id, bigimage from ppcl_products where id = 41;
In addition to the above issues, I had the same experience as the poster in the other thread I referenced. My config-int.php and config-inc.php files did not get updated even though both files were double-checked before the upgrade to ensure their permissions were 777.
Also, related to the problem the other user reported with getting php errors because things weren't where the program expected them to be, I discovered that the paths to where things were supposed to be in the options section and the config section in the classfieds admin pages had all been wiped out. Once I repaired those paths and set them right again, my template (which had also vanished) and my page headers and footers all-reappeared.
I hope this helps you figure out what went wrong. If I can answer any further questions, please don't hesitate to call me directly at 575-838-0784. In the meantime, I'm going to wait a couple of hours before I use my backup to roll my classifieds back and reinstall the older version.
Thanks! Let me know if I can help, please!
P.S. For some reason, the attachment didn't take so I'm adding it here instead.
The issue as I see it is that the 2.4 upgrade was ran more than once. You can restore the products table from your mysql backup and then run your upgrades from 2,4 forward only once.
When I didn't hear from anyone within a few hours yesterday, I decided to go back and carefully restore and retest the tables, files and programs for both Photopost and the Classifieds at their earlier release levels to confirm that the roll back had worked. I made a full account-save backup before installing PhotoPost upgrades on Saturday but neglected to make one afterwards. This was clearly my 1st and biggest mistake. I knew I needed backups but failed to make one after installing the Photopost upgrades. So yesterday I decided to roll back both upgrades and start completely over.
After I originally had trouble with the Classifieds upgrade on Saturday and decided to roll back and try again, I opted not to go "all the way back". In hindsite, that was obviously my 4th mistake. Instead, I tried to do a "selective restore" by only rolling back the Classifieds. Trouble was really brewing now. I was taking shortcuts. (Can you tell I was tired and judgment-impaired?)
This time I made a specific point of dropping all tables for both apps and I only reloaded the tables that existed before the upgrade. On my first rerun attempt on Saturday, I had overlooked the possibility that the Classifeids upgrade could have created new tables of its own and thus failed to drop any new tables that were created during the first upgrade before I tried the second time.
Once the two-product rollback was complete and I'd done enough testing to confirm both apps worked again, I then ran the Photopost upgrade and stopped and carefully tested it after the install. When it had been tested and looked good, I made the missed (after Photopost) backup that I failed to make on Saturday and installed the Classifieds upgrade again.
This time the upgrade was successful and things looked almost normal afterwards. Clearly I should have made that extra backup; because my attempt to do a partial roll back had only made things worse! :o
The bottom line is when I ran the classifieds upgrade this time it went better and I actually could see my images when it was done. Hurray! I was, however still missing my template though (as I was after the first upgrade) and the vbportal sidebar was missing too.
When I looked around afterwards, I realized one of these upgrades had added a new config table named config-intc.php that I had deliberately NOT uploaded in the prior 3 upgrades because I thought it duplicated one of the existing config tables and didn't want to overwrite them. This was unquestionably my 2nd mistake. Only after this third "almost worked" upgrade did I finally realize this file should have been uploaded too and that it needed to be setup correctly and have 777 permissions like the other config tables before the upgrade began.
When I added that file to the completed upgrade and set its paths and urls the way they should have been set BEFORE the upgrade, my template and all the other elements of VB and vbportal integration that were all missing after the FIRST upgrade all magically reappeared again.
It was only AFTER I had done all of this that I took a minute to peek at email again and found your reply, Chuck. You were right. I screwed up in several ways. You may now feel free to kick my butt in public if you wish. :o
So, what did I learn from this experience?
First, Photopost Classifieds provides no documentation or written procedure for how to install their upgrades. The user is on his own when it comes to figuring out the 'right way' to upgrade. No mention is made of new tables that have been added or of new config files that have been created and should be properly setup before running the upgrade. Also, no mention is made of required permissions that should be set for new files added during upgrades. The user must pay careful attention. This is not a 'late night exercise' or a place for those who are tired and not cross-checking every detail. The goblins 'll git-cha if ya dont watch out! :p (Mea Culpa!)
Second, Classifieds' upgrade scripts tend to display a bunch of mostly-meaningless mysql messages on the screen as they run whereas Vbulletin's, vbportal's and photopost's scripts almost never display such messages. :confused: If all you see is Successful completions at the ends of these messages, there's no need to worry. If you see what are clearly errors, DO worry and start asking yourself what you did wrong. But don't panic just because you suddenly see a bunch of scary messages flash by on your screen. :eek: Stop... Take a deep breath.... Clean out your shorts... and then carefully read those messages. They might not be as scary as they look and even if they are, they'll help keep you awake and doubting your sanity which is always a good thing when you're installing a bunch of upgrades anyway. :rolleyes: Let the upgrader beware and very careful!!
Third, when upgrading one can NEVER make enough backups. Duuuh! :o Don't be stupid. Even with products coming from the same vendor make an extra backup between the product upgrades. No two programmers think alike when it comes to such things. I don't CARE if you've already made 37 full backups. Make the 38th, damn it! ;)
Thanks, Chuck. I appreciate your help, your patience, and your support.
Best Professional Regards,
The upgrade worked almost perfectly on the 4th try! :D
Thanks again, Chuck! ;)
Yes things are never as bad as one thinks backups are always essential. We do have upgrade documentation which is in the documentation folder of the download by the way. Essentially its pretty much the same as any other program upload the files and run an upgrade script.
|All times are GMT -5. The time now is 10:41 PM.|
Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0