suma Command
Purpose
Creates a task to automate the download of Technology Levels (TLs) and Service Packs (SPs) from a fix server.
Syntax
- To create, edit, or schedule a Service Update Management Assistant (SUMA) task
-
suma { { [ -x ] [ -w ] } | -s CronSched } [ -a Field=Value ]... [ TaskID ] - To list SUMA tasks
-
suma -l [ TaskID ]... - To list or edit the default SUMA task
-
suma -D [ -a Field=Value ]... - To list or edit the SUMA global configuration settings
-
suma -c [ -a Field=Value ]... - To unschedule a SUMA task
-
suma -u TaskID - To delete a SUMA task
-
suma -d TaskID
Description
- Create
- Edit
- List
- Schedule
- Unschedule
- Delete
create operation is used to create a new SUMA task and hence a task
ID is not specified during the create operation. For the
edit operation, if a task ID is not specified, the system
creates a new SUMA task and generates a unique task ID for the newly created SUMA
task.Flags
| Item | Description |
|---|---|
| -c | Lists or edits the SUMA global configuration settings. You can update one or
more configuration settings by using the -c flag with a -a flag. When -c flag is
used without the -a flag, all SUMA
configuration settings are listed. You can edit the following configuration settings in the
Field=Value format by using the -a flag along with the -c flag.
|
| -c (Continued) |
|
|
|
| -c (Continued) |
|
| -c (Continued) |
|
| -c (Continued) |
|
| -d | Deletes the SUMA task that is associated with the specified TaskID and any schedules for this task that were created with the -s flag. |
| -D | Lists or edits the default SUMA task. You can update one or more Fields of the default task to the specified Value by using the -a flag. When used without the -a flag, the default SUMA task is listed. |
| -l | Lists the SUMA tasks. When used without a TaskID, all SUMA tasks are listed. The TaskID is used to specify one or more task IDs to list. |
| -s CronSched | Schedules a SUMA task. If specified when a new task is created, a save is
implied (-w flag functions). The
CronSched is a list of five space-separated entries (minute, hour, day, month,
weekday) contained in quotation marks. The following values are the valid values for these five
space-separated entries:
For more information, see crontab command. |
| -u | Unschedules a SUMA task. This flag removes any scheduling information for the specified TaskID. |
| -w | Writes or saves a SUMA task. The task is saved if this flag is used instead of the -s flag, and you can add the scheduling information later. If used with the -x flag, the task is run immediately and is saved. |
| -x | Specifies that a SUMA task must be run immediately and not scheduled. If used without the -w flag, the task is not saved for future use. |
| -a Field=Value ... | Assigns the specified Value to the specified
Field. The following values are the supported Fields and
Values for the create or edit operation on a SUMA task:
|
| -a (Continued) |
|
| -a (Continued) |
|
| -a (Continued) |
|
| -a (Continued) |
|
Parameters
| Item | Description |
|---|---|
| TaskID | Specifies a unique numeric identifier that is associated with a task. This ID is assigned when a task is created. |
Exit Status
| Item | Description |
|---|---|
| 0 | Indicates that the command is completed successfully. |
| >0 | Indicates that an error occurred. |
Examples
- To list the SUMA global configuration settings, enter the following command:
An output similar to the following sample screen is displayed:suma -cFIXSERVER_PROTOCOL=https DOWNLOAD_PROTOCOL=http DL_TIMEOUT_SEC=180 DL_RETRY=1 HTTP_PROXY= HTTPS_PROXY= DIRECT_LAN_CONNECT=yes DIRECT_LAN_PRIORITY=1 PROXY_CONNECT=no PROXY_ADDRESS_1= PROXY_PORT_1= PROXY_USERID_1= PROXY_PASSWORD_1= PROXY_PRIORITY_1=2 PROXY_ADDRESS_2= PROXY_PORT_2= PROXY_USERID_2= PROXY_PASSWORD_2= PROXY_PRIORITY_2=3 PROXY_ADDRESS_3= PROXY_PORT_3= PROXY_USERID_3= PROXY_PASSWORD_3= PROXY_PRIORITY_3=4 SCREEN_VERBOSE=LVL_INFO NOTIFY_VERBOSE=LVL_INFO LOGFILE_VERBOSE=LVL_VERBOSE SUMA_CHCC_LOG=CONSOLE MAXLOGSIZE_MB=1 REMOVE_CONFLICTING_UPDATES=yes REMOVE_DUP_BASE_LEVELS=yes REMOVE_SUPERSEDE=yes TMPDIR=/var/suma/tmp - To edit the SUMA global configuration setting to change the maximum log file size to 2 MB, enter
the following command:
suma -c -a MAXLOGSIZE_MB=2 - To list the SUMA task defaults, enter the following command:
An output similar to the following sample screen is displayed:suma -DDisplayName= Action=Download RqType=Latest RqName= Repeats=y DLTarget=/usr/sys/inst.images NotifyEmail=root FilterDir=/usr/sys/inst.images FilterML=7300-02 MaxDLSize=-1 Extend=y MaxFSSize=-1 - To create and schedule a task that downloads the latest fixes monthly, for example, on the 15th
of every month at 2:30 AM, enter the following command:
suma -s "30 2 15 * *" -a RqType=Latest \ -a DisplayName="Latest fixes - 15th Monthly"Note: A task ID is returned for this newly created task. This example assumes that some of the SUMA task defaults are used, as displayed by thesuma -Dcommand. For example, when the task is default of DLTarget=/usr/sys/inst.images, the installp images are downloaded into the /usr/sys/inst.images/installp/ppc directory. - To view the SUMA scheduling information that is set up when you run the
suma -s CronSchedcommand, enter the following command:crontab -l root - To create and schedule a task that checks for a specific TL once a week, for example, every
Thursday at 3 AM, downloads it when it becomes available, and sends email notifications to users on
a remote system, enter the following command:
suma -s "0 3 * * 4" -a RqType=TL -a RqName=6100-04 \ -a NotifyEmail="bob.smith@host2,ann@host2"Note: To make a weekly check for a TL, set theRepeatsfield to y. In this case, after the TL is found, the task is deleted. IfRepeats=n, only a single check occurs before deleting the task. - To create and schedule a task that checks for critical fixes monthly, for example, on the 20th
of every month at 4:30 AM, enter the following command:
suma -s "30 4 20 * *" -a RqType=Latest -a RqName= \ -a RqLevel=latest -a Repeats=yNote: By settingRepeats=y, this task repeats forever and is not deleted after a successful download. - To create and schedule a task that downloads the entire AIX Version 7.1 with the 5300-11 recommended maintenance
package into the /lppsrc/5311 directory at a specified time, for example, on
Monday at 11:00 PM, enter the following command:
This command also runs the lppmgr command clean operation after the download operation to remove any superseded updates, duplicate base levels, and conflicting updates.suma -s "0 23 * * 1" -a Action=Clean -a RqType=ML -a RqName=5300-11 \ -a DLTarget=/lppsrc/5311Note: Before you run a task that specifiesAction=Clean, runsuma -ccommand to verify the SUMA global configuration settings that are used when you run lppmgr command. TheREMOVE_SUPERSEDE,REMOVE_DUP_BASE_LEVELS, andREMOVE_CONFLICTING_UPDATESfields must be set to yes to run the clean operation. - To create and schedule a task that downloads the entire AIX Version 7.1 with the 5300-11 recommended maintenance
package into the /tmp/lppsrc/5311 directory at a specified time. For example,
on Monday at 11:00 PM, filtering against any updates that are already contained in
/lppsrc, enter the following command:
suma -s "0 23 * * 1" -a RqType=ML -a RqName=5300-11 \ -a DLTarget=/tmp/lppsrc/5311 -a FilterDir=/lppsrc -a FilterSysFile=/dev/nullNote: After the task is successfully completed, the task is removed becauseRqType=TLis a repeat until found task. However, ifRepeats=n, only a single check for the 5300-03 TL is made, and if the TL is not found on the fix server, the task is deleted because it is set up not to repeat. - To run a task that performs a preview to check whether an SP exists on the fix
server, and to create and schedule this task to be run later if the SP does not yet exist, enter the
following command:
suma -x -w -a Action=Preview -a RqType=SP -a RqName=6100-04-02Note: A task ID is returned for this newly created task. - To run the newly created task from the example 10 (assume task
ID 23 was returned) and attempt to download the SP and save the
Action=Downloadsetting for task ID 23, enter the following command:suma -x -w -a Action=Download 23Note: As this task is run from the command line, and not scheduled through cron command, theRepeatsfield is ignored and the task is not deleted whether the SP is found or not. - To schedule task ID 23 to check for a specific SP once a week, for example, every Thursday at 3
AM, and download it when it becomes available, enter the following command:
suma -s "0 3 * * 4" -a Repeats=y 23Note: This task is deleted when the SP is found. - To unschedule a task that removes its scheduling information from the
crontab file in the /var/spool/cron/crontabs directory,
enter the following command:
suma -u 23 - To delete a task that also removes its scheduling information if it exists, enter the following
command:
suma -d 23 - To list multiple SUMA tasks, where
4and23represent task IDs, enter the following command:suma -l 4 23 - To list all SUMA tasks, run the following command:
suma -l - To create and schedule a task that checks monthly (for example, on the 15th of every month at
2:30 AM) for the latest SP on the specified
FilterMLattribute, and download any SPs that are not already in the /tmp/latest repository, enter the following command:suma -s "30 2 15 * *" -a RqType=Latest -a FilterML=6100-02 \ -a DLTarget=/tmp/latest -a FilterDir=/tmp/latestNote: A task ID is returned for this newly created task.
Location
/usr/suma/bin/suma
Files
| Item | Description |
|---|---|
| /usr/suma/bin/suma | Contains the suma command. |
| /usr/sbin/suma | Contains the link to /usr/suma/bin/suma. |
| /var/adm/ras/suma.log | Contains detailed results from running the suma command. |
| /var/adm/ras/suma_dl.log | Contains a list of files that are downloaded. |
| /var/spool/cron/crontabs | Directory that contains the crontab file for scheduling. |