(redirected from Unslung.Apache)
Plead: Could someone please make it so we can use system() and exec() commands in PHP
(The answer seems to be "no"; as is noted below, running Apache in Prefork mode, which is necessary to support this, "uses too much memory to be useful on a slug, even when configured conservatively." If you want to experiment, note that Debian has Apache packages for each of the different MPM modes including Prefork, so you could try that.)
Some work has been done on building apache 2.0.x and php 5.x within the unslung package system. The relevant packages are:
Apache will listen on port 8000 (so as not to get in the way of the built-in web server) by default.
Apache vs. thttpd
Php-thttpd has a subset of the features of apache, and is much more resource-cheap. The main extra features apache has are:
If you don't need to serve more than one client, and don't need use any of the other features of apache, you are recommended to use php-thttpd instead.
Apache comes with quite a complicated build system of its own. The most familiar face of this is apxs, a perl script which can be used to build and install apache modules. Apxs "knows" the exact CC and LD that were used to build apache; it can also invoke a customised version of libtool; and copy makefile fragments containing hardcoded paths into various places. Similar complexities afflict apr-config and apu-config, which are the build tools installed by apr and apr-util respectively. Obviously all this is nasty to deal with when doing a staged cross-build.
I've configured apr, apr-util, and apache in such a way that the build system components end up containing paths that lead to the unslung staging directory, while other components, like libraries, contain only paths that make sense on the target system. (For example, for apr this is done by configuring with prefix=$(STAGING)/opt and libdir=/opt/lib). At staging time I install the whole lot into the staging directory. At packaging time, the build system is discarded (it is useless as it is full of hard-written paths that only make sense on the build machine).
The upshot of all this is the apxs binary found in the unslung staging area after "make apache-stage" can be used to build Apache modules from within Unslung. It will use whatever compiler and other tools were used to build apr, and will link opposite libraries in the staging directory. So building an Apache module within Unslung should be as simple as configuring --with-apxs=$(STAGING_DIR)/opt/sbin/apxs. Look at PHP for an example.
For Apache questions or issues, you may wanna search this large unofficial Apache Forum hosted by Nabble which currently archives all the Apache projects' mailing lists to allow cross search and browsing. If you could not find an answer, you can post your question to the approriate sub forum which will forward your post to the corresponding mailing list.
Access and error logs for this are at: /opt/var/apache2/log/
--issue i have a problem i only can see text if i want to acces an php page changed index page option => index.php maybe noob but i just dont get it i installed php 2 what am i doing wrong . i got it running befor i fuck up my first hdd and now its just not working
--issue I 'upgraded' to the latest version of apache and I can no longet run PHP, I have tried a clean install and it still doesn't work (same as Jeremy's issue by the sounds of it.) I have come to the conclusion that PHP with the new version of Apache is broken in some way. Can anyone confirm or give me a work around?
I did an ipkg upgrade and got this:
Configuring apache update-alternatives: Linking //opt/sbin/htpasswd to /opt/sbin/apache-htpasswd httpd: Syntax error on line 233 of /opt/etc/apache2/httpd.conf: Cannot load /opt /libexec/mod_access.so into server: /opt/libexec/mod_access.so: cannot open shar ed object file: No such file or directory httpd: Syntax error on line 233 of /opt/etc/apache2/httpd.conf: Cannot load /opt /libexec/mod_access.so into server: /opt/libexec/mod_access.so: cannot open shar ed object file: No such file or directory postinst script returned status 1 ERROR: apache.postinst returned 1 Nothing to be done
Now Apache does not run. I have Unslung V2.3R63-uNSLUng-6.8-beta. What do I need to do?
3/14/07 - i did ipkg install apache and get this error at the end:
An error ocurred, return value: 22. Collected errors: ipkg_download: ERROR: Command failed with return value 1: `wget --passive-ftp -q -P /tmp/ipkg-J1ZfYd? http://ipkg.nslu2-linux.org/feeds/unslung/cross/cyrus-sasl-libs_2.1.22-1_armeb.ipk' Failed to download cyrus-sasl-libs. Perhaps you need to run 'ipkg update'?
i did run ipkg update before installing, it downloads all the other files fine except for that one.
3/15/07 - Trying to install webdav-module I am trying to install a webdav module but didn't really get the part about the staging. Can someone please post the commandoes I need to run. I have unpacked the source and am trying to run ./configure --with-apxs in the source folder...
3/22/07 - ipkg upgrade problem
I can see disk 1 and disk 2 from an external connection using FTP but cannot log into password protected locations of the disk.
What has ipkg upgrade done?
Answer: The Apache config file must specify the server name.
7/07/07 - apache zombie issues on OpenWrt
After successfully installing Optware on my OpenWrt WRT54GS with SD mod, I tried to install apache. It starts, but can't serve web pages and the httpd processes go zombie (as via ps aux). The /opt/var/apache/log/error_log only status apache is resuming normal operations, and nothing is logged via /opt/var/log/access_log. Any ideas?
I intially installed on WhiteRussian (RC5), but later reflashed and tried again on Kamikaze 7.06 as indicated in the Optware guide. The same issue appeared both times, though on Kamikaze mod_unique_id doesn't seem to work as well. On WhiteRussian all modules seemed to load without error.
05/08/2007 Performed an upgrade from 2.0 to 2.2.
Biggest gripe is that for some reason it trampled my index.html so that my old web server was lost. Will have to spend several hours rewriting index.html since I didn't have a backup. My fault really. I had symlinked www to my directory.
Why trample index.html???
Also my old conf file can't load modules but I am still investigating.
view · edit · print · history · Last edited by fcarolo.
Based on work by Calum, tillin9, infoball, httpbet-com-msnbc-msn-com-sitefv500info, fcarolo, httplone-models-com-park-starcv100info, httpcraigslist-org-sfbayareafv500info, httpsportsline-comfv500info, FelixofMars, Mo, Phil Endecott, Laffez, minh, Rutger, Jeremy Jefferson, repvik, Jeremy, Chacko, Alsopache, jp30, barrym, j, an anonymous user of NSLU2-Linux, rwhitby, Oli, and tman.
Originally by jp30.
Page last modified on August 08, 2007, at 07:20 AM