Previous Next

Thread: Cannot save file via FTP when server copy is changed?

Last post 07-05-2008 12:45 PM by e1ny. 3 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (4 items)

Sort Posts:

  • 07-01-2008, 3:40 PM

    • e1ny
    • Top 25 Contributor
    • Joined on 12-10-2007, 9:50 PM
    • Posts 106
    • e1ny

    Cannot save file via FTP when server copy is changed?

    Hi All: I was working remotely on a server-based website via FTP in VWD2008...everything was working fine, and then suddenly I couldn't save .aspx files...I started getting a error like "the copy of the file on the server is newer than your cached copy...do you want to replace it with the server copy?" and if I say "yes" I then get an error "Cannot save the file 'myfile.aspx' to the Web server. 550 Access is denied."

    If I close the project without saving and the reopen it, I'm prompted to replace my local copies with the server ones...even after doing that, the same errors repeat as above. I can still open and save other files in the project (like .css files)...I'm just not understanding what the problem is?

    How do I get rid of the local cache files and just start fresh from the website?

  • 07-01-2008, 4:20 PM In reply to

    Re: Cannot save file via FTP when server copy is changed?

    Does the FTP account have at least MODIFY permission to the files/folders?

    Jeff

    Look for Wrox's new book Professional IIS 7 in your local bookstore, or order now at Amazon.com
  • 07-01-2008, 4:39 PM In reply to

    • e1ny
    • Top 25 Contributor
    • Joined on 12-10-2007, 9:50 PM
    • Posts 106
    • e1ny

    Re: Cannot save file via FTP when server copy is changed?

    The user account has "read/write" permissions for the entire directory...as I mentioned it was working fine, then all of a sudden I couldn't save the aspx files, like they were being held open in some way. I could still upload images, modify other files etc.

    If I closed down VWD I'd get a warning "the file on the server is newer than your cached copy, do you want to replace it", and I'd say "yes", but it made no difference...I'd reopen the project and I'd get the same error. What's weird is I can't even find the "cached" files anywhere in the VWD2008 directory hierarchy...just the project folder and a .SUO and .SLN file.

  • 07-05-2008, 12:45 PM In reply to

    • e1ny
    • Top 25 Contributor
    • Joined on 12-10-2007, 9:50 PM
    • Posts 106
    • e1ny

    Re: Cannot save file via FTP when server copy is changed?

    OK, finally, I got it to work, but I'm not clear on why it works :(

    I have a server with a number of websites, with the FTP Server 7 installed. Since all the websites share a single IP, I decided to create a single FTP site with the root set to the directory holding all the websites. Then, 

    • I created a new user in AD, that I want to use for FTP.
    • Under the FTP site, I added the user to the FTP Authorization Rules with Read, Write permissions.

    At this point, I would think I had done enough, but when I connected via FTP in VWD2008Express, with a subdirectory as the target (which itself was the root of a particular website), I could only read files, not save changes.

    I went back to the FTP folder, and gave the new user "Modify" permissions under "propertiies -> security". Still couldn't save files.

    I then finally, in IIS Manager, went to the website I was trying to modify (which is a subdirectory in the in the main FTP site), went to "properties -> security" there, and again added the user and gave it "modify" permissions, and now I can edit/save files via FTP.

    So, my question is, what is determining access restrictions on a particular sub-directory that is itself a root of a website? Why didn't the "modify" permissions for the user account propagate to the subfolders in the FTP site?

    Moving forward, I may want to give other users access only to specific websites. Can I do this the way I did it in IIS6, by creating a virtual directory in the FTP root that matches the username? Or will that "hack" no longer work in FTP7?

    Or am I approaching this all the wrong way?

Page 1 of 1 (4 items)
Page view counter