*DEPRECATED* Apache Web Server for unRAID 6.2


Recommended Posts

The high memory usage has to do with how apache works and that it's the 64bit version. Apache requires one process per connection and depending on web browser many connection may be opened. Each module takes some memory and all are loaded with each process. The only thing you can do is try disabling some of the modules.  The ones I listed plus proxy and ssl if not needed. It's been awhile since I tried nginx. I can probably easily convert the plugin to an nginx version. It uses an evented model and will use a single worker process for many connections.

Link to comment

It looks like I am missing something here. I've installed the plugin (since I am trying to setup Virtualbox as well). After installing the plugin, I am unable to run any of the VM's, with message "Error:invalid argument: could not find capabilities for arch=x86_64 domaintype=(null)". Tested several times (install plugin / reboot /VMs not working - uninstall plugin / reboot / VMs working). Images attached... Any ideas?

Were you able to run them before install this plugin? Do you have vt-x or vt-d eneabled in the bios? 

Link to comment

Unless you're actually running out of memory, I wouldn't worry too much.  Even if you stop apache the memory will still be cached but free for other programs to use.  I did test some settings to reduce the memory footprint of apache. You can try commenting out these modules in your httpd.conf. and any others that you don't need.

I am running out of memory.

 

After starting up Apache the memory footprint is very small (less than 10MB).

At what stage are the modules loaded? at Apache startup or only when needed by the specific web page?

If it is on startup then it doesn't explain the memory rise afterwards.

 

Once I start loading phpVirtualBox the memory starts rising as I navigate around the site and reaches over 1.6GB of memory usage by httpd processes.

This memory is kept in use and NOT cached !!!

 

Only when I disable Apache web server do all the httpd processes get removed and memory is returned to the system (freed not cached).

 

I have also tried it with eXplorer and also there the memory rises and not freed up, but not as much - only ~200MB.

I did get nginx up and running along with a php-fpm server.  However unRAID's php 5.4.40 was compiled with non thread safe and the public php packages are with thread safe. or vice versa I don't remeber but they are incompatible and I can't load soap. So I'll have to try and compile myself.

Link to comment

It looks like I am missing something here. I've installed the plugin (since I am trying to setup Virtualbox as well). After installing the plugin, I am unable to run any of the VM's, with message "Error:invalid argument: could not find capabilities for arch=x86_64 domaintype=(null)". Tested several times (install plugin / reboot /VMs not working - uninstall plugin / reboot / VMs working). Images attached... Any ideas?

Were you able to run them before install this plugin?  Do you have vt-x or vt-d eneabled in the bios?

 

dmacias, of course I was able to run them before. I am running them right now, with the plugin uninstalled. VT-x / VT-d question: not answering  ;D. Please check attached image and signature for details and running VMs. Passthrough is enabled and running as well ...

unraid_vms_running.jpg.3f9e5b4314d715538a28ff31c2fdca5c.jpg

Link to comment

It looks like I am missing something here. I've installed the plugin (since I am trying to setup Virtualbox as well). After installing the plugin, I am unable to run any of the VM's, with message "Error:invalid argument: could not find capabilities for arch=x86_64 domaintype=(null)". Tested several times (install plugin / reboot /VMs not working - uninstall plugin / reboot / VMs working). Images attached... Any ideas?

Were you able to run them before install this plugin?  Do you have vt-x or vt-d eneabled in the bios?

 

dmacias, of course I was able to run them before. I am running them right now, with the plugin uninstalled. VT-x / VT-d question: not answering  ;D. Please check attached image and signature for details and running VMs. Passthrough is enabled and running as well ...

 

 

It looks like I am missing something here. I've installed the plugin (since I am trying to setup Virtualbox as well). After installing the plugin, I am unable to run any of the VM's, with message "Error:invalid argument: could not find capabilities for arch=x86_64 domaintype=(null)". Tested several times (install plugin / reboot /VMs not working - uninstall plugin / reboot / VMs working). Images attached... Any ideas?

Were you able to run them before install this plugin?  Do you have vt-x or vt-d eneabled in the bios?

 

dmacias, of course I was able to run them before. I am running them right now, with the plugin uninstalled. VT-x / VT-d question: not answering  ;D. Please check attached image and signature for details and running VMs. Passthrough is enabled and running as well ...

 

From that image you are running kvm vm's. I assumed you meant virtualbox vms. I had no problem installing apache and running kvm vm's. However there was a package conflict that would not allow vm's to be created because of libpng error.  I have removed a couple packages and updated apache. To fix that problem you will have to upgrade the plugin and reboot.  For the problem your having I believe it's caused by virtualbox running. You cannot run them at the same time. To run virtualbox you would have to stop libvirt under settings/vm manager, enable vms = no.

 

If that doesn't fix it let me know.

Link to comment

just updated the plugin and now my apache will not start, this is the log error

 

apache: httpd: Syntax error on line 527 of /etc/httpd/httpd.conf: Syntax error on line 6 of /etc/httpd/mod_php.conf: Cannot load lib64/httpd/modules/libphp5.so into server: /usr/lib64/httpd/modules/libphp5.so: cannot open shared object file: No such file or directory

Link to comment

just updated the plugin and now my apache will not start, this is the log error

 

apache: httpd: Syntax error on line 527 of /etc/httpd/httpd.conf: Syntax error on line 6 of /etc/httpd/mod_php.conf: Cannot load lib64/httpd/modules/libphp5.so into server: /usr/lib64/httpd/modules/libphp5.so: cannot open shared object file: No such file or directory

Ok I see the problem.  libphp5.so is in wrong folder. I will fix.

Link to comment

just updated the plugin and now my apache will not start, this is the log error

 

apache: httpd: Syntax error on line 527 of /etc/httpd/httpd.conf: Syntax error on line 6 of /etc/httpd/mod_php.conf: Cannot load lib64/httpd/modules/libphp5.so into server: /usr/lib64/httpd/modules/libphp5.so: cannot open shared object file: No such file or directory

Ok I see the problem.  libphp5.so is in wrong folder. I will fix.

 

that fixed it. thanks!

Link to comment
  • 2 months later...

I keep getting errors when doing updates on unraid plugins page, goes away after uninstalling apache and rebooting server...

 

PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking wol.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking unassigned.devices.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking tftp.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking powerdown-x86_64.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking dynamix.system.stats.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking dynamix.system.info.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking dynamix.cache.dirs.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking dynamix.active.streams.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking community.applications.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking apache.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking NerdPack.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking unRAIDServer.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0

 

Thanks

Link to comment

I keep getting errors when doing updates on unraid plugins page, goes away after uninstalling apache and rebooting server...

 

PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking wol.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking unassigned.devices.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking tftp.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking powerdown-x86_64.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking dynamix.system.stats.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking dynamix.system.info.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking dynamix.cache.dirs.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking dynamix.active.streams.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking community.applications.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking apache.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking NerdPack.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0
plugin: checking unRAIDServer.plg ...
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib64/php/extensions/iconv.so' - /usr/lib64/php/extensions/iconv.so: undefined symbol: sapi_globals_id in Unknown on line 0

 

Thanks

I haven't had a chance to completely update the plugin yet. You can delete the iconv.so from the /boot/php-ext-5.4.40-x86_64-2_slack14.1 package. I'll try to update everything later today.

Link to comment

Updated for unRAID 6.1-rc+

 

updated, apache will not start

 

error: /plugins/apache/scripts/rc.apache: no such file or directory

I change the way the rc script was symlinked so it should fix the problem.

 

error on update:

plugin: downloading: "https://github.com/dmacias72/apache/archive/2015.08.20.tar.gz" ... done
mv: failed to access '/etc/rc.d/rc.apache': Too many levels of symbolic links
chmod: cannot access '/etc/rc.d/rc.apache': Too many levels of symbolic links
plugin: updated

Link to comment

Updated for unRAID 6.1-rc+

 

updated, apache will not start

 

error: /plugins/apache/scripts/rc.apache: no such file or directory

I change the way the rc script was symlinked so it should fix the problem.

 

error on update:

plugin: downloading: "https://github.com/dmacias72/apache/archive/2015.08.20.tar.gz" ... done
mv: failed to access '/etc/rc.d/rc.apache': Too many levels of symbolic links
chmod: cannot access '/etc/rc.d/rc.apache': Too many levels of symbolic links
plugin: updated

Did you try removing the plugin from the installed plugin page? Then reinstall. If that didn't work then remove, reboot, reinstall. Or just reboot with the latest plugin version.

Link to comment

Updated for unRAID 6.1-rc+

 

updated, apache will not start

 

error: /plugins/apache/scripts/rc.apache: no such file or directory

I change the way the rc script was symlinked so it should fix the problem.

 

error on update:

plugin: downloading: "https://github.com/dmacias72/apache/archive/2015.08.20.tar.gz" ... done
mv: failed to access '/etc/rc.d/rc.apache': Too many levels of symbolic links
chmod: cannot access '/etc/rc.d/rc.apache': Too many levels of symbolic links
plugin: updated

Did you try removing the plugin from the installed plugin page? Then reinstall. If that didn't work then remove, reboot, reinstall. Or just reboot with the latest plugin version.

all working.. im dumb and didnt reboot before reinstall

Link to comment

Updated for unRAID 6.1-rc+

 

updated, apache will not start

 

error: /plugins/apache/scripts/rc.apache: no such file or directory

I change the way the rc script was symlinked so it should fix the problem.

 

error on update:

plugin: downloading: "https://github.com/dmacias72/apache/archive/2015.08.20.tar.gz" ... done
mv: failed to access '/etc/rc.d/rc.apache': Too many levels of symbolic links
chmod: cannot access '/etc/rc.d/rc.apache': Too many levels of symbolic links
plugin: updated

Did you try removing the plugin from the installed plugin page? Then reinstall. If that didn't work then remove, reboot, reinstall. Or just reboot with the latest plugin version.

all working.. im dumb and didnt reboot before reinstall

It was my error. The rc.script wasn't getting removed correctly or its link.

Link to comment

Updated for 6.1

 

Have you tested it on 6.0.1? - I had to run the "start" script from command line after reboot in order to get phpvirtualbox working.

No I didn't. Is there anything in the logs that's suggests why it didn't start? It should run the /usr/local/emhttp/plugins/apache/scripts/start script on disks_mounted.  I thought the only thing that would be broke was the file tree for docroot and the httpd logs. There's also a newer version of php extensions since 6.1rc6 is on a newer version. I could post the plg file for the previous 6.01 version or it's in my github.

 

Link to comment

Updated for 6.1

 

Have you tested it on 6.0.1? - I had to run the "start" script from command line after reboot in order to get phpvirtualbox working.

No I didn't. Is there anything in the logs that's suggests why it didn't start? It should run the /usr/local/emhttp/plugins/apache/scripts/start script on disks_mounted.  I thought the only thing that would be broke was the file tree for docroot and the httpd logs. There's also a newer version of php extensions since 6.1rc6 is on a newer version. I could post the plg file for the previous 6.01 version or it's in my github.

 

From the log file:

Aug 30 21:20:41 Tower php: /plugins/apache/scripts/stop
Aug 30 21:20:55 Tower php: /plugins/apache/scripts/start
Aug 30 21:21:05 Tower emhttp: /usr/bin/tail -n 42 -f /var/log/syslog 2>&1
Aug 30 21:21:34 Tower php: /plugins/apache/scripts/stop
Aug 30 21:21:53 Tower php: /plugins/apache/scripts/start
Aug 30 21:21:57 Tower emhttp: /usr/bin/tail -n 42 -f /var/log/syslog 2>&1

 

The plugin didn't start and also didn't stop but indicated that it was running.

Link to comment

Updated for 6.1

 

Have you tested it on 6.0.1? - I had to run the "start" script from command line after reboot in order to get phpvirtualbox working.

No I didn't. Is there anything in the logs that's suggests why it didn't start? It should run the /usr/local/emhttp/plugins/apache/scripts/start script on disks_mounted.  I thought the only thing that would be broke was the file tree for docroot and the httpd logs. There's also a newer version of php extensions since 6.1rc6 is on a newer version. I could post the plg file for the previous 6.01 version or it's in my github.

 

From the log file:

Aug 30 21:20:41 Tower php: /plugins/apache/scripts/stop
Aug 30 21:20:55 Tower php: /plugins/apache/scripts/start
Aug 30 21:21:05 Tower emhttp: /usr/bin/tail -n 42 -f /var/log/syslog 2>&1
Aug 30 21:21:34 Tower php: /plugins/apache/scripts/stop
Aug 30 21:21:53 Tower php: /plugins/apache/scripts/start
Aug 30 21:21:57 Tower emhttp: /usr/bin/tail -n 42 -f /var/log/syslog 2>&1

 

The plugin didn't start and also didn't stop but indicated that it was running.

 

That looks like it is running from /plugins/... , not from /usr/local/emhttp/plugins/...

Link to comment

Updated for 6.1

 

Have you tested it on 6.0.1? - I had to run the "start" script from command line after reboot in order to get phpvirtualbox working.

No I didn't. Is there anything in the logs that's suggests why it didn't start? It should run the /usr/local/emhttp/plugins/apache/scripts/start script on disks_mounted.  I thought the only thing that would be broke was the file tree for docroot and the httpd logs. There's also a newer version of php extensions since 6.1rc6 is on a newer version. I could post the plg file for the previous 6.01 version or it's in my github.

 

From the log file:

Aug 30 21:20:41 Tower php: /plugins/apache/scripts/stop
Aug 30 21:20:55 Tower php: /plugins/apache/scripts/start
Aug 30 21:21:05 Tower emhttp: /usr/bin/tail -n 42 -f /var/log/syslog 2>&1
Aug 30 21:21:34 Tower php: /plugins/apache/scripts/stop
Aug 30 21:21:53 Tower php: /plugins/apache/scripts/start
Aug 30 21:21:57 Tower emhttp: /usr/bin/tail -n 42 -f /var/log/syslog 2>&1

 

The plugin didn't start and also didn't stop but indicated that it was running.

 

That looks like it is running from /plugins/... , not from /usr/local/emhttp/plugins/...

Thanks that may be it for 6.01 to work. The 6.1rc update.php appends /usr/local/emhttp to the path but will take the full path also.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.