instalMV BigData Sergio
instalMV BigData Sergio
instalMV BigData Sergio
Suivre ce lien et cliquer sur readme pour installation la machine virtuelle Big
Data MBDS/BIHAR
oracle-21c-vagrant
This Vagrant project builds an Oracle Linux 8 virtual machine.
The virtual machine is provisioned with scripts from the scripts directory,
configuration files from the config directory and other installation files that
need to be placed in the same directory as this README.md.
Prerequisites
Hardware
To build and run this project it is required that your computer supports
virtualization, have 30G of available disk space and 5G of available RAM.
Software
Install a Git client (for example git SCM).
Install Oracle VM VirtualBox 6.1 (Vagrant doesn't support VirtualBox version 7 at
the time of writing).
Install the VirtualBox Extension Pack.
Install Vagrant and (optionally) the vagrant-env plugin.
Setup installation files
Clone this repository's staging branch.
git clone -b staging https://github.com/SergioSim/vagrant-projects.git
Download the Oracle Database 21.3.0 installation zip file
(LINUX.X64_213000_db_home.zip) from OTN (the first time only) and place it in the
vagrant-projects/OracleDatabase/21.3.0 directory:
http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html
Download the Oracle NoSQL Database Enterprise Edition 22.3.32 installation zip file
(V1034077-01.zip) and examples (V1020129-01.zip) from OTN (the first time only) and
place it in the vagrant-projects/OracleDatabase/21.3.0 directory:
https://www.oracle.com/database/technologies/nosql-database-server-downloads.html
Note: Do not unzip the installation files. Double check that the installation
filenames match : LINUX.X64_213000_db_home.zip, V1034077-01.zip and V1020129-
01.zip.
To start interacting with the virtual machine, open a terminal and change into the
vagrant-projects/OracleDatabase/21.3.0 directory.
$ cd vagrant-projects/OracleDatabase/21.3.0
Get virtual machine status information
To get a short report about the current state of the virtual machine, you can use
the following command:
$ vagrant status
The command should output something like:
$ vagrant halt
Remove the virtual machine
To remove the virtual machine completely you can use the following commands:
$ vagrant destroy
$ vagrant box remove oraclelinux/8
Start the virtual machine
To start or restart the virtual machine you can use the following command:
$ vagrant up
Note: Provisioning scripts only run once at the very first start.
$ vagrant ssh
The command should provide you with a bash prompt for the vagrant user inside the
virtual machine (without requiring a password):
[vagrant@oracle-21c-vagrant ~]$
Note: the vagrant user has sudo privileges. If you would like to switch to the root
user you can run the sudo su - command.
Troubleshooting
If some components of this virtual machine stop working it is possible to re-
install them by re-running their corresponding provisioning scripts.
To update all changes made in the config directory (recopy all files to their
corresponding destination).
Note: Kafka consumes 1.5 G of additional RAM, consider increasing the VM_MEMORY up
to 6-7G in the Vagrantfile or stop unused services to save memory.
Note: running the 02_prerequisites.sh script is only required if you have installed
the VM prior to the Kafka installation addition.
Note: running the 02_prerequisites.sh script is only required if you have installed
the VM prior to the Sqoop installation addition.
<property>
<name>mapreduce.framework.name</name>
<value>yarn</value>
<description>
Local mode runs faster in a single node setup for simple tasks.
To use pseudo-distributed mode set the value to "yarn".
</description>
</property>
For the changes to apply - restart Yarn:
stop-yarn.sh
start-yarn.sh
To install Jupyter Notebook
cd /vagrant
jupyter notebook --ip=0.0.0.0
Connecting to Oracle
The default database connection parameters are:
Hostname: localhost
Port: 1521
SID: ORCLCDB
PDB: ORCLPDB1
EM Express port: 5500
Database passwords are auto-generated and printed on install
These parameters can be customized, if desired (see Configuration).
Resetting password
You can reset the password of the Oracle database accounts (SYS, SYSTEM and
PDBADMIN only) by switching to the oracle user (sudo su - oracle), then
executing /home/oracle/setPassword.sh <Your new password>.
Shell scripts will be executed as root. SQL scripts will be executed as SYS. SQL
scripts will run against the CDB, not the PDB, unless you include an ALTER SESSION
SET CONTAINER = <pdbname> statement in the script.
To run scripts in a specific order, prefix the file names with a number, e.g.,
01_shellscript.sh, 02_tablespaces.sql, 03_shellscript2.sh, etc.
Configuration
The Vagrantfile can be used as-is, without any additional configuration. However,
there are several parameters you can set to tailor the installation to your needs.
How to configure
There are three ways to set parameters:
Update the Vagrantfile. This is straightforward; the downside is that you will lose
changes when you update this repository.
Use environment variables. It might be difficult to remember the parameters used
when the VM was instantiated.
Use the .env/.env.local files (requires vagrant-env plugin). You can configure your
installation by editing the .env file, but .env will be overwritten on updates, so
it's better to make a copy of .env called .env.local, then make changes
in .env.local. The .env.local file won't be overwritten when you update this
repository and it won't mark your Git tree as changed (you won't accidentally
commit your local configuration!).
Parameters are considered in the following order (first one wins):
Environment variables
.env.local (if it exists and the vagrant-env plugin is installed)
.env (if the vagrant-env plugin is installed)
Vagrantfile definitions
VM parameters
VM_NAME (default: oracle-21c-vagrant): VM name.
VM_MEMORY (default: 5120): memory for the VM (in MB, 5120 MB = 5 GB).
VM_SYSTEM_TIMEZONE (default: host time zone (if possible)): VM time zone.
The system time zone is used by the database for SYSDATE/SYSTIMESTAMP.
The guest time zone will be set to the host time zone when the host time zone is a
full hour offset from GMT.
When the host time zone isn't a full hour offset from GMT (e.g., in India and parts
of Australia), the guest time zone will be set to UTC.
You can specify a different time zone using a time zone name (e.g.,
"America/Los_Angeles") or an offset from GMT (e.g., "Etc/GMT-2"). For more
information on specifying time zones, see List of tz database time zones.
Oracle Database parameters
VM_ORACLE_BASE (default: /opt/oracle/): Oracle base directory.
VM_ORACLE_HOME (default: /opt/oracle/product/21c/dbhome_1): Oracle home directory.
VM_ORACLE_SID (default: ORCLCDB): Oracle SID.
VM_ORACLE_PDB (default: ORCLPDB1): PDB name.
VM_ORACLE_CHARACTERSET (default: AL32UTF8): database character set.
VM_ORACLE_EDITION (default: EE): Oracle Database edition. Either EE for Enterprise
Edition or SE2 for Standard Edition 2.
VM_LISTENER_PORT (default: 1521): Listener port.
VM_EM_EXPRESS_PORT (default: 5500): EM Express port.
VM_ORACLE_PWD (default: automatically generated): Oracle Database password for the
SYS, SYSTEM and PDBADMIN accounts.
Optional plugins
When installed, this Vagrant project will make use of the following third party
Vagrant plugins: