Monday, May 30, 2011

Lubuntu Desktop on Natty

 If you don't like the default unity desktop , there are several alternative desktops available for Natty. Lubuntu from the LXDE project is one of my favorites.

install lubuntu in Ubuntu 11.04

Lubuntu is a faster, more lightweight and energy saving variant of Ubuntu based on LXDE desktop, the Lightweight X11 Desktop Environment.
  • Install Lubuntu in Ubuntu 11.04 by doing the following in Terminal.
sudo apt-get install lubuntu-desktop
  • Done. Lubuntu desktop will now be available within your Ubuntu GDM login window as a different session already.

Sunday, May 29, 2011

QR code on ubuntu

A QR Code (it stands for "Quick Response") is a mobile phone readable barcode.simply encode a URL into the QR Code and then point a mobile phone (or other camera-enabled mobile) at it. If the device has had QR Code decoding software installed on it, it will fire up its browser and go straight to that URL.

But it doesn't stop there - a QR Code can also contain a phone number, an SMS message  VCard data or just plain alphanumeric text, and the will respond by opening up the correct application to handle the encoded data appropriately courtesy of the FNC1 Application Identifiers that are embedded in the encoded data.

The technical specifications for a QR Code are set down in the ISO-18004 standard so they are the same all over the world, and the only significant variations from one QR code to another (apart from the data it contains) is the number of modules required to store the data.

To make things a bit more robust, the QR Code also contains its own error correction data, internal orientation calibration and self-alignment markers. In this way it doesn't matter whether the QR code is upside down or wrapped around a curved surface, the message will still get through.

You can easily generate QR Code under Ubuntu for this you need to install 'qrencode’ package. In Ubuntu, you can install qrencode using this command:
apt-get install qrencode
Go to terminal and type folloing command to generate QR code image:
qrencode -l L -v 1 -o unixlab.png "http://unixlab.blogspot.com"

Zorin Splash Manager

Zorin Splash Manager  is a cool application with which you can change the  theme  of Ubuntu desktop. The screen shot of the GUI is given below.

Install, change Plymouth Themes in Ubuntu

  Basically,   Zorin Splash Screen Manager is an application  made for Zorin OS project, a Linux distro based on Ubuntu. It offers the following features.
  •  You can install , remove and change the plymouth theme. Here are some additional screen shots on its usage.
Zorin Splash Screen Manager

Zorin Splash Screen Manager: Manage Plymouth Themes in Ubuntu
How  to install   Zorin Splash Screen Manager
 
     You can install the deb package  from the command line  or   you just double click of the deb package from nautilus ( this will launch gdeb-gtk)
 

 

Monday, May 16, 2011

Installing android on ubuntu

Here is a small tutorial on developing android apps on ubuntu platform.

 The article has step by step instructions and lots of screen shots.
http://ieffects.blogspot.com/2011/05/android-and-ubuntu-everything.html

Wednesday, May 11, 2011

Installing Ubuntu 11.04 in pendrive persistently : time for pendrive OS

What about the idea of carrying your operating system where you go? I am not talking about bringing your laptop everywhere you go, instead use your pendrive to carry your linux distro. Not simply the live distro, you can carry your operating system with all your configurations,

Sunday, March 20, 2011

Wall paper slide show on Kubuntu


Right Click on the Kubuntu Desktop and   Select "Desktop Activity Settings" Change the "Type" dropdown to read "Slideshow".
Select the Image folders you want to scan, and the time delay you want

How to block flash videos using Squid proxy Server

    Some times network admins want to block flash videos from  being played on the network. You can configure  Squid proxy server to do the same if we block the appropriate MIME type.
The MIME Type reply is generally set correctly so browsers are able to pass the reply to the correct module (image, text, html, flash, music, mpeg, etc.)

The MIME type for flash videos  is "video/x-flv". Creating an ACL to block this is easy.

First, create an ACL which matches the MIME type in question:
acl deny_rep_mime_flashvideo rep_mime_type video/x-flv
Then create a HTTP Reply ACL which denies any replies with that MIME type:
http_reply_access deny deny_rep_mime_flashvideo

If the content is blocked the following similar line will be seen in access.log:

1282485682.146    903 127.0.0.1 TCP_DENIED_REPLY/403 3143 GET http://tc.v15.cache3.c.youtube.com/videoplayback? - DIRECT/208.117.252.163 text/html

Saturday, March 19, 2011

Converting IMG files to ISO images

Some time you will find CD images with .img extentions. Most probably such images are created by clonecd, a windows program.

IMG files are raw-data copies of optical media and are primarily used  to  store  CDs with  odd  properties,such as sectors which need to have read errors when read. Conversion to ISO format removes this  information,as ISO format does not support this.

You can manipulate  such images if you install ccd2iso package.
   sudo aptitude install ccd2iso

  You can  convert  img files to iso files as shown below.
    ccd2iso file.img file1.iso
 IMG  files almost always include a SUB file, which contains additional data for the disc format, and a CCD file, which is a plaintext configu-ration file describing the disc layout.ccd2iso does not make use of  these files

  

Friday, March 18, 2011

How to Autostart a program at log in ( Ubuntu )

 You can start up a program or script automatically when you login by creating a ling to  ~/.config/autostart 
For example, to start Firefox at log in , create a symbolic link.
 $ sudo ln -s /usr/bin/firefox ~/.config/autostart
  

Thursday, February 24, 2011

How to enable PHP in Apache per user directory configuration on Ubuntu 10.10

   If you want to  do web application development on Ubuntu systems,  enabling per user directory configuration on Apache web server is a good idea.  You can  make a  directory on your home folder visible  to the web server and  view it via web browser.
   Let us start with  apache installation

$ sudo apt-get install apache2


  By default apache serves pages from  /var/www/
If you  invoke http://127.0.0.1 on a browser, you can view web pages stored in
/var/www . However , if you want to put a new  html page at /var/www , you need  root access.   You can make a directory in your home folder visible to the server and access this directory via http://127.0.0.1/~username.  ( Substitute username with your actual login name.) . For achieving this, do the following steps.
  
  $ sudo a2enmod userdir
        Enabling module userdir.
        Run '/etc/init.d/apache2 restart' to activate new configuration!


Now restart  apache
$ sudo /etc/init.d/apache2 restart



 Userdir   mod  will  make public_html  folder   in your home directory available on  web server.  You can create public_html   folder in your home folder and develop  your web applications.
    If you are developing  PHP applications , you have to enable php support  for per user directory configuration.
For enabling php,
sudo vi /etc/apache2/mods-available/php5.conf

Look for the lines that look like


and change them to look like:


 then restart apache.
sudo /etc/init.d/apache2 restart



 



Wednesday, February 16, 2011

System backup with TimeVault

Time vault is a GUI application that can assist  users in taking incremental back up.  Its functionality is similar  to Time/Machine available on Apple MACs

  TimeVault  makes automated  snapshots of (selected parts of) the file system. You can roll back to a previous version  of a file or directory, or just view it the way it was when the snapshot was taken. Snapshots are protected from accidental deletion or modification since they are read-only by default. The super-user can delete intermediate snapshots to save space, but files and directories that existed before or after the deletion will still be accessible

It's also integrates into Nautilus, so you can go the properties page for a snapshot'ed file (right-click in Nautilus and choose properties), and see a 'Previous Versions' tab with a calendar on it.

TimeVault Features include:
 * Automatically saves and recovers data
 * Actively monitors selected folders
 * Automated snapshots
 * Tight integration with Nautilus, the GNOME file manager
 * File-system agnostic
 * Highly configurable
 * Intuitive interface
 * Archive browser

TimeVault Installation and Configuration:
Download the .deb file from here, doubleclick on this file to install TimeVault.
After installing the .deb file, there are two steps required to complete installation:

You must configure TimeVault, the backend will start automatically but the notifier needs to be started: To get the notifier app to start in your systray whenever you log in you can add it to your startup programs in System > Preferences > Startup Applications, you should have an option to add a program click that, name it TimeVault and put:
/usr/bin/timevault-notifier
in the a terminal , you can put whatever you like in the comments box. After you have done this if you log out and back in again you should magically have the TimeVault notifier app sitting in your systray. Right click on it and go to preferences to configure TimeVault as you wish.

Using TimeVault:
There are three tabs: General, Include and Exclude.


General:
Enable Automated Snapshots: By default, TimeVault will not automatically take snapshots of your system. Checking this box will tell it to automatically take daily snapshots.

Show snapshot notifications: This switch toggles on and off whether snapshot notifications are to be shown or not.

Snapshot Root Directory: Where to store the snapshots. Ideally, you should pick a directory that is mounted onto another physical drive from the data you are backing up. This is so that, in the case of a hard-disk failure, the backups will remain intact (unless the drive containing the backups fails, in which case the current version of the data remains).

Make sure you change the settings under Advance to include your largest file, currently it is only set for 32mb. This is not large enough if you have videos as part of a back up. You may consider to back up to a network drive, in the case of total hard drive failure your data will be safe.

Include:
Backup paths are listed here. Every directory that you want snapshot should be added to this list.

Exclude:
Paths or patterns to exclude from the snapshots should be listed here.

When you have finished making the necessary changes click the save button and TimeVault should pop up a message saying. You have included new directories in the TimeVault. File signatures will now be computed. Click ok in this box and TimeVault should be active and will start watching your files.

Tuesday, February 15, 2011

Advanced IP subnet calculator sipcalc

      Sipcalc is an advanced console-based IP subnet calculator. It can take multiple forms of input (IPv4/IPv6/interface/hostname) and output a multitude of information about a given subnet.
 On ubuntu,  you can install it from  software center or from the command line.

If you want to calculate the netmask details of 123.123.123.123/28, here we go

$  sipcalc 123.123.123.123/28
-[ipv4 : 123.123.123.123/28] - 0

[CIDR]
Host address        - 123.123.123.123
Host address (decimal)    - 2071690107
Host address (hex)    - 7B7B7B7B
Network address        - 123.123.123.112
Network mask        - 255.255.255.240
Network mask (bits)    - 28
Network mask (hex)    - FFFFFFF0
Broadcast address    - 123.123.123.127
Cisco wildcard        - 0.0.0.15
Addresses in network    - 16
Network range        - 123.123.123.112 - 123.123.123.127
Usable range        - 123.123.123.113 - 123.123.123.126

Any net admin would love this gem.

You can use it on your existing interfaces too.
Here is the sample ipcalc output from my wlan interface

  # sipcalc -d -bcix -n 4 -e -r -t  wlan0


 [Classfull]
Host address        - 192.168.1.2
Host address (decimal)    - 3232235778
Host address (hex)    - C0A80102
Network address        - 192.168.1.0
Network class        - C
Network mask        - 255.255.255.0
Network mask (hex)    - FFFFFF00
Broadcast address    - 192.168.1.255

[CIDR]
Host address        - 192.168.1.2
Host address (decimal)    - 3232235778
Host address (hex)    - C0A80102
Network address        - 192.168.1.0
Network mask        - 255.255.255.0
Network mask (bits)    - 24
Network mask (hex)    - FFFFFF00
Broadcast address    - 192.168.1.255
Cisco wildcard        - 0.0.0.255
Addresses in network    - 256
Network range        - 192.168.1.0 - 192.168.1.255
Usable range        - 192.168.1.1 - 192.168.1.254
[Classfull bitmaps]
Network address        - 11000000.10101000.00000001.00000000
Network mask        - 11111111.11111111.11111111.00000000

[CIDR bitmaps]
Host address             - 11000000.10101000.00000001.00000010
Network address        - 11000000.10101000.00000001.00000000
Network mask              - 11111111.11111111.11111111.00000000
Broadcast address    - 11000000.10101000.00000001.11111111
Cisco wildcard        - 00000000.00000000.00000000.11111111
Network range        - 11000000.10101000.00000001.00000000 -
                                  11000000.10101000.00000001.11111111
Usable range        - 11000000.10101000.00000001.00000001 -
                                11000000.10101000.00000001.11111110

[Networks]
Network            - 192.168.1.0     - 192.168.1.255 (current)
Network            - 192.168.2.0     - 192.168.2.255
Network            - 192.168.3.0     - 192.168.3.255
Network            - 192.168.4.0     - 192.168.4.255






Reading E Books with FBReader

  If you are an avid E-book fan FBreader is a cool app for you. FBreader is available  on several platforms.Its main features are,

*  supports several open e-book formats: fb2, html, chm, plucker, palmdoc, ztxt, tcr (psion text), rtf, oeb, openreader, non-DRM'ed mobipocket, plain text, epub

*  reads directly from tar, zip, gzip, bzip2 archives (you can have several books in one archive)

*  supports a structured view of your e-book collection  automatically determines encodings

*  automatically generates a table of contents

*keeps the last open book and the last read positions for all open books between runs

*  automatic hyphenation (patterns for several languages are included)
*  searching and downloading books from www.feedbooks.com and www.litres.ru

* partial CSS support for epub files

  FBReader can be downloaded from its website for several platforms. Some of  the supported platforms include
       

  • Linux

  • Windowa

  • SmartQ 5/7 MID.

  • Nokia 770/N800/N810) Internet Tablet.

  • Sharp Zaurus with Qtopia-based ROindoiM (e.g., original Sharp, Cacko) installed.

  • Sharp Zaurus with pdaXrom installed.

  • Sharp Zaurus with OpenZaurus installed.

  • Siemens Simpad with OpenSimpad 0.9.0.

  • Archos PMA430.

  • PepperPad.

  • Motorola A1200 smartphone.

  • Google Android.


  •  
        FBReader   can be installed on  ubuntu from softeware center or from the command line.
    $ su apt-get install fbreader

     Here are some screen shots of FBReader