xml database (xdb)使我们能够使用ftp和html协议访问和管理asm磁盘组中的文件,可以方便的浏览和移入和移出。1. 查看当前的监听
xml database (xdb)使我们能够使用ftp和html协议访问和管理asm磁盘组中的文件,
pl/sql procedure successfully completed.
sql> execute dbms_xdb.setftpport(2100);
pl/sql procedure successfully completed.
sql> commit;
commit complete.
3. 重启数据库
$ srvctl stop database -d test
$ srvctl start database -d test
4. 查看ftp和http是否被监听,如果没有,,则重启监听
$ lsnrctl status
lsnrctl for linux: version 10.2.0.4.0 - production on 04-nov-2010 10:57:31
copyright (c) 1991, 2007, oracle. all rights reserved.
connecting to (address=(protocol=tcp)(host=)(port=1521))
status of the listener
------------------------
alias listener_db07
version tnslsnr for linux: version 10.2.0.4.0 - production
start date 29-oct-2010 13:13:18
uptime 5 days 21 hr. 44 min. 13 sec
trace level off
security on: local os authentication
snmp off
listener parameter file /home/oratest/product/10.2.0/db_1/network/admin/listener.ora
listener log file /home/oratest/product/10.2.0/db_1/network/log/listener_db07.log
listening endpoints summary...
(description=(address=(protocol=tcp)(host=10.32.10.247)(port=1521)))
(description=(address=(protocol=tcp)(host=10.32.10.72)(port=1521)))
(description=(address=(protocol=tcp)(host=db07.jiade.com)(port=8080))(presentation=http)(session=raw))
(description=(address=(protocol=tcp)(host=db07.jiade.com)(port=2100))(presentation=ftp)(session=raw))
services summary...
service +asm has 1 instance(s).
instance +asm1, status blocked, has 1 handler(s) for this service...
service +asm_xpt has 1 instance(s).
instance +asm1, status blocked, has 1 handler(s) for this service...
service plsextproc has 1 instance(s).
instance plsextproc, status unknown, has 1 handler(s) for this service...
service test has 2 instance(s).
instance test1, status ready, has 2 handler(s) for this service...
instance test2, status ready, has 1 handler(s) for this service...
service testxdb has 2 instance(s).
instance test1, status ready, has 1 handler(s) for this service...
instance test2, status ready, has 1 handler(s) for this service...
service test_xpt has 2 instance(s).
instance test1, status ready, has 2 handler(s) for this service...
instance test2, status ready, has 1 handler(s) for this service...
the command completed successfully
已经正常监听http:8080和ftp:2100端口。
5. 看看ftp
$ ftp -n
ftp> open db07 2100
connected to db07.jiade.com.
220- db07
unauthorised use of this ftp server is prohibited and may be subject to civil and criminal prosecution.
220 db07 ftp server (oracle xml db/oracle database) ready.
530 please login with user and pass.
530 please login with user and pass.
kerberos_v4 rejected as an authentication type
ftp> user system system_password (数据库用户和密码)
331 pass required for system
230 system logged in
简单命令:
ls : 列出当前目录下的所有文件和目录
cd : 切换目录
step-by-step
ftp> ls
227 entering passive mode (10,32,10,72,112,6)
150 ascii data connection
drw-r--r-- 2 sys oracle 0 sep 14 03:55 home
drw-r--r-- 2 sys oracle 0 mar 12 00:59 public
drw-r--r-- 2 sys oracle 0 sep 14 03:55 sys
-rw-r--r-- 1 sys oracle 0 nov 04 02:50 xdbconfig.xml
ftp> cd sys
ftp> ls
200 port command successful
150 ascii data connection
drw-r--r-- 2 sys oracle 0 mar 12 00:59 acls
drw-r--r-- 2 sys oracle 0 mar 12 00:59 apps
drw-r--r-- 2 sys oracle 0 mar 12 00:59 asm
-rw-r--r-- 1 sys oracle 0 sep 14 03:55 databasesummary.xml
drw-r--r-- 2 sys oracle 0 mar 12 00:59 log
drw-r--r-- 2 sys oracle 0 mar 12 00:59 oid
drw-r--r-- 2 sys oracle 0 sep 14 03:55 schemas
226 ascii transfer complete
ftp> cd asm
250 cwd command successful
ftp> ls
227 entering passive mode (10,32,10,72,56,54)
150 ascii data connection
drw-r--r-- 2 sys oracle 0 nov 04 03:13 data (2个diskgroups)
drw-r--r-- 2 sys oracle 0 nov 04 03:13 flash_recovery_area
226 ascii transfer complete
ftp> pwd
257 /sys/asm/data/test/datafile is current directory.
ftp> ls
200 port command successful
150 ascii data connection
-rw-r--r-- 1 sys oracle 681582592 nov 04 03:18 sysaux.256.734110923
-rw-r--r-- 1 sys oracle 524296192 nov 04 03:18 system.257.734111145
-rw-r--r-- 1 sys oracle 104865792 nov 04 03:18 example.258.734111271
-rw-r--r-- 1 sys oracle 89137152 nov 04 03:18 undotbs1.259.734111315
-rw-r--r-- 1 sys oracle 34611200 nov 04 03:18 undotbs2.260.734111351
-rw-r--r-- 1 sys oracle 5251072 nov 04 03:18 users.262.734111393
226 ascii transfer complete
flash_recovery_area 磁盘组
ftp> pwd
257 /sys/asm/flash_recovery_area/test/archivelog/2010_11_04 is current directory.
ftp> ls
200 port command successful
150 ascii data connection
-rw-r--r-- 1 sys oracle 45303808 nov 04 03:20 thread_1_seq_123.472.734176827
226 ascii transfer complete
ftp> lcd (自己在server的位置)
local directory now /
下载文件:
ftp> ls
227 entering passive mode (10,32,10,72,126,198)
150 ascii data connection
-rw-r--r-- 1 sys oracle 45303808 nov 04 03:22 thread_1_seq_123.472.734176827
226 ascii transfer complete
ftp> bin
200 type set to i.
ftp> get thread_1_seq_123.472.734176827
local: thread_1_seq_123.472.734176827 remote: thread_1_seq_123.472.734176827
227 entering passive mode (10,32,10,72,84,203)
150 bin data connection
226 bin transfer complete
45303808 bytes received in 1 seconds (4.4e+04 kbytes/s)
6. http
:8080
出来窗口输入数据库用户密码
