Sunday, December 27, 2009

Replacing Adobe PDF Reader

Adobe Reader has been giving problems for last few months in printing PDF documents. This wasn't any installation issue since it gave problems on multiple computers and multiple OSs. Instead of printing the document, it was printing this:
ERROR: undefined
OFFENDING COMMAND: eexec
STACK:
/quit
-dictionary-
-mark
After searching on net, I found that it is a problem with the newer version of Adobe Reader. So finally, I decided to get rid of this bloated software which Adobe anyway has been abusing to push other things on my computer.

I checked portableApps.com and found Sumatra PDF Portable. I tried this software for a few days. This is not a very slow and processor-intensive software and printing is not good. In fact, when I tried to print a document with 120 pages, it froze my computer for a few hours. Currently, I am back to Adobe Reader.

Saturday, December 26, 2009

How to have peace of mind working on a computer?

With so many scams going on Internet and so many virus/spyware/malware floating around, it's hard to feel safe.

Here are a few things you can do to have peace of mind
  1. Always work in a low privilege account. This will assure that even if you did something terrible by mistake, only your account will get affected and your system will be safe. This will avoid all kinds of rootkit attacks, keyboard logging, and operating system corruption. I create an "Admin" account and a "user" account for myself. "Admin" account has administrative privilege and I do all administrative work like software installation and tweaking the OS from that account. For my day to day working I use "user" account. If something requires administrative privilege and I am working in "user" account, the UAC will pop for "Admin" password.
  2. Keep your operating system and browsers up to date. Automatic update of Windows and automatic update of Firefox both can be irritating. But this little irritation is worth.
  3. Install an antivirus software. Gone are the days when you need to pay for anti-virus software and the anti-virus software were irritating and resource hungry. Get Microsoft Security Essentials - it is free, light, no hassle easy to use, it is fast and well integrated with Windows.

Other tips:
  1. For highly critical sensitive things like banking, use a browser that does not allow add-ons like Google Chrome, Internet Explorer in No-Addons mode.
In Windows XP, working in non-admin account was a pain, but with Windows 7, working in non-admin is expected. With Windows 7, there is no reason, all the above process is totally frictionless.

Friday, December 25, 2009

WinSCP Portable and PuTTYPortable integration is half baked

WinSCP and PuTTY integration is quite good. WinSCP can launch PuTTY automatically and interactively both. Not so with WinSCPPortable.

WinSCPPortable integration with PuttyPortable is messy. It wouldn't launch putty automatically or interactively and will ask you to manually launch it. Everytime I set the settings in WinSCP to point to the PuttyPortable.exe file, WinSCPPortable.exe overwrites the settings with path to "PortableApps\WinSCPPortable\App\winscp\PuTTYPortableLinker.EXE." There are two ways to fix this:
  1. Change WinSCPPortable.exe
  2. Change PuTTYPortableLinker.exe

I chose option 2 as it was easy. Here are the steps:
  1. Rename "PortableApps\WinSCPPortable\App\winscp\PuTTYPortableLinker.EXE" to "PortableApps\WinSCPPortable\App\winscp\PuTTYPortableLinker1.EXE."
  2. Copy "PortableApps\PuTTYPortable\App\putty\PUTTY.EXE" to "PortableApps\WinSCPPortable\App\winscp\PuTTYPortableLinker.EXE."

This will launch putty right from winSCP automatically.

This does come with a price - the settings for Putty will be stored in the registry. Since I use portable apps on only few computers, this is OK for me, much better than launching putty manually every time. In fact, I renamed "PortableApps\PuTTYPortable\PuTTYPortable.exe" to "PortableApps\PuTTYPortable\PuTTYPortable.exe1" so that I don't have two different set of settings.

Here is something I did more to make my life easier:
  1. After running this setup for first time, launch "PortableApps\WinSCPPortable\App\winscp\PuTTYPortableLinker.EXE" and set the options for "WinSCP Portable Temporary Session"
I hope in the future WinSCPPortable and PuTTYPortable integration will be much better.

Tuesday, December 22, 2009

Windows Server 2008 / R2

Windows Server 2008 <=> Windows Vista
Windows Server 2008 R2 <=> Windows 7

I wanted to install Windows Server 2008 R2, but oooops it is available only 64 bits. And I wanted to put a server on my one of the old boxes.

So I have to settle for Windows Server 2008 Standard. Got it from DreamSpark website.

Sunday, December 20, 2009

nenasysguard.exe osguard wornv: virus/malware

This is a malware or virus. Here are some details:

nenasysguard.exe
http://osguard-pro2009.com/purchase?r=57.1
Local Settings\Application Data\wkornv\nenasysguard.exe

"Google Update" firefox plugin: Google's first malware

I was just looking into options to chat or do more through browser. I didn't want to install anything on my computer. So I went to this website: http://www.google.com/talk/. I clicked on the video chat link thinking if it opens in the browser then awesome or else if it asks for download, I will cancel it. Guess what, it actually started installing on my computer without any download pop-up. Well, I didn't feel immediately threatened as the website was a google website, but it did took me with a big surprise.

How can Firefox download and install something without explicitly showing the download popup? I was puzzled for a few seconds. And then it occurred to me that Extensions and Plugins can change Firefox's behavior. And there it was - "Google Update" plugin. I disabled it and tried the same thing, this time Firefox did show the download dialog popup.

Google sneaked in this plugin without my knowledge!!! I think it did when I installed Google chrome. You never know when this plugin will install application on your machine - clicking on a link could take you to a new page or directly install an application bypassing any Firefox security. Uninstall/Disable this plugin ASAP.

Google - the malware provider!

Wednesday, December 16, 2009

VLC: best video player || WMP: best music player

WMP 12 - It is lightweight, fast and has everything for my music and video needs except space bar wouldn't do pause/resume in the "Now Playing" window. How do you pause/resume when you are watching a video - either point to the play/pause button or press CTRL+P. Here is a nice comment - Cntr+P requires two hands, is buried among other keys, and as such probably requires the light on because it cannot be found blindfolded. And are you going to point to that little button when you are watching video? HERE is a shitty explanation for why space bar is not the shortcut for pause/resume. This is a BIG BIG inconvenience for me for watching video, so no no to WMP for video. Space bar does work in the library window which is good for listening for music. Here is the keyboard shortcut for WMP 12:
Keyboard shortcut for Windows Media Player 12

iTunes - This is the worse option on Windows. It can't play most popular formats. It is a bulky shit and it has its own way of doing things and not a flexible application. Before you can play anything you have to add it to its library. It does not even have "Open file" option. Launching takes for ever and it is slower than a hippo. Drag and drop does not work. There is a big bug in iTunes - there is no way to do auto cleanup its library. For managing and playing video, there can't be any worse options. The only good use is if you want to play music which are already in its library. If you don't have an iPod and iPhone, don't bother, this shit will install a bunch of services, unnecssary applications and do its best to corrupt your system.

Quicktime - good for playing online videos. Not good for playing 5 videos in a row. Anyway, it can't play most formats. My recommendation: install it for the codecs, but never use it, its menu is polluted with "Buy Pro." One of the ugliest software on a Windows machine.

Realplayer - I had some pretty bad experiences with it in the past.

iTunes, Quicktime, Realplayer and many of these commercial media players are a kind of malware since they install bunch of other garbage things during installation, and are very irritating because of putting themselves everywhere in the system. They even set the system to automatically start a bunch of junk apps and services.

VLC - plays all audio and video formats I can think of. Space bar is for pause/resume. It beats WMP in other keyboard shortcuts too. All WMP shortcuts require two keys. In VLC, most shortcuts require one key and are very intuitive - F for forward, P for previous, S for stop, etc.
When you are watching a video, last thing you want to do is fumble around the keyboard.

The only thing which I didn't like about is its UI. WMP and iTunes both have got some coolness, but the UI of VLC is very simplistic. I hope going forward these guys will add some shading, transparency and texture in their player.

It's not that uncool actually. There are skins available for VLC which look pretty cool. Here are dozens of skins to chose from:
http://www.videolan.org/vlc/skins.php

I really didn't want to spend time experimenting with different skins, so I chose the familiar ones:
  • WMP11 - this seems very promising
  • iTunes - the familiar itunes
  • MediaPlayer - like WMP 8 or 9
You can play the audio and video as fast or as slow you want. Nice feature!

Looks like I have finally found my dream media player.

There is a feature called "Customize interface..." where you can customize everything about the interface.


Now all I have to find a way to associate all media formats with VLC.

Actually I tried all three skins mentioned above, but I didn't like them; I used the default skin which sounded better than the above three skins. But right now I am going for the native interface. I will experiment with different skins later, or may be need to tweak one of them.

Here is the keyboard shortuct for VLC:
http://www.jaystech.com/2007/12/vlc-media-players-keyboard-shortcuts.html
http://shortcut-keys.net/vlc-media-player-shortcut-keys-complete-list/


VLC - simple and simply best!!!

Conclusion: VLC for video, WMP for music

Friday, December 11, 2009

Gnome still lacking and probably heading in wrong direction

Gnome has copied lot of things from KDE and Windows, but in an effort to be different, it has done many wrong things. Many of the changes were unnecessary, many of them create confusion, many of them are annoying, and many of them hampers your productivity and fun.

What is the need for two bars - one up and one down? It's a just waste of costly screen real state.

In the most recent one, the shutdown, restart etc was put in a different menu and put on the right corner. What is the point of doing this? Just to be different? What is the keyboard shortcut for this menu? Can you execute these commands without touching a mouse?

I have found many applications in Gnome which does not have keyboard shortcuts and can't be used without a mouse. That is the beauty of KDE and Windows, you can do everything without a mouse, just by using keyboard shortcuts and it increases your productivity by many folds.

There is a menu for Preferences and many of the items in the list are confusing. You click on an item, explore the application, find that the settings you were looking for is not there, so you close it and repeat the whole thing in the hope that this time you don't have to repeat the whole thing. How irritating!!! There is no reason why all the items in the Preference menu can't be put in a single application like KDE Control Center or Windows Control Panel. Same is applicable to Administration Menu.

Gnome just sux!!!
Nowhere close to KDE!!!

Wednesday, December 9, 2009

Tuesday, December 8, 2009

Windows: Symbolic links and mount

Here is a link on how to create symbolic links and hard links in Windows:

Command: http://www.howtogeek.com/howto/windows-vista/using-symlinks-in-windows-vista/
Concept: http://en.wikipedia.org/wiki/NTFS_symbolic_link

Here is an article on how to mount a drive or CD-ROM to a blank directory:

http://support.microsoft.com/kb/307889

Sunday, December 6, 2009

Setting up Subversion Versioning System

Finally, I was able to setup a subversion system to track the my programs and other files. Now I can go back in different versions of all the files which is great!!!

Setting up a subversion system was easy, must easier than I thought.

[In Progress]

Wednesday, December 2, 2009

Download YouTube Videos for iPhone, and Computer

Use this website:
http://www.savevid.com/

Download video in mp4 format, that way it can be played on iPhone also in addition to your computer.

I use this one:
http://googlesystem.blogspot.com/2008/04/download-youtube-videos-as-mp4-files.html

Tuesday, December 1, 2009

How to install an application on Windows without admin privilege

How to install an application on Windows without admin privilege?

In a corporate or university or school environment, it will be many times the case that users don't have admin access. And there are lot of application (mostly free and/or open-source) which are "just" applications and don't need admin privilege, but when you click on the setup file (exe or msi), it will pop up UAC dialog. I remember I was able to install these applications in Windows XP without admin privilege.

I noticed that when I try to install Microsoft Live Mesh or Google Chrome Browser, they don't pop-up UAC.

Here is my conclusion based on these observations:
The installer for Microsoft Live Mesh and Google Chrome Browser were updated for Windows 7 (or may be Vista) and the installer for other "non-admin" applications were not. Windows 7 detects that these installers were written for Windows XP and older, so it pops up UAC. Although Microsoft implemented a feature but it is broken. In a nutshell, a user should be able to do non-admin stuffs from non-admin account if she was able to do in Windows XP.

Update:

I found it:

"Local Policies -> Security Options -> User Account Control: Detect application installations and prompt for elevation" -> Disabled

Now it will not prompt UAC for installers. So when installing application if you want to give admin access to an installer, right click and select "Run as administrator."

Mounting a home directory of Linux on Windows through SSH

You have an account on a remote Linux machine and you work on a Windows machine. How do you mount the remote machine file system on the local machine so that you can access all your files on the remote machine as if they are on the local machine. This is very convenient compared to file transfer if you edit files on the remote machine regularly.

Approach# 1
There are two commercial solutions:
  1. SFTDrive or ExpanDrive
  2. Webdrive
But unfortunately, there are no free solutions for mounting through SSH.

Approach# 2
There is a free (for home use) software which allows for mounting through FTP and WebDAV.
  • http://www.netdrive.net./
You can install a ftp server or webDAV server in your account, and use this client. You may need to forward some ports. I don't know how hard will it be to configure and run a ftp server or webDAV server from a user account and the security implications of this.

Approach# 3
Install samba server in your account, and use Windows SMB client. You may need to do some port forwarding and probably disable SMB server on the Windows machine. I don't know how hard will it be to configure and run samba server from a user account and the security implications of this.

Approach# 4
Install sshfs in the Ubuntu in virtual box on the local machine, export the file system as SMB share and mount on Windows. This is my preferred approach as I don't have to worry about security and server configurations. The Ubuntu is behind Windows network, so it can connect to outside world, but only my Windows box can connect to it.


Update


I have tried a couple of things from above.

My use case: I edit files on Windows, but run my scripts and experiments on Linux which generate lot of other files and graphs which I open on Windows for viewing.

Approach#1 is easiest. I tried both WebDrive and Expandrive.

Webdrive: It has caching which was a big problem for me because my files get changed on both sides. And if caching is disabled, it is slower than a tortoise. After looking into log file, I discovered that it was running dozens of commands for simple things like saving a file. In one word: Webdrive sux.

Expandrive/Sftpdrive: It has no caching and is superfast. The only problem is that it will change the permissions on the files. When I edited some executable perl script files, it removed the executable bit from the file permission which was kind of irritating. So I have to say good-bye to expandrive, although I might consider this software in future since more or less it is an excellent software.

Approach# 4: This has lot of technologies involved: Virtualbox, Ubuntu, sshfs, samba. This is as fast as Expandrive and it keeps the permissions of the files. So this is my preferred setup. The only problem is I need to keep VirtualBox+Ubuntu running.

In the end, both Expandrive and Approach#4 are good. But I prefer Approach#4.

Update 3/26/2010

I found FUSE and sshfs equivalents for Windows:
http://code.google.com/p/dokan/
http://dokan-dev.net/en/
I haven't tried it, but looks OK.