Basic System Administration
Overview of the Facets Systems
Before we proceed with the discussion of the administration of a Facets System, an overview of the various components of a working Facets System is necessary. Facets is a powerful persistence environment, and hence consists of a number of components which integrate seamlessly to provide the persistence mechanism that it does.We will describe each portion of the Facets System using the diagram below as a reference:![]() |
| Figure : Facets Components |
At the file level a Facets repository consists of at least one, but potentially dozens (depending on the size of the repository in question) of EXTENTS. Extents map to either disks, partitions on those disks, or files. Depending upon the performance requirements of a system, extents will be created using either partions, disks or file system files. File systems files make partitions simpler to manage, but because many file systems were designed in the days of relatively small disks they often impose unacceptable size and performance limits. For this reason high performance Facets systems typically allocate entire disks or partitions on disks as extents and allow Facets to read and write the disks directly. An extent has an internal structure which allows PAGES (which are the chunks memory moved between the disk and main memory) to be managed effectively, and consist of a number of pages, some of which are used and some unused which are managed on free lists.
The core of any Facets system is the SPC (SHARED PAGE CACHE) which holds cached pages. The SPC loads the pages from the extents, and makes use of a number of PAGE SERVERS, which are used to manage the transfer of changed pages back to disk. The STONE which also plays an important role, is responsible for managing transactions (i.e. ensuring consistency) and writing out COMMIT RECORDS to the TRANSACTION LOG. The SAP (SYSTEM AGENT PROCESS) does some initial mediation between a SESSION and the Stone. The GARBAGE COLLECTOR works hand in hand with the extents and the SPC, to ensure that both short term garbage (the garbage generated when persistent objects are updated or created) and long term garbage (garbage that is created when modifications to the repository result in objects that were referenced becoming unreferenced) is collected and the pages used by this garbage are returned to the system.
The GNS is a Facets JVM that keeps references to all the System Processes (such as the SAP and the GC). All other application JVMs make use of the services of the System Agent (SAP), the Shared Page Cache (SPC) , the Garbage Collector and the Stone to perform their tasks. When developing code you do not need to pay attention to either the Stone, the GC (as we call the Garbage Collector) or any other system object in the Facets environment, you just persist and retrieve your objects using Sessions and Transactions and the Facets processes will handle all the dirty work for you.
Using the Console
Many of us who are UNIX veterans find it easier to issue commands to the system from a UNIX shell. Not everyone enjoys working this way, you might find that you prefer to use the Facets Console to perform your system administration. Before attempting to start the Facets console, please ensure that the GNS is running. See the example below for starting the GNS from scratch
![]() |
| Figure : Starting the GNS from scratch |
Once the GNS is running the console can be started by issuing the command "gsjconsole". If everything is functioning correctly you should be rewarded with a window that looks similar to the one below
![]() |
| Figure : The Facets Console |
At this point click the Login button and the console will change to display the current state of the Facets environment. Some of the items are explained in the Figure below:
Figure : The Facets Console Explained
For more information on using the console, refer to the online or PDF manuals regarding the Console. The Console is an extremely powerful and useful piece of software and contains many settings that allow you to tune the behavior of Facets. If you plan on using Facets for important projects, it is worthwhile spending some time understanding the myriad of options that the Console allows you to work with.
Finding the status of Facets processes
The console is a simple way to ascertain the status of the various processes and daemons that constitute a working Facets environment. For those who prefer to use the command line, Facets provides a command line utility, called "gslist", that shows all of the processes that are currently running.
Starting and Stopping Facets
Starting Facets is not a complex task, but there are a few steps that must be followed in order to ensure a successful boot of a Facets repository. The GNS must be started, and then the system in question must be started. To start the GNS follow the directions given above, once the GNS is started you can start your system by using the following command (ensure that you are in the same directory that you specified when installing the system, or where you created your system), substitute the name you gave your system for systemName.
>gsjadmin start system systemName
You can also start a system using the Console. Start the Console and login, your Console window should look similar to the one below, select the name of your system, and click the Start button on the Control tab as shown below:
Figure : Starting a System using the Console
Similary the Console can be used to stop a system using the Stop button once the correct system name has been selected. Once you have shut a system down, it is important that you close the Console down, and then shutdown the GNS. The GNS can be shutdown by issuing the command, "gsjadmin stop gns", additionally a system can be shutdown from the command line by issuing the command, "gsjadmin stop system systemName". Note that the GNS must only be shutdown once all other running systems have been shutdown. Please remember that failure to shut the GNS down may prevent a Facets system from booting correctly.


