The MU forums have moved to

Changing the Upload Directory Structure - using symbolic links? (4 posts)

  1. ancawonka
    Posted 12 years ago #

    Hello everyone,

    I've managed to secure a large amount of file storage for our WordPress MU site, in the form of an NFS-mounted drive that is visible as a volume on our application host.

    Now, I need to tell WordPress MU to put uploaded files there. I was thinking that rather than trying to hack into the core and figure out how to point WPMU at something other than blogs.dir, I would just create a symlink of blogs.dir, and point it at the mounted volume.

    Can anybody think of a reason why this wouldn't work? I don't have the permissions to create my target directory on the NFS-mounted drive, nor am I allowed to change httpd.conf by myself - so, I'll need to get our sysadmin to do whatever's required. I think right now I need to make sure that Apache has follow-symlinks turned on, but I don't know anything more about this aspect of Apache config. Any other suggestions?

  2. andrea_r
    Posted 12 years ago #

    That might actually work.

    Also, you can define a different wp-content directory in wp-config.php.

  3. ancawonka
    Posted 12 years ago #

    All righty! Looks like making a symlink worked like a charm.

    WP is still providing URL's for my files that work (even though they get content off the remote drive).

    All I had to do was the following:

    > cd wp-content
    > ln -s /full/path/to/new/directory blogs.dir


  4. andrea_r
    Posted 12 years ago #

    Woot! Magic *and* the easy way. :D

About this Topic

  • Started 12 years ago by ancawonka
  • Latest reply from andrea_r