Koozali.org: home of the SME Server

server-manager Failure After 9 Install and Restore

Offline ylluminate

  • *
  • 39
  • +0/-0
server-manager Failure After 9 Install and Restore
« on: September 13, 2014, 11:00:47 PM »
Having some real headaches here after I installed 9 and performed a restore from the USB backup.  Whenever I attempt to hit the `/server-manager` now, I end up not getting a connection to the server via https and http just get's refused.  I'm not seeing any appreciable errors in /var/log/httpd-admin or /var/log/httpd except that in httpd log folder there is the following continually repeating in the error_log:
Code: [Select]
[Sat Sep 13 16:55:42 2014] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
[Sat Sep 13 16:55:42 2014] [warn] RSA server certificate CommonName (CN) `gateway.sub.domain.tld' does NOT match server name!?
[Sat Sep 13 16:55:42 2014] [error] Illegal attempt to re-initialise SSL for server (theoretically shouldn't happen!)

If I do it also as root on localhost I also get:
Code: [Select]
Unable to retrieve http://localhost/server-manager:
Connection refused
[ OK ]

One other odd thing I noted is that I cannot log in as admin now directly.  I have to ssh in as root and then su to admin to get the admin menu system.  Not a big deal, but wanted to make sure that it is not another issue going on.

The main problem, obviously, is no longer being able to get into `server-manager` and I need to get this resolved as soon as possible.

Offline Stefano

  • *
  • 10,839
  • +2/-0
Re: server-manager Failure After 9 Install and Restore
« Reply #1 on: September 14, 2014, 07:50:11 PM »
this should not happen.. please raise a bug asap, with all the details needed to describe what you did and how you did it

thank you

guest22

Re: server-manager Failure After 9 Install and Restore
« Reply #2 on: September 14, 2014, 07:57:02 PM »
The main problem, obviously, is no longer being able to get into `server-manager` and I need to get this resolved as soon as possible.

Try regenerating the certificates after restore.

http://wiki.contribs.org/Certificates_Concepts

Stefano is right, it should not happen. But I sense that it is expected that staff should be able to work this Monday morning.

Offline ylluminate

  • *
  • 39
  • +0/-0
Re: server-manager Failure After 9 Install and Restore
« Reply #3 on: September 14, 2014, 08:09:46 PM »
@RequestedDeletion, this was using the stock cert that came with the 8.x installation a few years ago.  What steps, as per those instructions, do I follow to simply recreate the cert for sme server?  So far, upon following the first set of steps I found that I continue getting the same error so I figured I should get some clarification here.


guest22

Re: server-manager Failure After 9 Install and Restore
« Reply #4 on: September 14, 2014, 08:11:19 PM »
I guess you can reach the console and login as root?

Then follow these steps: http://wiki.contribs.org/Certificates_Concepts#How_to_change_your_certificate

guest22

Re: server-manager Failure After 9 Install and Restore
« Reply #5 on: September 14, 2014, 08:15:30 PM »
This one looks a bit the same...

http://bugs.contribs.org/show_bug.cgi?id=5022

Offline ylluminate

  • *
  • 39
  • +0/-0
Re: server-manager Failure After 9 Install and Restore
« Reply #6 on: September 14, 2014, 08:16:20 PM »
@Stefano: As per your request, created here.  Unfortunately I am on a time limit with this server and will have to reinstall and manually reconfigure this server within the next couple of hours due to needing to have it back in production by this evening, so whatever logs or other information that may be needed to squash this bug, please let me know sooner than later since I have to move forward with this machine in some fashion to have it back up.

@RequestedDeletion: that is what I did and it did not seem to resolve the issue.

guest22

Re: server-manager Failure After 9 Install and Restore
« Reply #7 on: September 14, 2014, 08:20:46 PM »
Your certificates are wrong and that is being detected. Hence ssl access is being refused. Can you access server manager via the console application?

Offline ylluminate

  • *
  • 39
  • +0/-0
Re: server-manager Failure After 9 Install and Restore
« Reply #8 on: September 14, 2014, 08:22:38 PM »
@RequestedDeletion: unfortunately no, console is likewise refused as per explained in my initial post.

guest22

Re: server-manager Failure After 9 Install and Restore
« Reply #9 on: September 14, 2014, 08:24:41 PM »
Do the listing of /home/e-smith/ssl* directories tell you something?

guest22

Re: server-manager Failure After 9 Install and Restore
« Reply #10 on: September 14, 2014, 08:28:27 PM »
sorry, together with the command 'config show DomainName'

guest22

Re: server-manager Failure After 9 Install and Restore
« Reply #11 on: September 14, 2014, 08:34:51 PM »
What if you do (after changing certificates)

expand-template /etc/httpd/conf/httpd.conf

and then restart apache

service httpd-e-smith restart
service httpd-admin restart

?

edit: typo

Offline ylluminate

  • *
  • 39
  • +0/-0
Re: server-manager Failure After 9 Install and Restore
« Reply #12 on: September 14, 2014, 08:46:20 PM »
@RequestedDeletion: So here is what I have done and the results:

$ config setprop modSSL CommonName gateway.sub.domain.tld
$ expand-template /home/e-smith/ssl.crt/crt
$ expand-template /home/e-smith/ssl.key/key
$ signal-event domain-modify
$ signal-event email-update
$ config show DomainName
    Output: DomainName=sub.domain.tld

$ expand-template /etc/httpd/conf/httpd.conf
$ service e-smith restart
    Output: e-smith: unrecognized service

$ service httpd-admin restart
    Output: Restarting httpd-admin                                     [  OK  ]

$ su admin
    Output: Elinks starts request for https://gateway/server-manager   
    Output: Unable to retrieve http://localhost/server-manager: Connection refused
    # Same happens for `localhost` in place of `gateway` when `elinks` manually executed as root.

guest22

Re: server-manager Failure After 9 Install and Restore
« Reply #13 on: September 14, 2014, 08:49:47 PM »
$ service e-smith restart
    Output: e-smith: unrecognized service

That was my bad.

guest22

Re: server-manager Failure After 9 Install and Restore
« Reply #14 on: September 14, 2014, 08:51:37 PM »
$ config setprop modSSL CommonName gateway.sub.domain.tld
$ config show DomainName
    Output: DomainName=sub.domain.tld

These domains are not the same...