在linux下sqlplus工具不能进行历史命令的回调,使用backspace也会出现乱码。为此在网上找了相关资料,安装rlwrap
1.获取软件包
http://utopia.knoware.nl/~hlub/uck/rlwrap/rlwrap-0.37.tar.gz
2.编译安装
2.1解压软件包
[root@nodes02 ~]# tar -zxvf rlwrap-0.37.tar.gz
2.2编译和安装
[root@nodes02 rlwrap-0.37]# ./configure .... configure: creating ./config.status config.status: creating Makefile config.status: creating filters/Makefile config.status: creating doc/Makefile config.status: creating src/Makefile config.status: creating doc/rlwrap.man config.status: creating config.h config.status: executing depfiles commands Now do: make (or gmake) to build rlwrap make check for instructions how to test it make install to install it [root@nodes02 rlwrap-0.37]# make && make install
2.3别名设置
[oracle@nodes02 ~]$ echo 'alias sqlplus="rlwrap sqlplus"' >> .bash_profile [oracle@nodes02 ~]$source .bash_profile
现在可以去试试sqlplus的新功能了,十分方便。
转载于:https://blog.51cto.com/seneagle/1290361