创建外部用户_外部表

创建外部用户_外部表

大家好,又见面了,我是你们的朋友全栈君。

[root@localhost ~]# su - oracle

[oracle@localhost ~]$ sqlplus / as sysdba;

SQL*Plus: Release 11.2.0.3.0 Production on Fri Jul 13 22:22:59 2018

Copyright (c) 1982, 2011, Oracle.  All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

SYS@orcl> select instance_name ,status from v$instance;

INSTANCE_NAME    STATUS
---------------- ------------
orcl             OPEN

SYS@orcl> quit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@localhost ~]$ exit
logout

[root@localhost ~]# who am i
root     pts/10       2018-07-13 22:22 (192.168.242.1)
[root@localhost ~]#  useradd oracleexternal
[root@localhost ~]# passwd oracleexternal
Changing password for user oracleexternal.
New UNIX password:
Retype new UNIX password:
passwd: all authentication tokens updated successfully.
[root@localhost ~]# su - oracleexternal
[oracleexternal@localhost ~]$ cat .bash_profile
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/bin

export PATH
[oracleexternal@localhost ~]$ vi .bash_profile

# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/bin

export PATH
export ORACLE_SID=orcl
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1
export PATH=$PATH:$ORACLE_HOME/bin
export ORACLE_TERM=xterm
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ORACLE_HOME/lib

export CLASSPATH=$ORACLE_HOME/JRE:ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
~
~
~
~
~
~
".bash_profile" 20L, 479C written
[oracleexternal@localhost ~]$ cat .bash_profile
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/bin

export PATH
export ORACLE_SID=orcl
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1
export PATH=$PATH:$ORACLE_HOME/bin
export ORACLE_TERM=xterm
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ORACLE_HOME/lib

export CLASSPATH=$ORACLE_HOME/JRE:ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
[oracleexternal@localhost ~]$  source .bash_profile
[oracleexternal@localhost ~]$ su - oracle
Password:
[oracle@localhost ~]$ rlwrap sqlplus / as sysdba;

SQL*Plus: Release 11.2.0.3.0 Production on Fri Jul 13 22:25:45 2018

Copyright (c) 1982, 2011, Oracle.  All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

SYS@orcl> show parameter os

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
db_lost_write_protect                string      NONE
diagnostic_dest                      string      /u01/app/oracle
optimizer_index_cost_adj             integer     100
os_authent_prefix                    string      ops$
os_roles                             boolean     FALSE
remote_os_authent                    boolean     FALSE
remote_os_roles                      boolean     FALSE
timed_os_statistics                  integer     0
SYS@orcl> create user ops$oracleexternal identified externally;

User created.

SYS@orcl> grant create session to ops$oracleexternal;

Grant succeeded.

SYS@orcl> quit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@localhost ~]$ exit
logout

[oracleexternal@localhost ~]$ who am
[oracleexternal@localhost ~]$ whoami
oracleexternal
[oracleexternal@localhost ~]$ sqlplus /

SQL*Plus: Release 11.2.0.3.0 Production on Fri Jul 13 22:27:16 2018

Copyright (c) 1982, 2011, Oracle.  All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options



OPS$ORACLEEXTERNAL@orcl>
OPS$ORACLEEXTERNAL@orcl>  set time on;
22:29:13 OPS$ORACLEEXTERNAL@orcl>

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/107420.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • NAS备份, NDMP

    NAS备份, NDMP

    2022年3月8日
    126
  • 2022年Redis最新面试题第6篇 – Redis淘汰策略「建议收藏」

    2022年Redis最新面试题第6篇 – Redis淘汰策略「建议收藏」Redis过期键的删除策略?出现概率:★★★★Redis过期键的删除策略是:定期删除+惰性删除。1)、关于定期删除,Redis默认会每隔100ms就随机选取一些已经过期了的key,检查其是否过期,如果已经过期就删除。不过假设Redis里放了100w个key,而且都设置了过期时间,你每隔几百毫秒,就检查100w个key,那Redis基本上就卡死了,cpu负载也会很高的,基本都消耗在检查过期key上了。注意,这里可不是每隔100ms就遍历所有的设置过期时间的key,那样就是一场性能上的灾难。实际情况是每

    2022年10月21日
    4
  • 数据平滑处理

    数据平滑处理

    2021年11月21日
    51
  • cpu不能直接读取和执行_pc机有几个微处理器

    cpu不能直接读取和执行_pc机有几个微处理器笔记本电脑最重要的硬件是CPU(中央处理器)。它的质量直接关系到计算机的性能。CPU不好,其他硬件也很好,计算机性能也不好。因此,购买笔记本电脑时,务必要考虑CPU性能。以下编辑器分享了笔记本计算机的CPU性能排名,让我们看一下。笔记本CPU性能排名清单排名模型CPU标记值[第一名]IntelXeonE5-2687W@3.10GHz[评分:14564][第二名]IntelXeon…

    2026年1月29日
    4
  • matlab检验贝塔分布规律,贝塔分布背后的直觉:概率的概率分布

    matlab检验贝塔分布规律,贝塔分布背后的直觉:概率的概率分布编者按 贝塔分布的定义很简单 具有两个参数 gt 0 的一组定义在 0 1 区间的连续概率分布 但是 它背后的直觉却不是那么明显 StackOverflo 数据科学家 DavidRobinso 在 CrossValidat 解释了贝塔分布背后的直觉 简而言之 贝塔分布代表 probabilitie 概率的复数形式 的分布 也就是说 它代表当我们不知道概率是什么时 概率的所有

    2025年8月29日
    4
  • latex在大括号里换行_大括号的解决问题

    latex在大括号里换行_大括号的解决问题存在问题:在编译LaTex的时候,会出现存在大括号\left(\right),但是一旦公式过长需要换行时,例如这个时候会用到\\与&来做换行,但如果直接编译的话,会报错,例如解决办法:在换行符前面加入变成\right.\\与&\left.这样就可以解决大括号换行的问题了,一个小点千万别漏写了…

    2022年10月11日
    7

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号