Ubuntu 技巧

1. Ubuntu12.04 在右键快捷菜单中添加“Open in Terminal”

$ sudo apt-get install nautilus-open-terminal

$ nautilus -q(重启Nautilus)

2. Ubuntu 12.04 LTS 中文输入法的安装

$ ibus-setup // 执行之后,会自动调出一个 Ibus Preference 设置框

3. 设置 极点五笔 自动上屏

默认情况下,ibus-table不开启直接上屏模式(即敲完四个码,没有重码时,直接显示到屏幕上),在五笔输入法(未输入内容)下 Ctrl + / 即可。

4. Ubuntu 修改用户密码

$ sudo passwd username // username为要修改的用户名

5. Ubuntu 12.04 添加程序启动器

$ cd /usr/share/applications

$ vim eclipse.desktop

6. Ubuntu把家目录文件夹名称改为英文

$ export LANG=en_US

$ xdg-user-dirs-gtk-update

$ epxort LANG=zh_CN

7. Ubuntu 12.10截图快捷键  

修改快捷键方式:system settings---keyboard---shortcuts---screenshots

8. Linux下iconv转换字符集

windows编码(gbk, gb2312. gb18030)转换为linux编码(utf-8):

$ iconv -f gb18030 -t utf-8 source.txt -o target.output

9. Sharing Host VPN with VirtualBox guest

If you have a a domain like w3.mycompany.com that only resolves using the VPN’s DNS, you can resolve that name from your host (which is connected to the VPN), but not from your guest(VM) by default. You won’t be able to ping w3.mycompany.com from the guest. However, if you try to ping the IP address from your guest, that works.

VirtualBox has a nice feature to allow you to set the Host DNS resolver as the DNS proxy of a VirtualBox VM:

$ VBoxManage list vms

$ VBoxManage modifyvm "uuid|vmName" --natdnshostresolver1 on

e.g(Windows): 

$ C:\Program Files\Oracle\VirtualBox\VBoxManage.exe modifyvm "Ubuntu_12.04_x64" --natdnshostresolver1 on

Ps: 需要先关闭目标虚拟机和VirtualBox

posted on 2015-10-24 10:49  veins  阅读(276)  评论(0编辑  收藏  举报

导航