2010年10月28日 星期四

Change port number of Remote Desktop

Actually, there are a lot of the same content over Internet. I have a copy of someone's saved in my Firefox Scrapbook. However, I have many VMs to manage, so I figured it would be better if I put this in my Blog.

The default port of RDP is 3389.

Start>run>regedit.

Find port number under HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\TerminalServer\WinStations\RDP-Tcp\

Double click to edit the DWORD value, change to the port number you want.

image

How to change color scheme of vim?

I have been bothered by the color shown of vim when editing a configuration file of Linux with putty as the picture presented below.

image

The darkblue part just make eyes hard to see clearly.

Luckly, we can change the color shown in Vim by change its settings. The Vim settings are written in a file called .vimrc or vimrc. My CentOS has it located in /etc/vimrc.

Just add, colorscheme desert, in the vimrc, save and quit.

image

Isn't it better?

You can choose other color schemes, below is the list of color schemes of my vim from /usr/share/vim/vim70/colors

blue.vim      delek.vim    evening.vim  murphy.vim     README.txt  slate.vim
darkblue.vim  desert.vim   koehler.vim  pablo.vim      ron.vim     torte.vim
default.vim   elflord.vim  morning.vim  peachpuff.vim  shine.vim   zellner.vim

2010年10月22日 星期五

How to remove hidden devices

Have you ever encountered a situation like this!



If you have a NIC installed in one PCI slot and you moved it to another PCI slot in the same computer, when you still try to the same IP this message will appear. So, how can we make this message go away? Uninstall that hidden NIC, of course! But how? I googled it and found an instruction, which I think explain better. The link is http://www.tech-recipes.com/rx/504/how-to-uninstall-hidden-devices-drivers-and-services/


Open a command prompt, and type set devmgr_show_nonpresent_devices=1, enter, then type devmgmt.msc to execute device manager console.



In device manager, click View>Show hidden devices


Note: If you just open device manager without setting set devmgr_show_nonpresent_devices=1, you can still choose [show hidden devices]. However, you won't be able see devices uplugged as shown below.


The hidden devices are grayed out



Select the one you want to remove and click uninstall button