|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
mniskanen Smarty Rookie
Joined: 26 Apr 2003 Posts: 20 Location: Lieksa,Finland
|
Posted: Sun Sep 18, 2005 5:28 pm Post subject: Smarty (or actually PHP) with Apache2/Fedora |
|
|
I did a fresh test install of Fedora Core 4 to one of my old computers just
to test Apache 2. What followed was a true mess.
At first everything went just fine and I moved one of my project to the
server because it was faster than my main server (FreeBSD/Apache13).
Then mains power went down and I had to reboot the beast. This is
where the trouble started
Smarty only could write two compiled templates to "templates_c". I removed all
files from there and after that it could not write one single byte. I changed
templates_c to /tmp/templates_c giving all possible permissions. Nothing
helped (or actually did help, from time to time. The more I tried to trick
permissions the less Smarty could do and finally it could not even READ the source
templates!!! I also wrote a small log test PHP application without Smarty
and It could not write to its directory, either. Then, after maybe five Apache
restarts everything went smoothly again WITH THE ORIGINAL SETTINGS.
No changes in ownerships or permissions. Everything is now
exactly the way it used to be!
This is a clear evidence about the instability of Apache 2 and I will
certainly install 1.3 as soon as possible. We have written more than 150
Smarty applications so far not seen anything like this before.
Markku |
|
Back to top |
|
boots Administrator
Joined: 16 Apr 2003 Posts: 5611 Location: Toronto, Canada
|
Posted: Sun Sep 18, 2005 6:27 pm Post subject: |
|
|
Are you certain this is a problem of Apache2? Did you use prefork? May it have been a problem with SELinux instead? I am having good success with Apache2 on Debian. |
|
Back to top |
|
mniskanen Smarty Rookie
Joined: 26 Apr 2003 Posts: 20 Location: Lieksa,Finland
|
Posted: Sun Sep 18, 2005 7:48 pm Post subject: |
|
|
boots wrote: | Are you certain this is a problem of Apache2? Did you use prefork? May it have been a problem with SELinux instead? I am having good success with Apache2 on Debian. |
Well getting a bit off topic...
To be totally honest I have no idea what "prefork" means, I only used the
standard installation that came with Fedora. So far I have done my own
compilation of the 1.3 series and just wanted to see if everything goes
well 'out of the box'. It did not. As for the default Fedora PHP configuration,
it is far from satisfactory and needs a recompilation as well.
As for Smarty the whole thing was darn difficult to debug and I still have
no idea where the problem really was. Nothing in the logs reveals anything
about the possible cause.
Well, whatever it was, it truly broke my confidence in Fedora. The more "user friendly"
these beast are built the more badly they seem to behave. A month a go
an 'out-of-the-box' Ubuntu installation and a hangup in X destroyed
one of my NTFS partitions. Needless to say I feel much more
at home with the "do-it-yourself" distributions.
As for "SELinux"... well... I did use that installation option only to see that
the "Security Level" applet refuses to run... sigh... no idea, though, what
this applet should do. All in all this is what I remember having seen in
Windows 3.0 and Windows ME. Very, very bad programming indeed.
Well... back to something more stable. As for Debian I am not too sure as
the Sun Java support is pretty close to none or am I incorrect?
Markku |
|
Back to top |
|
boots Administrator
Joined: 16 Apr 2003 Posts: 5611 Location: Toronto, Canada
|
Posted: Sun Sep 18, 2005 9:42 pm Post subject: |
|
|
Hi again. I'll continue the OT just this once
mniskanen wrote: | To be totally honest I have no idea what "prefork" means, I only used the standard installation that came with Fedora. So far I have done my own compilation of the 1.3 series and just wanted to see if everything goes well 'out of the box'. It did not. As for the default Fedora PHP configuration, it is far from satisfactory and needs a recompilation as well. |
I haven't looked at Fedora in a long time but Apache2 supports several different processing modules, "prefork" being one of them. It is essentially the same per process model that Apache 1.3 uses as opposed to the threaded model which, AFAIK, isn't recommended for PHP use. I have no idea what the default model is in Fedora.
mniskanen wrote: | A month a go an 'out-of-the-box' Ubuntu installation and a hangup in X destroyed one of my NTFS partitions. Needless to say I feel much more at home with the "do-it-yourself" distributions. |
Ouch. Again, I have had much better luck but I long ago ditched all of my NTFS partitions and rely on Wine for the few windows apps I sometimes need. In fact, I recently upgraded to breezy (which is still beta) and despite a few relatively easy to correct glitches have no problems to speak of. *shrug* I guess I'll count my lucky stars
mniskanen wrote: | As for "SELinux"... well... I did use that installation option only to see that the "Security Level" applet refuses to run... sigh... no idea, though, what this applet should do. All in all this is what I remember having seen in Windows 3.0 and Windows ME. Very, very bad programming indeed. |
I'm staying away from SELinux until it matures and even then I'm not too sure. Owner / Group / World security works just fine for me.
mniskanen wrote: | Well... back to something more stable. As for Debian I am not too sure as the Sun Java support is pretty close to none or am I incorrect? |
I must be getting old because I'm tired of maintaining my own DIY distro for my desktop and have gotten comfortable with Ubuntu. Java support is quite possible and with various ports available. FWIW, I have Sun's 1.5 installed. Technically, it is not considered "Free" software so you have to do a little bit of manual work, but nothing worth mentioning. Considering your experiences, I have to add that YMMV |
|
Back to top |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|