Saturday, December 26, 2015

[Solved] - Could not reliably determine the server's fully qualified domain name...

Error: 'AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message, ubuntu 14.04'

Solution: 

In new version of apache2 you just following command like this:

 sudo nano /etc/apache2/apache2.conf  

Add the following new line end of file:

 ServerName localhost  

Then restart apache2:

 sudo nano service apache restart  

It's done!

Source: http://askubuntu.com/questions/256013/could-not-reliably-determine-the-servers-fully-qualified-domain-name

Friday, December 11, 2015

Ubuntu Asking for FTP Credentials on Localhost while using Wordpress

If you are on a Ubuntu OS and have been using Wordpress on a localhost and been trying to install a plugin or a theme and then being asked for FTP credential, below is the solution:

 sudo chown -R www-data:www-data 'insert-filename-of-wordpress-installation'  


Problem solved!

Wednesday, December 2, 2015

[Solved] Samba Not Working in Ubuntu 15.04

If you are unable to run Samba in Ubuntu 15.05 follow the following steps:

Open up your Terminal and execute the following commands:

 CTRL+F2  
 gksu system-config-samba  

 sudo touch /etc/libuser.conf  

 CTRL + F2  
 gksu system-config-samba  

Source: http://ubuntuforums.org/showthread.php?t=2290002

Monday, October 12, 2015

Difference Between CRM & ERP

Below is nice little video explaining the difference between ERP & CRM while I was researching on CRM.



Wednesday, October 7, 2015

Complete Google AdWords Tutorial 2015: Go from Beginner to Advanced Today!

As I was researching on how to make best use of Google Adwords this is the video I found which could help me in doing that. I recommend it to my blog visitors if in case you too were looking at ways to make best use of Google Adwords.



Tuesday, October 6, 2015

Shortcut To View Extension In Opera Browser

Open you Opera browser and enter the line below in your Address bar:

 opera://extensions  

Saturday, October 3, 2015

[SOLVED] - Unable To Uninstall phpMyAdmin in Ubuntu 14.04

I was unable to uninstall my phpMyAdmin due to some error I committed while trying to install it. After that while trying to uninstall it I started to get the following errors:

Errors were encountered while processing:phpmyadminE: Sub-process /usr/bin/dpkg returned an error code (1) 

Eventually the steps below worked for me:

Step 1:

 cd /var/lib/dpkg/info/  

Step 2:

  ls -l phpmyadmin.*  
 -rw-r--r-- 1 root root  165 2008-03-05 21:42 phpmyadmin.conffiles  
 -rwxr-xr-x 1 root root  287 2008-03-05 21:42 phpmyadmin.config  
 -rw-r--r-- 1 root root 33524 2008-08-06 11:31 phpmyadmin.list  
 -rw-r--r-- 1 root root 51996 2008-03-05 21:42 phpmyadmin.md5sums  
 -rwxr-xr-x 1 root root 3286 2008-03-05 21:42 phpmyadmin.postinst  
 -rwxr-xr-x 1 root root 1762 2008-03-05 21:42 phpmyadmin.postrm  
 -rwxr-xr-x 1 root root 1762 2008-08-06 09:12 phpmyadmin.postrm.orig  
 -rwxr-xr-x 1 root root  339 2008-03-05 21:42 phpmyadmin.preinst  
 -rw-r--r-- 1 root root 22441 2008-03-05 21:42 phpmyadmin.templates  

Step 3:

Now delete the phpMyAdmin files:

 sudo rm -r phpmyadmin.*  

Step 4:

Verify whether the phpMyAdmin files are still around:

 sudo apt-get remove phpmyadmin  

You should get the following message 'Package 'phpmyadmin' is not installed, so not removed' which confirms all the phpMyAdmin files have successfully been removed.

Step 5:

Finally if you wish you may install phpMyAdmin again:

 sudo apt-get install phpmyadmin  

Friday, October 2, 2015

Upgrade MySQL 5.5 to 5.6 -- Ubuntu 14.04

Step 1 : Take a backup:

 mysqldump --lock-all-tables -u root -p --all-databases > dump.sql  

Step 2 : Remove your older version of  MySQL:

 sudo apt-get remove mysql-server  

 sudo apt-get autoremove  

Step 3 : Install new version of MySQL:

 sudo apt-get install mysql-client-5.6 mysql-client-core-5.6  

 sudo apt-get install mysql-server-5.6  

Step 4 : Restore your data:

 mysql -u root -p < dump.sql  


Wednesday, September 23, 2015

Check Your Internet Speed from Terminal, Ubuntu

This post explains you how to test your internet speed from your terminal in Ubuntu:

1. Install the python-pip package:

 sudo apt-get install python-pip  

2. Now install the speedtest-cli:

 sudo pip install speedtest-cli 

3. Finally run the command below to test your internet speed:

 speedtest-cli  


Monday, September 7, 2015

[Solved] Magento 500 Internal Server Errors in Ubuntu

I purchased a Magento theme from themeforest and was trying to run a test install in my localhost under Ubuntu. I googled and tried various solutions but all in vain. Perhaps they might work for you and you may give it a try at by visiting the following link: How to Solve Magento 500 Internal Server Errors. But if that does not help you can try doing what I did.

1. Firstly go and check your Apache Error Logs at: '/var/log/apache2/error.log'

2. There check if you are getting an error such as:

[Mon Sep 07 12:40:40.533934 2015] [core:alert] [pid 31413] [client 127.0.0.1:47560] /var/www/html/magento/.htaccess: Invalid command 'Header', perhaps misspelled or defined by a module not included in the server configuration

To resolve this open your Terminal by pressing CTRL+ALT+T and enter the following commands. Basically what you are doing is what is called the mod_headers:

 sudo a2enmod headers  

and then restart your Apache web server:

 service apache2 restart  

Now try accessing your website and it should work!

[Solved] - Magento - Cannot delete or update a parent row: a foreign key constraint fails

If you get the following error while trying to drop your Magento tables all you need to do to delete the remaining tables is, first try and drop a few tables from top or bottom and then try deleting the remaining tables all at once.

This should work.

Sunday, August 30, 2015

Magento Base URL Issue While Installing In Localhost

Magento Base URL is the URL used to access Store pages. 

Seems like Magento is specific about the dots/periods in the URL and hence http://localhost/ /path-to-your-magento-installation don't seem to work.

If you are trying to install Magento in your localhost and during the process of installation experience issue with the base url then instead of 'http://localhost/path-to-your-magento-installation' use ''http://127.0.0.1/path-to-your-magento-installation' or create a virtual host and proceed with your installation.

Monday, July 20, 2015

How To Clear MySQL Screen In Ubuntu/Linux Terminal

While at your MySQL terminal enter the command below:

 mysql> \! clear  

Saturday, June 20, 2015

[Solved] cPanel Mailbox Running Out Of Space/Getting Filled! What To Do?

If you are on a Shared Hosting Account using cPanel as your Server Management Tool and use its' Web Mail feature, then often you might have landed into this precarious situation where you find yourself running out of Mailbox space after a certain period of time. That's if you begin to get loads of message running into thousands! And once your mailbox is filled your mail starts bouncing and the only option that remains with you is either to backup your mails in your local computer or delete some of your old mails. But again a time comes where you find yourself ---- back to square one with your mailbox filled!!! Also may be you would not want to delete all your mails and like to keep all/some of your mails with you.

So, today I finally have found an easy work around which will cost you not a single dime, save your lots of worry and precious time.

To achieve this we will use Gmail's variety of features and it's better you create an unique Gmail id for the email account you are trying to create a backup.I am sure the same can be done using Hotmail/Outlook and may be even Yahoo.

These handy features of Gmail will allow us to:
  1. Import all our mails from our Remote Server to it's inbox retaining all the originals in the Hosting Server (provided you select the option to retain all message in the web host, while configuring Gmail.)
  2.  Create an 'alias' to the above Email Account in Gmail so that you can reply from your Gmail account as though you were using the above Email Account.
  3. Create an automatic forwarder in the Web Host so that all the mails get automatically forwarded to your Gmail (This is optional --- read below to know why.)

    Out of personal experience I know this is a better choice than storing your mails in your local computer because if your computer happens to crash or experience data loss you will have no worry whatsoever about loosing your mails as all your mails will be in the Gmail Server.
Step 1:  Importing the Emails from Web Host to your Gmail Account

As in the above figure first click on Settings

Click on Accounts & Imports

Click on Import mail and contacts a Window as below will pop out.

Monday, June 8, 2015

Correctly Installing Kali Linux Headers

You might have wanted to install Guest Addition modules in Kali Linux under VirtualBox but failed due to failure of Kali Linux Headers. To solve execture the commands below in your terminal:

1. Find your header type by executing the following command:
 uname -r  

You should get output, depending on your version as:
3.18.0-kali3-amd64

2. Next execute the command below:
 apt-cache search amd64 headers  

3. Once you got the header information use it as below to download the latest header for your Kali Linux:
 apt-get install linux-headers-3.18.0-kali3-amd64 -y  

Your header should now be updated

Monday, June 1, 2015

Hidding Empty Taxonomy Term in Block Using Views

If you would like to hide empty terms while rendering them in blocks using Views try the method below:

  1.  Relationships > "Taxonomy term: Content with term" and checked the Required Relationship.
  2. Query settings > Distinct.
That's it!

Saturday, May 30, 2015

'Fatal error: Call to undefined function content_taxonomy_allowed_values()

If you are getting the following error:

'Fatal error: Call to undefined function content_taxonomy_allowed_values() in /modules/taxonomy/taxonomy.module on line 1496'

one of the reason might be you have disabled the Taxonomy and Content Taxonomy modules. Just check whether that's the case, if so, re-enable those modules and your problem should be resolved.

[Solved] Configure SSH, PuTTy in Ubuntu 14.04, 14.10, 15.04 to Connect from Localhost to Remotehost

Solutions to Successfully connect to a remote server using SSH in Ubuntu & cPanel account


After fiddling around with a lot of this and that the solution below is what eventually worked for me. I tried PuTTY SSH client and all that but eventually I found it simple and best to use the default Ubuntu Terminal. Anyway PuTTY is just a GUI client which you use instead of using the Terminal.

1. Generate SSH Key in Linux

Open your terminal and enter the following commands:
 $ ssh-keygen -t dsa  

You should get the output as below:
Note: When asked to enter file name simply hit enter without enterning any file name so that your file is named 'id_dsa' automatically.

Then enter  a strong passphrase and make sure you remeber it for future use.
 Generating public/private dsa key pair.  
 Enter file in which to save the key (/home/user/.ssh/id_dsa):  
 Enter passphrase (empty for no passphrase):  
 Enter same passphrase again:  
 Your identification has been saved in id_dsa.  
 Your public key has been saved in id_dsa.pub.  
 The key fingerprint is:  
 11:2e:e8:b2:1d:c9:b9:cf:76:9a:b3:3a:c1:1f:95:93 user@localhost  


This will create a private key written to /home/user/.ssh/id_dsa and a public key written to /home/user/.ssh/id_dsa.pub. The passphrase is used to protect your key. You will be asked for it when you connect via SSH.

 2. Upload Public Key to your cPanel Account

Open the file 'id_dsa.pub' in a text editor like Gedit and copy it's content.

Now log into your cPanel Account, Open SSH/Shell Access and Paste as shown in the image below.

If you don't do this you will get an error saying 'Permission denied (publickey).'

3. Time to Connect to your Remote Server Account

Now load your private SSH key using the following command:
 $ ssh-add /home/user/.ssh/id_dsa  

When asked to enter the passphrase enter the passphrase that you have set during the generation of the SSH key.

Now initiate your SSH connection by using the following commands:

 $ ssh Username@Hostname -pPort_Number  

where,
  • Username is your cPanel username or Webhost Account Username
  •  Hostname can be your server's IP address or domain name or your server's name
  • Port_Number is default is '22' or could be something like '18765' as set by my Webhost Provider.
Press "Enter" and if everything has been set up properly, you will establish an SSH connection to your account.

Friday, May 29, 2015

Install PuTTY SSH Client on Ubuntu 14.04, 14.10, 15.04

I tried installing PuTTY in Ubuntu under Wine Version 1.7.38 but everytime I tried to execute it from the Terminal I was getting the following error:

'wine: cannot find L"C:\\windows\\system32\\putty.exe"'

So after some searching I found out that it can be easily installed from the Software Center. Just click on the link below and download it:

https://apps.ubuntu.com/cat/applications/precise/putty/

Friday, May 22, 2015

Disable Show Hidden Files in Ubuntu

Somehow my 'Show Hidden Files' options seems to have become the default selection and hence everytime I opened my Files (Nautilius) all my Hidden files were being revealed. To fix it this is what I did:

1. Open Terminal and type:
 dconf-editor  
Enter and then in the window that has opened make the following Selection:
Goto org->gtk->settings->file-chooser
& UNCHECK show-hidden

Monday, May 18, 2015

Increasing the Script Timeout Limit in phpMyAdmin in Ubuntu 15.04 and other LAMP Servers

If you are facing problems importing your database dump into your  MySQL server using phpMyAdmin follow the steps below to resovle the issue:

Open the 'config.inc.php' file located inside '/etc/phpmyadmin/config.inc.php' and add the following line:
 $cfg['ExecTimeLimit'] = 0;  

This will remove any time constraint in phpMyAdmin for database import.

Now make the following changes in your 'php.ini' file which is located at '/etc/php5/apache2/php.ini.' You will have to sudo and open your editor to make/commit the changes:
 post_max_size = 750M  
 upload_max_filesize = 750M  
 max_execution_time = 300  
 max_input_time = 540  
 memory_limit = 1000M  

Now finally restart your Apache Web Server:
 sudo service apache2 restart  

Thursday, May 14, 2015

[SOLVED} How to RESET/CHANGE Administrator/Super User Password using Drush in Drupal 7?

If you have forgotten your Administrator password for your Drupal 7 Site you can try the following command in Drush to recover it:

 drush uli admin-username  

This will generate a one time login link. By default it provides one-time login link for administrator.

If you want to generate for other user try the following:

 drush uli some-username  

This will generate one time login link for that user.

Also you may try the method below:

 $ drush help user-password  

(Re)Set the password for the user account with the specified name.

Examples:

 drush user-password someuser --password="pass123"   

Sets the password for the username someuser.

Arguments:
 - name The name of the account to modify.
 - Options: --password= The new password for the account. Required.
 - Aliases: upwd

Sunday, May 10, 2015

Correctly Using Registry Rebuild in a Multisite Installation with Drupal 7

If you have a multisite Drupal installation and need to run Registry Rebuild follow the instruction below. As the first line in the download page states, remember this is not a module and you can't enable it. And if rightly set you can rebuild your Registry with ease.

Download the files and place it inside the folder of the website whose registry you would like to rebuild. Say, suppose your multisite is as follows:

1. www.example.com (Main Site)
2. www.abc.example.com (Multisite 1)
3. www.123.example.com (Multisite 2)

& you would like to rebuild the registry for Site #2 viz. www.abc.example.com.

So your folder structure for the websites below might be something like:
 /var/www/html/www.example.com  
 /var/www/html/www.example.com/sites/abc.example.com  
 /var/www/html/www.example.com/sites/123.example.com  

Extract and check the files inside your registry_rebuild folder. The file to note here is 'registry_rebuild.php.' Open it in an editor of your choice and make the following edit in line 10.

Change
 define('DRUPAL_ROOT', define_drupal_root());  
to
 define('DRUPAL_ROOT', $_SERVER["DOCUMENT_ROOT"]);  

This will help you get the appropriate Drupal Root for each of your multisites else you will get an error as below:
 Failure: Unable to discover DRUPAL_ROOT. You may want to explicitly define it near the top of registry_rebuild.php  

Now place the registry_rebuild folder that you just extracted inside the multisite folder whose registry you want to rebuild; in our case it's abc.example.com and access it as below in your browser:
 http://abc.example.com/sites/abc.example.com/registry_rebuild/registry_rebuild_multisite.php  

The process will take some time and you might just see a blank browser. Finally if your registry has been successfully rebuilt you should get a confirmation message as below:
 DRUPAL_ROOT is /var/www/html/projects/example.com.  
 Bootstrapping to DRUPAL_BOOTSTRAP_SESSION  
 Bootstrap caches have been cleared in DRUPAL_BOOTSTRAP_SESSION  
 Doing registry_rebuild() in DRUPAL_BOOTSTRAP_SESSION  
 Bootstrapping to DRUPAL_BOOTSTRAP_FULL  
 Rebuilding registry via registry_rebuild_cc_all in DRUPAL_BOOTSTRAP_FULL  
 All caches have been cleared with registry_rebuild_cc_all.  
 There were 616 files in the registry before and 616 files now.  
 All caches have been cleared with registry_rebuild_cc_all.  
 If you don't see any crazy fatal errors, your registry has been rebuilt.  

Now you should be able to access your site.

Note: Also if you are using VirtualHost then make sure your Document root is the path to the main site folder as below and not the multisite folders inside the 'sites' directory:
 DocumentRoot /var/www/html/example.com  
and not
 DocumentRoot /var/www/html/example.com/sites/abc.example.com  

Monday, May 4, 2015

How to Change Bluetooth Device Name in Ubuntu 15.04, Vivid Vervet

To change your default bluetooth device name 'ubuntu-0' to the name of your choice follow the steps below: Open Terminal (CTRL+ ALT+T) and execute the commands below:
 sudo gedit /var/lib/bluetooth/*/config  

Change the value of device name to the name of your choice.

SAVE & RESTART:
 service bluetooth restart  

Sunday, May 3, 2015

Enable/Customize Startup/Login Sound in Ubuntu 15.05 (Vivid Vervet)

If you would like to enable or customize startup/login sound in Ubuntu 15.05 and have been looking for a workaround, follow the instructions below:

1. First open your Terminal and enter the following commands and change the value NoDisplay from true to false:
 gksudo gedit /usr/share/gnome/autostart/libcanberra-login-sound.desktop   


SAVE the file and EXIT.

2. Now OPEN Startup Applications by searching it in your Unity Dash (you can press the Windows key and search)

3. Once in Startup Application click on Add and then you may enter as below:
 - Name: Login Sound  
 - Command: /usr/bin/canberra-gtk-play --id="desktop-login" --description="play login sound" --volume=10  
 Comment: Play sound when I logs in 



Click on SAVE

4. To play a custom sound, install mplayer (Movie player for Unix-like systems), then type following in command area:

 mplayer /home/handbook/Music/Hello-Moto.mp3  

5. Finally, Logout/Login and Chec

[SOLVED] [UBUNTU 15.04 - Vivid Vervet] Change cpufreqd default to Ondemand from Performance

After installing cpufreqd on Ubuntu 15.04 I noticed that by default the mode being selected is 'Performance.' I wanted it to be 'On Demand' as used to be in earlier versions. If you want to change to 'On Demand' like me follow the steps below:

1. First go to '/etc/' and find the file 'cpufreqd.conf' and make a backup of it. To do so you can copy the file and paste it in your Desktop.

2. You can manually change to 'On Demand' mode entering the following command in your terminal:
 sudo cpufreq-set -c 0 -g ondemand  

But this is a temporary change. If your restart cpufreqd you will see that it reverts back to 'Performance.' Try it using the following command:
 sudo service cpufreqd restart  

So to make the change permanent goto Step 3:

3. Open your terminal (CTRL+ALT+T) and type the following command:
 sudo gedit /etc/cpufreqd.conf  

On line 4 & line 5 you should see a Note as below(to view line numbers in gedit, Click on Edit - Preferences - Under View - Check Display line numbers:
 # Note: ondemand/conservative Profiles are disabled because  
 # they are not available on many platforms.  

Now uncomment all the lines from line number 28 to line number 40 as below:
 [Profile]  
 name=On Demand High  
 minfreq=40%  
 maxfreq=100%  
 policy=ondemand  
 [/Profile]  
 [Profile]  
 name=On Demand Low  
 minfreq=20%  
 maxfreq=80%  
 policy=ondemand  
 [/Profile] 

Also uncomment the lines from line number 71 to 83.

In line 92 change 'Performance High' to 'On Demand High' as below:
 profile=On Demand High  

Now SAVE your file and RESTART as stated above.

You should now see that your cpufreq mode changes to 'On Demand' if it was in 'Performance' or continue to stay in 'On Demand' mode.

Tuesday, April 28, 2015

Install Firewall in Ubuntu 15.04



Ubuntu 15.04 has already UFW firewall installed but it's command line. Install Graphical interface for UFW to configure firewall easily.
 sudo apt-get install gufw   

Wednesday, April 22, 2015

[[Solved]] Acer V3-571G Brightness Problem in Ubuntu 14.04

If you are facing problem with your screen's brightness with your Acer V3-571G laptop; you can try the working solution below:

This is the solution amongst the various solutions available in the internet that worked for me.

1. First open Terminal with CTRL + ALT + T

2. Run the following command in the terminal:
 sudo gedit /etc/default/grub  

then change
 GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"  
 GRUB_CMDLINE_LINUX=""  

to
 GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_backlight=vendor"  
 GRUB_CMDLINE_LINUX="acpi_osi=Linux"  

then SAVE & RUN
 sudo update-grub   

Finally RESTART your laptop for the changes to take effect.

[[Solved]] How to Install Android Games with Obb Files

Was trying to install Fifa 2014 on my Lenov Yoga 8 Tab and came across this solution. I tried Fifa 2015 but with the it's compulsory option of allowing a user to play the game online only, I didn't quite like it, so reverting back to Fifa 2014.


Saturday, April 18, 2015

[[SOLVED]] Configuring RALINK MOTOROLA Bluetooth Adapter in Ubuntu 14.04

After a lot of searching and trials and errors I have found the following configurations that have worked for me:

Problem #1: Bluetooth device not discoverable

Solution #1:  
With Ralink FAE, we found that the radio is OFF and the following command has to be executed to turn ON the device again:

sudo bccmd psset -s 0x0000 0x028c 0x0001

+ reboot

and after that bluetooth work fine (enable and disable in same time with wifi)


Tested on HP DV7-6090EF (Ralink RT5390 Combo Wifi/bluetooth) Driver (http://www.ralinktech.com/support.php?s=2 ) V2.4.0.4  Ubuntu Natty 11.04 64 bits

Source: http://ubuntuforums.org/showthread.php?t=1776108
 Problem #2: Audio Sink Problem to Nokia BH-503 Bluetooth Headset

Solutions #2:
I had this problem recently as I bought a bluetooth speaker and attempted to connect to it with my laptop. It kept giving me "Connection Failed: Stream setup failed". I eventually figured out how to make it work like this.

You need to have pulseaudio installed, which you can check for in Synaptic Package Manager by typing pulseaudio into the search bar. You can install it from there if it isn't already installed.

Next, you need to install pavucontrol, either in Synaptic Package Manager, or by running this in the terminal.
Code:

 sudo apt-get install pavucontrol  
This is the unfortunate part. Every time you boot, you need to run this command in the terminal before any bluetooth devices attempt to connect.
Code:

 pactl load-module module-bluetooth-discover  
You can now go into the bluetooth manager and tell it to connect to the device as an A2DP audio sink.

Now, finally, if you go into the PulseAudio Volume Control, on the Playback tab, you can choose the option to send audio through the bluetooth device.
Source: http://ubuntuforums.org/showthread.php?t=2246613

Wednesday, April 8, 2015

Alternative to Adobe Reader in Ubuntu 14.04 for Anottation, Text Hightlighting etc...

I found this wonderful alternative to Adobe Reader for Ubuntu/Linux and it's called Okular which is a free software PDF reader.

What is it?

Here what there website says:
Okular is a universal document viewer based on KPDF for KDE 4. This means Okular works on multiple platforms, including but not limited to Linux, Windows, Mac OS X, *BSD, etc.

Okular combines the excellent functionalities of KPDF with the versatility of supporting different kind of documents, like PDF, Postscript, DjVu, CHM, XPS, ePub and others.

The document format handlers page has a chart describing in more detail the supported formats and the features supported in each of them.
 Okular gives you various options such as annotation, text highlighting, text extraction etc.

To install Okular in your Ubuntu:

 sudo apt-get update  
 sudo apt-get install okular  

Friday, April 3, 2015

How do I enable directory listings for a folder on my Web site?

If a directory doesn't contain an index file (a file named "index.html", "index.htm", "index.php", etc.), Web servers will normally show an error message if someone uses a Web browser to visit the URL address of that directory.

This provides security for your files: it prevents strangers from viewing the names of all files in a directory and snooping through them, possibly finding files that are intended to be private.

However, if you actually want your site visitors to be able to see all the files in a directory, you can do that by placing a file named .htaccess in the directory. The file should contain this line of text:

 Options +Indexes  
(This command is explained in the Apache Web server documentation.)

After you do that (and also remove any index file such as "index.html" from the directory), anyone visiting the address of the directory will be able to view a list of all files in it and click on the individual files to open them.

Advanced directory listing customization

You can customize the directory listings by setting certain options for the mod_autoindex module.

The following lines display a file's full name, no matter how long it is:

 Options +Indexes  
 IndexOptions FancyIndexing FoldersFirst NameWidth=* DescriptionWidth=*  

Or you can set a character length limit, like this:

 Options +Indexes  
 IndexOptions FancyIndexing FoldersFirst NameWidth=30 DescriptionWidth=30  

You can suppress the display of file icons by adding the SuppressIcon option:

 Options +Indexes  
 IndexOptions FancyIndexing FoldersFirst SuppressIcon  

See the Apache Web server mod_autoindex documentation for full details about IndexOptions.

Source: https://support.tigertech.net/directory-index

Tuesday, March 31, 2015

[[SOLVED]] - Accidentally Deleted Snapshot in VirtualBox and OS not Booting in Ubuntu 14.04

If you happen to accidentally delete your 'Snapshot' files and have been getting an error as - 'vd: error verr_file_not_found opening image file;' read further for the solution:


If your VM is in the 'saved state' first you will have to the discard the saved state to make any changes. To do so in your VirtualBox Manager go to Machine and then select 'Discard saved states' or press 'CTRL+J.' As the prompt indicates this will be equivalent to switching off your system and now you can make the required changes.

Now go to File menu and select 'Virtual Media Manager' or press 'CTRL+D.' Release the snapshot displayed with a red mark and also Delete it.


Now you will have to select the original 'vdi file' that was created during your installation process. To do this Select Modify and go to the location where you have installed your VirtualBox and select the 'vdi file'  and Restart.


Your problem should be RESOLVED now.

Enabling USB WiFi Network Adapter in VirtualBox with Kali Linux as Guest OS


I found enabling USB WiFi Adapter in Window 7 much simpler than Linux, precisely Kali Linux. Not that I couldn't do it in Kali but after sometime the connection would drop. But with Windows 7 it didn't take me a fraction of time compared to Kali and with the method I discovered the connection is also not dropping in Kali now.

So here's how to do it with Kali Linux as Guest OS. You can also use the same technique while using other OS such as Windows as Guest OS:

1. First make sure you have  added yourself to the user group 'vboxusers'; else you will be unable to view your Wireless USB Network Adapter under the  USB Devices list.

2. Now you can select your Network Adapter by going to --> Devices -->  USB Devices --> Select your Network Adapter here

Now to save yourself from your 'connection getting dropped' every now and then, make sure you have disabled your Internet connection from your Host OS. See the image below.


To confirm your WLAN setup Open your terminal and type:


 ifconfig  

You should be seeing something like wlan0 along with the details as in the image above.

Monday, March 30, 2015

PDOException: SQLSTATE[42S22]: - ERROR

I got the error below while trying to migrate data from my remote host to local host in a multisite setup.

PDOException: SQLSTATE[42S22]: Column not found: 1054 Unknown column
 'base.owner' in 'field list' : SELECT base.id AS id, base.name AS name, 
base.label AS label, base.plugin AS plugin, base.active AS active, 
base.weight AS weight, base.status AS status, base.dirty AS dirty, 
base.module AS module, base.owner AS owner, base.access_exposed AS 
access_exposed, base.data AS data FROM {rules_config} base WHERE 
(base.plugin = :db_condition_placeholder_0) AND 
(base.active = :db_condition_placeholder_1) ; Array 
( [:db_condition_placeholder_0] => reaction rule 
[:db_condition_placeholder_1] => 1 ) in EntityAPIController->query() 
(line 187 of ntity\includes\entity.controller.inc).

The simplest way I could resolve this is using Drush to access update.php and update the contributed modules. Once I updated my site the problem resolved. Use the command below in your Drush CLI:

 drush updb  

Friday, March 20, 2015

Enable SSL in Unbuntu 14.04 in Localhost/VirtualHost

Follow the steps below to enable SSL in your Localhost and VirtualHost:

1. IF NOT USING VirtualHost:

Open the file 'default-ssl.conf' and you might see something like below. You will have to make changes to the lines in BOLD.
 <IfModule mod_ssl.c>  
   <VirtualHost _default_:443>  
     ServerAdmin webmaster@localhost  
     DocumentRoot /var/www/html    
     
     ErrorLog ${APACHE_LOG_DIR}/error.log  
     CustomLog ${APACHE_LOG_DIR}/access.log combined  
     SSLEngine on  
     SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem  
     SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key  
     <FilesMatch "\.(cgi|shtml|phtml|php)$">  
             SSLOptions +StdEnvVars  
     </FilesMatch>  
     <Directory /usr/lib/cgi-bin>  
             SSLOptions +StdEnvVars  
     </Directory>  
     BrowserMatch "MSIE [2-6]" \  
             nokeepalive ssl-unclean-shutdown \  
             downgrade-1.0 force-response-1.0  
     BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown  
   </VirtualHost>  
 </IfModule>  
Also you will have to add the following line just below the line 'DcoumentRoot /var/www/html':
 <Directory /var/www/html>  
   Options All  
   AllowOverride All  
   Require all granted   
 </Directory>  
Enable SSL:
 sudo a2ensite default-ssl.conf  
Then finally restart Apache and you should be done:
 sudo service apache2 restart  
2. IF USING VirtualHost:

Make a COPY of the file 'default-ssl.conf' and rename the copied file as 'your-site-name.ssl.conf' and make the following changes:
 <IfModule mod_ssl.c>  
   <VirtualHost _default_:443>  
     ServerAdmin webmaster@localhost 
     ServerName your-site.local
     ServerAlias www.you-site.local 
     DocumentRoot /var/www/html/path-to-your-site    
     
     ErrorLog ${APACHE_LOG_DIR}/error.log  
     CustomLog ${APACHE_LOG_DIR}/access.log combined  
     SSLEngine on  
     SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem  
     SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key  
     <FilesMatch "\.(cgi|shtml|phtml|php)$">  
             SSLOptions +StdEnvVars  
     </FilesMatch>  
     <Directory /usr/lib/cgi-bin>  
             SSLOptions +StdEnvVars  
     </Directory>  
     BrowserMatch "MSIE [2-6]" \  
             nokeepalive ssl-unclean-shutdown \  
             downgrade-1.0 force-response-1.0  
     BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown  
   </VirtualHost>  
 </IfModule>  
Once again add the following lines just below the line 'DcoumentRoot /var/www/html':
 <Directory /var/www/html>  
   Options All  
   AllowOverride All  
   Require all granted   
 </Directory>  
Enable SSL:
 sudo a2ensite your-sitename.local-ssl.conf  
Then finally restart Apache and you should be done:
 sudo service apache2 restart  

Using Drush to Install Drupal 7 from Scratch


 Using Drush you can really simplify the process of installing a brand new Drupal site using a couple of commands in your CLI/Terminal.

Follow the instructions below to get started.

1. Firstly, create a Database for your New Drupal Installation and note the login credentials.

2. Open your terminal and change directory 'CD" to your Web Directory and enter the commands below:

The Web Directory/Document Root will depend on the OS you are using:
Linux/Ubuntu:

Linux: var/www/html/
Windows (XAMPP/WAMPP): C:\xampp\htdocs or C:\wamp\htdocs
7.x: here 'x' is the version number. Right now it's 7.35 so i enter drupal-7.35.

 drush dl drupal-7.x  

 Now in your terminal change directory to: cd drupal-7.x and enter the commands below:

 drush site-install standard --account-name=admin --account-pass=admin --db-url=mysql://root:1bm04CS093@localhost/test_dronaas  

  • Note: The Drupal username and password seem to always end up as admin/admin no matter what I set them to. So, I suggest just using those and then changing them after you login to your new site.
  • Also if you are using Linux/Ubutnu make sure to assign the apache-user to the directory 'files' located at 'sites/default/files.' You can do that using the command below:

 sudo chown www-data   

Monday, March 16, 2015

Cracking RAR, ZIP & 7z Passwords using RARCRACK and Ubuntu

Below are the steps by which you can try cracking your Zip, RAR & 7z passwords.

1. Firstly download the rarcrack program: Download.
2. Then COPY it to your Desktop.

3. Building and installing:


 $ tar -xjf rarcrack-VERSION.tar.bz2  
 $ cd rarcrack-VERSION  - eg cd rarcrack-0.2
 // you need gcc or any C compiler (edit Makefile CC=YOUR_C_COMPILER)  
 $ make  
 // you must be root in next step:  
 $ make install  

If you get an error like 'xml2-config: not found'; you can resolve this issue by:
Installing 'package libxml2-dev' for example:

On Linux/Ubuntu:
sudo apt-get install libxml2-dev

On CentOS/RHEL:
sudo yum install libxml2-devel

4. Once you have compiled RARCRACK you can execute it to crack your relevant file. Firstly come out of the rarcrack directory that you just extracted and compiled and type the following command in your terminal:
 rarcrack --type rar filename.rar  
asdasddsa

For more reference you may visit the RARCRACK site:  http://rarcrack.sourceforge.net/

or check the video below:



Monday, March 9, 2015

How to Update Oracle VM VirtualBox in Ubuntu 14.04

Updating to the latest version of VirtualBox:

  1. Download the latest version of VirtualBox at: https://www.virtualbox.org/wiki/Downloads.
  2. Right Click on the Downloaded Package and Select 'Open With > Ubuntu Software Center.'
  3. Now VirtualBox should be Updated.

Once you Update VirtualBox and Open it you will get a prompt to Update your Guest Additions as well. Simply follow the instructions in the simultaneous dialog box that prompts in your screen and Update the Guest Additions as well.

Wednesday, January 14, 2015

Install and Configure Upload Progress (PECL uploadprogress) on Ubuntu 14.04 / Drupal

1. INSTALL DEPENDENCIES

 sudo apt-get -y install php5-dev make  

2. INSTALL via PECL

 sudo pecl install uploadprogress  

3. CONFIGURE UPLOAD PROGRESS
Create a PHP uploadprogress configuration file.

 sudo gedit /etc/php5/mods-available/uploadprogress.ini  
 and add the line below and save your file 
 extension=uploadprogress.so  

4 ENABLE THE PHP UPLOADPROGRESS MODULE

 sudo php5enmod uploadprogress  

5. RESTART APACHE SERVICE

 sudo service apache2 restart  

Unsintall PECL:

If you would like to uninstal PECL execute the following command in your terminal:

 sudo pecl uninstall uploadprogress  

Friday, January 9, 2015

Sharing Drive/File/Folder in VirtualBox with Ubuntu as Host and Kali Linux or Windows as Guest OS

1. To Share Drive/Folder in Kali Linux as Guest OS:

First make sure your Guest OS is turned off else you won't be able to make the changes.


 Then on your VirtulaBox Management Page make the following changes as shown in the above image or continue to read below:
  1. Click on Settings
  2. Click on Shared Folders
  3. In 'Folder Path' select the desired Drive/Folder/File
  4. If you just want to read the files from your Guest OS the select Read-only else if you want to read/write leave it as it is.
  5. Give a name to your folder in 'Folder Name'.
  6. Select Auto-mount if you would like to mount your drive/folder/file on startup.
  7. Finally Click OK and that's all there is to 'Sharing Folders' in Virtual Box.
If you are using Kali Linux you can locate your drive/folder/file under '/media/your_shared_drive_folder_file'

Thursday, January 8, 2015

Using Winamp Skins in Audacious

I just tried using Audacious 3.4.3. It seems to be a nice audio player but the inability of the latest release to magnify the Winamp Skins made me loose interest in it. Anyway anybody interested in using it and looking for how to use Winamp Skins in it may read on:



To INSTALL Audacious in Ubuntu 14.04/14.10:

 sudo add-apt-repository -y ppa:nilarimogard/webupd8  
 sudo apt-get update  
 sudo apt-get install audacious audacious-plugins  

To Use Winamp Skins in Audacious:

In the Audacious Menu:
  • Click on View
  • Click on Interface
  • Select Winamp Classic Interface
Now your Audacious player should be displayed in a Winamp Skin as in the image below:


 To INSTALL New Winamp Skins:
 You can download Winamp skins from here: http://customize.org/winamp2

Then copy it to the following location: '/usr/share/audacious/Skins'.

Support the following file formats (.zip, .wsz, .tgz, .tar.gz, or .tar.bz2 file.

Then  on your Audacious Menu once again:
  • Go to View
  • Interface Preferences
  • Select your Skin from the list
Instead of Audacious I found out Clementine Music Player to be AWESOME!!!

How to Conceal that you are using PHP on your server to prying eyes?

I just found this simple technique to conceal that you are using PHP for your sites from tools like wappalyzer and statcounter. Just make the following change in your php.ini file located (Ubuntu 14.04) at /etc/php5/apache2/php.ini. Here's how to do it.

 1. Prest CTRL+ALT+T to open Terminal  
 2. sudo gedit  
 3. expose php = Off  
Reload Apache:
 service apache2 reload  

Monday, January 5, 2015

Change Wallpapers Automatically in Ubuntu 14.04


You can right click your desktop, select "Change Desktop Background" and choose any one of the wallpapers pre-installed, but you need to do it each time you want to change a wallpaper. What about changing a wallpaper automatically within a certain time interval? Try to install the wallpaper changer Variety.

 Press Ctrl-Alt-T to run Terminal.  
 Enter sudo add-apt-repository ppa:peterlevi/ppa  
 Enter sudo apt-get update  
 Enter sudo apt-get install variety  

With this wallpaper changer, you can change wallpapers in a fixed time interval from the sources you set and run it with several other settings such as randomly applying filter effects, color and size, customizing the indicator icon and so on.

Install LAMP Stack in Ubuntu 14.04 with a Single Command & PHP Modules

You can install LAMP stack in Ubuntu 14.04 with a single command. Here's the command:

 $ sudo apt-get install apache2 php5 php5-mysql mysql-client mysql-server  

During the installation process you will be asked to enter PASSWORD for your MySQL 'root' user account. This is optional.

Once the installation is successful you can crosscheck by creating a info.php file under 'var/www/htm/info.php' containing the code below:

 <?php phpinfo(); ?>  

Now open a browser and view the result of the above PHP file. If you are using a localhost you can enter the forllowing URL in your browser:

 http://localhost/info.php  

Install PHP Modules

If you would like to add some additional modules to enhance your PHP read below:

To see the available options for PHP modules and libraries, you can type this into your system:

 apt-cache search php5-  

The results are all optional components that you can install. It will give you a short description for each:

 php5-cgi - server-side, HTML-embedded scripting language (CGI binary)  
 php5-cli - command-line interpreter for the php5 scripting language  
 php5-common - Common files for packages built from the php5 source  
 php5-curl - CURL module for php5  
 php5-dbg - Debug symbols for PHP5  
 php5-dev - Files for PHP5 module development  
 php5-gd - GD module for php5  
 . . .  

To get more information about what each module does, you can either search the internet, or you can look at the long description in the package by typing:

 apt-cache show package_name  

If, after researching, you decide you would like to install a package, you can do so by using the apt-get install command like we have been doing for our other software.

If we decided that php5-cli is something that we need, we could type:

 sudo apt-get install php5-cli  

If you want to install more than one module, you can do that by listing each one, separated by a space, following the apt-get install command, like this:

 sudo apt-get install php5-cgi php5-cli php5-curl php5-mysql php5-odbc php5-memcache php5-memcached php5-oauth  

Top Magento Hosting:

Top 5 Posts (Weekly)

Lets Connect: