本机远程访问192.168.2.1的共享服务器再访问另一台安装oracle的linux系统机子,部署项目

本文介绍如何使用SSH Secure File Transfer Client在两台服务器间安全地传输文件,并利用SSH Secure Shell Client登录远程服务器创建Oracle表空间及用户,进行权限分配及数据导入等操作。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

192.168.2.1访问192.168.3.126的数据库服务器(Linux下的oracle)

使用SSH Secure File (SSH Secure File Transfer Client互相传文件免去了DOS下FTP上传文件、SSH Secure Shell Client登录)

 

1.SSH Secure File Transfer Client

使用DOS命令FTP上传文件给另一台服务器


 

 

 

2.SSH Secure Shell Client登录进入另一台服务器的oracle(用户名密码oracle)

创建表空间,用户密码

--创建表空间

create tablespace elearning

logging

datafile ‘elearning.dbf' --物理存放位置

size 100m --初始大小

autoextend on --自动增长

next 10m maxsize 1000m --最大大小

extent management local --其他属性默认  extent-范围

 

 

--创建用户指定密码

create user elearning identified by elearning

default tablespace elearning --指定默认表空间

grant connect, resource, dba to elearning --赋予权限

  以下步骤是导入的

2、  连接数据库:sqlplus sys/orcl@orcl as sysdba

3、  创建表空间 create tablespace egg datafile 'C:\/egg.dbf' size 100M autoextend onmaxsize unlimited;

4、  创建用户 create user egg identified by orcl default tablespace egg accountunlock;

5、  用户授权 grant connect,resource,dba to egg;

6、  imp egg/orcl@orcl file=c:\/egg.dmp fromuser=egg touser=egg ignore=y(此句直接用于CMD命令下,注意,fromuser是数据导出时的用户名,touser是你现在导入数据要使用的用户名)

7、  连接数据库:sqlplus egg/orcl@orcl as sysdba

可以使用select语句对egg的table进行查询。成功了。

imp elearning/elearning@orcl file=c:\/elearning.dmp full=y ignore=y

 

Failed to open expat.dmp for read出错后,(学习一下Linux命令)

pwd显示当前目录

ls打印出当前目录的清单

 

 

 

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值