Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 27th April 2006, 15:24
Hans Hans is offline
Join Date: Dec 2005
Location: Montfoort, The Netherlands
Posts: 2,263
Thanks: 216
Thanked 649 Times in 295 Posts
Default Server Monitoring With munin And monit - Page 2


On the Debian server i want to monitor there is ISPConfig installed.
Can i enable SSL and create a certicate via ISPConfig in stead of doing this:

Now we create the certificate like this:

Now we must create the file /var/www/www.example.com/web/monit/token and write some random string into it:

mkdir /var/www/www.example.com/web/monit
echo "hello" > /var/www/www.example.com/web/monit/token

Next we create the pem cert (/var/certs/monit.pem) we need for the SSL-encrypted monit web interface:

mkdir /var/certs
cd /var/certs

We need an OpenSSL configuration file to create our certificate. It can look like this:

vi /var/certs/monit.cnf

# create RSA certs - Server

RANDFILE = ./openssl.rnd

[ req ]

default_bits = 1024

encrypt_key = yes

distinguished_name = req_dn

x509_extensions = cert_type

[ req_dn ]

countryName = Country Name (2 letter code)

countryName_default = MO

stateOrProvinceName = State or Province Name (full name)

stateOrProvinceName_default = Monitoria

localityName = Locality Name (eg, city)

localityName_default = Monittown

organizationName = Organization Name (eg, company)

organizationName_default = Monit Inc.

organizationalUnitName = Organizational Unit Name (eg, section)

organizationalUnitName_default = Dept. of Monitoring Technologies

commonName = Common Name (FQDN of your server)

commonName_default = server.monit.mo

emailAddress = Email Address

emailAddress_default = root@monit.mo

[ cert_type ]

nsCertType = server

Now we create the certificate like this:

openssl req -new -x509 -days 365 -nodes -config ./monit.cnf -out /var/certs/monit.pem -keyout /var/certs/monit.pem
openssl gendh 512 >> /var/certs/monit.pem
openssl x509 -subject -dates -fingerprint -noout -in /var/certs/monit.pem
chmod 700 /var/certs/monit.pem

Reply With Quote
Sponsored Links


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +2. The time now is 13:47.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.