LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 12-20-2014, 06:40 PM   #1
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Rep: Reputation: 30
WordPress issue - could not copy file


I posted this to the WordPress forums a few days ago with no response, so I'm trying here.

I have Fedora 21 running on a local box with a Workstation install (plus a bunch of packages I installed via yum manually) and am now on my local blog update. I am trying to either do a one click upgrade of WordPress or a new plugin install and consistently get the following error:

Code:
Could not copy file. akismet/wrapper.php
The file name is never the same.

For example, here's what I get if I rerun the code:

Could not copy file.
Code:
akismet/_inc/img/logo-full-2x.png
I realize the files are being stored to upgrade/akismet.tmp (or whatever other folder there is). The files are being created to that folder.

I set the permissions to 777 there. Heck, I got so desperate that I set the permissions of the ENTIRE WordPress directory recursively to 777. And I still got that error.

My wp-config file has FTP declared properly. I also changed FS_METHOD per other WordPress forum suggestions. ftpsockets doesn't work at all for me (it won't connect to the ftp), and direct/ftpext both connect but fail in the way I described earlier.

I see no errors anywhere; WP debug was on and no errors were thrown. Nothing is in Apache's error_log etiher.

I have full access to this server. If I have to change some variable in php.ini or whatever, I am open to doing so. php.ini is still running its default values, so there's a lot that could be done there. I just need to figure out what it is that I need to do, because I pored through all similar reports of this issue and it was either a permissions issue or some sort of FS_METHOD issue and neither is the case for me.

Anyone know what this could be or how to find out more info?
 
Old 12-20-2014, 09:15 PM   #2
sag47
Senior Member
 
Registered: Sep 2009
Location: Raleigh, NC
Distribution: Ubuntu, PopOS, Raspbian
Posts: 1,899
Blog Entries: 36

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
Setting perms to 777 recursively is almost never a good solution. Some programs (like OpenSSH) require some files to have specific permissions to operate. It sounds like an selinux issue. See if selinux is enabled.

Code:
getenforce
If it is enabled then your issue likely lies in files being the wrong selinux context or sebools (selinux settings) not being properly set. You can try to temporarily disable selinux and test.

Code:
setenforce 0
If it appears to work after that then you have incorrect selinux settings. For troubleshooting tips and setting up selinux correctly search "selinux" in my blog. You should see the tips on audit2allow with audit.log. Here's a relevant post. http://www.linuxquestions.org/questi...oxypass-34305/

See also man selinux and man httpd_selinux. The man pages are a good resource. Don't forget to re-enable selinux.

Code:
setenforce 1

Last edited by sag47; 12-20-2014 at 09:23 PM.
 
Old 12-20-2014, 10:07 PM   #3
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
SELinux is disabled. I don't use it at all.

And I only did the recursive 777 for testing. It was never intended as a temporary or even permanent solution. In short, it told me that the issue has nothing to do with permissions.

Any other ideas?
 
Old 12-21-2014, 11:19 AM   #4
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
Bump for any other suggestions please
 
Old 12-22-2014, 06:52 AM   #5
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
Still hoping someone can help with this! Thanks.
 
Old 12-22-2014, 07:12 AM   #6
imadsani
Member
 
Registered: Aug 2013
Distribution: CentOS 6.5
Posts: 64

Rep: Reputation: Disabled
Try adding the following to the wp-config.php file
Code:
define('FS_METHOD', 'ftpsockets');
Possible fix from this link: https://wordpress.org/support/topic/...e-upgrade-fail

Note: Backup your site before making any changes

Last edited by imadsani; 12-22-2014 at 07:15 AM.
 
Old 12-22-2014, 07:47 AM   #7
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
Thanks imadsani - I already mentioned in the first post that I tried that without any success. The FTP doesn't connect when I do that. It only works with ftpext/direct, but then it fails in the method described earlier.

I pored through all the WordPress.org posts already; nothing there seems to help.
 
Old 12-22-2014, 07:53 AM   #8
imadsani
Member
 
Registered: Aug 2013
Distribution: CentOS 6.5
Posts: 64

Rep: Reputation: Disabled
Long shot, but you could try another ftp server.

This may sound stupid, but have you checked whether you have diskspace available?

[b]Also, try changing the owner of wordpress recursively to apache:apache. I know I'm asking you to throw everything but the kitchen sink, but something's got to stick.

Last edited by imadsani; 12-22-2014 at 07:55 AM.
 
Old 12-22-2014, 08:27 AM   #9
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
It's a brand new machine with plenty of space. I don't want to try another FTP server. I want to figure out why it's not working. I know other FTP servers are fine...

And I already tried apache:apache. I also tried the FTPuser:apache. The permissions, again, aren't the issue.

I know something has to stick but it's gotta be something I haven't thought of already
 
Old 12-22-2014, 05:11 PM   #10
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
Anything else along the lines of SElinux?
 
Old 12-24-2014, 12:56 PM   #11
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
Bump again for other ideas. Really open to anything I haven't tried already...
 
Old 12-26-2014, 08:17 AM   #12
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
Another post holiday bump since I remain clueless and need to try something else.
 
Old 12-27-2014, 10:33 PM   #13
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
So is anyone reading this and is just clueless, or do you guys have anything for me to try?
 
Old 12-27-2014, 11:17 PM   #14
astrogeek
Moderator
 
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,264
Blog Entries: 24

Rep: Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194
Reading, but clueless, if that makes you less lonesome...
 
Old 12-28-2014, 01:06 AM   #15
punt
Member
 
Registered: Jun 2001
Distribution: Fedora 22
Posts: 371

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by astrogeek View Post
Reading, but clueless, if that makes you less lonesome...
haha it does, thanks
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Wordpress image issue money_shots Linux - Server 4 10-24-2013 08:05 PM
12.04 LTS wordpress issue wulfsburg Ubuntu 0 05-08-2013 03:44 AM
Wordpress issue Pascal Linux - Newbie 1 06-07-2012 09:34 PM
File Copy Issue-Special Characters fortezza Linux - Software 1 11-14-2005 07:16 AM
file copy issue lifetaster Linux - Networking 3 02-21-2004 09:31 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 12:13 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration