File Corruption when Linux Guest reads files on OSX
Posted: 17. Apr 2010, 20:55
I have a Linux (Fedora 12) guest installation for a web project. It's running Apache/Resin/Railo.
I have Host-Only networking setup, and the Linux guest can read/write files on my Mac.
In Eclipse, I have my project setup with my web code, and on the Linux guest, Apache is configured to get the files from my Mac, e.g. /mnt/rob/www/etc/etc/etc.
This works great when viewing the site on my Mac pointing to the guest's IP.
But then if I edit a file, say, a javascript file, and save it, then try to reload the page, it throws an error (in Firebug) saying there are invalid characters. Upon closer inspection, the file it thinks it has read is NOT the current file, and there are now a dozen or more weird characters at the end of the file. No amount of editing or cache clearing corrects this.
I tried restarting apache, resin, railo etc, to no avail. The only cure is to totally restart the guest. But then it's the same thing all over with each file change. So as near as I can tell, the problem seems to lie in whatever handles the filesystem mounting. It's not picking up changes when they happen, or something.
My current fix, which I don't care for, is to keep the web code on the Linux guest and access it through a Samba share I created from my Mac to the Linux guest. This works fine, but I would much rather keep the code local.
Has anybody else seen this problem or have any ideas what I might do to correct it?
Thanks!
Rob
I have Host-Only networking setup, and the Linux guest can read/write files on my Mac.
In Eclipse, I have my project setup with my web code, and on the Linux guest, Apache is configured to get the files from my Mac, e.g. /mnt/rob/www/etc/etc/etc.
This works great when viewing the site on my Mac pointing to the guest's IP.
But then if I edit a file, say, a javascript file, and save it, then try to reload the page, it throws an error (in Firebug) saying there are invalid characters. Upon closer inspection, the file it thinks it has read is NOT the current file, and there are now a dozen or more weird characters at the end of the file. No amount of editing or cache clearing corrects this.
I tried restarting apache, resin, railo etc, to no avail. The only cure is to totally restart the guest. But then it's the same thing all over with each file change. So as near as I can tell, the problem seems to lie in whatever handles the filesystem mounting. It's not picking up changes when they happen, or something.
My current fix, which I don't care for, is to keep the web code on the Linux guest and access it through a Samba share I created from my Mac to the Linux guest. This works fine, but I would much rather keep the code local.
Has anybody else seen this problem or have any ideas what I might do to correct it?
Thanks!
Rob