H-Sphere Documentation Sysadmin Guide

For more information contact us at info@psoft.net

Understanding Control Panel Server Configuration

 

H-Sphere Control panel is represented by Apache/JServ combination. Separate instance of Apache is running on ports 8080 and 8443 (https), under user cpanel.

Configuration files:

a) By default, user cpanel is located in the directory /hsphere/local/home/cpanel
In it, you will find the followind files and directories:
apache - apache installation
apache/etc - apache config files
apache/etc/httpd.conf - apache httpd configuration
apache/etc/jserv/jserv.conf - jserv conf file
apache/etc/jserv/jserv.properties - jserv properties file
apache/etc/jserv/zone.properties - jserv zone file
shiva - H-Sphere related binary and config files
shiva/psoft_config - H-Sphere config files
shiva/psoft_config/hsphere.properties - H-Sphere config file
shiva/psoft_config/HS_VERSION - file that contains version number of H-Sphere
shiva/shiva-templates - H-Sphere templates/UI, httpd root for the apache server.
shiva/shiva-templates/index.html - Redirect to control panel, served when http://cp.domain.com:8080/ is accessed
shiva/custom/templates - This is the directory where H-Sphere custom templates should be placed.
shiva/custom/images - This is the directory for custom images, such as icons, etc.
shiva/custom/bundles - This is the directory for custom bundles, such as language files, etc.

/hsphere/shared/SiteStudio/psoft_config/masonry.properties - SiteStudio config file (can be on a different server)

b) H-Sphere config file - hsphere.properties
The file should be located at ~cpanel/shiva/psoft_config/hsphere.proper
URL configuration - url by which H-Sphere is called.
CP_HOST = cp.domain.com -- host name
CP_PORT = 8443 -- port
CP_PROTOCOL=https:// -- protocol
CP_URI = /psoft/servlet/psoft.hsphere.CP

This is not the only place were those settings have to be altered.
URI cannot be changed at this moment.
Make sure that dns is properly configured if you want to change domain.
Make sure to alter apache if you want to change domain and port.

Database settings (it should be enough for you to connect to db):
DB_DRIVER = org.postgresql.Driver
DB_URL = jdbc:postgresql://127.0.0.1/hsphere -- database name, usually hsphere
DB_USER = wwwuser -- db user name - usually wwwuser
DB_PASSWORD = your_db_password -- db user password
DB_NEWID = SELECT nextval(''{0}'')

Log file:
log4j.appender.A1.File=/var/log/hsphere/hsphere.log -- location of the log file.

Cron jobs

There are several cron jobs that are executed by H-Sphere:
Accounting - recurrent billing process, tag ACCOUNTING
OverLimitCron - checks that the account does is not going over the limmit, tag OVERLIMIT
ResellerCron - billing for resellers, tag RESELLER
TrialCron - to automatically suspend trial accounts, tag TRIAL
RevenueCron - for calculationg billing summary info, tag REVENUE

All those cron processes use the following table in the H-Sphere database:

CREATE TABLE last_start (
        name  varchar(20) NOT NULL PRIMARY KEY,
        value timestamp,
        last_user int8
);

When H-Sphere is restarted, those values are read from this table for each cron.
Field name - corresponds to cron tag
Field value - last time that cron was executed
Field last_user - user_id of the last user that was calculated with the cron (used only for accounting and overlimit).
Next time cron will be started on value+1 day, the value will be reset to the new one once new cron process is started.
To change the time when it different cron processes are started, change value field for the given cron, and restart control panel.



Home   Products   Services   Partners   Support   News   Contact   Forum
© Copyright 1998-2003. Positive Software Corporation.
All rights reserved.