Tuesday, December 1, 2009

Undo the settings of pppoeconf command

"pppoeconf" sets up dialup networks on linux/ connect to internet without connecting via network manager. But thats done, it sets up few files to always do that.
To undo this on ubuntu, follow these steps :

1) Edit nm-system-settings.conf

vim /etc/NetworkManager/nm-system-settings.conf


You have to write managed=true under [ifupdown]

4) Edit interfaces

vim /etc/network/interfaces


This file must look like this:

auto lo
iface lo inet loopback

auto eth0
iface eth0 dhcp


5) Restart your computer

reboot


6) Finished.

Friday, November 13, 2009

Finding out your external IP address

If you want to find out what external IP address your router has assigned to it, you can either search the Internet for sites that can display that said IP address or you can use the Linux command line:

wget -O - -q icanhazip.com


wget options:
'-O -' will display output on terminal instead of saving it in a file.
'-q' will suppress wget's output (e.g. connecting ,saving)

This are other sites which can be used instead of icanhasip.com
http://www.canyouseeme.org/
http://www.formyip.com/
http://www.checkip.org/
http://www.whatismyip.org/

Monday, November 9, 2009

Multiple line comments and designs

Have you ever wondered how do people make fancy design around comments like

/**************************/
/* Different all twisty a */
/* of in maze are you, */
/* passages little. */
/**************************/


or like
__ _,--="=--,_ __
/ \." .-. "./ \
/ ,/ _ : : _ \/` \
\ `| /o\ :_: /o\ |\__/
`-'| :="~` _ `~"=: |
\` (_) `/
.-"-. \ | / .-"-.
.---{ }--| /,.-'-.,\ |--{ }---.
) (_)_)_) \_/`~-===-~`\_/ (_(_(_) (
( qwe )
) asd (
( zxc )
) (
'---------------------------------------'


I even tried creating a one in one of my files. Then I had to change my message and my design was screwed.

Today in casual browsing I found this and all questions which have been there for years were solved.

All you need to do is
1. yum/apt-get install boxes

2. Open vim select the text you want inside the box in visual mode.

3. Type : (Prompt will be :'<,'>)
4. And then type !boxes (Prompt will be :'<,'>!boxes)

And you will have nice designed comments.

If you want to undo boxes, select the whole box using visual mode(only box,not starting of next line), and say !boxes -r

Friday, November 6, 2009

Cross-platform Browser Sync - Xmarks

I have 3 machines, each one with Linux/windows installation. Its really a pain to sync my browsers for bookmarks and ....
But now I found this and its really working great. I suggest you to try this out too.
http://www.xmarks.com/

Thursday, October 29, 2009

Dropbox - online storage/backup

Every morning I start my computer, I pray that it at least starts.
This is why I always looking for option for getting things off of the local computer.

Recently I came across Dropbox. I am really liking it. It gives you 2 GB of storage free of cost.
To Setup follow these commands

For Ubuntu :
1. Go to https://www.getdropbox.com/downloading and download appropriate package.
2. # dropbox start -i

For Redhat/Fedora (without Nautilus plugin):
1. If 32 bit,
wget http://www.getdropbox.com/download?plat=lnx.x86
If 64 bit,
wget http://www.getdropbox.com/download?plat=lnx.x86_64


tar zxof dropbox-*.tar.gz
mv .dropbox-dist ~/.dropbox-dist
wget http://dl.getdropbox.com/u/6995/dbmakefakelib.py
wget http://dl.getdropbox.com/u/6995/dbreadconfig.py
python dbmakefakelib.py

It will ask all the information,fill it and let it sync. Then close it using icon->stop or ^C.


python dbreadconfig.py
cat >> ~/.bash_profile << END
~/.dropbox-dist/dropboxd &
END


You will get a folder ~/Dropbox. Create anything in that folder and it will be backed up automatically. Also they have a folder called ~/Dropbox/Public where you can put a document and its available to non-dropbox users too.

Here are other options available
http://en.wikipedia.org/wiki/List_of_online_backup_services
http://tomuse.com/ultimate-review-list-of-best-free-online-storage-and-backup-application-services/

Ubuntu has its own online storage too. Its called Ubuntu_one.

Wednesday, September 30, 2009

my ~/.vimrc

"-------------------------------------
" always show this custom status line
set notitle       " to avoid vim renaming the title of the xterm window
set nonumber      " we don't need line numbers on the left, because we have status line
set laststatus=2  " always show the status line
set statusline=%<%F%h%m%r%h%w%y\ %{&ff}\ %{strftime(\"%c\",getftime(expand(\"%:p\")))}%=\ col:%c%V\ line:%l\,%L\ %P
" -------------------------------------
" use 2-space indentation
" set tabstop=2     " read :help tab for explanation of tabstop, softtabstop, shiftwidth
" set softtabstop=2 "
set shiftwidth=2  "
" set expandtab     " inserts spaces instead of tab (for real tab use ctrl-V - tab)
" -------------------------------------
set showmatch     " When a bracket is inserted, briefly jump to the matching one if it is visible on the screen.
set matchtime=3
" -------------------------------------
" set autoindent
" set smartindent
" set paste       " you can set paste temporarily, but be aware that it interferes with autoindent
                  " it turns it off (and many other settings). Read :help paste
" -------------------------------------
set incsearch     " search incremental
set ignorecase    " search case-insensitive
set smartcase     " search case-insensitive for small chars, case-sensitive if at least 1 capital char
set nohlsearch    " search highlighting
" -------------------------------------
" This only works if you have plugin under .vim in home dir
" or if you include here a command to source plugin, for example:
"   source ~lselector/lselector/.vim/plugin/taglist.vim
:map :TlistToggle
let Tlist_Exit_OnlyWindow = 1
" -------------------------------------

set ignorecase
set smartcase
set incsearch
set title
set wrap
set wildmenu
set noautoindent smartindent
set hlsearch
set paste
set ic

set softtabstop=2
set shiftwidth=2
set tabstop=2
set expandtab

match ErrorMsg '\%>80v.\+'
match

nnoremap :set invpaste paste?
set pastetoggle=
set showmode

nnoremap :set nowrap!
"set wrap!=
"set showmode

":set mouse=a
":map
":map
":map
":map

:map
:map
noremap :call ToggleMouse()

function! ToggleMouse()
  if &mouse == 'a'
    set mouse=
  else
    set mouse=a
  endif
endfunction

if match($TERMCAP, 'Co#256:') == 0 || match($TERMCAP, ':Co#256:') > 0          
      set t_Co=256                                                               
endif

command -nargs=1 T2 :2match Search //




2nd paragraph is for not putting tab as /t ( instead, put it as 2 spaces).
3rd paragraph is for limiting column to 80. It will start highlighting if it goes after 80. For undoing it in some cases you can say ':match'.

Monday, September 28, 2009

Editing multiple lines in vim

1.Press ctrl + v (To selest visual block. v/V are for visual region)
2.Select lines you want to append to.
3.Press I{string}<ESC>
(Note: Its I = capital i = shift+i)

In our case, {string} = #. It takes a while for changes to appear after you press <ESC>.

Saturday, September 19, 2009

Searching using/in URL bar

1. Go to any site which you use for searching (e.g. Wikipedia).
2. Right click on text box where you enter your query.
3. Click on "Add a keyword for this search".
4. Enter <keyword>(e.g. wk) in keyword box.
5. Save.

Whenever you want to search 'something' in Wikipedia, just type 'wk something' in URL bar. If search doesn't work, try to analyse and modify location field.

Wednesday, September 16, 2009

'rename' command

To rename multiple files:
I wanted to rename all files in a folder from *_vXXX.sh to *_vYYY.sh.
Thus I used

rename XXX YYY *_vXXX.sh


We can specify the number of wild characters in searching pattern by ? e. g. reaplce only a_vXXX.sh but not ab_vXXX.sh

rename XXX YYY ?_vXXX.sh

Monday, September 7, 2009

'ndiswrapper' on fedora 11

Again this might change with newer version of OS or different version of OS.

rpm -Uvh http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stabl
yum install kmod-ndiswrapper
mkdir ~/new_installation/ndiswrapper_driver
cd ~/new_installation/ndiswrapper_driver
wget http://www.jbg.f2s.com/bcm43.bz2
tar jxvf bcm43.bz2
cd bcmwl5\ driver
ndiswrapper -i bcmwl5.inf


Now reboot your machine and execute these commands.

modprobe ndiswrapper
ndiswrapper -ma

Wednesday, September 2, 2009

Installing GUI on a non-GUI/Command line terminal

We need to execute 2 packages as opposed to google's result.

yum -y groupinstall "X Window System" "GNOME Desktop Environment"

Friday, August 28, 2009

Comparing 2 files

Better than opening in 2 VIM windows , I used to take diff and open its output in vim :).
But diff itself has flag which will compare files line by line.


diff -ay file1 file2 | less

Friday, August 21, 2009

Creating your own file/web host

Pretty easy.

yum install httpd
ln -s /directory_to_share /var/www/directory_to_share
chmod 777 /directory_to_share
service httpd restart


i take drastic approach when it come to directories.:)

Wednesday, August 19, 2009

Connecting to windows machine from linux machine

By default Linux has "rdesktop" program.
Problem will rise on windows machine(of course!!).

1.Go in Start -> Control Panel -> Windows firewall.
2.Goto "Exceptions" tab.
3.Check "Remote Desktop" entry.
4.Press OK.

5.Open System Properties menu (Computers -> Right Click -> Properties)
6.Goto Remote tab
7.In Remote Desktop menu, check "Allow users to connect remotely to this computer"
8.Press OK.

Other variants with similar setting are tsclient on Linux(which is for both VNC and rdesktop),vncviewer(again by default in Linux ,but need VNC on windows machine)

Monday, August 10, 2009

KVM live migration

You can refer to my previous post for setting up KVM.

Before :

[root@euclid ~]# virsh list
Id Name State
----------------------------------
4 veuler running

[root@gauss ~]# virsh list
Id Name State
----------------------------------



Migration Command :

[root@euclid ~]# virsh migrate --live veuler qemu+ssh://gauss/system
root@gauss's password: *****


After :

[root@euclid ~]# virsh list
Id Name State
----------------------------------

[root@gauss ~]# virsh list
Id Name State
----------------------------------
4 veuler running



QEMU Vs KVM :

QEMU provides virtualization purely by means of software, and can be used as a stand-alone package.

KVM--which stands for "Kernel-based Virtual Machine"--provides for hardware-assisted virtualization. It can only be used with newer processors, such as Intel Core 2's or more recent AMD Athlon64's. It must be used in conjunction with QEMU.

Thursday, August 6, 2009

Opening qcow files

Qcow files are used as disks in KVM

losetup -f

Get a free loop-back device, say /dev/loop0.

losetup /dev/loop0 harshal.qcow
kaprtx -av /dev/loop0
vgscan


Get the name of the volume group in qcow file, say vg_harshal.

vgchange -ay vg_harshal

Enable that volumegroup.

lvdisplay

Get logical volume name for that volume group, say /dev/vg_harshal/root1

mount /dev/vg_harshal/root1 /mount_point

Good to Use.

Once done, we need to undo the changes.


umount /mount_point
vgchange -an vg_harshal
kpartx -dv /dev/loop0
losetup -d /dev/loop0

Sunday, July 19, 2009

"Firefox already running" error

Do you get this error when there is no process called firefox?
I mean

# ps -aux | grep firefox
#


Then do this

cd ~/.mozilla/firefox/[profile_name]
rm lock .parentlock

Wednesday, July 15, 2009

Network tweaks

Many times client computer doesn't get IP address even if its protocol is DHCP. If we manually give IP address to it, everything works perfectly fine. Thus the command to give manual IP is as follow


ifconfig eth0 'new_ip' netmask 255.255.255.0 up


Do not forget to fill in the IP adress you want.

Also if the default routes are screwed up, fix it like this

cat >> /etc/sysconfig/network << END
GATEWAY='Gateway_IP'
END

Friday, July 10, 2009

Setting up NIS server

These are the scripts which I have tried and tested in order to set NIS service over the network.

On server side :

yum -y install ypserv
domainname SCRC
cat >> /etc/yp.conf << END
ypserver 127.0.0.1
END
cat >> /etc/sysconfig/network << END
NISDOMAIN=SCRC
END
service ypserv start
chkconfig ypserv on
/usr/lib/yp/ypinit -m
service ypbind start
chkconfig ypbind on
service ypxfrd start
chkconfig ypxfrd on
cd /var/yp
make



On client side :

yum -y install ypbind
domainname SCRC
cat >> /etc/yp.conf << END
ypserver pioneer
END
cat >> /etc/sysconfig/network << END
NISDOMAIN=SCRC
END
service ypbind start
chkconfig ypbind on


Do not forget to change /etc/nsswitch.conf

Friday, June 12, 2009

SVN Introduction

A very common thing while doing any kind of project is using repository. I tend to forget these commands every now and then. That's why this

svn checkout http://fileextensiontype.unfuddle.com/svn/fileextensiontype_fi/ local_directory_name

svn status

svn add *

svn commit


You may also have to do this
export EDITOR=vim

Monday, June 8, 2009

Wordweb Equivalent on Linux

One feature I really miss in Linux is Word-Web. We can have word-web in Linux using wine but pressing the hot-key when word is selected does not activate it. Thus, we can use "gnome-dictionary" with "xbindkeys" and "xclip" to get same kind of functionality.

yum install xbindkeys
yum install xclip
xbindkeys --defaults > ~/.xbindkeysrc
xbindkeys -k

Now a small window will appear and you can get code for the key-combination pressed. Use this combination in configuration file ~/.xbindkeysrc. (I got m:0x1c + c:52 for alt+ctrl+e)

cat <<- END
"gnome-dictionary $(xclip -o)"
m:0x1c + c:52
END
echo "xbindkeys &" >> ~/.bashrc
killall -HUP xbindkeys


Equivalent to "delimiter cat" is "echo -e".

That's it. Just select any word you don't know and press your key combination. We will get its meaning.

Friday, June 5, 2009

Using cscope and ctags

Many people complain that though Linux is in C they don't have good IDE for C development. Though there the things mentioned here are not great but they are good enough to help you in C development.

1. Cscope

find . -name '*.c' > cscope.files
cscope -i cscope.files


cscope.files is default file name, thus just cscope command would work. To exit, you can type Ctrl+D and to see help, you can type "?".

2.Ctags

cd /path/to/your/project
ctags -R *
vim -t

Once inside a file, hitting ctrl-] while the cursor is over a function/class name, Vim will attempt to open the file with that tag. Pressing ctrl-t will take you back a step. To exit, , regular ":q" should work.

Friday, May 29, 2009

KVM setup

I usually love to start from a brand new OS installation. That way we know what packages we actually need. Follow these instructions for both machines A and B.

1. Confirm your CPU has virtualisation support
egrep 'vmx|svm' /proc/cpuinfo

2. Install kvm packages
yum install kvm kmod-kvm qemu

3. Install appropriate kernel module
modprobe kvm-intel
OR
modprobe kvm-amd

4.Check whether the module is installed or not
lsmod | grep kvm
Also make sure the kvm is present as a device
ls -l /dev/kvm

5.Mount same NFS share at same path (say /mount_point)
mount server:/nfs_share /mount_point

6.Download ISO file for creation on virtual machine
wget -O /mount_point/fedora.iso http://mirror.cc.vt.edu/pub/fedora/linux/releases/10/Fedora/i386/iso/Fedora-10-i386-DVD.iso

7. Create VM image file
qemu-img create fedoraroot.img -f raw 10G

8. I do not know if there is a command line version of qemu. So if your server does not have GUI, you can use following commands
On server
export DISPLAY=your_machine:0.0
On your_machine
xhost +
You can specify server's name after + sign. But I prefer accepting whole world to avoid routing problems.

9. Start VM using
qemu-kvm -m 512 -cdrom fedora.iso -boot d fedoraroot.img

10. Once installation is done, change boot flag to "c"( which is default). You can also remove CD-ROM from VM.
qemu-kvm -m 512 fedoraroot.img

Wednesday, May 20, 2009

Wallpaper changer script

Tired of changing wallpaper everyday? You will get many soft-wares which will change it for you everyday. The only thing which I dint like about them is, they put a picture which is stored on your computer. SO there is possibility that you have seen that picture before. What about a truly random pic??
Here is the script:

rm -f ~/wallpaper/w.jpg ~/wallpaper/widescreen_rss.php
wget -O ~/wallpaper/widescreen_rss.php http://www.mlewallpapers.com/widescreen_rss.php
wget -O ~/wallpaper/w.jpg `grep enclosure ~/wallpaper/widescreen_rss.php | cut -d \" -f 2`
gconftool-2 -t str --set /desktop/gnome/background/picture_filename ~/wallpaper/w.jpg

Put it in your cron so that it will execute daily. You can modify this to fetch picture from any site which will give new picture daily.


All this can be done using following :

mkdir -p ~/new_installation/wallpaper
cat > ~/new_installation/wallpaper/wallpaper_changer.sh << END
rm -f ~/new_installation/wallpaper/w.jpg ~/new_installation/wallpaper/widescreen_rss.php
wget -O ~/new_installation/wallpaper/widescreen_rss.php http://www.mlewallpapers.com/widescreen_rss.php
wget -O ~/new_installation/wallpaper/w.jpg \`grep enclosure ~/new_installation/wallpaper/widescreen_rss.php | cut -d \" -f 2\`
gconftool-2 -t str --set /desktop/gnome/background/picture_filename ~/new_installation/wallpaper/w.jpg
END
chmod a+x ~/new_installation/wallpaper/wallpaper_changer.sh
cat >> /etc/sudoers << END
# crontab root scripts
action-owl ALL=(ALL) NOPASSWD:~/new_installation/wallpaper/wallpaper_changer.sh
END

For fedora :

cat >> /var/spool/cron/root << END
0 12 * * * ~/new_installation/wallpaper/wallpaper_changer.sh >/dev/null 2>&1
END

For ubuntu :

cat >> /var/spool/cron/crontabs/root << END
0 12 * * * ~/new_installation/wallpaper/wallpaper_changer.sh >/dev/null 2>&1
END


This will change wallpaper on 12 noon every day.

Tuesday, May 19, 2009

Installing 64 bit adobe in firefox

I have 64 bit ubuntu in office and for some strange reasons, it installs 32 bit flash player through apt-get. To install 64 bit version here are the commands to copy paste in terminal.


wget -O flash.tar.gz http://download.macromedia.com/pub/labs/flashplayer10/libflashplayer-10.0.22.87.linux-x86_64.so.tar.gz
tar xvzf flash.tar.gz
mkdir -p ~/.mozilla/plugins
mv libflashplayer.so ~/.mozilla/plugins
pkill firefox
firefox

Friday, May 15, 2009

Open terminal in current folder

One feature I really miss in Fedora after moving from redhat was opening a terminal in current folder of nautilus.
So my workaround is this :


echo gnome-terminal > ~/.gnome2/nautilus-scripts/terminal
chmod a+x ~/.gnome2/nautilus-scripts/terminal

Monday, May 11, 2009

MS office 2007 in openoffice

We need to have this plug-in in order to open docx and xlsx files in open-office.

http://rpm.pbone.net/index.php3/stat/4/idpl/10821603/com/odf-converter-integrator-0.2.0-2.i386.rpm.html

Thursday, May 7, 2009

Radio in linux

Being in linux, its a obvious thing to use command line for EVERYTHING. For example, listening songs. "Usual" folks just go on some site, either download or keep browser open if the site is providing media player itself. But in linux, its just a command (which can be run in background). I use following commands for listening radio :

mplayer -playlist http://asx.abacast.com/arabian_radio-city-64.asx -loop 0
mplayer - playlist http://www.1.fm/TuneIn/WM/energybbfm128k/Listen.aspx -loop 0
mplayer mmsh://citadelcc-wplj-fm.wm.llnwd.net/citadelcc_WPLJ_FM?MSWMExt=.asf


"-loop 0" because dont let a single corrupt packet stop your radio.

You can always find a radio station of your choice. One radio station which I would really like to promote is http://wnyu.org/.

Friday, May 1, 2009

Sopcast in linux

Love watching sports? But cant get working on linux??
Here is what I found.

1. Download sopcast for linux from http://code.google.com/p/sopcast-player/.
(No need to download player. Just the source i.e. sp-auth is enough)

2. Create a small script ('~/sop' in my case) as follows :

#!/bin/sh
while [ 1 ]
do
sp-sc $1 3908 8908 > /dev/null &
mplayer http://localhost:8908/tv.asf
done
pkill sp-sc


(while loop because mplayer doesn't start the stream in first attempt.)

3. Search the forums like http://myp2p.eu/index.php?part=sports for your favourite channel and get the sopcast link which will look like sop://broker1.sopcast.com:3912/10912

4.

./sop sop://broker1.sopcast.com:3912/10912


then sit back and enjoy!!!

Tuesday, April 28, 2009

passwordless SSH Log in and even more secure

Suppose you want to log into your office computer very often from home computer. Its very annoying to enter password each time you open a terminal or new window in terminal. Thus I searched a bit and found a procedure to bypass entering password. And it happens to be more safer way that entering password.

1.On your Home-comp
ssh-keygen -t rsa

This will generate ~/.ssh/id_rsa.pub file

2.
cat ~/.ssh/id_rsa.pub | ssh office-user@office-comp "cat >> ~/.ssh/authorized_keys"


This will ask you password for one last time. Note that we have used cat command over ssh. Hence we will require the password at least once.

Make sure that you have following permissions on "office-comp" :
chmod 750 ~
chmod 700 ~/.ssh
chmod 600 ~/.ssh/authorized_keys

Monday, April 27, 2009

Getting CD-ROM info in linux

I wanted to burn a DVD( Ubuntu :D) but my machine does not have DVD RW. I thought one of the server might have it, so I needed to check them. The problem is all servers are without X, so I needed some command to get that info. After Googling a bit I found some useful files.

/proc/sys/dev/cdrom/autoclose
/proc/sys/dev/cdrom/autoeject
/proc/sys/dev/cdrom/check_media
/proc/sys/dev/cdrom/debug
/proc/sys/dev/cdrom/info
/proc/sys/dev/cdrom/lock

All the files are readable by all and produce ASCII output when read. They reflect the current state of the CDROM subsystem. This location is part of the procfs's window through to the sysctl configuration mechanism (see man sysctl). All but info are writable by the superuser. There is a column for each CDROM and DVD player in the system in info (not just SCSI devices).

As an example, the auto eject feature can be turned on by the superuser with the command echo "1" > /proc/sys/dev/cdrom/autoeject. This will cause cdroms to be ejected from the drive when unmounted.

Sunday, April 26, 2009

NYU wireless/VPN on linux

I use Fedora on my laptop and I had tough time configuring NYU wireless in it. I found three procedures, of which I tried hard with the first one but Couldn't get it working. It was for Ubuntu but I thought I might give it a try. Here it is.

Approach 1 :
First off you'll need to get the Verisign Root CA certificate:
1.Go to https://getca.verisign.com/ and download the current Root CA Certificate. It downloads for me as 'getrootcert.cer'.
2.Convert the .cer file to a .pem file:
openssl x509 -in getrootcert.cer -inform d -out verisign.pem

3.Save verisign.pem wherever you want (/etc/ssl/certs would make sense).
4.You need to go to the network manager (usually on the top bar) where you select wireless networks, click the left mouse button and select 'connect to other wireless network'.
5.Select 'WPA2 Enterprise' for a 'Wireless Security', and a whole bunch of new options will appear.
Network Name is 'nyu'
EAP Method is PEAP
Key Type: Automatic (or, I believe AES)
Phase2 Type is MSCHAPv2
Identity is you NYU NetID (eg. js123 -- don't include the @nyu.edu )
Password is your NetID password.
Anonymous Identity, Client Certificate File, Private Key File, and Private Key Password should be left blank.
6.For CA (Certifying Authority, I guess) Certificate file use the verisign.pem file.
It should work fine.



Approach 2:(NYU VPN)

After a while I found second one.I got this thing working in first attempt but the problem is we never know when will NYU-ITS will shut off NYU-Roam3.Here is the procedure.

1.Connect to NYU-ROAM3.
2.Create a VPN connection using cisco VPN.
3.Gateway : vpn.nyu.edu
4.Group name : nyu-vpn
5.User password : NYU net ID password
6.Group password : nyu-net
7.User : NYU net ID

For ubuntu:
Install vpnc and network-manager-vpnc using synaptic first.



Approach 3:

Simplest of all.
1. Get guest username and password from library.
2. Connect to NYU-GUEST.
3. Put that username and password.

But dont get too excited, this user name and password is changed every Monday.

Friday, April 24, 2009

LaTeX Introduction

Here are some LaTeX resources that I've found useful:




Monday, April 20, 2009

Becoming invisible in Pidgin on Gmail

1. Open the Buddy List.
2. In the menu, Tools->Plugins. Enable XMMP Console. Close the Plugin Window
3. In the menu again, Tools->XMMP Console->XMMP Console.
(See if your account in which you want to go invisible is selected if you have multiple accounts. )
4. In the text box, put the following XML snippet

{{{
<presence>
<priority>5</priority>
</presence>
<presence type="unavailable">
<priority>5</priority>
</presence>
}}}

and then press enter.
5. Done this is it. If this is not working on your version, now try changing the status to Invisible.

Finally, if you want to reset the above settings. Follow the same procedure but make < presence type="available" > in the above XML snippet.