1. Overview of GlassFish Server Administration
Default Settings and Locations
Instructions for Administering GlassFish Server
Domains for Administering GlassFish Server
Domain Administration Server (DAS)
Creating, Logging In To, and Deleting a Domain
To Create a Domain From a Custom Template
Starting and Stopping a Domain
Configuring a DAS or a GlassFish Server Instance for Automatic Restart
To Configure a DAS or an Instance for Automatic Restart on Windows
To Configure a DAS or an Instance for Automatic Restart on Linux
To Configure a DAS or an Instance for Automatic Restart on Oracle Solaris
To Prevent Service Shutdown When a User Logs Out on Windows
Suspending and Resuming a Domain
Setting Up Automatic Backups of a Domain
To Create a Backup Configuration
To Enable a Backup Configuration
To Disable a Backup Configuration
To Delete a Backup Configuration
Re-Creating the Domain Administration Server (DAS)
To Switch a Domain to Another Supported Java Version
To Change the Administration Port of a Domain
4. Administering the Virtual Machine for the Java Platform
6. Administering Web Applications
7. Administering the Logging Service
8. Administering the Monitoring Service
9. Writing and Running JavaScript Clients to Monitor GlassFish Server
10. Administering Life Cycle Modules
11. Extending and Updating GlassFish Server
Part II Resources and Services Administration
12. Administering Database Connectivity
13. Administering EIS Connectivity
14. Administering Internet Connectivity
15. Administering the Object Request Broker (ORB)
16. Administering the JavaMail Service
17. Administering the Java Message Service (JMS)
18. Administering the Java Naming and Directory Interface (JNDI) Service
19. Administering Transactions
Creating backups is part of regular administrative duties, and GlassFish Server supports two ways to perform this duty:
Automatically on a scheduled basis, as described in Setting Up Automatic Backups of a Domain
Manually, as described in this section
The following topics are addressed here:
Use the backup-domain subcommand in local mode to make a backup of a specified domain.
When you use the backup-domain subcommand, GlassFish Server creates a ZIP file backup of all the files and subdirectories in the domain's directory, domain-root-dir/domain-name, except for the backups subdirectory.
The backup-domain subcommand provides several options to meet particular needs, including:
--backupdir to specify a directory in which to store the backup instead of the default domain-root-dir/domain-name/backups.
--description to provide a description of the backup to be stored in the backup itself.
The backup-domain subcommand operates only when the domain is stopped or suspended.
Start or resume the domain.
Example 3-25 Backing Up the Default Domain
This example makes a backup of the default domain, domain1, storing the backup file in /net/backups.example.com/glassfish:
asadmin> backup-domain --backupdir /net/backups.example.com/glassfish domain1 Backed up domain1 at Mon Jan 17 08:16:22 PST 2011. Command backup-domain executed successfully
See Also
You can also view the full syntax and options of the subcommand by typing asadmin help backup-domain at the command line.
Use the restore-domain subcommand in local mode to use a backup file to restore the files and subdirectories in a specified domain's directory.
The restore-domain subcommand can use backup files created by the backup-domain subcommand and by automatic backup configurations, both full backups and configuration-only backups. Automatic backup configurations are available only in Oracle GlassFish Server.
The restore-domain subcommand operates only when the domain is stopped.
To determine whether the domain is running, use the list-domains(1) subcommand, as described in To List Domains.
To stop the domain, use the stop-domain(1) subcommand as described in To Stop a Domain.
Example 3-26 Restoring the Default Domain
This example restores files for the default domain, domain1, from the most recent backup stored in a specified backup directory:
asadmin> restore-domain --backupdir /net/backups.example.com/glassfish domain1 Restored the domain (domain1) to /home/user1/glassfish3/glassfish/domains/domain1 Command restore-domain executed successfully.
See Also
You can also view the full syntax and options of the subcommand by typing asadmin restore-domain --help at the command line.
Use the list-backups subcommand in local mode to display information about backups of a specified domain stored in a specified backup directory.
The list-backups subcommand provides several options to meet particular needs, including:
--backupdir to specify a directory where backups are stored instead of the default domain-root-dir/domain-name/backups.
Example 3-27 Listing Backups of the Default Domain
This example lists the backups of the default domain, domain1, that are stored in the /net/backups.example.com/glassfish directory:
asadmin> list-backups --backupdir /net/backups.example.com/glassfish domain1 CONFIG USER BACKUP DATE FILENAME user1 Mon Jan 17 08:16:22 PST 2011 domain1_2011_01_17_v00001.zip monthly-full user1 Wed Dec 01 00:00:00 PST 2010 domain1_2010_12_01_v00001.zip monthly-full user1 Sat Jan 01 00:00:03 PST 2011 domain1_2011_01_01_v00001.zip monthly-full user1 Tue Feb 01 00:00:01 PST 2011 domain1_2011_02_01_v00001.zip Command list-backups executed successfully.
Note that this listing includes backups created automatically by a backup configuration. This feature is available only in Oracle GlassFish Server.
See Also
You can also view the full syntax and options of the subcommand by typing asadmin help list-backups at the command line.