Oracle Linux - Using The Cockpit Web Console
Oracle Linux - Using The Cockpit Web Console
F51970-02
June 2022
Oracle Linux Using the Cockpit Web Console,
F51970-02
iii
5 Use Cockpit to Monitor System Logs
Access the system logs 5-1
Customize the list of logs 5-1
Use the text search functionality to filter the events list 5-2
Using the available predefined filters 5-2
Using available quantifiers 5-2
Searching by log fields or free form text 5-3
Using advanced search 5-3
iv
11 Use Cockpit to Manage Partitions
Access the storage information 11-1
Display partitions that are formatted with file systems 11-1
Create partitions 11-1
Delete partitions 11-2
v
17 Use Cockpit to Manage NFS Mounts
Access the storage information 17-1
Connect NFS mounts 17-1
Customize mount options 17-2
vi
Preface
Oracle Linux includes a web console you can use for system administration. The web
console is called Cockpit. For non-minimal installations, Cockpit is automatically installed,
although not automatically enabled. Cockpit provides a web browser interface for performing
system configuration and administration tasks, either locally or remotely on multiple servers.
These tasks include system resource monitoring and log review, network and firewall
configuration, and package management and updates. Cockpit uses the same APIs to
access system services, so any changes you make using operating system command line
tools are updated in real time in Cockpit.
Conventions
The following text conventions are used in this document:
Convention Meaning
boldface Boldface type indicates graphical user
interface elements associated with an action,
or terms defined in text or the glossary.
italic Italic type indicates book titles, emphasis, or
placeholder variables for which you supply
particular values.
monospace Monospace type indicates commands within a
paragraph, URLs, code in examples, text that
appears on the screen, or text that you enter.
Documentation Accessibility
For information about Oracle's commitment to accessibility, visit the Oracle Accessibility
Program website at https://www.oracle.com/corporate/accessibility/.
For information about the accessibility of the Oracle Help Center, see the Oracle Accessibility
Conformance Report at https://www.oracle.com/corporate/accessibility/templates/
t2-11535.html.
vii
Preface
viii
1
Install and Log Into the Cockpit Web Console
This chapter shows you how to install and set up the Cockpit web console on an Oracle Linux
system to enable you to perform basic system configuration and administration by using a
web-based user interface.
The service starts and runs a web server that listens on TCP port 9090 by default. You can
check the status of the service by running:
1-1
Chapter 1
Logging into Cockpit
https://myserver.example.com:9090
https://localhost:9090
If you are not using a signed security certificate, a warning that the connection is
not private is displayed. To continue, add an exception for the site in the browser.
2. Log into Cockpit using a system user account. If the user account has sudo
privileges, you can run privileged tasks in the web console. To enable running
sudo commands, check the Reuse my password for privileged tasks option.
Click Log In. The Cockpit dashboard is displayed.
Tip:
To connect to a remote Oracle Linux server running Cockpit, use the
Connect to field in Other Options and enter the URL for the remote host.
1-2
2
Use Cockpit to Configure Kdump
This chapter shows you how to enable and configure the kernel dump (kdump) feature on an
Oracle Linux system by using the Cockpit web console. You can access the web console to
view the current status of the kdump service and the amount of memory that is reserved for
the kdump kernel, as well as specify the target location of the vmcore dump file and test your
kdump settings..
2-1
Chapter 2
Test your kdump settings
3. Click the link next to the Crash dump location option to open the Crash dump
location window, as shown in the following figure.
4. For the Location where you want to save the crash dump, select from the options
provided in the drop-down list. The default location is Local Filesystem. Other
locations include the following:
• Remote over SSH: This option sends the vmcore to a remote system by using
SSH. To use this option, you must provide the information for the Server, ssh
key, and Directory fields with the remote machine address, ssh key location,
and a target directory.
• Remote over NFS: This option sends the vmcore to a remote system by using
the NFS protocol. To use this option, provide the required information in the
Mount field.
5. (Optional) To specify whether to compress the crash dump to save space, select
the Compression check box.
6. Click Apply to save the changes.
2-2
Chapter 2
Test your kdump settings
WARNING:
Selecting this option causes a system crash and loss of data.
2-3
3
Use Cockpit to Configure System Settings
and View System Information
This chapter shows you how to configure basic system settings, such as the system host
name, date, and time for an Oracle Linux system by using the Cockpit web console.
3-1
Chapter 3
View more information about your hardware
3-2
Chapter 3
Join a Domain
The Pretty Host Name is a friendly free-form system name that is displayed in user interface
environments. If it is not set, the Real Host Name is used instead.
The Real Host Name is equivalent to the static host name set in the /etc/hostname file and
the transient host name that is used at run time by the system and which can be reset
automatically by services like DHCP or mDNS. Setting this value takes immediate effect and
does not require a reboot.
This feature is equivalent to using the hostnamectl command to set these values on the
command line.
Join a Domain
If your system is not already configured as part of an Active Directory or IPA domain, you can
use Cockpit to enroll the system and join a domain. This process is handled using the realmd
DBus API. The Join Domain link in the Overview's Configuration section opens a dialog
where you can enter the domain details required to enroll the system. Note that this process
is similar to using the realm join command from the command line. More information is
available on the realm(8) manual page.
3-3
4
Use Cockpit to Set Up Performance Profiles
This chapter describes how to set up Tuned performance profiles for an Oracle Linux system
by using the Cockpit web console. The web console configures the tuned service for the
selected profile. For more information about working with Tuned by using the command line,
see Working With Tuned in Oracle Linux 8: Monitoring and Tuning the System.
Note:
The "Recommended" profile is usually indicated as such.
4-1
Chapter 4
Change a performance profile
4-2
5
Use Cockpit to Monitor System Logs
This chapter shows you how to use Cockpit to monitor processes through the system logs to
check their status and identify faulty operations that require further investigation.
Each item in the list has a corresponding time stamp as well as the source of that event log,
such as sudo, systemd, kernel, and so on. Because monitoring is ongoing, logs are added to
the list over time. To halt the continuing display, click Pause.
By selecting a specific event log, you can obtain further details about the event. The report
displays the event's priority, syslog facility, syslog identifier, the audit login UID and session,
and other details.
• Only emergency
• Alert and above
• Critical and above
• Error and above (default)
• Warning and above
• Notice and above
• Info and above
5-1
Chapter 5
Use the text search functionality to filter the events list
• All (default)
• cockpit-session
• kernel
• password
• sshd
• sudo
• systemd
To display the command syntax, click the question mark icon next to the Text field.
priority:emerg identifier:kernel
When you press Enter, a list of logs that match the search criteria is generated.
5-2
Chapter 5
Use the text search functionality to filter the events list
• boot: Show messages that apply to a specific boot. This quantifier is partially used by the
predefined filter Time.
• since: Show messages that apply to a specified date or time. The format must be YYYY-
MM-DD HH:MM:SS. The time uses the 24-hour format.
For example, you might search the logs with the following quantifiers:
However, you can also type free form text to search the logs. The following search lists logs
that refer to the makecache process:
makecache
5-3
6
Use Cockpit to Manage System Services
This chapter shows you how to use Cockpit to manage Oracle Linux system services.
6-1
7
Use Cockpit to Manage User Accounts
This chapter shows you how to create and manage user accounts on an Oracle Linux system
using the Cockpit web console. The chapter also describes how to view individual user
account settings so you can modify the settings as necessary
The page displays the current users on the system. At a minimum, the root account is
displayed. If you created a user when you installed Oracle Linux, then that user is also
displayed.
Create a user
Click Create New Account to create a new user. A new window opens that prompts you for
the following information about the user:
• Full name
• User name
• Password
• Confirm
Note:
The password must be at least 8 characters in length. Otherwise, you cannot
proceed to create the account.
7-1
Chapter 7
Specify additional user settings
Note:
You can also use this page to delete a user account.
7-2
8
Use Cockpit to Manage Software Updates
This chapter describes how to use Cockpit to manage manual software updates, as well how
to automate software updates. Note that to apply software updates by using either of the
following methods, you must meet the same requirements and you must be logged in to the
web console.
The Software Updates module in the web console is based on the yum utility.
8-1
Chapter 8
Manage automatic software updates
4. (Optional) To modify the time of the automatic update, from the drop-down list,
click the time and then select a specific time, for example, 6:00.
If you want to disable automatic software updates, switch the Automatic Updates
button to the disabled position.
8-2
9
Use Cockpit to Manage Network
Configuration
This chapter shows you how to configure network interfaces and firewall rules on an Oracle
Linux system using the Cockpit web console.
The Network configuration page displays realtime graphical representations of incoming and
outgoing network traffic. The graphs show aggregated traffic across all network interfaces. To
see graphs specific to an interface, click on the specific interface in the Interfaces section.
The page also has a Firewall section. A switch indicates whether or not the firewalld
service is enabled. The section also indicates the number of firewall rules that are currently
configured. Click the Firewall heading to view more information or to add or remove services.
The Interfaces section consists of a table of configured network interfaces and their
corresponding IP addresses in CIDR format as well as their current traffic throughput for send
and receive operations. On the right side of the table heading are options for adding different
networking features, such as bonding, teams, bridges, and VLANs. Click on any of the
9-1
Chapter 9
Configure the Firewall
When the firewalld service is enabled, all incoming network traffic is dropped by
default. To allow traffic for particular services, click Add Services. A dialog opens
where you can select different service types, for example, SSH, to add as an allowed
service. Note that you can select only from the services listed on the page. You cannot
add your own customized services.
All of the enabled services and corresponding ports for specific zones on the system
are displayed in table format. Click on any of the listed services to view additional
detail about the service, including an option to delete that service.
Note that custom rules for specific ports that are unattached to a predefined service
and that have been opened by an alternative utility, such as the firewall-cmd tool, are
not shown in this table.
9-2
Chapter 9
Configure a Network Bond
netmask, and gateway for the interface. Other configurable options include adding DNS
servers, DNS search domains and configuring static routes.
• IPv6: Provides a link to a page of IPv6 related configuration options. By default,
Automatic is set and the device is automatically configured by the IPv6 auto-
configuration mechanism. However, you can select Automatic (DHCP) if you prefer to
rely on DHCPv6 instead. Or, you can select Manual if you want to set a static IP address,
netmask, and gateway for the interface. Other configurable options include adding DNS
servers, DNS search domains and configuring static routes.
• MTU: A link indicating the currently configured MTU setting for the network interface,
which is typically Automatic. However, you can provide a fixed MTU value to resolve
network issues such as lag or disconnection issues caused by inappropriate packet
sizes.
9-3
Chapter 9
Configure a Network Team
determines how often the carrier state is checked in milliseconds; the Link up
delay to determine how long to wait, in milliseconds, until using an interface that is
up; and the Link down delay which determines how long to wait before switching
to another interface if the interface is marked as down.
• ARP: The ARP monitor sends ARP queries to peer systems on the network and
uses the response to indicate whether an interface is up. The ARP monitor relies
on the device driver to keep track of the last transmit and recieve times. If the
information is not updated by the device driver, the interface is marked as down. If
you select this monitor, you need to configure the Monitoring Interval, which
determines how often ARP requests are sent, in milliseconds; and the Monitoring
Targets, a comma-separated list of IP addresses for peers on the network that
can be used for ARP monitoring.
Click Apply to create the new bond.
9-4
10
Use Cockpit to Manage Physical Drives in
Volume Groups
This chapter shows you how to use Cockpit to configure physical drives in volume groups.
For detailed information about LVM, see Working With Logical Volume Manager in Oracle
Linux 8: Managing Storage Devices.
10-1
11
Use Cockpit to Manage Partitions
This chapter describes how to use Cockpit to manage file systems.
Create partitions
To create partitions in the web console, you must meet all of the previously mentioned
requirements, as well as have an unformatted volume that is connected to the system visible
in the Other Devices table of the Storage tab.
1. In the Other Devices table, click the volume in which you want to create the partition.
The Create partition dialox box opens.
2. In the Create partition dialog box, select the size of the new partition.
3. n the Erase drop-down list, select from the following:
11-1
Chapter 11
Delete partitions
• Don’t overwrite existing data: The web console rewrites only the disk
header. Select this option for speedier formatting.
• Overwrite existing data with zeros: The web console rewrites the entire disk
with zeros. Note that this option is slower, but more secure, because the
program has to go through the whole disk. Select this option if the disk
includes any data that needs to be overwritten.
4. Select a file system type from the Type drop-down list:
• XFS (selected by default): This file system type supports the following: large
logical volumes, switching physical drives online without outage, and growing
an existing file system.
• ext4: This file system type supports the following: logical volumens, switching
physical drives online without outage, and growing and shrinking a file system.
Note that an option for enabling encryption of the partition through LUKS (Linux
Unified Key Setup) is also available. This option enables you to encrypt the
volume with a passphrase.
5. In the Name field, type the logical volume name.
6. In the Mounting drop down menu, select Custom.
The Default option does not ensure that the file system is mounted on the next
boot.
7. In the Mount Point field, add the mount path, then select Mount at Boot.
8. Click Create partition.
Formatting can take several minutes and is dependent on volume size and the
formatting options you selected.
9. Verify that the partition was successfully added by switching to the Storage tab
and then checking for the partition in the Filesystems table.
Delete partitions
Follow these steps to delete partitions by using the web console:
1. In the Filesystems table, select the volume in which you want to delete the
partition.
2. In the Content section, click on the partition that you want to delete.
3. When the partition information is exposed, click Delete to delete the partition.
Note:
To perform this operation, the partition must not be currently mounted
and used.
4. Verify that the partition was successfully deleted by switching to the Storage tab
and then checking the Content section.
11-2
12
Use Cockpit to Manage Logical Volumes With
LVM
This chapter shows you how to use Cockpit to configure volumes that are managed with
Logical Volume Management (LVM).
For detailed information about LVM, see Working With Logical Volume Manager in Oracle
Linux 8: Managing Storage Devices.
12-1
Chapter 12
Format logical volumes
Note:
You cannot reduce volumes that contain the GFS2 or XFS file systems.
1. Select the volume group in which you want to create logical volumes, then select
the logical volume that you will resize.
2. On the Volume tab, click Grow.
3. In the Grow Logical Volume dialog box, adjust the volume space, then click
Grow.
12-2
13
Use Cockpit to Encrypt Block Devices With
LUKS
This chapter shows you how to use Cockpit to configure encrypted block devices with the
Linux Unified Key Setup (LUKS).
For detailed information about LUKS encryption on block devices, see Using Encrypted Block
Devices in Oracle Linux 8: Managing Storage Devices.
13-1
Chapter 13
Change the LUKS configuration
13-2
14
Use Cockpit to Manage Virtual Data Optimizer
Volumes
This chapter shows you how to use Cockpit to manage Virtual Data Optimization (VDO) on
system volumes.
VDO is a technology that enables you to use your storage efficiently through its
compressioning, deduplicating, and thin provisioning features. Thus you are able to allot
greater virtual disk space that would otherwise be available from the physical or logical
storage.
14-1
Chapter 14
Format the VDO volume
14-2
15
Use Cockpit to Manage Redundant Arrays of
Independent Disks
This chapter shows you how to use Cockpit to configure redundant arrays of independent
disks.
For detailed information about RAID, see Working With Software RAID in Oracle Linux 8:
Managing Storage Devices.
15-1
Chapter 15
Create partitions on RAID storage
b. In the Erase drop-down list, you can decide whether to ignore or overwrite
existing data.
c. In the Partitioning drop-down list, select GPT for volumes larger than 2TB, or
MBR for smaller volumes, then click Format.
4. Click the Format button next to the RAID you would like to format.
5. In the Erase drop-down list, you can decide whether to ignore or overwrite existing
data.
6. In the Type drop-down list, select the file system for the new RAID device, then set
a Name for your formatted volume.
7. Select the Custom mounting option to ensure the file system is mounted on next
boot.
8. In the Mount Point field add the directory path, for example, /mnt/raid.
9. Select Mount at boot, then click Format.
10. When the format is complete, click Mount.
15-2
16
Use Cockpit to Enable Network Bound Disk
Encryption
This chapter shows you how to use Cockpit to automatically unlock an encrypted storage
device through the use of a key from a Tang server. The steps in this chapter are part of a
wider task of implementing Policy-Based Decryption (PBD) by configuring Network-Bound
Disk Encryption (NBDE) that features Tang and Clevis server and client components. For
more information, see Oracle Linux: Enabling Network-Bound Disk Encryption.
For a tutorial in installing and configuring a Tang server, see Use Network Bound Disk
Encryption on Oracle Linux 8.
16-1
Chapter 16
Confirm that the configuration is successful
• Disk passphrase: Specify the LUKS passphrase for the encrypted device.
6. Click Add.
The Verify key window opens and displays the generated key hash. The window
also provides instructions for verifying the key.
7. Verify the hash key by doing the following steps:
a. On the left navigation panel, select Terminal to open a terminal window.
b. Obtain the key hash that the Tang server provided by typing the following
command.
Check that the key hash that is generated matches the key that is displayed in
the Verify key window.
8. On the Verify key window, click Trust key.
9. Return to the terminal window and enable early boot decryption.
Keys
Passphrase Slot 0
Keyserver: tangserver.example.com:7500 Slot 1
16-2
17
Use Cockpit to Manage NFS Mounts
This chapter describes how to use Cockpit mount remote directories by using the Network
File System (NFS) protocol.
17-1
Chapter 17
Customize mount options
17-2
18
Use Cockpit to Manage Virtual Machines
This chapter shows you how to create and manage KVM-based virtual machines on an
Oracle Linux system by using the Cockpit web console.
Enabling Virtualization
You must enable the virtualization module, install virtualization packages, and ensure that
your system is configured to host VMs. The virtualization module provides the virt-install
package used to install VMs from a CLI and a virt-viewer package used to view VMs.
To enable virtualization from within the Cockpit web console, follow these steps:
1. Click Terminal in the left panel to open a terminal.
2. Enable the virtualization module:
virt-host-validate
18-1
Chapter 18
Review the Virtual Machines Page
18-2
Chapter 18
Check the Networks
18-3
Chapter 18
Create a Virtual Machine
11. From the VM's details page, review its information. You can add or delete a disk,
edit or add a network interface, pause, shutdown, restart and more.
Note that you can also create a VM by using the terminal in the Cockpit web console.
For more information, see Creating a New Virtual Machine.
18-4
Chapter 18
Video Demonstration
Video Demonstration
The video demonstration and tutorial provided at https://www.youtube.com/watch?
v=daHQeCY13s8 may also be useful if you need more information on using Cockpit to create
a new virtual machine.
You may also refer to the video demonstration at https://www.youtube.com/watch?v=-
Z3AwP2HPa4 for more information on setting up Cockpit to manage your virtual machines:
18-5
19
Use Cockpit to Manage Podman Containers
This chapter shows you how to manage podman containers on an Oracle Linux system by
using the Cockpit web console.
Podman and any other dependencies are installed automatically if they are not on the system
already.
19-1
Chapter 19
Managing Podman Images
You can use Cockpit to pull any images that you want to use by clicking on the Get
new image button.
A search dialog is presented to allow you to search any configured registries for
matching images. You can select the owner of the image to either download the image
as a system user or as the currently logged in user. Images and containers that are
owned by the system user are run in root mode. The search dialog also includes an
optional drop down selector that you can use to limit your search to a particular
registry. In the search field, type the name of an image that you are interested in using.
For example, you can type oraclelinux. The search area populates automatically with
images that you can pull from any of the configured registries. Select an image and
registry, for example you could select the docker.io/library/oraclelinux image. In
the tag field, type the tag of the image that you wish to download. For example, you
can type 8-slim. Click on the Download button to pull the image.
Each image that is available on the host system is listed to provide details including
the image name, image creation date, image size and image owner. Additional
information about each image is available by clicking on the image in the listing. The
dropdown display includes information such as the entry point, runtime command and
exposed ports and also provides an option to delete an image from the system. A play
icon on the right of each image in the listing allows you to run the image within a new
container. When you click on the icon to run an image, a dialog is displayed to allow
you to configure runtime options.
19-2
Chapter 19
Managing Podman Images
19-3
Chapter 19
Managing Podman Containers
6. Ports: allows you to configure port mappings between the container and the host
system. This can be useful to expose services running inside a container to the
host or to other systems in your infrastructure.
7. Volumes: allows you to configure volume mappings to share file system space on
the host system with the container and to determine access modes for these
voume shares.
8. Environment: allows you to specify environment variables as key and value
entries. These are commonly used by container images to set configuration
options for container-based applications.
Each listed container provides the runtime container name, the image used to
instantiate the container, the runtime command, CPU and memory usage, the owner of
the container and the container runtime state. You can click on each container to view
more information and to access container management controls.
Each container information dropdown displays tabs to allow you to view container
information, container logs and to access a web-based terminal into the container.
Controls are also provided to delete or destroy the container; commit changes in the
container as a new image; restart or force restart the container; and stop or force stop
the container. If you opt to commit changes, a dialog prompts you for the image name
and tag, runtime command and other variables that should be used when the
container is saved as an image.
19-4