Hey Leighton,
Since moving servers and a couple of directories around last week, our file downloads aren't working. They were definitely working before the server change. I've tested lots of different ways of doing this over the past several hours, but still can't seem to get it to work. It appears that it's not able to read a certain directory (more on that later), though I'm not sure why... Here's how everything is configured:
- /var/www/domain.com/downloads
- /var/www/domain.com/downloads/ms_files
- /var/www/domain.com/downloads/FileToDownload.pdf
- /var/www/domain.com/downloads/ms_files/FileToDownload.pdf
--- chmod -R 777 on each of these folders and files above.
- /admin/settings/file-system
--- File System Path: /var/www/domain.com/downloads
--- Temporary Directory: /var/www/domain.com/tmp (Note: I've also tried making this /var/www/domain.com/downloads )
--- Download Method: Private
--- (Note: Our webroot is /var/www/domain.com/www )
- /admin/moneyscripts/ms_files
--- [Checked] Generate New Download Link Each Time
--- Advanced Settings > Existing Files Search Path: [Blank], I have also tried making this /var/www/domain.com/downloads.
- /admin/build/ms_files/edit/1
--- File Settings > Current File : the filename shows up properly.
--- Choose New File > Select an Existing File : the files in the directory show up properly in the dropdown.
--------------------
Now, the buggy part:
- /admin/build/ms_files/edit/1
--- Choose New File > Choose File : I choose a file to upload, it goes through the process, then displays the following two lines on the confirmation page:
----- The directory is not accessible
----- PayPal File Saved: [File Display Name].
What I find weird about this is that when I look through the module's the code, it looks like it could either be in row 1896 or 1948. It also looks like it should be displaying a directory path between "directory" and "is" in the error display.
Do you know what could be causing this? I'm imagining that this is related to the fundamental problem on this end. Like I said, I've checked file and directory permissions, database entries, etc. Everything I know to look at, I've looked at and it seems like it should be working. I have tried everything I can think of, including creating a new file download product, entering all directory paths explicitly, deleting files and reuploading them via SCP, uploading new files, changing download directories, etc, and nothing seems to work.
Thoughts?
Ben








Hey Leighton,
It looks like something also went terribly wrong in my watchdog table that relates to this. I'm looking into it now, but I had, literally, over 30,000,000 entries in watchdog. I deleted all but 1000 of them so I could work in there, but the ones that are left look like most of them are one of the following:
a:4:{s:6:"%error";s:7:"warning";s:8:"%message";s:57:"fread() expects parameter 1 to be resource, boolean given";s:5:"%file";s:79:"/var/www/domain.com/www/sites/all/modules/moneyscripts/ms_files/ms_files.module";s:5:"%line";i:590;}
a:4:{s:6:"%error";s:7:"warning";s:8:"%message";s:56:"feof() expects parameter 1 to be resource, boolean given";s:5:"%file";s:79:"/var/www/domain.com/www/sites/all/modules/moneyscripts/ms_files/ms_files.module";s:5:"%line";i:588;}
Not sure if that helps or not. I looked at the file and just don't understand the module well enough to know why it would be giving this error. :-/