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

1.1.2 Help!

#1
I keep on getting these errors when I 'upload' e.g updated

Screen Shot 2012-02-07 at 20.22.46.png


Then when I go to 'install' your on 1.1.0 update -.- what do I do I followed the info. And Hostgator says 'Richard B.:I'm not sure how your script works so I can't tell you what to do from here. ' and this Richard B.:You may need to contact the script developer as it seems that some files my be missing and this' Richard B.:You can try now but 0777 most likley will not work on our server. '

Thank's if you can help
 

shawn

Well-known member
#3
Do they absolutely have to be 777? Seems like they could be 775 or even 755 if the ownership settings were correct (Apache:web, or something similar)
 

shawn

Well-known member
#7
Just keep it at 777 if you don't want errors later ;)
Yeah, but in the case of the OP, his host may not allow 777 permissions.

This is just an upgrade, so it was obviously working before. It sounds like he merged a few directories and changed their ownership by accident. A quick look inside the directories at the XF-created files (the attachments directory, the attachments themselves, etc) should show what user created those files and what group they're a member of. Then you could chown and chmod the data and internal_data directories accordingly.

I'm just thinking through the problem... I know XF calls for those directories to be world-writable, but the reality is the web server is the only user that's going to be working in them. You're really just making sure that user has access, 777 is the easiest way to do that, but not the only way.
 
#8
Right now I am getting this.

Screen Shot 2012-02-07 at 22.03.11.png

Looks like I have to pay once again $70pound to updated it Much more better if there had 'updated button'
 

shawn

Well-known member
#9
Looks like I have to pay once again $70pound to updated it Much more better if there had 'updated button'
I'm with Brogan. You need to make friends with someone who can show you how to upload the files. Whatever you've messed up would probably only take a minute to fix. Last time, you put the files in the wrong directory.

I wouldn't recommend an 'update' button as a feature. Wordpress has had one forever, but it's useless for me. A self-updating website depends on a certain level of access and permission that is rarely the same from one host to another.
 

brendanc

Active member
#10
Just keep it at 777 if you don't want errors later ;)
You should *never* leave a directory at 777 permissions. 777 means it is world writable. At most it should be 775 (still potentially insecure), and 755 is better.

Without going into a "why is leaving something chmodded 777" lecture, it's best to sum it up as being very insecure. It means anyone with an account on the same server can potentially write to that directory. You might be thinking "oh, well, my host has open_basedir on!" but PHP is far from the only scripting language that can write to files :p

For some, it is simply a fact of life that their server is set up (incorrectly) in a way that forces them to use 777.

To that I would say: find a new webhost.
 

Floren

Well-known member
#11
Just keep it at 777 if you don't want errors later ;)
From documentation:
In the set of files and directories you just uploaded, you will see 2 folders: data and internal_data.
These two directories must be set to world writeable (CHMOD 0777) or give the IUSR_ Full Control in Windows.
I set mines to 0755 with a specific user, to avoid any security issues. Having them set to 0777 is like playing Russian roulette, even if you allow an user to access them locally only.

As a side note, my upgrade went fine except that for the first time since I do upgrades on Xenforo I got a 404 page when I visited the /community/ link. Usually I was presented with an upgrade page, not this time. When I went to /community/admin.php page I got the usual upgrade page.
 
#13
Okay, I think it is this '/public_htm/forums' I was uploafing it to.other and I can not go on cp now I think there is an lot of files misson. Also I agree I will need forums help ill try one of my admins
 

Floren

Well-known member
#14
By default, which directories are left as 777 in a default xenforo install ?
Probably quite a few !
A simple shell script will take care of this very easy. I created my own upgrade script because I'm very lazy, heh. All I have to do is upload the Xenforo .zip file and run the script, everything is done automatically.
This is the part that takes care of the permissions:
Code:
dir="/var/www"
prog="${dir}/xenforo"
...
echo "Set all directory permissions to 0755 ..."
find ${prog} -type d -print | xargs chmod 0755
check_step
 
echo "Set all file permissions to 0644 ..."
find ${prog} -type f -print0 | xargs -0 chmod 0644
check_step
 
echo "Set data directories and files to user 'php-fpm' ..."
chown -R php-fpm:root ${prog}/{data,internal_data}
check_step
 

shawn

Well-known member
#15
By default, which directories are left as 777 in a default xenforo install ?
Probably quite a few !
By "default", the only directories that are set 777 are the ones that the webmaster leaves that way. I know when I scp stuff to my site, it shows up as 755 with my username and group... which aren't shared with the web group. So I've got to chown everything before it works.
 

brendanc

Active member
#17
By default, which directories are left as 777 in a default xenforo install ?
Probably quite a few !
None, you have to set them that way.

Your FTP client sets the permissions on upload, and if it doesn't, on unix/linux systems there is the default umask which sets a default permissions (umask is usually 022, so 0755 for directories and 0644 for files). If your FTP client is setting permissions on directories or files to 777, either use a different FTP client or fix that setting.
 
#18
Sorry, I'm confused here. The installation instructions say to make data and internal data to 0777. Fine, can handle that. However, there's nothing later in the installation instructions to say to change them back or to anything different. So should I go and change data and internal data back to 0755? Or does leaving those two at 0777 not cause any harm? If they should be changed back then the installation instructions need to make this clear.
 

shawn

Well-known member
#20
Sorry, I'm confused here. The installation instructions say to make data and internal data to 0777. Fine, can handle that. However, there's nothing later in the installation instructions to say to change them back or to anything different. So should I go and change data and internal data back to 0755? Or does leaving those two at 0777 not cause any harm? If they should be changed back then the installation instructions need to make this clear.
The instructions say to make them 0777 so that you can be sure the web user(s) can write there. Whether or not you leave them that way is up to you. It's somewhat less secure as 0777, but it will always work. If you know which users need to write to those directories, you can chown the directory to that user:group, then chmod it 755 or 775 or whatever octet you'd rather have.