Chapter 1 Using the Spacewalk Web Interface and the spacecmd Command

You can use either the Spacewalk web interface or the spacecmd command to administer Spacewalk.

The Spacewalk Server for Release 2.7 is supported on Oracle Linux 6 and Oracle Linux 7. The Spacewalk Client for Release 2.7 is supported on Oracle Linux 6 and Oracle Linux 7, as well as Oracle Linux 5.

You can also create your own web and command interfaces by using the Spacewalk XML/RPC API. For more information, see Appendix D, Spacewalk XML/RPC API.

For an introduction to the concepts and features of Spacewalk and best practices for using Spacewalk for managing Oracle Linux systems, see Spacewalk for Oracle® Linux: Concepts Guide for Release 2.7.

For requirements and instructions on installing Spacewalk, see see Spacewalk for Oracle® Linux: Installation Guide for Release 2.7.

1.1 About the Spacewalk Web Interface

After installing a Spacewalk server, you will need to set up the main Spacewalk administrator account. Starting with Spacewalk 2.6, you must also create an initial organization as part of the Spacewalk setup.

To launch the Spacewalk web interface, point a browser at the URL that is specified in the output of Step 7 of Installing a Spacewalk Server in see Spacewalk for Oracle® Linux: Installation Guide for Release 2.7.

The following example is similar to the output that is displayed:

Installation complete.
Visit https://swksvr.mydom.com to create the Spacewalk administrator account.

Create the administrator account and an initial organization (if applicable to the Oracle Linux release that you are running), then log in to the Spacewalk web interface. For step-by-step instructions, see Configuring an Initial Spacewalk Administrator and Organization in Spacewalk for Oracle® Linux: Installation Guide for Release 2.7..

After configuring the main administrator account and an organization, you can log in to the Spacewalk web interface, where the Overview page is displayed. This page shows the individual Spacewalk administrative areas, menus, page views, and various actions that you can perform by using the web interface.

Overview Page

The Spacewalk web interface menu header has the following administrative areas that you can select. The default page for each menu item displays summary information. You can obtain more detailed information and perform actions on the various items by selecting the item from the left-hand menu or by clicking the tab views on a given page.

Figure 1.1 Spacewalk Overview Page

The default Overview page presents a dashboard view of the state of the Spacewalk server. The page displays important information about systems that are inactive or in a critical state, recently scheduled actions, relevant security errata that you can apply to your systems, and lists of system groups and recently registered systems. The page also provides links to administrative tasks that you can perform.

Refer to the Overview Legend pane for the meaning of any icons that the page displays for a system.

To customize the layout of the Overview page:

  1. Select Your Preferences.

  2. On the Your Preferences page in the Overview Start Page section, select or deselect the check boxes against the information that you want or do not want to display.

    You can configure other preferences on this page, such as whether to receive email notifications, the number of entries per-page in lists, and the separator character for comma-separated values (CSV) files.

  3. To save your changes, click Save Preferences.

Systems Tab

Figure 1.2 Systems Overview Page

The System Overview page displays a summary of the number of available updates, errata, packages, configuration files and crashes, the name of the base channel, and any entitlements for each managed client system.

Note

Starting with Spacewalk 2.6, the Management entitlement is automatically assigned to all registered clients. You can also enable the Virtualization entitlement to enable Spacewalk to identify and manage virtual guests on a client server. All other entitlements have been removed.

Refer to the System Legend pane for the meaning of any icons that the page displays for a system.

Errata Tab

Figure 1.3 Errata Relevant to Your Systems Page

The Errata Relevant to Your Systems page displays information about the errata that are available for your registered systems.

Refer to the Errata Legend pane for the meaning of any icons that the page displays for a system.

Channels Tab

Figure 1.4 Full Software Channel List Page

The Full Software Channel List page displays the channels to which you can subscribe your registered systems. By default, only the base channels are shown. To display child channels, click the plus sign (+) next to the name of the base channel.

Audit Tab

Figure 1.5 OpenSCAP Scans Page

The OpenSCAP Scans page displays a summary of any scans that you have performed on your systems.

Configuration Tab

Figure 1.6 Configuration Overview Page

The Configuration Overview page displays a summary of the configuration files that are known to Spacewalk, links to actions you can perform with configuration files, and scheduled deployments of configuration files.

Schedule Tab

Figure 1.7 Pending Actions Page

The Pending Actions page displays a list of actions that are scheduled to be performed.

Users Tab

Figure 1.8 Active Users Page

The Active Users page displays a list of administrators or other users and their allocated roles.

The Spacewalk Administrator role permits a user to perform all actions in Spacewalk.

You can configure the Organization Administrator role to grant one or more of the following roles to a user who has administrative access to one or more organizations:

  • System Group Administrator

  • Channel Administrator

  • Activation Key Administrator

  • Configuration Administrator

  • Monitoring Administrator

A read-only API user has limited access to the XML/RPC API but cannot access the web interface.

Admin Tab

Figure 1.9 Organizations Page

The Organizations page displays the organizations for which you have configured the Spacewalk server to administer and the number of systems, Spacewalk administrators, and trusts that are configured for the system. If a trust is enabled, you can share content and move systems between organizations.

Note

Starting with Spacewalk 2.6, you must define at least one Spacewalk organization as soon as you have installed the Spacewalk server.

1.2 About the spacecmd Command

You can use the spacecmd command-line interface (CLI) to perform most of the actions that you perform by using the web interface.

You can run the spacecmd command either directly on the Spacewalk server or remotely. If you run the spacecmd command remotely, you must specify the server by its IP address or by a resolvable domain name.

The following example shows how you would specify the server by its host name:

$ spacecmd -s swksvr.mydom.com
Welcome to spacecmd, a command-line interface to Spacewalk.

Type: 'help' for a list of commands
      'help <cmd>' for command-specific help
      'quit' to quit

Spacewalk Username: swadmin
Spacewalk Password: password
INFO: Connected to https://swksvr.mydom.com/rpc/api as swadmin

where the values for the host name, Spacewalk user, and password are those that you specified when installing and configuring Spacewalk.

Note

You must authenticate yourself as a Spacewalk user with an assigned role with sufficient privileges for performing the requested actions.

As an alternative to entering the Spacewalk user name and password at the prompts, you can use the -u and -p options to specify these values. Be aware however, that specifying the password on the command line is insecure, as it is visible in command histories and the process list. A more secure method is to create a credentials file, such as ~/.spacecmd/config with mode 400 that contains information that defines the Spacewalk server, user name, and password, as shown in the following example:

[spacecmd]
server=swksvr.mydom.com
username=swadmin
password=password

Note the following additional information about using the spacecmd CLI:

  • To display a list of spacecmd shell commands, type help.

  • To display more help about a command, type help command.

  • To exit the shell, type exit or quit.

  • The spacecmd command attempts [Tab] completion of partial commands or arguments.

  • You can run the spacecmd command as an interactive shell or non-interactively. This guide includes examples of using the interactive shell.

    If you want to run the spacecmd command non-interactively, specify the spacecmd shell command and its arguments after a -- delimiter, as shown in the following example:

    $ spacecmd -- softwarechannel_create -l oraclelinux7-x86_64-ksplice \
      -n "Oracle Linux 7 x86_64 Ksplice Channel" -p oraclelinux7-x86_64 -a x86_64
    INFO: Connected to https://swksvr.mydom.com/rpc/api as swadmin
    $ spacecmd -q -- softwarechannel_list
    INFO: Connected to https://swksvr.mydom.com/rpc/api as swadmin
    oraclelinux7-x86_64
    oraclelinux7-x86_64-addons
    oraclelinux7-x86_64-ksplice
    oraclelinux7-x86_64-optional
    oraclelinux7-x86_64-patch
    oraclelinux7-x86_64-spacewalk26-client
    oraclelinux7-x86_64-spacewalk26-server
    oraclelinux7-x86_64-uek-r3
    oraclelinux7-x86_64-uek-r4
    $ spacecmd -q -y -- softwarechannel_delete oraclelinux7-x86_64-ksplice
    Channels
    --------
    oraclelinux7-x86_64-ksplice
    $ spacecmd -q -- softwarechannel_list
    oraclelinux7-x86_64
    oraclelinux7-x86_64-addons
    oraclelinux7-x86_64-optional
    oraclelinux7-x86_64-patch
    oraclelinux7-x86_64-spacewalk26-client
    oraclelinux7-x86_64-spacewalk26-server
    oraclelinux7-x86_64-uek-r3
    oraclelinux7-x86_64-uek-r4

    The -q option suppresses informational messages. The -y option specifies a yes answer to all prompts to confirm whether you want to delete or change data. By default, spacecmd assumes the answer no.

For more information, see the spacecmd(1) man page.