Adam,

Unfortunately, this did not repair the startup error. Once I created a new 
virtual environment, installed arches, uninstalled/re-installed psycopg2, 
corrected a directory oversight in my config file, and pointed to the new 
environment in apache2, I still got the following in my apache2 error.log 
and no coredump:

[Sun Jan 05 19:58:35.485867 2020] [mpm_event:notice] [pid 37579:tid 
139672454474688] AH00491: caught SIGTERM, shutting down

[Sun Jan 05 19:58:35.636147 2020] [mpm_event:notice] [pid 1993:tid 
140438837296064] AH00489: Apache/2.4.29 (Ubuntu) OpenSSL/1.1.1 
mod_wsgi/4.5.17 Python/2.7 configured -- resuming normal operations

[Sun Jan 05 19:58:35.636244 2020] [core:notice] [pid 1993:tid 
140438837296064] AH00094: Command line: '/usr/sbin/apache2'

[Sun Jan 05 19:58:49.346899 2020] [wsgi:error] [pid 2006:tid 
140438713235200] [client 161.149.102.22:2459] wsgi:error 'arches': 
/Projects/ssl/hpla/hpla/wsgi.py

[Sun Jan 05 19:58:49.650548 2020] [core:notice] [pid 1993:tid 
140438837296064] AH00051: child pid 2002 exit signal Segmentation fault 
(11), possible coredump in /etc/apache2

[Sun Jan 05 19:58:50.731314 2020] [wsgi:error] [pid 2004:tid 
140438585472768] [client 161.149.102.22:2460] Truncated or oversized 
response headers received from daemon process 'arches': 
/Projects/ssl/hpla/hpla/wsgi.py, referer: 
https://historicplacesla.lacity.org/


I went back to my new environment to double-check psycopg2 and found:

(ENV)hpla:/Projects/ssl$ pip freeze | grep psycopg2

DEPRECATION: Python 2.7 nag

psycopg2==2.8.3

psycopg2-binary==2.7.4

I figured the binary was the problem and uninstalled that. Nope. 
So I uninstalled/reinstalled psycopg2 and see that psycopg2==2.8.3 and no 
binary is listed. Nope.  
Just because, I restarted apache2. Nope. The error regarding truncated or 
oversized response headers remains and there is no coredump. 
I found a suggestion online that I should add  WSGIApplicationGroup 
%{GLOBAL} to my config file. Nope. 

I see other suggestions, like switching from the system mod-wsgi to the 
Python package and the psycopg2-binary package, but still hope for further 
guidance here from anyone successfully serving arches with HTTPS on Ubuntu 
18.04. Is mod-wsgi 4.5.17 a problem?
 
Thanks,
Martha
 

On Saturday, December 28, 2019 at 6:38:02 AM UTC-8, Adam Cox wrote:
>
> Hi Martha, the daemon process error has to do with your config file, 
> you'll just need to make sure the arches process is created before you 
> reference it.
>
> The other issue, the truncated........ Is much trickier, but has to do 
> specifically with the version of psycopg2 (a python library in your virtual 
> environment) that you have installed. I put this comment on a PR a long 
> time ago, which gives a little context: 
> https://github.com/archesproject/arches/pull/4965#issuecomment-521806491
>
> Ultimately, I recommend creating a new virtual environment, pip installing 
> everything as normal, then
>
> Pip uninstall psycopg2
> Pip install psycopg2==2.8.3
>
> You can then point the apache configs at the new environment and it should 
> solve this problem.
>
> Good luck,
> Adam
>
> On Fri, Dec 27, 2019, 6:38 PM Martha S <[email protected] <javascript:>> 
> wrote:
>
>> I feel I'm sooo close to implementing secured access to Arches and need a 
>> little help to get over the top, please. I'm running Ubuntu 18.04. My 
>> certificate is in and working.
>>
>> I tried making a copy of 000-default.conf (with --preserve=all), changing 
>> the port to 443, and adding these lines as directed by the CA:
>>
>> ServerName historicplacesla.lacity.org
>> SSLEngine on
>>
>> SSLCertificateFile XXX.crt
>> SSLCertificateKeyFile XXX.key
>>
>> When I tried to restart Apache2 after enabling SSL, the complaint was 
>> 'Name duplicates previous WSGI daemon definition', so I commented it out in 
>> default-ssl.conf and tried again. Apache started, but I still can't launch 
>> Arches. The browser gets an error 500 and the Arches error.log has the 
>> entry: 
>>
>> 'Daemon process called 'arches' cannot be accessed by this WSGI 
>> application: /Projects/prod/hpla/hpla/wsgi.py, referer: 
>> https://historicplacesla.lacity.org/arches.' 
>>
>> I get the same error if I try with http. My next effort was to rename my 
>> 000-default.conf and uncomment the line in default-ssl.conf. Now, in 
>> addition to the error above, I get 
>>
>> '[wsgi:error] Truncated or oversized response headers received from 
>> daemon process 'arches': /Projects/prod/hpla/hpla/wsgi.py
>> [core:notice] AH00051: child pid 83357 exit signal Segmentation fault 
>> (11), possible coredump in /etc/apache2
>>
>> There is no new file, dump or otherwise in /etc/apache2.
>>
>> For the moment, I've disabled SSL, renamed the two configuration files so 
>> only 000-default.conf is loaded, restarted Apache2 and things are running 
>> as usual. I get that it is at least partly an access rights issue. 
>> historicplacesla.lacity.org has been added to ALLOWED_HOSTS in 
>> settings.py.
>>
>> What do I still need to do to what to deal with these errors? 
>>
>> Thanks so much and happy new year to all,
>> Martha
>>
>>
>>
>> -- 
>> -- To post, send email to [email protected] <javascript:>. To 
>> unsubscribe, send email to [email protected] <javascript:>. For 
>> more information, visit 
>> https://groups.google.com/d/forum/archesproject?hl=en
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "Arches Project" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected] <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/archesproject/d5bebd17-14c3-4925-b5e7-ba5128d446d0%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/archesproject/d5bebd17-14c3-4925-b5e7-ba5128d446d0%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
-- To post, send email to [email protected]. To unsubscribe, send 
email to [email protected]. For more information, 
visit https://groups.google.com/d/forum/archesproject?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Arches Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/archesproject/47ab9eed-1363-4ac0-8530-82326fb29303%40googlegroups.com.

Reply via email to