Welcome Guest, Not a member yet? Register   Sign In
Files reported missing
#1

[eluser]Sean Downey[/eluser]
Hello

Has anyone ever had a problem where the codeigniter system is reporting that a controller or view file is missing even though the file is actually there?

The server setup is:
3 web servers
1 filer
Web servers have a mount setup looking at the same code on the filer.

This has happened to me twice now a couple of months apart.
The first time the code couldn't find a view file even though it hadn't been moved/touched. This time it was only 2 of the 3 web server which had a problem with that file.
The second time the main controller couldn't be found and so the main application gave an error on the page.
The was the error in the Log file
Quote:ERROR - 2008-09-11 15:10:30 --> 404 Page Not Found --> main/index


What I did on both occasions was to run the unix command "touch" on the files and this mysteriously fixed the issue.


Why would a touch command fix the issue?
How can I prevent this from happening again?

Any help will be gratefully received.

Thank you
#2

[eluser]Derek Allard[/eluser]
I can only think this must be a server issue. CodeIgniter doesn't care at all when files are timestamped, and doesn't check them, so the only think I can think of is that the server wasn't serving them until they got touched? I'm not sure. I've never heard of anyone else having an issue like this.
#3

[eluser]Sean Downey[/eluser]
Hi Derek

Thanks for the reply. Yes it is very odd. It has only happened twice in about 4 months.
We have been using these servers for non-CodeIgniter php projects for about 4 years with no issues.
I don't understand why a "touch" would fix the problem either.

We will just have to keep an eye out for it.
Thanks
#4

[eluser]xwero[/eluser]
touch creates the file it it doesn't exist but then you should have other errors because it's an empty file.

Maybe there are some problems synchronizing the files on the different servers?
#5

[eluser]Sean Downey[/eluser]
Hi Xwero

Yes but the file did exist and they had been working perfectly for over a month.
They hadn't been changed in the last week but suddenly the server couldn't find that 1 file.

I will go back to our sys admin but he didn't know what could be causing it either.

Thanks
#6

[eluser]xwero[/eluser]
It's very strange that one file disappears. And the sys admin can't see in his logs when the file is deleted? Maybe that way you can find out what happens.
#7

[eluser]Sean Downey[/eluser]
Hi Xwero

No the file isn't actually deleted. But the CodeIgniter log says that it can't find it.
The touch command isn't recreating the file it is just setting a new timestamp on it.
#8

[eluser]xwero[/eluser]
Could it be possible the file is synchronised without content? And because there is no content the error in the log occurs because the index method isn't found.
#9

[eluser]Sean Downey[/eluser]
But the code is stored on the filer and accessed by the web servers via a mount. So they are not actually synchronised.




Theme © iAndrew 2016 - Forum software by © MyBB