howto

Utilizing Off Time in Internet Radio

Submitted by abhishek on Sat, 09/27/2014 - 11:14
Airtime Image from Wikipedia

No one likes a silence when tuning to a radio station, and for a radio manager its tough to have 24*7 programmes, in case you are running an Internet Radio Station using Airtime you probably would be programming your shows and in Offtime your radio is always silent i would suggest you to play some random tracks in this Offtime and also include a track which tells when your station plays live so here is how to achieve this

Resize Multiple Images

Submitted by abhishek on Sat, 02/22/2014 - 10:25
ImageMagick

I am sure you would have come to a situation when you would have to resize multiple images say you copied 200 images from your Digital Camera and now need to upload them and need to resize them all, now doing this using GIMP would take ages here is a easy way.

Step 1) Install ImageMagick

sudo apt-get install imagemagick

Step 2) Change to the Directory where all Images are Present

Step 3)

a) If you need to reduce images to a specific Percentage

mogrify -resize 20% -format jpg *

b) If you need to reduce to Specific Width & Height

mogrify -resize 800x600 -format jpg *

c) If you need to reduce to Specific Width

mogrify -resize 1024x -format jpg *

Further Reading Click Here !!!

Drush & Dreamhost

Submitted by abhishek on Wed, 04/14/2010 - 10:19

Its been more than a year since i am using Dreamhost, The basic package is not too great but is cheap and the support is responsive.

Drush or the Drupal Shell is one of the most powerful tools to use when you are working with Drupal. DreamHost provides php5 but uses php4 as the default for the php command line and in that case drush wont work, so here is a 3 step guide to setup drush on your dreamhost account.

  1. Download & Extract Drush some where on your home folder
  2. Add the following lines to .bash_profile using your favorite editor.

    export PATH=/usr/local/php5/bin/:$PATH
    alias drush='/home/username/drush/drush'

    replace the path of drush as per your preferences :)

Using SQL * Plus on Command Line in Ubuntu

Submitted by abhishek on Sun, 02/28/2010 - 23:30

This blog post is an HowTo "Setup SQL*Plus to work on BASH" The commands illustrated in this howto are tested on Ubuntu 9.10 with Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production Installed.

What is SQL * Plus ?

SQL*Plus is a command line SQL and PL/SQL language interface and reporting tool that ships with the Oracle Database Client and Server software. It can be used interactively or driven from scripts. SQL*Plus is frequently used by DBAs and Developers to interact with the Oracle database.

Prerequisite

Oracle Database 10g Express Edition Release 10.2.0.1.0 Installed

Once you have Oracle 10g Installed successfully you can go to

Applications > Oracle Database 10g Express Edition > Run SQL Command Line

and successfully run all your SQL PL/SQL easily but using SQL*Plus directly on BASH is the real fun, Below are the steps which will enable you to use SQL*Plus on BASH

1) set ORACLE_HOME

4 Steps to add Ubuntu Systems to Active Directory Setup

Submitted by abhishek on Fri, 02/05/2010 - 12:13

The IT environment today in any organization is a sort of a mixture where many different Operating Systems are used, and Windows Active Domain Controller exists in majority of such organization.

Below is a 4 step How to on "Connecting Linux (Ubuntu) Systems to Active Directory Setup"

1) Update the Software Repositories

sudo apt-get update

2) Install Required Packages (likewise-open)

sudo apt-get install likewise-open

3) Join The Domain using Domain Administrator Account, replace Administrator with Domain Administrator Username and fqdn..domain with the Fully Qualified Domain Name

sudo domainjoin-cli join fqdn.domain Administrator

4) Update the Startup Scripts

sudo update-rc.d likewise-open defaults

Restrict Multiple Logins in Domain (AD)

Submitted by abhishek on Thu, 10/22/2009 - 12:00

I have always asked this question to my colleagues as to "How do i restrict Multiple Logins in an Active Directory Setup"

So here is the answer

Create a file when a user login and check for such file each time the login request is received  if file exists logoff, if file is not present Login and create the file. Its that simple

Below is the step by step process to achieve this using Group Policy

Assumptions:

Key Based Authorization with SSH

Submitted by abhishek on Wed, 08/26/2009 - 19:09

Using remote shells is all time favourite but remembering those many passwords is a pain so here are the steps to login using SSH without putting a password :)

 

1. Create a public ssh key, if you haven’t one already. Look at ~/.ssh. If you see a file named id_dsa.pub then you obviously already have a public key. If not, simply create one.

ssh-keygen -t dsa should do the trick. Please note that there are other types of keys, e.g. RSA instead of DSA.

2. Make sure your .ssh dir is not publically writable

    # chmod 700 ~/.ssh

Configuring Apache with SSL

Submitted by abhishek on Fri, 06/12/2009 - 14:47

Apache is the most common web server used now a days, you would have already configured apache many times by now but what about configuring it with SSL i.e. using apache to service on the https protocol, i assume you have already configured the basic apache server and have also enabled the SSL module, if not refer to my previous post on Configuring Apache Web server.

The following post is an extremely simplified step by step guide to configure SSL in apache using Self Signed Certificates you can also use a real certificate issued by a CA if you have it

Prerequisites

1) Apache with SSL module enabled
2) openssl installed

Step 1) Generate a Private Key

We will use the openssl toolkit for generating a RSA Private Key and Certificate Signing Request, as the first step generate the key the command below will create a 1024bit key using 3des

Configuring BSNL EVDO Modem in Debian GNU/Linux

Submitted by abhishek on Thu, 04/30/2009 - 23:16

EVDO DeviceI recently shifted to Debian GNU/Linux (Lenny), and the first task included configuring my Internet Connection, i use BSNL EVDO Modem to connect to the internet which is not recognized my default in Debian so following is the process by which i configured my BSNL EVDO in Debian

Step 1) Checked for Modem, Vendor and Product ID

$ cat /proc/bus/usb/devices

You will find many entires in this just check for your modem entry in my case i found

T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  4 Spd=12  MxCh= 0
D:  Ver= 1.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
P:  Vendor=19d2 ProdID=fffe Rev= 0.00
S:  Manufacturer=ZTE, Incorporated
S:  Product=ZTE CDMA Tech

by this i know the following information

G2Image in Drupal using TinyMCE with WYSIWYG API

Submitted by abhishek on Tue, 04/14/2009 - 13:03

UPDATE: This post is quite old now and wont work with the latest version of WYSIWYG API, will try to update this soon.

Gallery2 is one of the best galleries available which could be integrated with Drupal easily you would have read my post on integrating it earlier, after you have integrated it the bigger question is how get those images into your content or nodes so this posts answers it, after reading this post you would be able to integrate Gallery2 with your WYSIWYG (TinyMCE) Editor.

Prerequisites