如何获得一个Oracle 23ai数据库(vagrant box)

准确的说,是Oracle 23ai Free Developer版,因为企业版目前只在云上(OCI和Azure)和ECC上提供。

前面我博客介绍了3种方法:

  1. Virtual Appliance
  2. RPM安装
  3. Docker

今天介绍最近新出的一种方法,也是我最为推荐的方法,使用vagrant box一键式获取23ai。

要使用这种方法,你需要有以下2个软件:

  • Oracle VirtualBox
  • Vagrant

然后克隆Oracle官方的vagrant项目:

git clone https://github.com/oracle/vagrant-projects.git

或许你早已克隆,但这个23ai是最近才有的,所以你更新一下就好:

git pull origin main

然后,进入23.4.0-Free目录:运行vagrant up即可,以下是日志片段:

PS C:\Users\****\Desktop\WORKSPACE\vagrant-projects\OracleDatabase\23.4.0-Free> vagrant up
==> vagrant: Getting Proxy Configuration from Host...
Bringing machine 'oracle23ai-free-vagrant' up with 'virtualbox' provider...
==> oracle23ai-free-vagrant: Box 'oraclelinux/9' could not be found. Attempting to find and install...oracle23ai-free-vagrant: Box Provider: virtualboxoracle23ai-free-vagrant: Box Version: >= 0
==> oracle23ai-free-vagrant: Loading metadata for box 'https://oracle.github.io/vagrant-projects/boxes/oraclelinux/9.json'oracle23ai-free-vagrant: URL: https://oracle.github.io/vagrant-projects/boxes/oraclelinux/9.json
==> oracle23ai-free-vagrant: Adding box 'oraclelinux/9' (v9.3.513) for provider: virtualboxoracle23ai-free-vagrant: Downloading: https://yum.oracle.com/boxes/oraclelinux/ol9/OL9U3_x86_64-vagrant-virtualbox-b513.boxoracle23ai-free-vagrant:oracle23ai-free-vagrant: Calculating and comparing box checksum...
==> oracle23ai-free-vagrant: Successfully added box 'oraclelinux/9' (v9.3.513) for 'virtualbox'!
==> oracle23ai-free-vagrant: Importing base box 'oraclelinux/9'...
==> oracle23ai-free-vagrant: Matching MAC address for NAT networking...
==> oracle23ai-free-vagrant: Checking if box 'oraclelinux/9' version '9.3.513' is up to date...
==> oracle23ai-free-vagrant: Setting the name of the VM: oracle23ai-free-vagrant
==> oracle23ai-free-vagrant: Clearing any previously set network interfaces...
==> oracle23ai-free-vagrant: Preparing network interfaces based on configuration...oracle23ai-free-vagrant: Adapter 1: nat
==> oracle23ai-free-vagrant: Forwarding ports...oracle23ai-free-vagrant: 1521 (guest) => 1521 (host) (adapter 1)oracle23ai-free-vagrant: 22 (guest) => 2222 (host) (adapter 1)
==> oracle23ai-free-vagrant: Running 'pre-boot' VM customizations...
==> oracle23ai-free-vagrant: Booting VM...
==> oracle23ai-free-vagrant: Waiting for machine to boot. This may take a few minutes...oracle23ai-free-vagrant: SSH address: 127.0.0.1:2222oracle23ai-free-vagrant: SSH username: vagrantoracle23ai-free-vagrant: SSH auth method: private keyoracle23ai-free-vagrant:oracle23ai-free-vagrant: Vagrant insecure key detected. Vagrant will automatically replaceoracle23ai-free-vagrant: this with a newly generated keypair for better security.oracle23ai-free-vagrant:oracle23ai-free-vagrant: Inserting generated public key within guest...oracle23ai-free-vagrant: Removing insecure key from the guest if it's present...oracle23ai-free-vagrant: Key inserted! Disconnecting and reconnecting using new SSH key...
==> oracle23ai-free-vagrant: Machine booted and ready!
==> oracle23ai-free-vagrant: Checking for guest additions in VM...
==> oracle23ai-free-vagrant: Setting hostname...
==> oracle23ai-free-vagrant: Configuring proxy environment variables...
==> oracle23ai-free-vagrant: Configuring proxy for Yum...
==> oracle23ai-free-vagrant: Mounting shared folders...oracle23ai-free-vagrant: /vagrant => C:/Users/****/Desktop/WORKSPACE/vagrant-projects/OracleDatabase/23.4.0-Free
==> oracle23ai-free-vagrant: Running provisioner: shell...oracle23ai-free-vagrant: Running: C:/Users/****/AppData/Local/Temp/vagrant-shell20240614-21940-manzyc.shoracle23ai-free-vagrant: INSTALLER: Started uporacle23ai-free-vagrant: Oracle Linux 9 BaseOS Latest (x86_64)           7.1 MB/s |  27 MB     00:03oracle23ai-free-vagrant: Oracle Linux 9 Application Stream Packages (x86 8.3 MB/s |  36 MB     00:04oracle23ai-free-vagrant: Oracle Linux 9 UEK Release 7 (x86_64)           4.6 MB/s |  36 MB     00:07oracle23ai-free-vagrant: Last metadata expiration check: 0:00:07 ago on Fri 14 Jun 2024 08:33:01 AM UTC.oracle23ai-free-vagrant: Dependencies resolved.oracle23ai-free-vagrant: =====================================================================================================oracle23ai-free-vagrant:  Package                         Arch    Version                             Repository          Sizeoracle23ai-free-vagrant: =====================================================================================================oracle23ai-free-vagrant: Installing:oracle23ai-free-vagrant:  kernel-uek-core                 x86_64  5.15.0-207.156.6.el9uek             ol9_UEKR7           49 Moracle23ai-free-vagrant:  kernel-uek-devel                x86_64  5.15.0-207.156.6.el9uek             ol9_UEKR7           39 Moracle23ai-free-vagrant: Upgrading:oracle23ai-free-vagrant:  NetworkManager                  x86_64  1:1.46.0-8.0.1.el9_4                ol9_baseos_latest  2.3 Moracle23ai-free-vagrant:  NetworkManager-libnm            x86_64  1:1.46.0-8.0.1.el9_4                ol9_baseos_latest  1.9 Moracle23ai-free-vagrant:  acl                             x86_64  2.3.1-4.el9                         ol9_baseos_latest   87 k
...oracle23ai-free-vagrant: INSTALLER: Oracle preinstall and openssl completeoracle23ai-free-vagrant: INSTALLER: Environment variables setoracle23ai-free-vagrant: INSTALLER: Downloading Oracle Database softwareoracle23ai-free-vagrant: Last metadata expiration check: 0:06:04 ago on Fri 14 Jun 2024 04:33:01 PM +08.oracle23ai-free-vagrant: Dependencies resolved.oracle23ai-free-vagrant: ================================================================================oracle23ai-free-vagrant:  Package                        Arch        Version     Repository         Sizeoracle23ai-free-vagrant: ================================================================================oracle23ai-free-vagrant: Installing:oracle23ai-free-vagrant:  oracle-database-free-23ai      x86_64      1.0-1       @commandline      1.3 Goracle23ai-free-vagrant:oracle23ai-free-vagrant: Transaction Summaryoracle23ai-free-vagrant: ================================================================================oracle23ai-free-vagrant: Install  1 Packageoracle23ai-free-vagrant:oracle23ai-free-vagrant: Total size: 1.3 Goracle23ai-free-vagrant: Installed size: 3.6 Goracle23ai-free-vagrant: Downloading Packages:oracle23ai-free-vagrant: Running transaction checkoracle23ai-free-vagrant: Transaction check succeeded.oracle23ai-free-vagrant: Running transaction testoracle23ai-free-vagrant: Transaction test succeeded.oracle23ai-free-vagrant: Running transactionoracle23ai-free-vagrant:   Preparing        :                                                        1/1oracle23ai-free-vagrant:   Running scriptlet: oracle-database-free-23ai-1.0-1.x86_64                 1/1oracle23ai-free-vagrant:   Installing       : oracle-database-free-23ai-1.0-1.x86_64                 1/1oracle23ai-free-vagrant:   Running scriptlet: oracle-database-free-23ai-1.0-1.x86_64                 1/1oracle23ai-free-vagrant: [INFO] Executing post installation scripts...oracle23ai-free-vagrant: [INFO] Oracle home installed successfully and ready to be configured.oracle23ai-free-vagrant: To configure Oracle Database Free, optionally modify the parameters in '/etc/sysconfig/oracle-free-23ai.conf' and then run '/etc/init.d/oracle-free-23ai configure' as root.oracle23ai-free-vagrant:oracle23ai-free-vagrant:   Verifying        : oracle-database-free-23ai-1.0-1.x86_64                 1/1oracle23ai-free-vagrant:oracle23ai-free-vagrant: Installed:oracle23ai-free-vagrant:   oracle-database-free-23ai-1.0-1.x86_64oracle23ai-free-vagrant:oracle23ai-free-vagrant: Complete!oracle23ai-free-vagrant: INSTALLER: Oracle software installedoracle23ai-free-vagrant: Specify a password to be used for database accounts. Oracle recommends that the password entered should be at least 8 characters in length, contain at least 1 uppercase character, 1 lower case character and 1 digit [0-9]. Note that the same password will be used for SYS, SYSTEM and PDBADMIN accounts:oracle23ai-free-vagrant: Confirm the password:oracle23ai-free-vagrant: Configuring Oracle Listener.oracle23ai-free-vagrant: Listener configuration succeeded.oracle23ai-free-vagrant: Configuring Oracle Database FREE.oracle23ai-free-vagrant: Enter SYS user password:oracle23ai-free-vagrant: *************oracle23ai-free-vagrant: Enter SYSTEM user password:oracle23ai-free-vagrant: ***************oracle23ai-free-vagrant: Enter PDBADMIN User Password:oracle23ai-free-vagrant: ***************oracle23ai-free-vagrant: Prepare for db operationoracle23ai-free-vagrant: 7% completeoracle23ai-free-vagrant: Copying database filesoracle23ai-free-vagrant: 29% completeoracle23ai-free-vagrant: Creating and starting Oracle instanceoracle23ai-free-vagrant: 30% completeoracle23ai-free-vagrant: 33% completeoracle23ai-free-vagrant: 36% completeoracle23ai-free-vagrant: 39% completeoracle23ai-free-vagrant: 43% completeoracle23ai-free-vagrant: Completing Database Creationoracle23ai-free-vagrant: 47% completeoracle23ai-free-vagrant: 49% completeoracle23ai-free-vagrant: 50% completeoracle23ai-free-vagrant: Creating Pluggable Databasesoracle23ai-free-vagrant: 54% completeoracle23ai-free-vagrant: 71% completeoracle23ai-free-vagrant: Executing Post Configuration Actionsoracle23ai-free-vagrant: 93% completeoracle23ai-free-vagrant: Running Custom Scriptsoracle23ai-free-vagrant: 100% completeoracle23ai-free-vagrant: Database creation complete. For details check the logfiles at:oracle23ai-free-vagrant:  /opt/oracle/cfgtoollogs/dbca/FREE.oracle23ai-free-vagrant: Database Information:oracle23ai-free-vagrant: Global Database Name:FREEoracle23ai-free-vagrant: System Identifier(SID):FREEoracle23ai-free-vagrant: Look at the log file "/opt/oracle/cfgtoollogs/dbca/FREE/FREE.log" for further details.oracle23ai-free-vagrant:oracle23ai-free-vagrant: Connect to Oracle Database using one of the connect strings:oracle23ai-free-vagrant:      Pluggable database: localhost.localdomain/FREEPDB1oracle23ai-free-vagrant:      Multitenant container database: localhost.localdomainoracle23ai-free-vagrant: INSTALLER: Database createdoracle23ai-free-vagrant: oracle-free-23ai.service is not a native service, redirecting to systemd-sysv-install.oracle23ai-free-vagrant: Executing: /usr/lib/systemd/systemd-sysv-install enable oracle-free-23aioracle23ai-free-vagrant: INSTALLER: Created and enabled oracle-free-23ai systemd serviceoracle23ai-free-vagrant: INSTALLER: setPassword.sh file set uporacle23ai-free-vagrant: INSTALLER: Running user-defined post-setup scriptsoracle23ai-free-vagrant: INSTALLER: Done running user-defined post-setup scriptsoracle23ai-free-vagrant: ORACLE PASSWORD FOR SYS, SYSTEM AND PDBADMIN: 3PZKRiIBbhsS1oracle23ai-free-vagrant: INSTALLER: Installation complete, database ready to use!

和生成其他版本的Oracle 数据库不同,23ai无需提前准备安装介质,这是在安装中自动下载的,因此网速很重要。

另外,这个数据库的操作系统是Oracle Linux 9:

[vagrant@localhost ~]$ cat /etc/redhat-release
Red Hat Enterprise Linux release 9.4 (Plow)

PDB不是orclpdb1了,而是freepdb1:

[oracle@localhost ~]$ sqlplus / as sysdbaSQL*Plus: Release 23.0.0.0.0 - Production on Mon Jun 17 15:02:50 2024
Version 23.4.0.24.05Copyright (c) 1982, 2024, Oracle.  All rights reserved.Connected to:
Oracle Database 23ai Free Release 23.0.0.0.0 - Develop, Learn, and Run for Free
Version 23.4.0.24.05SQL> show pdbsCON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------2 PDB$SEED                       READ ONLY  NO3 FREEPDB1                       READ WRITE NO

立此存照:
在这里插入图片描述
最后,看下环境变量设置:

$ tail .bashrc
...
export ORACLE_BASE=/opt/oracle
export ORACLE_HOME=/opt/oracle/product/23ai/dbhomeFree
export ORACLE_SID=FREE
export PATH=$PATH:$ORACLE_HOME/bin

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/bicheng/30857.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

Debugger的使用

断点调试 1.打断点 2.以debug模式运行 3.流程控制

SQL注入-sqlmap使用

sqlmap简介 一款自动化的SQL注入工具,其主要功能是扫描,发现并利用给定的URL的SQL注入漏洞,目前支持的数据库是MySQL, Oracle, PostgreSQL, Microsoft SQL Server, Microsoft Access, IBM DB2, SQLite, Firebird, Sybase和SAP MaxDB Sqlma…

图像处理:Python使用OpenCV 减少图片噪音

文章目录 1. 均值滤波 (Mean Filtering)2. 高斯滤波 (Gaussian Filtering)3. 中值滤波 (Median Filtering)4.代码实现示例5.效果展示 在图像处理中,均值滤波、高斯滤波和中值滤波是三种常用的降噪方法。它们的实现原理各有不同: 1. 均值滤波 (Mean Filte…

Object类hashCode方法和equals方法源码

hashCode方法 顶级类Object里面的方法,所有类都是继承Object的,返回值int类型 根据一定的hash规则(存储地址、字段、或者长度等),映射成一个数值,即散列值 public static int hashCode(Object a[]) {if (a…

wps要会员才能把pdf分开,这不纯属智商税吗

我有一个文档 然后 我给你们写好了一个代码 from PyPDF2 import PdfReader, PdfWriterdef split_pdf(file_path, ranges, output_names):# Open the input PDF filewith open(file_path, rb) as pdf_file:reader = PdfReader(pdf_file)total_pages = len(reader.pages)if len…

Cookie、Session、Token的关系和区别

关系 Session与Cookie:Session通常依赖于Cookie来工作。当服务器为客户端创建一个Session时,它会在服务器上存储与客户端相关的信息,并将一个唯一的SessionID通过Cookie发送给客户端。客户端在后续的请求中会携带这个Cookie(包含…

北航数据结构与程序设计查找与排序编程题

查找与排序编程题 单词查找(查找——基本题)排座位(简)a 单词查找(查找——基本题) 【问题描述】 从标准输入中读入一个英文单词及查找方式,在一个给定的英文常用单词字典文件dictionary3000.…

如何使用SQL工具批量执行SQL文件?(以MySQL和SQLynx为例)

目录 1. 配置MySQL数据源 2. 打开 SQL 文件 3. 执行 SQL 文件 4. 检查执行结果 5. SQL文件示例 6. 注意事项 7. 总结 在现代数据库管理和操作中,批量执行 SQL 文件在 MySQL 中显现出其巨大的价值和不可替代的作用。通过将多个 SQL 语句集成在一个文件中进行批…

MySQL安装教程,包含root账户密码的修改(绿色版安装)---超简单好用

1、下载(mysql-8.0.27-winx64) 2、下载地址:https://dev.mysql.com/downloads/mysql/ 3、已经将 mysql-8.0.27-winx64 文件放在了文章最后,有需要的自取(解压配置即可用)。 4、配置环境变量: 右键点击我的电脑->属性->高级系统设置->高级->环境变量->系…

FineReport报表

一、报表类型 模板设计是 FineReport 学习过程中的主要难题所在,FineReport 模板设计主要包括普通报表、聚合报表、决策报表三种设计类型。 官网: ‘‘报表类型简介- FineReport帮助文档 - 全面的报表使用教程和学习资料 ‘’ 二、聚合报表 2-1 介绍…

爬虫逆向实战(41)-某花顺登陆(Cookie、MD5、SHA256)

一、数据接口分析 主页地址:某花顺 1、抓包 通过抓包可以发现在登陆时,网站首先请求了pwdRangeCalcRegular.json、getGS两个接口,接着请求dologinreturnjson2进行登陆,但是此接口会返回请先完成滑块验证码校验的响应。然后网站…

智慧公厕的五大好处:深圳光明源全面解析

智慧公厕通过集成现代智能技术和优化管理,显著提升了公共卫生设施的使用体验和管理效率。以下是智慧公厕的五大好处: 提升卫生条件: 自动感应设备:智能感应水龙头、洗手液机和干手器等设备减少了用户对设备的直接接触&#xff0…

【嵌入式开发】STM32+USB的快速开发

目录 一、概述 二、STM32+USB开发流程 2.1 建立新的工程 2.2 系统配置 2.3 时钟配置 2.4 操作系统 2.5 选择USB配置 2.6 在USB_HOST中选择支持的子类(class) 2.7 Clock 配置 三、注意事项 3.1 应用驱动配置 3.2 上电调试基础工作 一、概述 USB作为大家耳熟能详的…

20240621 每日AI必读资讯

🤖GPT-4 通过图灵测试!! 研究人员称人们在图灵测试中无法区分 GPT-4 和人类,圣地亚哥加州大学认知科学系的研究人员针对GPT 4复刻了图灵测试。 研究人员招募了500名参与者,与四个代理人:人类、1960年代的…

龙讯旷腾PWmat计算vdW异质结中热载流子冷却 | 复刻《Phys. Chem. Chem. Phys 》文献

01 NAMD 背景介绍 在各类光物理与光化学过程当中,均会牵涉到激发态载流子动力学过程,诸如电荷弛豫、复合以及输运等等。光激发或者电子注入将初始的平衡状态打破,所产生的热载流子在其演化进程中,会与原子核产生强烈耦合。此时&a…

环境配置02:CUDA安装

1. CUDA安装 Nvidia官网下载对应版本CUDA Toolkit CUDA Toolkit 12.1 Downloads | NVIDIA Developer CUDA Toolkit 12.5 Downloads | NVIDIA Developer 安装配置步骤参考:配置显卡cuda与配置pytorch - 知乎 (zhihu.com) 2. 根据CUDA版本,安装cudnn …

生育是家庭和个人的重要的选择

生育是个人和家庭的重要选择,而国家对于生育政策的制定应该综合考虑多种因素,包括人口结构、经济发展和社会稳定等。同时,我们也应该认识到,男女不应该成为决定一个人是否能够生育的因素。男女在生育中扮演着不同的角色&#xff0…

程序员必须知道!Serverless超强打造国产BAAS

在当今快节奏的软件开发领域,懒人开发者和独立开发者们一直在寻找能够简化开发流程、提高效率的利器。而今,MemFire Cloud以其强大的功能和简便的操作,成为了解决方案中的明星。无需搭建服务,无需开发API接口,你甚至可…

Python画箱线图展示数据分布情况

箱线图(Boxplot)是一种常用的统计图表,用于展示数据的分布情况。 它由五个统计量组成:最小值、第一四分位数(Q1)、中位数(Q2)、第三四分位数(Q3)和最大值。 …

【c语言】字符串函数和内存函数

🌟🌟作者主页:ephemerals__ 🌟🌟所属专栏:C语言 目录 前言 一、字符串函数 1.strlen的使用和模拟实现 2.strcpy的使用和模拟实现 3.strcat的使用和模拟实现 4.strcmp的使用和模拟实现 5.strstr的使…