Author Topic: what is cwp-httpd?  (Read 13796 times)

0 Members and 1 Guest are viewing this topic.

what is cwp-httpd?
« on: February 12, 2018, 01:59:42 PM »
Code: [Select]
yum remove httpd
Quote
Running transaction
  Erasing    : httpd-2.4.6-67.el7.centos.6.x86_64                                                     1/1
warning: directory /var/www: remove failed: Device or resource busy
  Verifying  : httpd-2.4.6-67.el7.centos.6.x86_64                                                     1/1

Removed:
  httpd.x86_64 0:2.4.6-67.el7.centos.6

Complete!

Code: [Select]
systemctl restart cwpsrv cwp-phpfpm
Code: [Select]
yum list installed | grep httpd
Quote
cwp-httpd.x86_64                       2.4.29-1
  ???



Having uninstalled apache there is still apache..  ??? What is this (for)? And why is is displaying an apache version on the CWP when httpd is effectively gone?








Offline
***
Re: what is cwp-httpd?
« Reply #1 on: February 12, 2018, 05:24:25 PM »
cwp-httpd is responsible for running apache in cwp.

Re: what is cwp-httpd?
« Reply #2 on: February 12, 2018, 05:36:14 PM »
apparently, also needs cwp-suphp.

Just how it is 'responsbile'? shouldn't httpd be running on its own merit? What does cwp-httpd exactly do?

Offline
***
Re: what is cwp-httpd?
« Reply #3 on: February 12, 2018, 05:51:10 PM »
remove cwp-httpd and your apache will stop working. There is no httpd package is installed by yum.

Offline
***
Re: what is cwp-httpd?
« Reply #4 on: February 12, 2018, 05:55:50 PM »
also cwp-suphp is installed.

Re: what is cwp-httpd?
« Reply #5 on: February 12, 2018, 06:25:28 PM »
If you run
Code: [Select]
yum remove httpd
it does remove apache. The info on display, apache version and php version, are not really about the appache server but about cwp-httpd and cwp-php. And that is why this info is still on display even after the removal of httpd.

Which caused the curiosity about cwp-httpd in the first place and what hold it has over httpd. I would like to be in picture about what is happening on the server and thus I am still not clear what the exact role (responsibility) of that module is.

There should be some transparency about this by CWP, like in their wiki.

how to register cwp-httpd with the os as default httpd?
« Reply #6 on: February 19, 2018, 07:59:09 AM »
how to register cwp-httpd in the os/system as default httpd  ???

Apparently cwp-httpd is not registered os/systemwide as httpd. For some reason CWP also installed httpd 2.4.6 (/etc/httpd) which just sits dormant. Any CLI interaction thus is not with cwp-httpd but the dormant httpd instead, e.g.
Code: [Select]
httpd -t -D DUMP_RUN_CFG results in
Quote
ServerRoot: "/etc/httpd"
Main DocumentRoot: "/var/www/html"
Main ErrorLog: "/etc/httpd/logs/error_log"
Mutex default: dir="/run/httpd/" mechanism=default
Mutex mpm-accept: using_defaults
Mutex authdigest-opaque: using_defaults
Mutex proxy-balancer-shm: using_defaults
Mutex rewrite-map: using_defaults
Mutex authdigest-client: using_defaults
Mutex proxy: using_defaults
Mutex authn-socache: using_defaults
PidFile: "/run/httpd/httpd.pid"
Define: _RH_HAS_HTTPPROTOCOLOPTIONS
Define: DUMP_RUN_CFG
User: name="apache" id=48
Group: name="apache" id=48

vs. /usr/local/apache/bin/httpd -t -D DUMP_RUN_CFG

Quote
ServerRoot: "/usr/local/apache"
Main DocumentRoot: "/home"
Main ErrorLog: "/usr/local/apache/logs/error_log"
Mutex default: dir="/usr/local/apache/logs/" mechanism=default
Mutex rewrite-map: using_defaults
Mutex ssl-stapling-refresh: using_defaults
Mutex ssl-stapling: using_defaults
Mutex proxy: using_defaults
Mutex ssl-cache: using_defaults
PidFile: "/usr/local/apache/logs/httpd.pid"
Define: DUMP_RUN_CFG
User: name="nobody" id=99
Group: name="nobody" id=99

Again, this is lacking transparency and is not documented in the wiki. It may also incur lot of confusion, not only for the user but also applications depending on httpd.

In the above described setup provided by CWP no other application is recognising cwp-httpd as httpd only when manually pointed to by (CWP) scripts.

Whilst the dormant httpd 2.4.6 can be safely removed (yum remove httpd) I would like to know how to register cwp-httpd in the os/system as default httpd for other application to recognise (and the user to be able to interact via CLI with the direct httpd command).  ???

Re: how to register cwp-httpd with the os as default httpd?
« Reply #7 on: February 19, 2018, 01:25:58 PM »
2 ways, as the cwp-httpd exec is located in /usr/local/apache/bin

set syslink
Code: [Select]
cd /usr/sbin
ln /usr/local/apache/bin/httpd httpd

or add the cwp-httpd path to the OS environment path
Code: [Select]
export PATH=$PATH:/usr/local/apache/bin
The only issue now is to get yum packages to recognize the presence of cwp-httpd as httpd, whilst

Code: [Select]
rpm -qa | grep httpd* produces
Quote
cwp-httpd-2.4.29-2.x86_64

Code: [Select]
yum list installed httpd comes up short
Quote
Error: No matching Packages to list

cwp-httpd seems to the lacking the 'webserver' rpm descriptor in order to be recognized by yum as httpd.

Any idea how to set said descriptor  ???
« Last Edit: February 19, 2018, 02:24:25 PM by n8v8r »