How to delete sites manually with Ensim Pro (Linux) when normal deletion fails

This solution was given to us by the Ensim staff, as a paid support request. Hopefully, if you’re reading this, you will not have to buy a support ticket:

To delete the sites manually you will have to do the following:

1. Find the siteID.
sitelookup -d domainname /etc/virtualhosting/mappings/
grep siteID *
3. Remove the entry from domainmap file and regenerate the domainmap.db using
makemap hash domainmap.db < domainmap
4. cd /home/virtual/
rm -rf siteID/
5. Remove any apache entries.
cd /etc/httpd/conf/
rm -rf siteID siteID.preview
cd virtual
rm -f siteID
cd ../virtual.preview
rm -f siteID
6. Restart httpd.
service httpd restart
7. Remove cron jobs
cd /etc/cron.weekly/
rm -f 0virtualhosting.siteID
cd ../cron.daily/
rm -f 0virtualhosting.siteID

How to fix mod_perl with Apache2 on Ensim 3.7.x and Ensim 4.0.x?

Fixing mod_perl

Based on Ensim Knowledge ID:964

mod_perl fails with Apache 2.0 on Ensim Pro/Basic


When using Apache 2.0 with Ensim Pro/Basic, mod_perl no longer functions.  This is due to improper module references.  Ensim will provide an official fix in an upcoming Erratum.  A symptom of this error will be the following error information in /var/log/httpd/error_log

[Wed May 19 13:42:14 2004] [error] failed to resolve handler `Apache::Registry’
[Wed May 19 13:42:14 2004] [error] [client] Can’t locate loadable object for module Apache::Constants in @INC (@INC contains: /usr/lib/perl5/5.8.1/i386-linux-thread-multi /usr/lib/perl5/5.8.1 /usr/lib/perl5/site_perl/5.8.1/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.1 /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.1/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.1 /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.1/i386-linux-thread-multi /usr/lib/perl5/5.8.1 . /etc/httpd/ /etc/httpd/lib/perl) at /usr/lib/perl5/site_perl/5.8.1/i386-linux-thread-multi/ line 14
Compilation failed in require at /usr/lib/perl5/site_perl/5.8.1/i386-linux-thread-multi/ line 6.
BEGIN failed–compilation aborted at /usr/lib/perl5/site_perl/5.8.1/i386-linux-thread-multi/ line 6.
Compilation failed in require at /usr/lib/perl5/site_perl/5.8.1/i386-linux-thread-multi/Apache/ line 2.
BEGIN failed–compilation aborted at /usr/lib/perl5/site_perl/5.8.1/i386-linux-thread-multi/Apache/ line 2.
Compilation failed in require at (eval 1) line 3.

Applies to:



 Ensim Pro, Ensim Basic



 3.7.x, 4.0



 Red Hat Enterprise, Fedora


mkdir /root/working
cd /root/working
gunzip mod_perl.pyc.gz
cp /usr/lib/python2.2/site-packages/vh3/modules/mod_perl.pyc /root/working/mod_perl.pyc.backup
cp mod_perl.pyc /usr/lib/python2.2/site-packages/vh3/modules/mod_perl.pyc
service webppliance restart
for i in $(sitelookup -a site_handle); do EditVirtDomain $i; done
rpm -e mod_perl-httpd13

How to look up admin info about a site?

usage: sitelookup [ -w  ] [ -s  ] [ -d  ]

[ -u ] [ -a ]
[ domain,wp_user,site_handle,site_root,site_admin ]

-w:wp_user is the top level unix user (admin1)
-s:site_handle is the site equivalent of wp_user (site1)
-d:domain is the hostname for a site (
-u:site_admin is the username for a site (bob)
-a:returns info on all sites

E.g. sitelookup -d site_handle

How to make a site IP based Solution:

A) Converting a Name-based site to a ip-based site
login as root and run the command:

EditVirtDomain -c ipinfo,namebased=0,nbaddrs=\[\],ipaddrs=\[new_ip_addr\] domain_name
new_ip_addr is the new ip address
domain_name is the domain name of the site

e.g. EditVirtDomain -c ipinfo,namebased=0,nbaddrs=\[\],ipaddrs=\[\]

B) Converting an ip-based site to a Name-based site

login as root and run the command:

EditVirtDomain -c ipinfo,namebased=1,ipadrs=\[\] domain_name
domain_name is the domain name of the site

e.g. EditVirtDomain -c ipinfo,namebased=1,ipaddrs=\[\]

Can’t edit PostgreSQL datasource in CFMX

The original URL where we found this solution is here: PostgreSQL DSN Config Bug

Workaround for PostgreSQL DSN Config Bug

How to fix a bug for PostgreSQL Data Source configuration in the ColdFusion MX Administrator.

The problem is that when configuring a PostgreSQL DSN according to the instructions in this TechNote, if you choose a Driver Name field of PostgreSQL, then that will trigger ColdFusion to invoke a handler template of postgresql.cfm. This handler template is defined in the configuration file neo-query.xml in ColdFusion MX’s lib directory. At one time the ColdFusion MX Administrator was going to provide a PostgreSQL JDBC driver out of the box, and that was partially implemented. However, the postgresql.cfm handler file was never implemented or even created. The result is that after first creating the data source when you return to edit it again ColdFusion will recognize the Driver Name of PostgreSQL and attempt to trigger the postgresql.cfmhandler. This causes the error:

"File not found: /CFIDE/administrator/datasources/postgresql.cfm 
The specific sequence of files included or processed is: 
C:\CFusionMX\wwwroot\CFIDE\administrator\datasources\postgresql.cfm "

The author discovered the solution on a CFTALK thread. The solution in the CFTALK thread shows how to change the handler reference from postgresql.cfm to default.cfm. Then restart ColdFusion MX. You will then be able to edit the data source correctly. Click Here for the interactive RoboHelp (Demo).
Pete Freitag pointed out in a comment that a better solution would be to find the default.cfm then make a copy named postgresql.cfm.

Bynari: Configuration files to change

[line 10] $isHost = '<server>';

[replace with correct IP i.e.]
           <item   option="myhostname" >
           <item   option="mydomain" >
           <item   option="myorigin" >
           <item   option="mydestination" >
           <item   option="mynetworks" >
           <item   option="inet_interfaces"   hidden="1" >
           <item   option="relay_domains" >
           <item   option="#relayhost" >
           <item   option="ldapsource_server_host"   hidden="1" >
           <item   option="Listen" >
           <item   option="LDAPServer"   hidden="1" >
           <item   option="SocketBindTight"   hidden="1" >
           <template   name="proftpd" >

[replace with correct IP]
start-stop-daemon --start --pidfile /var/lib/ --exec /usr/lib/openldap/slapd -- -h "ldap:// ldaps://"
[in vi you would do ":%s/69.250/69.232/g"]

  imap          cmd="imapd" listen="" prefork=0
  pop3          cmd="pop3d" listen="" prefork=0
  imaps         cmd="imapd -s" listen="" prefork=0
  pop3s         cmd="pop3d -s" listen="" prefork=0
  sieve         cmd="timsieved" listen="" prefork=0
  lmtpunix      cmd="lmtpd" listen="/var/imap/socket/lmtp" prefork=0

ldap_servers: ldap://


<IfModule mod_ssl.c>
AddType application/x-x509-ca-cert .crt
AddType application/x-pkcs7-crl    .crl
SSLPassPhraseDialog builtin
SSLSessionCache shm:logs/ssl_scache(512000)
SSLSessionCacheTimeout  300
SSLMutex  sem
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
SSLLog      logs/ssl_engine_log
SSLLogLevel info

#DefaultServer on
SocketBindTight on
DefaultRoot /home/ftp
<Directory /*>
  <Limit WRITE>
<Directory /home/ftp/freebusy>
  <Limit READ WRITE>
  <Limit STOR>
  Port 21

# Generated by Bynari InsightServer 4.0, 03/11/03 14:49:11
# Any changes to this file will be lost
myhostname =
mydomain = $myhostname
myorigin = $myhostname
mydestination = $myhostname,$mydomain
mynetworks = $myhostname,
relay_domains = $mydestination
inet_interfaces = $myhostname
#relayhost =
soft_bounce = yes
queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/lib/postfix
mail_owner = postfix
local_recipient_maps = $alias_maps ldap:ldapsource
#in_flow_delay = 1s
alias_maps = hash:/etc/mail/aliases
alias_database = hash:/etc/mail/aliases
mailbox_transport = cyrus
#fallback_transport =
#luser_relay =
smtpd_banner = $myhostname ESMTP $mail_name ($mail_version)
local_destination_concurrency_limit = 5
default_destination_concurrency_limit = 20
debug_peer_level = 2
disable_mime_input_processing = no
disable_mime_output_conversion = no
disable_vrfy_command = yes
mime_boundary_length_limit = 2048
mime_nesting_limit = 20
strict_8bitmime = no
strict_mime_domain_encoding = no
#always_bcc =
#hash_queue_depth = 2
hopcount_limit = 50
max_idle = 100s

max_use = 100
delay_warning_time = 0h
initial_destination_concurrency = 2
#maximal_backoff_time = 4000s
maximal_queue_lifetime = 5d
#minimal_backoff_time = 1000s
#queue_run_delay = 1000s
bounce_size_limit = 50000
#default_process_limit = 50
#fork_attempts = 5
#fork_delay = 1a
#deliver_lock_attempts = 5
#deliver_lock_delay = 1s
#duplicate_filter_limit = 1000
#header_size_limit = 102400
#line_length_limit = 2048
#message_size_limit = 10240000
queue_minfree = 0
transport_retry_time = 60s
#stale_lock_time = 500s
allow_percent_hack = yes
#fallback_relay =
ignore_mx_lookup_error = no
smtp_connect_timeout = 30s
smtpd_timeout = 300s
smtpd_tls_auth_only = no
smtpd_tls_cert_file = /etc/ssl/server.pem
smtpd_tls_key_file = /etc/ssl/server.pem
smtpd_tls_CAfile = /etc/ssl/server.pem
smtpd_use_tls = yes
smtpd_enforce_tls = no
smtpd_tls_cipherlist = DEFAULT
smtpd_starttls_timeout = 300s
smtpd_sasl_auth_enable = yes
smtpd_recipient_restrictions = permit_sasl_authenticated, permit_mynetworks, check_relay_domains
virtual_maps = ldap:ldapsource
ldapsource_server_host =
ldapsource_server_port = 389
ldapsource_timeout = 10
ldapsource_query_filter = (|(mailalias=%s)(mail=%s))
ldapsource_result_attribute = mailForward,login
ldapsource_bind = no


How to secure web (admin) connections?

To secure admin server connections that are not running on a secure Apache web server, one can use “stunnel”. For example, to secure Sun One ASP, the following command will do it (to be run on the server to secure):

stunnel -D 7 -P/tmp/ -p  /usr/share/ssl/certs/imapd.pem -d 5143 -r localhost:5100

Of course, you may want to use a more appropriate secure cert.

How to upgrade Chili!ASP (SUN One ASP)

The modules need to be recompiled for the new version of Apache. Here are the steps:

  # mkdir -p /opt/casp/module/linux2_optimized/apache_[version]/eapi
  # cd /opt/casp/module/source/build/
  # apxs -c mod_casp2.c
  # cp /opt/casp/module/linux2_optimized/apache_[version]/eapi
  # ./configure-server

The initial configuration reports:

| SERVER CONFIGURATION COMPLETE                                               |
|  Your server was successfully configured.  Its information is as follows:   |
| Server installed (asp-server-3000):                                         |
|   Associated Web server conf file: /etc/httpd/conf/httpd.conf               |
|   Associated Web server port: 80                                            |
|   Location: /opt/casp/asp-server-3000                                       |
|   Port: 3000                                                                |
|   Samples: Enabled.                                                         |
|   Documentation: Enabled.                                                   |
|   Automatic ASP start on system boot: Enabled.                              |
|   ASP started: Yes.                                                         |
|   ASP start script: /opt/casp/asp-server-3000/startcaspd                    |
|   ASP stop script: /opt/casp/asp-server-3000/stopcaspd                      |
|   ASP general control script: /opt/casp/asp-server-3000/caspctrl            |
|   Samples URL:                 |
|                                                                             |