用到的linux 和oracle命令

來源:互聯網
上載者:User

---使用oracle使用者,進入sqlplus 刪除使用者再建立一個使用者並賦權

--許可權中要有synonym 否則imp dmp檔案的時候,會出錯

su - oracle

sqlplus / as sysdba

drop user base cascade;
create user base identified by zdsoft default tablespace tbs_base;
grant connect,resource,create table,create view,execute any procedure,create any synonym to base;

 

--exit到命令列執行,將dmp資料匯入到資料庫
imp system/zdsoft  file=center2010-08-04.dmp  fromuser=sxcenter touser=base2

 

--匯出該使用者的資料庫到dmp檔案

exp base/zdsoft file=base2.6/base2.0_201008.dmp

 

--匯出指定的表到dmp

exp base2/zdsoft file=base2.6/base2.0_201008.dmp  tables=base_class,base_dept,base_family,base_grade,base_school,base_student,base_teacher,base_unit,base_user,base_order,su_ware,su_server,base_order_his 

 

-- 拷貝base2.6檔案夾到到其他的機器

scp -r base2.6/ oracle@192.168.1.86:/home/oracle/

 

 

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.