1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Upgrade problem: wants to start fresh install

Discussion in 'Installation, Upgrade, and Import Support' started by dutchbb, Feb 5, 2011.

  1. dutchbb

    dutchbb Well-Known Member

    Just uploaded the upgrade package to the server, opened it, and dragged the new files to the old ones. This is not how I usually do it, but I thought it would have been quicker than uploading the individual files. When I go to the forums it wants to start a fresh install. What did I do wrong?
     
  2. Mike

    Mike XenForo Developer Staff Member

    It sounds like whatever approach you took "synced" the server, as it likely removed config.php (and possibly data and internal_data). You will need to either recreate config.php if that is the only thing missing, or really, if data and internal_data are missing, you'll need to restore from a backup otherwise you're going to lose attachments and avatars.

    Here's the minimal library/config.php:
    Code:
    <?php
    
    $config['db']['host'] = 'localhost';
    $config['db']['port'] = '3306';
    $config['db']['username'] = 'x';
    $config['db']['password'] = 'y';
    $config['db']['dbname'] = 'z';
    Change as needed.
     
  3. dutchbb

    dutchbb Well-Known Member

    Thanks. Luckily it's a test forum, but this is really strange behavior of the server, it removed all the old files instead of overwriting them. Not sure why it did that.

    Edit: avatars are not removed.
     
  4. dutchbb

    dutchbb Well-Known Member

    Hm I can't upgrade, even with the config file edited with the old info it keeps redirecting to a fresh installation?
     
  5. Brogan

    Brogan XenForo Moderator Staff Member

    Is your install-lock.php file in place in /internal_data ?
     
  6. dutchbb

    dutchbb Well-Known Member

    The installer asked me to remove that file if I wanted to re-install, so I removed it, but then it redirected to a fresh install instead of an upgrade.
     
  7. dutchbb

    dutchbb Well-Known Member

    Is there some kind of option I need to change to make it upgrade instead of install?
     
  8. Brogan

    Brogan XenForo Moderator Staff Member

    All you need are config.php and install-lock.php.
     
  9. dutchbb

    dutchbb Well-Known Member

    Well apparently something went wrong and now I'm in limbo :(
     
  10. Brogan

    Brogan XenForo Moderator Staff Member

    I would recommend uploading the upgrade package once again.

    Then ensure you have the correct details in /library/config.php
    And replace the /internal_data/install-lock.php

    That should allow you to upgrade.
     
  11. dutchbb

    dutchbb Well-Known Member

    I've already tried that, it keeps directing me to a fresh install... But I'll try it one more time.
     
  12. dutchbb

    dutchbb Well-Known Member

    Again it redirects to new install...

    fresh_install.png


    I've made some template changes I don't want to lose so I rather not do a fresh install even though it's a test forum.
     
  13. Mike

    Mike XenForo Developer Staff Member

    Provided you're going to <url>/install/, then one of those files must not exist - I suspect it's internal_data/install-lock.php.
     
  14. dutchbb

    dutchbb Well-Known Member

    Yes I removed install-lock.php because it said something like 'already installed, remove install_lock.php to re-install'. I thought that way I could upgrade. Oh well I have a backup so I'll just put it back and try again :)
     
  15. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    That is wrong. You can't upgrade unless the internal_data/install-lock.php file exists.

    You can replace the file to fix this. Just create a new file called install-lock.php inside of the internal_data directory. It only checks for the existence of the file. The file doesn't need to contain anything.

    Once the internal_data/install-lock.php file is in place then load the /install URL again. It should direct you to the upgrade system.
     
    Infopro and yoghurtfarmer like this.
  16. dutchbb

    dutchbb Well-Known Member

    I removed it because when it was there I could not upgrade either and the installer told me to remove it if I wanted to re-install. Anyway, I just re-uploaded everything and created the install-lock.php file again and now the upgrade worked.

    Thanks for the help.
     
  17. Floris

    Floris Guest

    Just go to /install/
    and at the end of the url replace ?install with ?upgrade


    make sure you're not running in debug mode.
     
  18. Floris

    Floris Guest

    If you go to install/ and it says you've already got installed, but to RE-install to remove that file, obviously it is not a step you should follow, as your intentions were to upgrade.
     
  19. dutchbb

    dutchbb Well-Known Member

    Well, because I was in upgrade mode I thought they meant 'upgrade' when they mentioned 're-install'... Why would it ask to install while I'm upgrading.

    The upgrade is done now, this can be locked.
     
  20. sayUncle

    sayUncle New Member

    One possible reason for upgrade trying to install new is if the upgrade files were uploaded into the root folder of the domain when the forum is in a subfolder. This is the mistake I made and it tried to install as new asking for mysql login information etc. When I finally figured out my mistake and installed the files into the correct /forum folder of the domain everything went smoothly. Even though this error is by the user, the upgrade should not try to proceed when it is evident the upgrade files were not uploaded into the correct folder. The user should be prompted to "please check that the upgrade files were uploaded to the correct folder" rather than asking for mysql information and trying to install a new install by wiping the old db out after asking for the login and username of the mysql db. When it is supposed to be UPGRADE!!
     

Share This Page