Thursday, May 30, 2013

[Solved] Unable to find a valid source directory. Please install the kernel headers for your operating system.

To fix the error " Unable to find a valid source directory. Please install the kernel headers for your operating system." Run the command below:
---------------------------------------------------------------
yum install kernel-header kernel-devel
---------------------------------------------------------------

SAMPLE OUTPUT:
-------------------------------------------------------------
 [~]# yum install kernel-header kernel-devel
Loaded plugins: fastestmirror, rhnplugin, security
Loading mirror speeds from cached hostfile
 * cloudlinux-x86_64-server-6: xmlrpc.cln.cloudlinux.com
Setting up Install Process
No package kernel-header available.
Resolving Dependencies
--> Running transaction check
---> Package kernel-devel.x86_64 0:2.6.32-379.22.1.lve1.2.17.1.el6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================================================================================================================
 Package                            Arch                         Version                                                 Repository                                        Size
================================================================================================================================================================================
Installing:
 kernel-devel                       x86_64                       2.6.32-379.22.1.lve1.2.17.1.el6                         cloudlinux-x86_64-server-6                       7.3 M

Transaction Summary
================================================================================================================================================================================
Install       1 Package(s)

Total download size: 7.3 M
Installed size: 0
Is this ok [y/N]: y
Downloading Packages:
kernel-devel-2.6.32-379.22.1.lve1.2.17.1.el6.x86_64.rpm                                                                                                  | 7.3 MB     00:00   
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : kernel-devel-2.6.32-379.22.1.lve1.2.17.1.el6.x86_64                                                                                                          1/1
  Verifying  : kernel-devel-2.6.32-379.22.1.lve1.2.17.1.el6.x86_64                                                                                                          1/1

Installed:
  kernel-devel.x86_64 0:2.6.32-379.22.1.lve1.2.17.1.el6                                                                                                                        
Complete!
------------------------------------------------------------- 

Saturday, April 6, 2013

Read message from postfix queue


Reading message content on postfix queue
postcat -q MESSAGE_ID

To get "MESSAGE_ID" we can use "mailq" or "mailq | grep " where  is a e-mail address.

To delete a mail from queue use the command below:
postsuper -d MESSAGE_ID

To delete all deferred messages from queue:
 postsuper -d ALL deferred


To get ALL the MESSAGE_IDS of a particular e-mail address from queue:
 mailq|grep apache@vagrant2.vagrantweb.com|awk '{print $1}'

To delete ALL the mails from queue of a particular e-mail address:
for i in `mailq|grep apache@vagrant2.vagrantweb.com|awk '{print $1}'` ; do postsuper -d $i ; done

To delete ALL the mails from queue
postsuper -d ALL

Tuesday, February 12, 2013

Port Glance

How many ports did you know ??

Tuesday, January 29, 2013

How to Enable Java script in your Browser

 

Internet Explorer 6 and above

  • 1. Select Internet Options from the Tools menu.
  • 2. In Internet Options dialog box select the Security tab.
  • 3. Click the Custom Level... button. The Security Settings dialog box will pop up.
  • 4. Under Scripting category enable Active scripting.
  • 5. Click OK twice to close out.
  • 6. Click Refresh.

Mozilla 3.6.X and above

  • 1. Select Options from the Tools Menu
  • 2. Select Content tab
  • 3. Make sure Enable JavaScript is checked

Google Chrome

  • 1. Click the settings next to Address bar.
  • 2. Click Settings.
  • 3. Click on Show advanced settings...
  • 4. Click on Content Settings under Privacy.
  • 5. Check Allow all sites to run JavaScript (recommended) under Javascript.
  • 6. Click OK.

Wednesday, January 23, 2013

INSTALL OCR TESSERACT


Download the Tesseract-ocr package at
http://tesseract-ocr.googlecode.com/files/tesseract-2.00.tar.gz

Download the Tesseract-ocr language data package you want here:
http://code.google.com/p/tesseract-ocr/downloads/list

Choose the different packages you want, named "tesseract-2.00.XX.tar.gz" where "XX"
represents the language you want.
Now open a terminal and go to the folder containing your lastest downloads with the command "cd".
You need to run the next commands to install OCR Tesseract : ($> represents the prompt of your terminal)
$>tar –xvzf tesseract-2.00.tar.gz
$>cd tesseract-2.00
$>./configure
$>make
$>sudo make install
$>tar –xvzf tesseract-2.00.XX.tar.gz ("XX" represents the prefix language)| do it
$>sudo cp ./tessdata/* /usr/local/share/tessdata/ | for each language archive | 
$>rm –rf tessdata

Now that you have OCR tesseract on your computer, you can try it with these commands:
$>tesseract phototest.tif test
$>cat test.txt "test.txt" contains the same text than the picture "phototest.tif".

Twitter Delicious Facebook Digg Stumbleupon Favorites More

 
Design by Free WordPress Themes | Bloggerized by Lasantha - Premium Blogger Themes | Affiliate Network Reviews