Installing drupal on a local machine

Running drupal on your local machine will be easy to learn how to use drupal. Moreover, there is no expense to install it like we do in web hosting.


Git should be installed and configured on your machine. If not done, then follow these commands –

$ sudo apt-get install git #installing git
$ git config --global "<username>"        
$ git config --global <email>

Also, you need to install composer before going to the next step. For that follow this one line code –

curl -sS | sudo php -- --install-dir=/usr/local/bin --filename=composer

Some more things to install

sudo apt-get install php5-gd php5-curl libssh2-php

Now you need to install and setup lamp server on your local machine. For that follow my previous post -> Installing LAMP server on ubuntu

Also you need to do some configurations with your apache files and mysql.

First thing is to create a database

mysql -u root -p


CREATE USER drupaluser@localhost IDENTIFIED BY 'password';




Now configure apache file –

sudo nano /etc/php5/apache2/php.ini

Check the below conditions are given correctly –

. . .
expose_php = Off
. . .
allow_url_fopen = Off
. . .
sudo a2enmod rewrite
sudo nano /etc/apache2/sites-enabled/000-default.conf

Check whether the below codes match with the file you opened now

<VirtualHost *:80>
    . . .
    DocumentRoot /var/www/html

    <Directory /var/www/html>
        AllowOverride All
    . . .

Now restart your web server to execute the changes you have done in php and apache

$ sudo service apache2 restart

Now, if you have done till now without any issue then clone the desired version drupal repository to /var/www/html. Follow the given syntax –

git clone --branch 8.x

Now, extract the file. Get into the drupal extracted folder ands do composer install.

$ composer install --no-dev

And search for the given address in your browser

http://localhost/"<name of the directory you cloned>"

Hope you gotcha. Just install with your valid database name, username & password.


How to make a USB drive bootable (in Linux distros) ?

Greeting folks,

Things you need to make a bootable USB drive are –

  • a USB drive with minimum 2 GB space
  • a machine with any Linux machine

First, you need to download the desired ISO file.

Once your downloading work is finished, open Disks in your system and select your USB drive.

Now format your USB to fat 32 ( be careful while selecting and formatting your USB ).

Now open Startup disk creator in your machine, select your ISO file and click on Make Startup Disk button. It will take some time, wait till it finishes.

Finally, you are done with it.

Yeah, this method is very easy for beginners but what if someone wants to do through terminal ? Developers might feel to do everything using the terminal, right ?    😛

So developers, open  your terminal and do :

$ sudo apt-get install syslinux mtools

Create a mount point and mount Linux ISO image using the following command.

$ sudo mkdir /media/iso
$ sudo mount -o loop /opt/Ubuntu.iso /media/iso

Now connect your USB. In case it is not mounted the to mount it, do :

$ sudo mount /dev/sdc /medma/usb

Copy all files from mounted iso to the USB drive.

$ sudo cp -ra /media/iso/* /media/usb

Finally, we need to make this USB bootable. Copy ldlinux.sys file to USB drive to make it bootable.

$ sudo syslinux -s /dev/sdd1

Now rename some required files and directories as like below. Navigate to USB drive

$ cd /medma/usb
$ mv isolinux syslinux
$ cd syslinux
$ mv isolinux.cfg syslinux.cfg

Now you can connect this USB to the computer which you need to install Linux operating system and boot it from USB.


Fix : zsh corrupt error


Recently I got an issue, whenever I open my terminal it shows some error that my .zsh got corrupt.

Somewhat like this :

$ zsh: corrupt history file /home/myusername/.zsh_history

How to fix this issue ?

This is due to some error in zsh history.

You just need to copy the following codes in your terminal :

$ cd ~

$ mv .zsh_history .zsh_history_bad

$ strings .zsh_history_bad > .zsh_history

$ fc -R .zsh_history

Now reboot your system

$ sudo reboot


One of my senior suggested me that we don’t have to go so long, we can just simply delete our  ~/.zsh_history. To remove that just follow these codes –





Now that error won’t prompt you. #</HappycOding>

Creating a Drupal site

Hey Folks

Get your own Drupal site within few minutes and few clicks 🙂

First install xampp

Go to this link and download xampp according to your operating system ->\

Then follow these codes –

cd /home/[Username]/Downloads

Now to make installable file execute

chmod +x

Your file is ready to execute, now to run this file

sudo -s -H

Now you will get a dialogue box to install it, do install

and then type the following command to get started with xampp

sudo /opt/lampp/lampp restart

Here you installed xampp server

Now go to your browser and type the following on address bar


and you will be redirected to xampp server. Scroll down and check for Drupal in the following list. Click on Drupal to Download.

Now do the following commands

cd Downloads/
chmod +x <name of the drupal file you downloaded>
./ <name of the drupal file you downloaded>

This will show you another dialogue box to install Drupal. install it and get into your own Drupal site 🙂


Hope this worked for you

Changing Ubuntu’s password

Hello folks, usually we should keep a perfect password for our computer which will safer, secure and easy to remember. But it happens sometimes that you forget your password. This blog will no more offend for forgetting ubuntu’s password. 🙂


Very first thing you need to do is **reboot your computer**

Hold shift key to get into GRUB, for dual booted version they automatically get into GRUB.

Highlight your image of Ubuntu and press E to edit image.

Find out the line starting with linux and at the end of the line Type this command -> rw init=/bin/bash

Then press F10 or ctrl + x to boot and wait for sometime, if it comes as a blank page with a blinking underscore then do all above steps again.

Hope it worked till now …….

Now you get into root mode and type passwd <your username>

You will get an option to enter a new UNIX password, enter your new password and press enter.


Congratulations your are back to ubuntu 🙂

Installing LAMP server on ubuntu

LAMP is a open source web server to set up websites. It is used to get access to website locally. It include Linux, Apache, Mysql and PHP/Python/Perl.

How to setup a lamp server ?

Installing LAMP is not a difficult task, you just need to copy some codes to your terminal and here it is.

Installing LAMP on ubuntu

Installing Apache

$ sudo apt-get install apache2

To check whether apache is installed or not, you can type http://localhost/ on your address bar and you will be redirected to an apache page.

Installing MySQL

$ sudo apt-get install mysql-server

Installing PHP

$ sudo apt-get install php5 libapache2-mod-php5

Restarting apache

$ sudo /etc/init.d/apache2 restart

Try again to check your localhost

Also you can check about php

$ php -r 'echo "\n\nYour PHP installation is working fine.\n\n\n";'


If you have successfully completed all of these, then congratulations you have installed LAMP in your pc.




” Always hope for the best and work for the worst “

WiFi issue for rtl8723be Drivers

*** This method is only applicable to rtl8723be drivers and for Ubuntu users ***

Greeting Folks

Recently I was having an issue with my laptop which supports rtl8723be driver. It was not getting connected to WiFi network. Then I searched a lot and got a solution for it, although it is not permanent but still it will work for two lines of code 🙂

For continuing this process you must do the following things :

First of all go to bios setup and then follow –

System configuration -> Boot option -> Secure boot -> Disable

Then you need to install rtlwifi-linux-firmware, open your terminal and follow these codes

$ sudo add-apt-repository ppa:hanipouspilot/rtlwifi
$ sudo apt-get update
$ sudo apt-get install rtlwifi-new-dkms linux-firmware

*set your country code( like for India – IN )

$ sudo iw reg set 'your country code'

Do restart your computer once the country code is set

$ sudo iw reg set IN

Now go to the given link and download or clone the zip file from Github. Also extract that file in your home terminal.

Follow these codes :

$ sudo apt-get install linux-headers-$(uname -r) gcc g++ build-essential dkms git 
 (try to install one by one)
$ sudo reboot
$ cd rtlwifi_new-rock.new_btcoex
$ make
$ sudo make install
$ sudo modprobe -rv rtl8723be

Now copy these following code in your terminal

$ sudo modprobe -v rtl8723be ant_sel=2
$ sudo modprobe -r rtl8723be
$ sudo modprobe rtl8723be

Now your system will be okay with WiFi.

To make it permanent follow these codes :

$ echo "options rtl8723be ant_sel=2 fwlps=0" | sudo tee /etc/modprobe.d/rtl8723be.conf


Hope it worked 🙂

If any problem occurred then please do a comment.





Source :

” It’s all fun and games until you lose your WiFi signal “