Instead of using the installer script as described in the Quickstart, you can manually install the CLI and its dependencies. Before proceeding, be sure you meet the Requirements.
You can also download the CLI installation files and perform an offline installation.
Step 1: Installing Python
Python installation instructions vary for each operating system that the CLI supports.
Note
The CLI supports only the Python versions listed in the CLI Requirements.
Install a supported version of PythonВ from the Python Windows downloads page. During installation, choose to add Python to the PATH and/or environment variables (depending on the prompt).
Some versions of Oracle Linux come with incompatible versions of Python, and might require additional components to install the CLI. Before installing the CLI, run the following commands on a new Oracle Linux image.
Tip
Oracle Autonomous Linux 7 and Oracle Linux Cloud Developer 8 come with the CLI pre-installed.
Oracle Linux 7 and Oracle Linux 8
Oracle Linux 6
Before you install the CLI, run the following commands on a new CentOS image.
CentOS 7, CentOS 8
Before you install the CLI, run the following commands on a new Ubuntu image.
Ubuntu 16, Ubuntu 18, and Ubuntu 20
Mac OS X comes with Python pre-installed.
To install the latest version of Python on Mac OS X, see the official Python documentation.
Step 2: Creating and Configuring a Virtual Environment
The venv Python module is a virtual environment builder that lets you create isolated Python environments. We recommend installing the CLI in a virtual environment.
Installing and Activating your Virtual Environment
After Python is installed, set up a virtual environment for your operating system using the following steps.
Navigate to the directory in which you would like to create the virtual environment.
Create the virtual environment by running the following command:
Navigate to the directory in which you would like to create the virtual environment.
Create the virtual environment by running one of the following commands, depending on the version of Python installed:
Step 3: Installing the Command Line Interface
You can download the CLI from GitHub or install the package from Python Package Index (PyPI).
To install using the GitHub download:
Download and unzip oci-cli.zip.
Run the following command.
To install using PyPI, run the following command:
For information on how to start a CLI session, see Using the CLI.
Installing Without a Virtual Environment
We do not recommend installing the CLI in your system-wide Python and suggest that instead you install the CLI using the installer or virtual environment.
In cases where you are trying to install the CLI in your system-wide Python using the latest pip version, you might encounter conflicts with some distutils installed packages. Following is an example error message when this occurs:
Another option is to install the CLI for the user using the following command, although this approach is not supported:
Offline Installation
If you have Python 3 installed, you can perform an offline installation of the OCI CLI.
For troubleshooting offline installs, see Common Issues or create an issue on GitHub.
Источник
Oracle linux version command
Use this checklist to check minimum operating system requirements for Oracle Database.
Table 1-2 Operating System General Checklist for Oracle Database on Linux
Item
Task
Operating system general requirements
OpenSSH installed manually, if you do not have it installed already as part of a default Linux installation.
A Linux kernel in the list of supported kernels and releases listed in this guide.
Linux x86-64 operating system requirements
The following Linux x86-64 kernels are supported:
Oracle Linux 8.1 with the Unbreakable Enterprise Kernel 6: 5.4.17-2011.0.7.el8uek.x86_64 or later Oracle Linux 8 with the Red Hat Compatible kernel: 4.18.0-80.el8.x86_64 or later
Oracle Linux 7.4 with the Unbreakable Enterprise Kernel 4: 4.1.12-124.19.2.el7uek.x86_64 or later Oracle Linux 7.4 with the Unbreakable Enterprise Kernel 5: 4.14.35-1818.1.6.el7uek.x86_64 or later Oracle Linux 7.7 with the Unbreakable Enterprise Kernel 6: 5.4.17-2011.4.4.el7uek.x86_64 or later Oracle Linux 7.5 with the Red Hat Compatible Kernel: 3.10.0-862.11.6.el7.x86_64 or later
Red Hat Enterprise Linux 8: 4.18.0-80.el8.x86_64 or later
Red Hat Enterprise Linux 7.5: 3.10.0-862.11.6.el7.x86_64 or later
SUSE Linux Enterprise Server 15: 4.12.14-23-default or later
SUSE Linux Enterprise Server 12 SP3: 4.4.162-94.72-default or later
Review the system requirements section for a list of minimum package requirements.
IBM: Linux on System z operating system requirements
The following IBM: Linux on System z kernels are supported:
Red Hat Enterprise Linux 8.3: 4.18.0-240.el8.s390x or later
Red Hat Enterprise Linux 7.4: 3.10.0-693.el7.s390x or later
SUSE Linux Enterprise Server 12: 4.4.73-5-default s390x or later
Review the system requirements section for a list of minimum package requirements.
Oracle Database Preinstallation RPM for Oracle Linux
If you use Oracle Linux, then Oracle recommends that you run the Oracle Database Preinstallation RPM for your Linux release to configure your operating system for Oracle Database and Oracle Grid Infrastructure installations.
Oracle RPM Checker utility for IBM: Linux on System z
Oracle recommends that you use the Oracle RPM Checker utility to verify that you have the required Red Hat Enterprise Linux or SUSE packages installed on your IBM: Linux on System z operating system before you start the Oracle Database or Oracle Grid Infrastructure installation.
Disable Transparent HugePages
Oracle recommends that you disable Transparent HugePages and use standard HugePages for enhanced performance.
Источник
Manage the Boot Kernel for Oracle Linux 8
Introduction
This tutorial describes how to set the default kernel of an Oracle Linux system from the command line. This tutorial is targeted at Oracle Linux 8 users, but the grubby command is also available on Oracle Linux 6 and Oracle Linux 7.
Background
By default, Oracle Linux systems are configured to boot the most recent kernel version first. In most cases, changing the default kernel is unnecessary.
However, the default kernel might not be the correct version to use in certain scenarios, such as the following:
The current kernel version might be incompatible with a particular hardware you are using.
Cases involving Unbreakable Enterprise Kernel (UEK) releases on the system
UEK releases are typically based on kernel versions that are newer than the Red Hat Compatible Kernel (RHCK) version on which an Oracle Linux release is based. Thus, the new UEK version becomes the default kernel, which is not the same as the Oracle Linux kernel.
If a UEK beta or technical preview release is installed on the system, the UEK kernel needs to be demoted to ensure that the kernel is used only if intentionally and manually selected as the boot kernel by an administrator.
A UEK kernel might need to be promoted because a specific software depends on it.
These examples and other similar cases would necessitate that you switch between kernel types.
In previous releases, setting the default kernel was performed by configuring the GRUB boot loader or by using other alternative commands. Now, however, you should preferrably use the grubby command to control and manage all of your boot requirements. This tool offers the benefit of being scriptable and can abstract bootloader configuration from the user.
Objectives
In this lab, you’ll learn how to:
determine the current loaded kernel
determine the default kernel
determine which kernel versions are available on the system
how to use grubby to manage kernels
What Do You Need?
Any Oracle Linux system that has the grubby package installed
(Hands-on Lab) Connect to the Compute Instance
Note: This step is specific to the Oracle provided free lab environment.
The Desktop environment will display before the instance(s) are ready. Deployment of this environment can take two to five minutes, depending on the number of resources and provisioning steps needed.
First, to access the lab compute instance(s), connect to the Oracle Cloud Console and copy the compute instance Public IP address.
Sign in to Oracle Cloud Console, and select your Compartment.
Click Instances.
Copy the Public IP to a temporary location (such as a text file) on your computer.
To copy, highlight the IP address with the mouse and press Ctrl+C.
Connect to the instance.
Where is the IP address copied from the Oracle Cloud Console.
Accept the ECDSA key fingerprint by typing yes at the prompt.
You are now connected to the compute instance for this lab.
If the connection fails with the Permission denied (publickey,gssapi-keyex,gssapi-with-mic) message, wait a bit longer for the provisioning process to complete and try making the ssh connection again.
Check available kernels
Several methods are available for checking which kernels are available on a system.
Using the rpm command
Note that the command output also includes other kernel related packages and can therefore be confusing.
Listing the kernels in the /boot directory
The command produces an accurate list of kernels available on the system. However, due to the way kernels are named, the kernel version that the system currently uses is not easily identifiable.
Using the grubby command on specific kernels or using the ALL option:
The command provides fuller information about the boot configuration associated with each kernel in the system’s /boot directory. The details are based on the GRUB title configuration.
In general, kernels are named to include the upstream version number and the distribution build numbering. The kernel names on Oracle Linux also include indications of whether or not they are standard RHCK or whether they are UEK based. Additionally, the names also identify their system architecture. For example, the el8 suffix would indicate an RHCK, while el8uek would indicate a UEK.
Check the current default kernel
To check which kernel is already configured as the current default kernel to use at boot, run:
To check which kernel is currently running on a system, run:
If the default kernel and the currently running kernel are not identical, the underlying reasons might be one of the following:
A newer kernel is installed, but the system has not been rebooted.
During a system reboot, an alternative kernel was manually selected to be the operative kernel.
The default kernel was manually updated but the system has not been rebooted after the update.
Change the default kernel
To switch to a different default kernel, run the following command. Make sure to specify the full path to the designated default kernel.
The change takes effect immediately and persists across system reboots.
The grubby command has additional boot arguments for configuring kernel and boot operations. Refer to the documentation for more information.
Change kernel command line boot parameters
Use the —update-kernel option to update a kenel entry in combination with —args to add new arguments or —remove-arguments to remove existing arguments. Multiple arguments can be specified for each option in a quoted space-separated list. You can add and remove arguments in the same operation.
To update a specific kernel, provide the —update-kernel option with the full path to the kernel that you wish to update. To update all kernel entries to use a specific kernel boot argument, you can set —update-kernel=ALL .
For the purpose of this tutorial you can update all kernel entries to change the loglevel and LANG arguments:
Use the grubby info=ALL command to check that the change is implemented across kernels:
Video Demonstrations
An introductory video that provides an overview of the kernel and underlying system architecture and which demonstrates switching kernel using the grubby command is provided at https://www.youtube.com/watch?v=a0zXGhzPRp8.
A more advanced video demonstration and tutorial is provided at https://www.youtube.com/watch?v=0dv87RFGcKI if you need more information on working with GRUB2 on Oracle Linux 8.
Note that this tutorial does not describe use of the grubby command and explains the underlying components that grubby interacts with. For most kernel management requirements on Oracle Linux, the grubby tool is sufficient.
Additional Information
More Learning Resources
Explore other labs on docs.oracle.com/learn or access more free learning content on the Oracle Learning YouTube channel. Additionally, visit education.oracle.com/learning-explorer to become an Oracle Learning Explorer.
For product documentation, visit Oracle Help Center.
This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited.
The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing.
If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, then the following notice is applicable:
U.S. GOVERNMENT END USERS: Oracle programs (including any operating system, integrated software, any programs embedded, installed or activated on delivered hardware, and modifications of such programs) and Oracle computer documentation or other Oracle data delivered to or accessed by U.S. Government end users are «commercial computer software» or «commercial computer software documentation» pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, the use, reproduction, duplication, release, display, disclosure, modification, preparation of derivative works, and/or adaptation of i) Oracle programs (including any operating system, integrated software, any programs embedded, installed or activated on delivered hardware, and modifications of such programs), ii) Oracle computer documentation and/or iii) other Oracle data, is subject to the rights and limitations specified in the license contained in the applicable contract. The terms governing the U.S. Government’s use of Oracle cloud services are defined by the applicable contract for such services. No other rights are granted to the U.S. Government.
This software or hardware is developed for general use in a variety of information management applications. It is not developed or intended for use in any inherently dangerous applications, including applications that may create a risk of personal injury. If you use this software or hardware in dangerous applications, then you shall be responsible to take all appropriate fail-safe, backup, redundancy, and other measures to ensure its safe use. Oracle Corporation and its affiliates disclaim any liability for any damages caused by use of this software or hardware in dangerous applications.
Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.
Intel and Intel Inside are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC International, Inc. AMD, Epyc, and the AMD logo are trademarks or registered trademarks of Advanced Micro Devices. UNIX is a registered trademark of The Open Group.
This software or hardware and documentation may provide access to or information about content, products, and services from third parties. Oracle Corporation and its affiliates are not responsible for and expressly disclaim all warranties of any kind with respect to third-party content, products, and services unless otherwise set forth in an applicable agreement between you and Oracle. Oracle Corporation and its affiliates will not be responsible for any loss, costs, or damages incurred due to your access to or use of third-party content, products, or services, except as set forth in an applicable agreement between you and Oracle.
Oracle Documentation License
This document uses the Web-based Help format from DocBook XML. The following license information applies to this format.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the «Software»), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
Except as contained in this notice, the names of individuals credited with contribution to this software shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization from the individuals in question.
Any stylesheet derived from this Software that is publicly distributed will be identified with a different name and the version strings in any derived Software will be changed so that no possibility of confusion between the derived package and this Software will exist.
THE SOFTWARE IS PROVIDED «AS IS», WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL NORMAN WALSH OR ANY OTHER CONTRIBUTOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
Except as contained in this notice, the names of individuals credited with contribution to this software shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization from the individuals in question.
Any stylesheet derived from this Software that is publicly distributed will be identified with a different name and the version strings in any derived Software will be changed so that no possibility of confusion between the derived package and this Software will exist.
Warranty: THE SOFTWARE IS PROVIDED «AS IS», WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL DAVID CRAMER, KASUN GAJASINGHE, OR ANY OTHER CONTRIBUTOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Certain search characteristics associated with the DocBook XSL webhelp stylesheets are provided as javascript files generated using Apache Lucene and other fourth party technologies, which are licensed under the Apache License reproduced below.