I have a windows VNC client(RealVNC) connecting to my Linux VNC server.The default way of connecting is enabling remote desktop in GNOME.You can do this by going to System -> Preferences -> Remote Desktop  and checking “Allow other users to view your desktop”

This will give you the address that you need to enter in vncviewer in order to connect to the server which in this case is hoopoe.elk:0.But there is one issue with this kind of setup you’ll not be able to copy from your windows client and paste it to x server and vice versa.To solve this issue you need to remove vino which is the default VNC server and install and enable x11vnc.

Replacing vino with x11vnc

Disable Vino

go to System -> Preferences -> Remote Desktop  and uncheck “Allow other users to view your desktop”

Get x11vnc and install it

1.get latest version from here
2.its a tarball file install it
3.create password for x11vnc

sudo <x11vnc installation dir>/bin/x11vnc -storepasswd  <yourpswd> <x11vnc installation dir>/etc/x11vnc.pass

change <x11vnc installation dir> with dir where you've installed x11vnc and <yourpswd> with password that you want

4.edit the Init/Default file in GDM.

gedit /etc/gdm/Init/Default

before the end of file, prior to exit, add the following line

# x11vnc

<x11vnc installation dir>/bin/x11vnc -rfbauth <x11vnc installation dir>/etc/x11vnc.pass -o /tmp/x11vnc.log -forever -shared -bg -rfbport 5900

save file and exit gedit

5.create a file in /etc/gdm/gdm.conf

gedit /etc/gdm/gdm.conf

Add the following:

[Debug]KillInitClients=false

All letters here are case sensitive. save file and exit gedit.

6.Restart the server.

VNC is running now you can connect to it from any VNC client use the ip address of the server,you'll be asked for a password that you created in step 3 if you want to change the password later repeat step 3

Note

1.I am using gnome as window manager

2.you should have access to the server from console via ssh(you should be able to login to server from console)

3.ensure that you disable vino

4.ensure that you’ve created the password file

Reference

 

 

 

 

Today was the first day of 3rd international conference on human computer interaction hosted by IIIT Bangalore.The original schedule of today was a talk followed by workshop on Industrial Software User Experience, the talk got canceled due to some reason.I could not check my mail this morning before I started for IIITB,so I need to wait for almost 3 hours,luckily I got company with some of the pros in usability field so it was time well spent.This is the third conference in India after IISC and IITB  as host for last two conferences.

Industrial Software User Experience Workshop was driven by Dr. Mikko Rissanen who is R&D Scientist at ABB Corporate Research and Dr. Kari Rönkkö who is assistant professor at the School of Engineering at Blekinge Institute of Technology.It was a good mix of industry and academic people in workshop.first there was introduction to Industrial Software User Experience followed by group discussion on aspects of Software User Experience.The discussion was good and we discussed great many things including how Industrial Software User Experience(IndUX) is different from a more common approach to UX driven by consumer products and web based interaction.

Second part of the workshop was about the metrics used in IndUX and we had discussion about the possible benchmarks,
with everyone having their opinion on the objective question of metrics the discussion reminded me of a quote by Einstein “Not everything that can be counted counts, and not everything that counts can be counted” .

While wtf/minute can be good metric for code quality it can be used in UX review as well :)

Overall it was a good experience I am looking forward to more fun in coming days with the crowd at India HCI 2011.

I was trying to check a log file for a particular keyword with grep,it only prints the line for which the keyword matches but I wanted the context as well.
what I needed was 10 lines before and after the matching line checked the man page and bingo! there it was.

if you use -B 10 with grep you’ll get 10 lines before the matching line,try -A number for number of lines after the match.If after and before number of line are going to be same you can use -C so
grep -C 10 keyword will show 10 lines before and after matching line.
[image:Clip Files by juan23for]

check out pendrivelinux for all Linux enthusiast this site has cool tools that’ll allow you to run ubuntu or other distros from flash drive(in persistent mode if you wish).in fact this post is written on such installation.it gives you the freedom to take your own tailored to fit operating system to any system you work on.

we all know last moment changes always result in that dreaded 3:00AM call from support guys,this has been proven infact there is a phd[pdf] thesis on it,Andreas Zeller from saarland university has done research on change inducing fixes,the research[pdf] can be simplified as linking version control and bug database together to track when the bugs are introduced in system and how they relate to some changes made recently.

below is the google tech talk given by Andreas Zeller where he discusses concept of delta debugging and software archaeology[pdf] further.

python

here is a tip on assigning hot keys for commonly launched apps.I am using firefox for example.
go to start menu go to programs right click on firefox(or if its pinned onto start menu like in my case directly right click on it)
assign_shorcut
click on properties and assign shortcut by selecting shorcut key text box and pressing the keys.
ff_shortcut
I used ctrl+alt+f you can use ctrl+alt+ in most cases so its easy to remember,in case ctrl+alt+ is already assigned to something else you can use different combination.

sortIn most database centric applications its faster to do sorting at database level(sorting at presentation layer is more desirable for some apps but an order by is much cleaner approach for reports that are just a database pull),as database are wired(read optimized) for sorting data.for reporting applications where its desirable to get certain columns to appear sorted in report,order by forces database to wait for all results and than apply sorting.

when this can go wrong? one scenario I see is trying to sort a non indexed column by applying order by.this can result in severe performance penalty.its always advisable to apply order by on indexed column and if possible create index on columns often sorted.If you’ve clustered index the cost of order by is almost zero as data is already sorted.if there is where clause as well in query its better to have index on column used in where and order by both so it can be used for filtering as well as sorting.

refactorin item 19 of effective java joshua bloch advises
Use interfaces only to define types
interface is always a quality of the implementing class like implementing Runnable implies that implementing class object can run as thread. so an interface tells what your class can do
all constant interface can be refactored to
enums
noninstantiable utility class (and can be used by static import to improve readibility)

truncatein db2 there is delete but there is nothing like truncate which is available in sybase and oracle.so what is the difference between truncate and delete.both are means to achieve almost the same end which is to empty a table but the main difference being while delete provides rollback truncate does not.what rollback means is if something goes wrong you’ll able to rollback to the original state your db was before you started.this is achieved by row level logging while deleting a record,which renders the process to be extremely slow for large tables.truncate comes to rescue as its a logged operation but at page level and just logs the deallocation of pages,so while the rows are still there it marks page to be used for any other storage.its faster with a caveat you won’t be able to rollback to original state before truncate.you can not truncate a table that has foreign key constraint you need to remove foreign key constraint truncate table and reapply the constraint.

there are few more differences like
delete is DML and truncate is DDL statement.
you can’t use where clause in truncate while it can be used in delete.
trigger doesn’t get fired in case of truncate while it does in case of delete.

its possible in db2 to truncate a table just the syntax is not that obvious.here is how you truncate a table in db2

alter table schema_name.table_name activate not logged initially with empty table

so what’s happening here

all data from current table is deleted,it can not be rolled back and can only be regained by RESTORE facility,if the unit of work in which this statement was passed is rolled back there will still be no data in table.when you issue this command no delete trigger on the table will get fired also any index on table gets deleted.

there is another way to achieve this and this operation is fully recoverable.

db2 load from /dev/null of del replace into table_name

later is preferred among the two option.

Next Page »

Follow

Get every new post delivered to your Inbox.