Windows啟動ServerDB Script
LocalDB.bat:
set PATH=E:\app\oracle\product\10.2.0\db_1\BIN;C:\Windows\System32;
set nls_lang=AMERICAN_AMERICA.UTF8;
sc start OracleOraDb10g_home1TNSListener
sc start OracleServiceBRUCE
ping localhost -n 15 >nul
lsnrctl status
sqlplus / as sysdba @e:\app\SelectDB.sql @e:\xxxxxx\plsql common use sql\sp
SelectDB.sql:
set pagesize 100
set linesize 160
--set timing on
col tablespace_name format a25
select x.tablespace_name,y.bytes/1024/1024 total_size_mb,x.bytes/1024/1024 free_size_mb,(y.bytes-x.bytes)/1024/1024 use_size_mb,round((y.bytes-x.bytes)/y.bytes,4)*100 usage
from
(select tablespace_name,sum(bytes) bytes from dba_free_space group by tablespace_name) x,
(select tablespace_name,sum(bytes) bytes from dba_data_files group by tablespace_name) y
where x.tablespace_name=y.tablespace_name
order by 5 desc;
select instance_name from v$instance;
select open_mode from v$database;
set PATH=E:\app\oracle\product\10.2.0\db_1\BIN;C:\Windows\System32;
set nls_lang=AMERICAN_AMERICA.UTF8;
sc start OracleOraDb10g_home1TNSListener
sc start OracleServiceBRUCE
ping localhost -n 15 >nul
lsnrctl status
sqlplus / as sysdba @e:\app\SelectDB.sql @e:\xxxxxx\plsql common use sql\sp
SelectDB.sql:
set pagesize 100
set linesize 160
--set timing on
col tablespace_name format a25
select x.tablespace_name,y.bytes/1024/1024 total_size_mb,x.bytes/1024/1024 free_size_mb,(y.bytes-x.bytes)/1024/1024 use_size_mb,round((y.bytes-x.bytes)/y.bytes,4)*100 usage
from
(select tablespace_name,sum(bytes) bytes from dba_free_space group by tablespace_name) x,
(select tablespace_name,sum(bytes) bytes from dba_data_files group by tablespace_name) y
where x.tablespace_name=y.tablespace_name
order by 5 desc;
select instance_name from v$instance;
select open_mode from v$database;
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/24237320/viewspace-1778535/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 自動啟動ORACLE Script ServiceOracle
- Use windows batch script to create menuWindowsBAT
- windows defender怎麼開啟 windows defender啟動方法Windows
- Windows 啟動過程Windows
- windows自動登入telnet批處理檔案VBS法(Windows Script Host)Windows
- Get your Windows product key from a scriptWindows
- windows開機自動啟動oracleWindowsOracle
- Windows環境啟動RocketMQWindowsMQ
- windows啟動管理器未能啟動如何解決Windows
- 自動重新啟動oracle例項 for windowsOracleWindows
- windows下oracle自動啟動指令碼WindowsOracle指令碼
- Windows 設定 FRP 自動啟動WindowsFRP
- windows下啟動nacos服務Windows
- Windows 安裝包啟動PostgresqlWindowsSQL
- windows 卡在正在啟動問題Windows
- 讓ubuntu預設啟動windowsUbuntuWindows
- Windows開機啟動指定程式Windows
- windows下啟動服務時不啟動oracle例項WindowsOracle
- Powershell script to install Windows Updates (msu) from folderWindows
- Windows10 開機自動啟動 VagrantWindows
- 自動重新啟動oracle監聽程式 for windowsOracleWindows
- Shell Script(bash)--用於自動備份的Shell Script(轉)
- windows10未能啟動怎麼修復_windows10無法啟動解決方法Windows
- windows10怎麼關閉快速啟動_windows10關閉快速啟動的方法Windows
- 求助:windows啟動時卡住,必須重啟……(轉)Windows
- UEFI雙啟動Windows和LinuxWindowsLinux
- Windows 8下如何禁用啟動項Windows
- python得到windows自啟動列表PythonWindows
- Windows 下快速後臺啟動 RedisWindowsRedis
- MySQL Windows下關閉和啟動MySqlWindows
- 談Windows 7的VHD啟動薦Windows
- windows 下 asm儲存啟動故障WindowsASM
- 在Windows下啟動Linux(轉)WindowsLinux
- windows如何開機自動啟動某些應用?Windows
- Windows10系統開啟快速啟動的方法Windows
- windows10開機啟動項在哪裡_windows10開機啟動項怎麼設定Windows
- Windows bcdedit刪除多啟動項---Windows 7環境下Windows
- wsl 中啟動 Windows 的 *.exe 應用Windows