• rmaxfiel

    (@rmaxfiel)


    Hi! I’m having trouble uploading files through the Media Library. I made sure that the user which was running WordPress had permissions for the uploads folder, but it still doesn’t work. I’m led to understand that this is because I migrated the WP installation to a different address, but I don’t actually know how to move forward solving this problem now that I (maybe) know what it is.

    The error message I’m getting is “Unable to create directory wp-content/uploads/2018/03. Is its parent directory writable by the server?” If I pre-create the directory to see what happens, I still get an error message telling me the file can’t be moved to that directory.

Viewing 13 replies - 1 through 13 (of 13 total)
  • Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    Well, “Is its parent directory writable by the server”?

    What is the OWNERSHIP as well as the permissions? How are you hosting this site?

    Please install the health check plugin to see if all directories are properly writable: https://www.ads-software.com/plugins/health-check/

    Thread Starter rmaxfiel

    (@rmaxfiel)

    It’s hosted on our own server. The directory is owned by me, but the apache user running wordpress is in the group that owns it.

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    The directory MUST be owned by the same user under which PHP runs.

    Thread Starter rmaxfiel

    (@rmaxfiel)

    Thank you! That seems to do it.

    Thread Starter rmaxfiel

    (@rmaxfiel)

    Okay, I then get the error “There has been an error cropping your image.” when I try to upload it as an icon through Customize > Site Identity? 2018/03 and the image are both owned by the apache user.

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    Do you have php-gd installed as as well as ImageMagick? Did you install the health-check plugin?

    Thread Starter rmaxfiel

    (@rmaxfiel)

    I do have ImageMagick but can’t tell if gd is installed. I ran the health-check, what should I be looking for with regard to this problem?

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    Look at “media handling” on the debug tab .

    Thread Starter rmaxfiel

    (@rmaxfiel)

    Huh, well it does say that neither Imagick nor GD is available. If it’s installed but not accessible to the wordpress installation (I checked with “convert -version”) how do I fix that? Or is that not the right thing anyway?

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    YOu need to install ImageMagick and the php-gd libraries from your distribution’s software repo.

    Thread Starter rmaxfiel

    (@rmaxfiel)

    Hi, I know it’s been a while (other projects came up). I tried installing ImageMagick and php-gd on a sandbox server running WordPress (didn’t want to potentially disrupt live projects on the production server), and WordPress can’t seem to find them. When I installed ImageMagick from a .tar it worked fine, but installing ImageMagick and php-gd from the repo, no. Health Check is showing that neither is available. do you know why WordPress might not be finding them?

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    Did you restart PHP and httpd after installing?

    Thread Starter rmaxfiel

    (@rmaxfiel)

    Ah, okay. I restarted httpd, health check is still telling me it doesn’t see ImageMagick or gd but I’m able to crop the image now, hm. Thank you!

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Server unable to upload files to Media Library’ is closed to new replies.