Upgrading XenForo 2

Asphyxia

Owner
Administrator
Apr 25, 2015
1,845
2
2,199
327
This is a very simple way to upgrade your XenForo forum:
  1. Sign in to your XenForo account and download the next XenForo version as shown from your forum admin.php page.
    2027
  2. You should have WinSCP downloaded and installed. Connect to your server, and go into /var/www
  3. Drag and drop your xenforo_2.X.X_XXX_upgrade.zip file into the /var/www directory (just in front of /var/www/html).
  4. Using Putty, connect to your server (download/install if not already) via SSH.
  5. cd /var/www, now unzip with unzip xenfor, press the tab key to autocomplete, you should see the .zip file, and lastly point to a temp directory.
    2028
  6. Now we should have /var/www/html/temp/upload, we want all of these files inside of /var/www/html/ - so how can we?
  7. Simply using cp, cp -Rf /var/www/temp/upload/* /var/www/html
  8. Now time to clean our mess!
Cleaning up is simple, just delete the .zip we had created.
Code:
rm /var/www/xen*zip
rm -rf /var/www/temp
find /var/www/html -type d -exec chmod 755 {} \;
find /var/www/html -type f -exec chmod 644 {} \;

The bottom 2 lines actually set 755 to directories and 644 to files.

Keep in mind that https://xenforo.com/xf1-docs/manual/install-upgrade/#installing-xenforo states
In Linux, these should be "chmod 0777". You can generally do this via your FTP client by making sure that the directory has read, write, and execute permissions for user, group and world.

If anyone has any questions/ideas, please share.
 

Asphyxia

Owner
Administrator
Apr 25, 2015
1,845
2
2,199
327
Well this was damn annoying - I had to do this:
Code:
root@XX:/var/www/html/install# find /var/www/html -type d -exec chmod 777 {} \;
root@XX:/var/www/html/install# find /var/www/html -type f -exec chmod 777 {} \;

To upgrade, now I can set perms back I guess.
 

Asphyxia

Owner
Administrator
Apr 25, 2015
1,845
2
2,199
327
Also if your one-click is giving you some bullshit (you may have to replace www-data with your web server user):
Code:
sudo chown www-data:www-data /var/www -R
find /var/www/html -type d -exec chmod 777 {} \;
find /var/www/html -type f -exec chmod 777 {} \;


Run your one-click install, then:
Code:
find /var/www/html -type d -exec chmod 755 {} \;
find /var/www/html -type f -exec chmod 644 {} \;

And life is back to being great, I think!?
 
Top