当前位置:网站首页>centos——开启/关闭oracle
centos——开启/关闭oracle
2022-06-30 20:11:00 【专注写bug】
资料参考
centos7虚拟机启动Oracle数据库和关闭命令行操作指导
自己操作心得
由于停电,导致测试服务器关机重启,oracle并未启动。遂启动oracle。
启动oracle必须保证下面的这个顺序:
停监听 – 登数据库— 停数据库服务 – 启动数据库服务 — 启动监听
停监听
停监听,需要将root账户切换到oracle账户,使用下列命令:
[[email protected] ~]#
su - oracle

登数据库
这里的登数据库,是使用sqlplus进行登录。先使用sqlplus /nolog登录sqlplus,再使用conn / as sysdba以sysdba 登录数据库。其实上面的两个命令可以简写成下面的方式:
sqlplus / as sysdba

停oracle服务
上面的命令执行后,会出现一个sqlplus的命令窗口,再窗口中输入下面命令:
SQL> shutdown immediate;
即可停止oracle服务。
启动数据库服务
采取startup命令进行数据库服务的启动:
SQL> startup;
当执行命令后,窗口出现如下信息,表示启动成功:
开启监听
当数据库的服务启动后,需要再次开启服务监听。此时命令还在SQL>中,需要先进行退出操作,再执行监听开启命令:
lsnrctl start
完整流程如下所示:
此时再通过lsnrctl status可以查看到当前监听的状态信息。
问题记录——远程pl/sql连接超时
这种问题,如果是服务器本机上进行连接操作能够成功,远程连接会超时,需要注意防火墙设置。
开放指定端口。
不要使用 iptables -F,这种命令虽然能够在不关闭防火墙的前提下,放开所有端口的限制,但还是不安全!
边栏推荐
- 最新海康摄像机、NVR、流媒体服务器、回放取流RTSP地址规则说明[通俗易懂]
- Label Contrastive Coding based Graph Neural Network for Graph Classification
- SQL优化
- 北京大学ACM Problems 1003:Hangover
- Huffman Tree (1) Basic Concept and C - language Implementation
- 亚马逊在阿拉伯联合酋长国限制LGBTQ相关的搜索和产品销售
- 黑苹果 服务器系统安装教程,黑苹果安装教程,详细教您黑苹果怎么安装[通俗易懂]
- A complete collection of vulnerability scanning tools. Mom doesn't have to worry that I won't find any more vulnerabilities
- Summary of personal work of 21 groups in the first week of summer training
- 大神详解开源 BUFF 增益攻略丨直播
猜你喜欢

为什么vscode用久了电脑速度变慢?

PHP obtains opcode and C source code

All the important spark summit features were released here last night (with ultra clear video attached)

左值引用和右值引用

obsidian配合hugo的使用,让markdown本地编辑软件与在线化无缝衔接

杰理之触摸按键识别流程【篇】

NLP 论文领读|文本生成模型退化怎么办?SimCTG 告诉你答案

树基本概念

Great God detailed open source Buff gain Introduction 丨 Live

Jenkins can't pull the latest jar package
随机推荐
NLP 论文领读|文本生成模型退化怎么办?SimCTG 告诉你答案
DEX文件解析 - method_ids解析
北京大学ACM Problems 1003:Hangover
Summary of personal work of 21 groups in the first week of summer training
为什么vscode用久了电脑速度变慢?
On inline function
Lumiprobe染料 NHS 酯丨BDP FL NHS 酯研究
The newly born robot dog can walk by himself after rolling for an hour. The latest achievement of Wu Enda's first disciple
jfinal中如何使用过滤器监控Druid监听SQL执行?
Pytorch implements the calculation of flops and params
Big God explains open source buff gain strategy live broadcast
Web host iptables firewall security script
Jerry's touch key recognition process [chapter]
Openfire solves the problem of Chinese garbled code after using MySQL database
Meeting, onemeeting, OK!
树基本概念
Jerry's question about long press boot detection [chapter]
maya房子建模
obsidian配合hugo的使用,让markdown本地编辑软件与在线化无缝衔接
Wechat applet development practice cloud music