[20210722]sqlplus下show recycebin的小问题.txt
--//sqlplus下执行show recycebin遇到一些疑问,通过测试慢慢展开问题的探究.
1.环境:
SCOTT@test01p> @ ver1
PORT_STRING VERSION BANNER CON_ID
------------------------------ -------------- -------------------------------------------------------------------------------- ----------
IBMPC/WIN_NT64-9.1.0 12.2.0.1.0 Oracle Database 12c Enterprise Edition Release 12.2.0.1.0 - 64bit Production 0
SCOTT@test01p> create table tx as select * from dept ;
Table created.
SCOTT@test01p> create table ty as select * from dept ;
Table created.
2.测试:
SCOTT@test01p> show recyclebin
SCOTT@test01p> drop table tx ;
Table dropped.
SCOTT@test01p> drop table ty ;
Table dropped.
SCOTT@test01p> show recyclebin
ORIGINAL NAME RECYCLEBIN NAME OBJECT TYPE DROP TIME
---------------- ------------------------------ ------------ -------------------
TX BIN$T7f14az+TMuluJgGIOXiPA==$0 TABLE 2021-07-21:20:33:43
TY BIN$5quvB25qT7eMZtdPExTTZg==$0 TABLE 2021-07-21:20:33:45
--//OK正确.在结尾加入分号看看.
SCOTT@test01p> show recyclebin;
ORIGINAL NAME RECYCLEBIN NAME OBJECT TYPE DROP TIME
---------------- ------------------------------ ------------ -------------------
TX BIN$T7f14az+TMuluJgGIOXiPA==$0 TABLE 2021-07-21:20:33:43
TY BIN$5quvB25qT7eMZtdPExTTZg==$0 TABLE 2021-07-21:20:33:45
--//OK正确.在结尾加入空格(tab键)与分号看看.
SCOTT@test01p> show recyclebin ;
--//显示为空,为什么?
3.使用toad自带的SQL Tracker跟踪:
SELECT ORIGINAL_NAME ORIGNAME_PLUS_SHOW_RECYC,
OBJECT_NAME OBJECTNAME_PLUS_SHOW_RECYC,TYPE OBJTYPE_PLUS_SHOW_RECYC,
DROPTIME DROPTIME_PLUS_SHOW_RECYC
FROM USER_RECYCLEBIN
WHERE CAN_UNDROP = 'YES'
AND ORIGINAL_NAME = UPPER(:NMBIND_SHOW_OBJ)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ORDER BY ORIGINAL_NAME,DROPTIME DESC,OBJECT_NAME;
--//为了美观,我做了格式化处理.你可以发现下划线带入参数:NMBIND_SHOW_OBJ.很明显我在分号前一个空格的情况下,
--//带入的参数为空,这样就没有显示.
SCOTT@test01p> show recyclebin tx
ORIGINAL NAME RECYCLEBIN NAME OBJECT TYPE DROP TIME
---------------- ------------------------------ ------------ -------------------
TX BIN$T7f14az+TMuluJgGIOXiPA==$0 TABLE 2021-07-21:20:33:43
SCOTT@test01p> show recyclebin tx ;
ORIGINAL NAME RECYCLEBIN NAME OBJECT TYPE DROP TIME
---------------- ------------------------------ ------------ -------------------
TX BIN$T7f14az+TMuluJgGIOXiPA==$0 TABLE 2021-07-21:20:33:43
--//你可以发现带入参数的情况下显示正确.如果你执行show recyclebin;执行的sqlplus如下:
SELECT ORIGINAL_NAME ORIGNAME_PLUS_SHOW_RECYC,
OBJECT_NAME OBJECTNAME_PLUS_SHOW_RECYC,TYPE OBJTYPE_PLUS_SHOW_RECYC,
DROPTIME DROPTIME_PLUS_SHOW_RECYC
FROM USER_RECYCLEBIN
WHERE CAN_UNDROP = 'YES'
ORDER BY ORIGINAL_NAME,DROPTIME DESC,OBJECT_NAME
--//没有绑定变量,说明我的判断正确.
4.继续,以上测试在windows下进行,如果linux呢?
SCOTT@book> @ ver1
PORT_STRING VERSION BANNER
------------------------------ -------------- --------------------------------------------------------------------------------
x86_64/Linux 2.4.xx 11.2.0.4.0 Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
SCOTT@book> show recyclebin;
ORIGINAL NAME RECYCLEBIN NAME OBJECT TYPE DROP TIME
---------------- ------------------------------ ------------ -------------------
TY BIN$x5jlVlgTFx3gU05kqMAqNg==$0 TABLE 2021-07-21:09:20:02
SCOTT@book> show recyclebin ;
ORA-24550: signal received: [si_signo=11] [si_errno=0] [si_code=1] [si_int=33260000] [si_ptr=0x1fb81e0] [si_addr=(nil)]
kpedbg_dmp_stack()+362
<-kpeDbgCrash()+192
<-kpeDbgSignalHandler()+119
<-skgesig_sigactionHandler()+218
<-__sighandler()
<-afiwsk()+544
<-afinsym()+80
<-afishosop()+1930
<-afisho()+516
<-aficmd()+2714
<-aficfd()+2669
<-aficdr()+138
<-afidrv()+4237
<-frame_dummy()+123
<-__libc_start_main()+244
--//注:我做了折行处理,不然太长了。
rlwrap: warning: sqlplus crashed, killed by SIGSEGV.
rlwrap itself has not crashed, but for transparency,
it will now kill itself (without dumping core) with the same signal
warnings can be silenced by the --no-warnings (-n) option
Segmentation fault
--//在分号前有空格的情况下,连接进程直接crash.
--//使 stack:
Discovered stack type: short stack
Parsed short stack:
kpedbg_dmp_stack()+362 kernel programmatic interface [partial hit for: kp ]
kpeDbgCrash()+192 kernel programmatic interface [partial hit for: kp ]
kpeDbgSignalHandler()+119 kernel programmatic interface [partial hit for: kp ]
skgesig_sigactionHandler()+218 operating system dependent kernel generic [partial hit for: skg ]
__sighandler() (?) [partial hit for: ]
afiwsk()+544 (?) [partial hit for: ]
afinsym()+80 (?) [partial hit for: ]
afishosop()+1930 (?) [partial hit for: ]
afisho()+516 (?) [partial hit for: ]
aficmd()+2714 (?) [partial hit for: ]
aficfd()+2669 (?) [partial hit for: ]
aficdr()+138 (?) [partial hit for: ]
afidrv()+4237 (?) [partial hit for: ]
frame_dummy()+123 (?) [partial hit for: ]
__libc_start_main()+244 (?) [partial hit for: ]
$ oerr ora 24550
24550, 00000, "unhandled signal #%ld received. %s"
// *Cause: Serious error: signal received
// *Action: Refer to the platform-specific signal code, and see if the
// application code caused the error. Otherwise, record
// all error state and notify Oracle Support Services.
5.继续登录测试:
SCOTT@book> @ spid
SID SERIAL# PROCESS SERVER SPID PID P_SERIAL# C50
---------- ---------- ------------------------ --------- ------ ------- ---------- --------------------------------------------------
295 9 17218 DEDICATED 17219 21 5 alter system kill session '295,9' immediate;
$ strace -f -p 17219
Process 17219 attached - interrupt to quit
read(7, "", 8208) = 0
close(10) = 0
close(7) = 0
getrusage(RUSAGE_SELF, {ru_utime={0, 22996}, ru_stime={0, 14997}, ...}) = 0
times({tms_utime=2, tms_stime=1, tms_cutime=0, tms_cstime=0}) = 1825693747
times({tms_utime=2, tms_stime=1, tms_cutime=0, tms_cstime=0}) = 1825693747
close(4) = 0
times({tms_utime=2, tms_stime=1, tms_cutime=0, tms_cstime=0}) = 1825693747
open("/u01/app/oracle/product/11.2.0.4/dbhome_1/rdbms/mesg/diaus.msb", O_RDONLY) = 4
fcntl(4, F_SETFD, FD_CLOEXEC) = 0
lseek(4, 0, SEEK_SET) = 0
read(4, "\25\23\"\1\23\3\t\t\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 256) = 256
lseek(4, 512, SEEK_SET) = 512
read(4, "\371\311\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 512) = 512
lseek(4, 1024, SEEK_SET) = 1024
read(4, "\210\273\353\273\363\273\373\273\4\274\16\274\26\274!\274)\2741\274<\274G\274T\274_\274k\274t\274"..., 192) = 192
stat("/u01/app/oracle", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
getrlimit(RLIMIT_NOFILE, {rlim_cur=64*1024, rlim_max=64*1024}) = 0
getrlimit(RLIMIT_FSIZE, {rlim_cur=RLIM_INFINITY, rlim_max=RLIM_INFINITY}) = 0
stat("/u01/app/oracle/diag", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/trace", {st_mode=S_IFDIR|0750, st_size=5337088, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/alert", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/incident", {st_mode=S_IFDIR|0750, st_size=12288, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/metadata", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/metadata_pv", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/metadata_dgif", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/hm", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/ir", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/incpkg", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/sweep", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/lck", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/cdump", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/stage", {st_mode=S_IFDIR|0750, st_size=32768, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/metadata", {st_mode=S_IFDIR|0750, st_size=4096, ...}) = 0
lstat("/u01/app/oracle/diag/rdbms/book/book/metadata/ADR_CONTROL.ams", {st_mode=S_IFREG|0640, st_size=65536, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/metadata/ADR_CONTROL.ams", {st_mode=S_IFREG|0640, st_size=65536, ...}) = 0
lstat("/u01/app/oracle/diag/rdbms/book/book/metadata/ADR_INVALIDATION.ams", {st_mode=S_IFREG|0640, st_size=65536, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/metadata/ADR_INVALIDATION.ams", {st_mode=S_IFREG|0640, st_size=65536, ...}) = 0
lstat("/u01/app/oracle/diag/rdbms/book/book/metadata/INC_METER_IMPT_DEF.ams", {st_mode=S_IFREG|0640, st_size=65536, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/metadata/INC_METER_IMPT_DEF.ams", {st_mode=S_IFREG|0640, st_size=65536, ...}) = 0
lstat("/u01/app/oracle/diag/rdbms/book/book/metadata/INC_METER_PK_IMPTS.ams", {st_mode=S_IFREG|0640, st_size=65536, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/metadata/INC_METER_PK_IMPTS.ams", {st_mode=S_IFREG|0640, st_size=65536, ...}) = 0
lstat("/u01/app/oracle/diag/rdbms/book/book/metadata/INCIDENT.ams", {st_mode=S_IFREG|0640, st_size=475136, ...}) = 0
stat("/u01/app/oracle/diag/rdbms/book/book/metadata/INCIDENT.ams", {st_mode=S_IFREG|0640, st_size=475136, ...}) = 0
shmdt(0x60000000) = 0
shmdt(0x60c00000) = 0
shmdt(0x86800000) = 0
munmap(0x7fcda79d2000, 143360) = 0
munmap(0x7fcda79f5000, 143360) = 0
munmap(0x7fcda7a18000, 143360) = 0
close(4) = 0
munmap(0x7fcda7b7b000, 262144) = 0
munmap(0x7fcda75ba000, 524288) = 0
munmap(0x7fcda74ba000, 1048576) = 0
munmap(0x7fcda763c000, 524288) = 0
close(6) = 0
rt_sigprocmask(SIG_BLOCK, [ALRM], NULL, 8) = 0
rt_sigaction(SIGALRM, {SIG_DFL, ~[ILL ABRT BUS FPE SEGV USR2 XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x379a00eca0}, {0x7edfb0c, ~[ILL ABRT BUS FPE KILL SEGV USR2 STOP XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x379a00eca0}, 8) = 0
rt_sigprocmask(SIG_UNBLOCK, [ALRM], NULL, 8) = 0
rt_sigaction(SIGILL, {SIG_DFL, ~[ILL ABRT BUS FPE SEGV USR2 XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x379a00eca0}, {0x6b48fd6, ~[ILL ABRT BUS FPE KILL SEGV USR2 STOP XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_STACK|SA_SIGINFO, 0x379a00eca0}, 8) = 0
rt_sigaction(SIGTRAP, {SIG_DFL, ~[ILL ABRT BUS FPE SEGV USR2 XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x379a00eca0}, {0x6b48fd6, ~[ILL ABRT BUS FPE KILL SEGV USR2 STOP XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_STACK|SA_SIGINFO, 0x379a00eca0}, 8) = 0
rt_sigaction(SIGABRT, {SIG_DFL, ~[ILL ABRT BUS FPE SEGV USR2 XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x379a00eca0}, {0x6b48fd6, ~[ILL ABRT BUS FPE KILL SEGV USR2 STOP XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_STACK|SA_SIGINFO, 0x379a00eca0}, 8) = 0
rt_sigaction(SIGFPE, {SIG_DFL, ~[ILL ABRT BUS FPE SEGV USR2 XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x379a00eca0}, {0x6b48fd6, ~[ILL ABRT BUS FPE KILL SEGV USR2 STOP XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_STACK|SA_SIGINFO, 0x379a00eca0}, 8) = 0
rt_sigaction(SIGBUS, {SIG_DFL, ~[ILL ABRT BUS FPE SEGV USR2 XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x379a00eca0}, {0x6b48fd6, ~[ILL ABRT BUS FPE KILL SEGV USR2 STOP XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_STACK|SA_SIGINFO, 0x379a00eca0}, 8) = 0
rt_sigaction(SIGSEGV, {SIG_DFL, ~[ILL ABRT BUS FPE SEGV USR2 XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_RESTART|SA_SIGINFO, 0x379a00eca0}, {0x6b48fd6, ~[ILL ABRT BUS FPE KILL SEGV USR2 STOP XCPU XFSZ SYS RTMIN RT_1], SA_RESTORER|SA_STACK|SA_SIGINFO, 0x379a00eca0}, 8) = 0
rt_sigaction(SIGSYS, {SIG_DFL, ~[ILL ABRT BUS FPE SEGV USR2 XCPU XFSZ SYS RTMIN RT_1],......
原文转载:http://www.shaoqun.com/a/890947.html
跨境电商:https://www.ikjzd.com/
woot:https://www.ikjzd.com/w/604
派代:https://www.ikjzd.com/w/2197
asiabill:https://www.ikjzd.com/w/1014
[20210722]sqlplus下showrecycebin的小问题.txt--//sqlplus下执行showrecycebin遇到一些疑问,通过测试慢慢展开问题的探究.1.环境:SCOTT@test01p>@ver1PORT_STRINGVERSIONBANNERCON_ID--------------------------------------------------------
hts:https://www.ikjzd.com/w/525
台风玲玲影响华南海南广东大雨 北方晴晒南方周末变闷热:http://www.30bags.com/a/433500.html
台风玲玲致浙闽多地渔船回港 13号台风风雨时间表公布:http://www.30bags.com/a/425468.html
台风路径实时发布系统 别指望12号台风云雀登陆上海能降温:http://www.30bags.com/a/432838.html
台风罗莎登陆日本中国使馆发提醒 700多架次航班取消:http://www.30bags.com/a/425240.html
女友去乡下玩被三个老头调教 3人不停在她体内进进出出:http://lady.shaoqun.com/a/247232.html
口述:我和两位小姨子们的难忘激情性事(7/7):http://lady.shaoqun.com/a/64585.html
趁女朋友洗澡上她闺蜜 把女闺蜜摸出水了:http://lady.shaoqun.com/a/247548.html
三种性学理论中人类性欲的本质和发展过程(8):http://lady.shaoqun.com/a/427374.html
刚刚!贝索斯成功上天,3分钟烧掉了28亿美元,还被卖家们骂了……:https://www.ikjzd.com/articles/146805
饥饿的男人居然挖墙入侵老人3年,最大的是95岁:http://lady.shaoqun.com/a/427376.html
曹写了一封信,要求在结婚十年后与妻子离婚。原判决让他感到愧疚,回到了家人身边:http://lady.shaoqun.com/a/427378.html
没有评论:
发表评论