Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to upload files #616

Closed
BrodieReuter opened this issue Feb 13, 2015 · 14 comments
Closed

Unable to upload files #616

BrodieReuter opened this issue Feb 13, 2015 · 14 comments

Comments

@BrodieReuter
Copy link

Today around noon central time we started receiving the below error when trying to upload files (images, text, etc.) on any one of our 3 BOA servers (2 production and 1 dev) running BOA 2.3.8. We have ruled out any updates, modules or platforms, nothing was done to all 3 servers at the same time today. This error is also shown in popup windows when the upload fails.

"PHP Warning: File upload error - unable to create a temporary file in Unknown on line 0"

@pricejn2
Copy link
Contributor

I had the same thing happen. For me, permissions on /data/disk/o1/.tmp changed.

I believe they should be 775 o1:www-data, but not on a computer to verify.

@mrconnerton
Copy link

I had the same issue with the same fix.

@BrodieReuter
Copy link
Author

Awesome thanks that works, but what caused this change and will it happen again?

@pricejn2
Copy link
Contributor

From what I can see, it should only be a one time issue once /data/disk/o1/.tmp/.ctrl.240stableA.txt exists.

See the differences between https://github.com/omega8cc/boa/blob/BOA-2.3.8/aegir/tools/system/manage_ltd_users.sh#L934 (2.3.8) and https://github.com/omega8cc/boa/blob/master/aegir/tools/system/manage_ltd_users.sh#L1388 (master)

@omega8cc
Copy link
Owner

Ops.. sorry about that.

@lefterav
Copy link

Hi, I had the same problem and the suggested correction fixed it. Unfortunately I have been trying to debug for 3-4 hours, googling endlessly with no luck. I should have looked in this issue queue earlier.

@pricejn2
Copy link
Contributor

This is reoccurring for me. I'm guessing that the ctrl file gets removed as part of the daily temp purge, which forces a rebuild of the folder permissions.

These are my edits to /var/xdrago/manage_ltd_users.sh lines 1390 and 1391:

      chown ${_USER}:www-data ${dscUsr}/.tmp &> /dev/null
      chmod 02775 ${dscUsr}/.tmp &> /dev/null

@omega8cc
Copy link
Owner

You should probably set _SKYNET_MODE=OFF if you still run previous stable and not the latest.

@rpsu
Copy link

rpsu commented Feb 16, 2015

Same here. Upgrade 2.3.8 -> 2.4.0 do break [image] uploads on BOA servers. And as Drupal file_save_upload() does not explain in all cases why upload failed, this is slightly tricky to figure out ;)

@pricejn2
Copy link
Contributor

Just to confirm, for pre-2.4.0 installs with this issue:

  1. chown o1:www-data /data/disk/o1/.tmp
  2. chmod 775 /data/disk/o1/.tmp
  3. echo _SKYNET_MODE=OFF >> /root/.barracuda.cnf

@danielbeeke
Copy link

Had this same issue

@lefterav
Copy link

Hi. This issue occured to me again tonight by itself. I see that a new file /data/disk/o1/.tmp/.ctrl.242stableU.txt appeared a few minutes ago and the permissions of the directory changed

@omega8cc
Copy link
Owner

The /data/disk/o1/.tmp is not used as a temporary directory by the web server any longer since BOA-2.4.0, and we can't support instances which are not upgraded to the 2.4.x series yet.

@omega8cc
Copy link
Owner

Again, the upgrade from 2.3.8 to 2.4.x doesn't break the upload. Unless you will upgrade only barracuda and forget about octopus upgrade.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants