vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   ./images/avatars directory not writable even though... (https://vborg.vbsupport.ru/showthread.php?t=290971)

Snowhog 11-18-2012 06:23 PM

./images/avatars directory not writable even though...
 
...the permissions and ownership on it are correct:

I'm logged onto our server now (SSH) and looking at the directory for avatars: ./images/avatars

The directory has no image files. The index.html file is there as well as the thumbs sub-directory, which is also devoid of any images files (it also has an index.html file).

I don't know what to make of this, as this is the only avatar directory I am aware of, yet all the Administrators avatars are being displayed, as well as their profile pictures.

Something interesting, is that in the AdminCP, when I run Maintenance > General Update Tools > Rebuild Avatar Thumbnails I get the message:
Quote:

The avatar thumbnail directory at /images/avatars/thumbs is not writable. Please contact your host for assistance. Thumbnails cannot be created until this issue is resolved.
Yet the permissions and ownership of the directory, files, sub-directory and files are correct:
Code:

drwxr-xr-x  3 root root  4096 2012-11-18 12:02 avatars
Code:

drwxr-xr-x  3 root root 4096 2012-11-18 12:02 .
drwxr-xr-x 24 root root 4096 2012-03-26 00:03 ..
-rw-r--r--  1 root root    1 2012-08-29 22:10 index.html
drwxr-xr-x  2 root root 4096 2012-01-10 08:35 thumbs

Code:

drwxr-xr-x 2 root root 4096 2012-01-10 08:35 .
drwxr-xr-x 3 root root 4096 2012-11-18 12:02 ..
-rw-r--r-- 1 root root    1 2012-08-29 22:10 index.html

Added:
This from the follow-up post by our member:
Quote:

I started noticing posts without avatars yesterday evening. Also, when trying to access the avatar panel I get the following error message:
Code:

benny_fletch, you do not have permission to access this page. This could be due to one of
several reasons:
Your user account may not have sufficient privileges to access this page. Are you
trying to edit someone else's post, access administrative features or some other
privileged system?
If you are trying to post, the administrator may have disabled your account, or it may
be awaiting activation.

EDIT: I am actually getting a similar error as above when trying to send a PM, accessing Settings -> General Settings, Edit Profile, and Edit Avatar. Also, it is the posting Avatar, I don't think I ever set one that shows in my profile page.
Suggestions? Comments? Thoughts?

Why is the avatars directory not writable, according to vBulletin, even though it is? How do I fix this?


Additionally, our members (non-Administrators) are also saying:

"I also get similar errors when trying to send PMs, access profile settings and general settings"

kh99 11-18-2012 06:47 PM

Edit: Actually Stefan118's probably right. It could just be that the error message you posted is displaying the relative path.

Stefan118 11-18-2012 06:49 PM

The directory is not writable, becouse you do NOT have set the right permissions!

drwxr-xr-x means: chmod 755 permissions on a directory: writeable by owner, readable by all and where files are executable by all.

You need to set them to: drwxrwxrwx (chmod 666) which means that everyone can read, write and execute the files.

Snowhog 11-18-2012 06:52 PM

Quote:

Originally Posted by Stefan118 (Post 2382267)
The directory is not writable, becouse you do NOT have set the right permissions!

drwxr-xr-x means: chmod 755 permissions on a directory: writeable by owner, readable by all and where files are executable by all.

You need to set them to: drwxrwxrwx which means that everyone can read, write and execute the files.

But ALL the directories under images have the exact same permissions, and those were set when the forum was installed. They must be correct, and, this problem didn't present itself until just a few days ago. Prior to that, all was just fine.

Stefan118 11-18-2012 06:55 PM

but still i mis the w from write, so your forum can't write to the directory.
It has been set to writable for a logged in user only (the owner of the site)

kh99 11-18-2012 07:02 PM

Quote:

Originally Posted by Stefan118 (Post 2382269)
but still i mis the w from write, so your forum can't write to the directory.
It has been set to writable for a logged in user only (the owner of the site)

Well, the first set of 3 is the permissions for the owner of the file or directory. So if it was working before then it could be that the owner of the directories was changed, or maybe that the user the php scripts run as was changed.

Snowhog 11-18-2012 07:04 PM

Quote:

Originally Posted by kh99 (Post 2382266)
Edit: Actually Stefan118's probably right. It could just be that the error message you posted is displaying the relative path.

Hmm. Looking at the Avatar File Path note (AdminCP > Avatars > Add New Avatars) it does say:

Avatar File Path
This file path should be readable AND writeable by your web server (usually chmod 0777)

I can/will change the permissions, but how did the directory and sub-directory/contents permission get set to 0755? I didn't do it, and I know that none of the other Administrators did.

Hmm.

kh99 11-18-2012 07:07 PM

They say to set it to 777 because then it will be writable for everyone. But it's possible that it could work with the permissions set to 755 depending on what user owns the file and what user the php scripts run as. I only know the basics of linux admin, but I think it's normal for the web server to run as a different user than the one that owns the files and directories, for security.

Stefan118 11-18-2012 07:08 PM

Why it is changed i don't know.
But the fact is, you need to set it to eighter 666 or 777 (executable is an option)

Snowhog 11-18-2012 07:08 PM

Quote:

Originally Posted by kh99 (Post 2382271)
Well, the first set of 3 is the permissions for the owner of the file or directory. So if it was working before then it could be that the owner of the directories was changed, or maybe that the user the php scripts run as was changed.

Now I'm confused. I don't want to set anything within our forums root directory to globally read/writable (0777) unless that is what it is supposed to be, and I really doubt that that is the case. As I said, I changed nothing, nor our other Administrators.

What are the permissions for the ./images/avatars directory on your forums? What are the permissions on the contents of that directory? In other words, what are the 'default' permissions supposed to be?


All times are GMT. The time now is 01:20 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01174 seconds
  • Memory Usage 1,750KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_code_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete