Complete Contents
Preface
Chapter 1 Installation and Deployment
Chapter 2 Configuring Calendar Server
Chapter 3 Admininistering Calendar Server
Chapter 4 Monitoring the Calendar Server
Appendix A Commnand Line Utilities
Appendix B Monitoring Tools
Appendix C Time Zones
Appendix D Calendar Server LDAP Schema
Index
iPlanet Calendar Server: Administration Guide: Administering Calendar Server
Previous Next Contents Index


Chapter 3 Administering Calendar Server

This chapter describes how to administer and maintain your Calendar Server. It includes the following sections:


Administration Tools
iPlanet Calendar Server provides the following tools for server administration:


Starting and Stopping the Server
You can start and stop the Calendar Server the using:

Using start-cal and stop-cal
The start-cal and stop-cal utilities are located in the server-root/cal/bin directory. Both can be run either on a remote machine or the local machine where the Calendar Server is installed.

To start the Calendar Server, go to the server-root/cal/bin directory and type: start-cal on the command line. For example:

  1. cd /opt/SUNWicsrv/cal/bin
  2. Type: start-cal
To stop the Calendar Server, go to the server-root/cal/bin directory and type: stop-cal on the command line. For example, enter:

  1. cd /opt/SUNWicsrv/cal/bin
  2. Type: stop-cal
Using iplncal.sh (Unix only)
The iplncal.sh program is located in /etc directory. It must be run on the local machine where the Calendar Server is installed.

To start the Calendar Server using iplncal.sh, go to the /etc directory and execute the program from the command line. It takes the following syntax:

iplncal.sh [-h] [-r ServerRoot] start|refresh|stop|list [service]

where:

Using the Services Panel (Windows NT only)
On Windows NT, you can open the Services dialog box from the Control Panel to start and stop the Calendar Server. Refer to the documentation provided with the operating system for instructions.


Using the Command Line Utilities
This section describes the tasks you can perform to administer Calendar Server using the command line utilities. The examples in this section use the most commonly used commands and options. For complete details on the command utilities syntax and usage, see Appendix A, "Command Line Utilities."

This section includes the following topics:

Table 3.1 lists the command line utilities and their purpose.

Table 3.1 Command Line Utilities
Use
To
csbackup
Backup individual calendars, users, and the calendar database.
cscal
Manage calendars and their properties.
cscomponents
Manage components (events and tasks) in a calendar.
csdb
Manage calendar databases.
csexport
Export a calendar in ICAL or XML format.
csimport
Import a calendar in ICAL or XML format.
csrestore
Restore individual calendars, users, and the calendar database.
cssession
Manage user sessions in a Calendar Server.
csstart
Start the Calendar Server.
csstats
Display counters in a Calendar Server.
csstop
Stop the Calendar Server.
cstool
General purpose tool to ping a Calendar Server, to control and monitor the server, and to force the server to refresh its configuration.
csuser
Manage calendar users.

Managing Calendar Users
The following command line utilities let you perform administrative tasks on calendar users.

Use the csuser command line utility to:

Use the cssession command line utility to:

Creating a Calendar User
Use the csuser utility's create command to create a calendar user. For example, to create the calendar user JSmith using the default configuration settings, enter the following command on the command line:

csuser -g John -s Smith -y password -c calJSmith create JSmith

where:

Deleting a Calendar User
Use the csuser utility's delete command to delete a user from the Calendar Server.

Note. The delete command removes all of the user's information from the LDAP server. (Calendar database information can be recovered from a calendar database that has been saved to a backup. See Backing-Up the Calendar Database.)

For example, to delete JSmith from the Calendar Server, enter the following command:

csuser delete JSmith

Enabling a Calendar User
Users are automatically enabled for calendaring when they log on to the Calendar Server for the first time, if they are not already enabled. In such cases, the calendar ID (CALID) of the user's default calendar is the user's USERID. For example, if JSmith is not enabled for calendaring and logs on to the Calendar Server for the first time, the server enables JSmith for calendaring automatically and assigns this user a default calendar with the CALID JSmith. Additionally, the prefix JSmith is assigned to the CALID of each subsequent calendar that JSmith creates. For example, if JSmith, who was enabled automatically, creates a calendar called sports, the assigned CALID is JSmith:sports.

Use the csuser utility's enable command to let a user access Calendar Server data and to assign specific configuration settings such as a user's default calendar. For example, to enable JSmith for calendaring and assign a default calendar, enter the following command:

csuser -c calendarA enable JSmith

The above command enables JSmith to log on to the Calendar Server and creates a default calendar for this user with the CALID calendarA.

Disabling a Calendar User
Use the csuser utility's disable command to prevent a user from logging into the Calendar Server. The disable command prohibits a user from accessing calendar data, but does not remove the user's information from the calendar database.

For example, to disable JSmith from access to Calendar Server data, enter the following command:

csuser disable JSmith

Note. If a user is currently logged on to the Calendar Server, the disable command has no affect until the user logs off. The cssession utility lets you logout a calendar user (see Logging Out a User).

Checking if a User is Enabled
Use the csuser utility's check command to determine if a specified user is enabled to access calendar data. For example, to check if JSmith is enabled for calendaring using the default configuration settings, enter the following command:

csuser check JSmith

Displaying User Information
Use the csuser utility's list command to list all calendar-enabled users or to view the calendar attributes of a specified user.

For example:

To list all users enabled for calendaring, enter the following command:

csuser list

To view all of the calendar attributes of a single user, such as JSmith, enter:

csuser -v list JSmith

Resetting User Calendar Attributes
Use the csuser utility's reset command to restore the default settings for all calendar attributes of a specified user. For example, to reset all calendar attributes of JSmith to the default configuration settings, enter the following command:

csuser reset JSmith

Managing Calendars
This section provides examples that show how to perform administrative tasks on calendar data using the cscal utility's commands. You must run the cscal utility on the local machine where the Calendar Server is installed.

The cscal utility lets you perform the following tasks:

Creating a Calendar
Every calendar has a primary owner and, optionally, other owners. A primary owner can update the events and tasks of a calendar as well as change the properties of a calendar, such as the name, description, additional owners, and display settings. Other owners can update a calendar's events and tasks, but cannot change a calendar's properties.

Calendars can also be private or public. Public calendars can be viewed by any calendar-enabled user, but only the owners can make changes to the calendar. Private calendars can be viewed only by the calendar's owners.

Use the cscal utility's create command to create a calendar. For example, to create a calendar owned by JSmith that can be read by anyone, enter the following command on the command line:

cscal -n exampleA -o JSmith -r public create calA

where:

The following command creates a calendar similar to the example above, but also associates it with the category sports and specifies RJones as an other owner:

cscal -n exampleA -o JSmith -g sports -y RJones -r public create calA

where:

Deleting Calendars
Use the cscal utility's delete command to delete one or more calendars from the Calendar Server.

Note. The delete command removes all of the calendar's information from the calendar database and cannot be undone. (Database information, however, can be recovered from a database that has been saved to a backup. See Backing-Up the Calendar Database.)

The cscal utility lets you delete a single calendar or multiple calendars. For example, to delete a specific calendar with the CALID calendarA, enter the following command:

cscal delete calendarA

The following example deletes all calendars whose primary owner is JSmith:

cscalutil -o JSmith delete

Enabling a Calendar
Use the cscal utility's enable command to allow users to access a calendar. For example, to enable calendarA using the default configuration settings, enter the following command:

cscal enable calendarA

The following command enables all calendars owned by JSmith:

cscal -g John -h airius.com -p 80 enable JSmith

Disabling a Calendar User
Use the cscal utility's disable command to prevent users from accessing one or more calendars. The disable command prohibits users from accessing the calendar's data, but does not remove its information from the calendar database.

For example, to prevent users from accessing calendarA on the Calendar Server, enter the following command:

cscal disable calendarA

To prevent users from accessing all calendars whose primary owner is JSmith, enter the following command:

cscal -o JSmith disable

Modifying Calendar Properties
Use the cscal utility's modify command to change the properties of a calendar. For example, to specify that RJones is an other owner of calendarA and make it readable only by the owners, enter the following command:

cscal -y RJones-r private modify calendarA

where:

Removing Properties from a Calendar

To remove a property value, specify two double quotes ("") as the value of the property option using the modify command.

For example, to remove a description from calendarA:

cscal -d "" modify calendarA

To remove all categories from calendarA:

cscal -g "" modify calendarA

To remove other owners from calendarA:

cscal -y "" modify calendarA

Displaying Calendars
Use the cscal utility's list command to list all calendars, all calendars owned by a user, or all properties of a specific calendar. For example, to list all calendars in the calendar database, enter the following command:

cscal list

To list all calendars owned by JSmith, enter:

cscal -o JSmith list

To list all the properties of a calendar with the CALID calendarA, enter:

cscal -v list calendarA

Resetting Calendar Properties
Use the cscal utility's reset command to restore the default settings for all properties of a specified calendar or all calendars owned by a specified user. For example, to reset all the properties of calendarA to the default configuration settings, enter the following command:

cscal reset calendarA

To reset the attributes of all calendars whose primary owner is JSmith to the default configuration settings, enter the following command:

cscal -o JSmith reset

Managing Calendar Events and Tasks
The cscomponent utility lets you:

You must run the cscomponent utility on the local machine where your Calendar Server is installed.

Use the cscomponent utility's list command to list all events and tasks in a calendar. For example, to list the events and tasks in calendarA, enter the following command:

cscomponents -v list calendarA

where:

Use the cscomponent utility's delete command to remove events and tasks in a calendar. For example, to delete all events and tasks in calendarA occurring in 1998, enter the following command:

cscomponents -s 19980101T000000Z -e 19981231T000000Z delete calendarA

where:

To delete all calendar events and tasks from calendarA, enter:

cscomponents -s 0 -e 0 delete calendarA

where specifying 0 for both start and end dates indicates the beginning and end of time.

Managing Calendar Databases
Use the csdb command line utility to view the statistics of the local calendar databases, and to create, delete, backup and restore the calendar database. You must run the csdb utility on the local machine where your Calendar Server is installed. This section describes how to use csdb to view database statistics and to create and delete databases. For csdb backup and restore options, see Backup and Restore Procedures.

Warning. You must stop the Calendar Server before restoring, creating, or deleting the calendar database.

For example:

To view calendar database status and statistical information, enter the following command:

csdb list

To create a new calendar database if it was accidentally deleted, enter:

csdb create

To delete the calendar database before restoring it from a backup, enter:

csdb delete

To attempt to recover a damaged calendar database in the current directory, enter the following command:

csdb recover

Importing and Exporting Calendar Data
The csexport and csimport command line utilities let you export and import calendar data to a text file using ICAL or XML format.

Note. The csexport and csimport utilities must be run locally on the machine where your Calendar Server is installed and can be executed while the server is either running or stopped.

Exporting Calendar Data
Use csexport to export a calendar to a file. The file name extension (.ics or .xml) that you specify for the output file determines which format is used. For example:

To export the calendar with the CALID JSmithcal in ICAL (text/calendar MIME) format to a file named jsmith.ics, enter the following command:

csexport -c JSmith calendar jsmith.ics

To export the calendar JSmithcal in XML (text/xml MIME) format to a file named jsmith.xml, enter:

csexport -c JSmithcal calendar jsmith.xml

Importing Calendar Data
Use csimport to import calendar data from a file previously saved using the csexport utility. The file name extension of the import file (.ics or .xml) indicates the format in which it was saved. For example:

To import calendar data to the CALID JSmithcal from the file jsmith.ics that was saved in ICAL (text/calendar MIME) format, enter the following command:

csimport -c JSmith calendar jsmith.ics

To import data into the calendar JSmithcal from a file named jsmith.xml that was saved in XML (text/xml MIME) format, enter:

csimport -c JSmithcal calendar jsmith.xml

Note. If the specified CALID already exists, its data is cleared before the new data is imported.


Backup and Restore Procedures
This section describes how to use the command line utilities to backup and restore Calendar Server data:

Note. The csexport and csrestore utilities must be run locally on the machine where Calendar Server is installed and can be executed while the server is running or stopped.

This section includes the following topics:

Backing-Up a Specified Calendar
Use the csbackup utility's calendar command to backup a calendar to a plain text file using ICAL or XML format. The file name extension (.ics or .xml) that you specify for the output file determines which format is used. For example:

To backup the calendar JSmithcal in ICAL (text/calendar MIME) format, enter the following command:

csbackup -c JSmithcal calendar jsmith.ics

To backup the calendar JSmithcal in XML (text/xml MIME) format, enter:

csbackup -c JSmithcal calendar jsmith.xml

Restoring a Specified Calendar
You can restore a specified calendar the using the csrestore utility's:

Restoring a Calendar from a File
Use the csrestore utility's calendar command to restore a calendar that was saved to a backup file using the csbackup utility. The file name extension (.ics or .xml) of the backup file indicates the format in which it was saved. For example:

To restore the calendar JSmithcal that was saved in ICAL (text/calendar MIME) format to the file jsmith.ics located in the bcakupdir directory, enter the following command:

csrestore -c JSmithcal calendar backupdir/jsmith.ics

To restore the calendar JSmithcal that was saved in XML (text/calendar MIME) format to the file jsmith.xml located in the bcakupdir directory, enter:

csrestore -c JSmithcal calendar backupdir/jsmith.xml

Restoring a Calendar from a Database
Use the csrestore utility's database command to restore a calendar from a database that was saved to a backup directory using the csbackup utility. For example, to restore the calendar JSmithcal from the backup database directory backupdir, enter the following command:

csrestore -c JSmithcal database backupdir

Backing-Up a User's Default Calendar
Use the csbackup utility's defcal command to backup a user's default calendar to a plain text file using ICAL or XML format. The file name extension (.ics or .xml) that you specify for the output file determines which format is used. For example:

To backup calendar user JSmith's default calendar in ICAL (text/calendar MIME) format to a file named jsmith.ics, enter the following command:

csbackup -a JSmithcal defcal jsmith.ics

To backup calendar user JSmith's default calendar in XML (text/xml MIME) format to a file named jsmith.xml, enter the following command:

csbackup -a JSmithcal defcal jsmith.xml

Restoring a User's Default Calendar
Use the csrestore utility's defcal command to restore a a user's default calendar that was saved to a backup file using the csbackup utility. The file name extension (.ics or .xml) of the backup file indicates the format in which it was saved. For example:

To restore calendar user JSmith's default calendar that was saved in ICAL (text/calendar MIME) format to a file named jsmith.ics located in the backup directory backupdir, enter the following command:

csrestore -a JSmithcal defcal backupdir/jsmith.ics

To restore calendar user JSmith's default calendar that was saved in XML (text/xml MIME) format to a file named jsmith.xml located in the backup directory backupdir, enter the following command:

csrestore -a JSmithcal defcal backupdir/jsmith.xml

Backing-Up the Calendar Database
Use the csbackup utility's database command to backup the calendar database to an output directory. For example, to backup the calendar database to a directory named backupdir, enter the following command:

csbackup database backupdir

Restoring the Calendar Database
The following command line utilities let you restore the calendar database:

The csrestore and csdb commands must be run on the local machine on which your Calendar Server is installed.

Warning. You must stop the Calendar Server before restoring or recovering the calendar database. (The server may be running, however, when you backup the database.)

Use the csrestore utility's database command to restore a calendar database that was saved to a backup directory using the csbackup utility. For example, to restore the calendar database that was saved to a backup directory named backupdir, enter the following command:

csrestore database backupdir

Use the csdb utility's recover command to recover a calendar database that was accidentally corrupted or deleted. For example, to attempt to recover a damaged calendar database in the current directory, enter the following command:

csdb recover

Using Solstice or Legato Software to Backup Calendar Server
We recommend using the Sun Solaris Solstice Backup or the Legato file backup and restore products to backup the Calendar Server. If you do not have Solstice Backup, use the command line utilities csbackup, csdb, or csexport. See http://docs.sun.com for documentation on Solstice Backup.

Note. Solstice Backup and the Legato Networker product are identical. The instructions here are applicable to both products. Read the Solstice Backup or Legato Networker documentation set before attempting to backup the Calendar Server.

Calendar Server provides backup and restore procedures that let you:

Backing Up Calendar Server Data
Use the following steps to backup calendar data:

  1. Run the command line utilities to backup the calendar database or specified calendars.
  2. For more information, see Backup and Restore Procedures).

    The backup procedure creates a backup directory under the current directory. This directory is not the actual directory calendar data is stored, but a directory image of how calendars are stored. This files in this directory are empty and are used only to provide information to the backup program on how calendars will be stored on the backup media. If the backup directory already exists, it is synchronized with the directory structure of the current hierarchy.

  3. Start Solstice or Legato backup.
  4. You can use the backup program's graphical user interface or the save command to back up calendar data.

    Note: Do not use the Solstice Backup incremental backup feature because the backup directory is only an image of the folder structure and contains no actual data. The incremental backup feature is not supported in iPlanet Calendar Server.

    Important: The .nsr files generated by the command line utilities contain standard Networker directives and should never be modified.

  5. Automate the backup procedure.
  6. The preceding steps describe how to run a backup manually. It is recommended that you set up the backup program's backup command to run the Calendar Server csbackup command line utility before the running backup program's save command to achieve an automated backup process.

    Note: You cannot use Networker to backup a calendar with a name that contains non-ASCI characters or the forward slash (/).

Restoring Calendar Server Data
Use the Solstice nwrestore feature or the recover command to restore backed up calendar information. If you use nwrestore, you will receive the message:

"File already exists. Do you want to overwrite, skip, backup, or rename?"

Choose overwrite. (This message appears because the backup tree is just the directory hierarchy, that is, it consists of empty files and stays that way permanently.)

Note. If you use the Solstice recover command, you can use the -A and -iy arguments to suppress this message.

 

© Copyright 2000 Sun Microsystems, Inc. Some preexisting portions Copyright © Netscape Communications Corp. All rights reserved.