Unicon: Introduction

From The Uniform Server Wiki
Revision as of 17:04, 23 November 2008 by Ric (talk | contribs) (New page: {{Uc nav Unicon}} '''Unicon Introduction''' leftUnicon started life as a two-button controller with auto-drive detection to control Uniform Server 3.5-Apollo. Ov...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

MPG UniCenter

MPG UniCenter

Unicon

Unicon Introduction

Unicon started life as a two-button controller with auto-drive detection to control Uniform Server 3.5-Apollo. Over a period of time I added a few extra features that are active only when certain conditions arise.

Main objective was to remove any dependencies such as batch files and additional programs more importantly have a minimal interface.

The following attempts to provide enough information so you can tailor it to you own requirements.

The program is written in C and complied with lcc-win32 a powerful but easy to use program.

Not being a programmer but a code hacker expect a basic explanation of code, what’s important is to know what terms to search for in order to find a detailed explanation or a solution to problems you may encounter with any modifications. To be honest most coding problems have already been solved, it’s just a matter of refining these solutions to meet your coding requirements.

This program does contain some original code simply because I could not find a solution to meet my requirements that said I do not reinvent the wheel I am more than happy to use existing code. Anyway enough of this digression let’s get back to this little utility.

Top

Buttons

Well they do what they say with the exception of test, this has a few hidden features.

  1. Initially run reports status of the server ports for Apache and MySQL. Ports are extracted from the configuration files.
  2. This is followed by an option to perform a syntax check on Apache,s configuration file. Any errors prevents Apache running.
  3. Start MySQL and an additional option is provided allowing you to start a command window to run mysqladmin.exe.

Top

Diagnostics

The program is designed to prevent a user (me) doing something silly, Apache and MySQL buttons toggle hence cannot run two instances of the same program.

Then again can the programs be run! Clicking a start button firsts checks if the port is in use. If occupied kills the button and provides useful information to a user in the form of a pop-up.

Apanel and phpMyAdmin buttons are disabled until conditions are appropriate for their correct operation.

Run the utility from an unrelated location, kills itself gracefully, well after providing some information.

All of the above are hidden features activated only when appropriate.

Top

Bug Corrections

Know minor bugs in US3.5 are catered for allowing transparent operation this requires a small amount of extra code.

Top

Remote operation

The utility implements a form of push and pop, saves the caller address on completion restores this address. This allows the utility to be run by another program from any location. This can be a batch file on a different drive or a USB memory stick start-up ini file.

Top

Multi-Servers

To run more than one instance of Apache requires renaming the Apache executable file. This needs to be picked up by Unicon, to communicate a name change Unicon uses a configuration file, note this file is not required for a default installation of Uniform Server.

Top

Cosmetics

It’s easy to use the built-in win32 API buttons however these have the old chunky win95 style. I decided to replace these with a more modern version seen on most Web pages as a rollover link!

Top

Summary

I hope the above has wetted your appetite for more informationfollow the appropriate links; first I cover installation, running on a USB memory stick and multi-servers.

The remainder of this series covers creating a new project on lcc-win32 allowing you to compile and make modifications. To help in this process I have provided some code snippets.


Top


Ric