Posts

Showing posts from September, 2012

Access denied for user 'root'@'localhost' (using password: no)

Image
The error may be caused due to password reset problem, You can solve the issue by following step

Step 1 :Open MYSQL CONSOLE for that go to Wamp icon on your Desktop
            and Left click to open menu, you will see Mysql folder then click Mysql
            folder you will see Mysql Console

Step 2: Type the following command in Console
            UPDATE mysql.user SET Password=PASSWORD('YourNewpassw')
            Where User='root';

Step 3: Then Flush the privilege by
            FLUSH PRIVILEGES;

Step 4: Exit Console

Step 5: Go to Link
            http://localhost/phpmyadmin/

Odesk installation problem in 11.10[Solved]

Odesk installation problem in 11.10[Solved]
When installing Odesk in Ubantu 11.04 you may greeted by an error

“Dependency is not satisfiable:libnotify1(>=0.5.0)”.


Installing libnotify1 will solve the problem .Find the following installation Link


http://packages.ubuntu.com/natty/libnotify1

Current Date to Filename in Bash Shell

To assign current date to file name use month,date,time format like   date +%m%d%y and if You want to assign the date value to a variable follow     the date syntax format
time=$(date +%m%d%y) or time=`date +%m%d%y`
Some sample Examples are given below

#!/bin/bash time=$(date +%m%d%y) echo “Backup file of $time”
#!/bin/bash time=$(date +%m%d%y) musqldumb -u root -ppassword databasename > database_$time.sql
#!/bin/bash time=$(date +%m%d%y) mv /var/www/filename /home/sreeraju/ cd /home/sreeraju/ tar -cvf backup_$time.tar filename

Hardening Apache2 and PHP in Ubuntu 12.04 server

Step 1 : Edit php.ini file

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

#Add or Edit the following line in it .

             disable_functions = exec,system,shell_exec,passthru
 ; Decides whether PHP may expose the fact that it is installed on the server 
             expose_php =off
             magic_quotes_gpc = on
             display_errors = Off
             log_errors = On
             display_errors = Off
             log_errors = On
             display_errors = Off
             log_errors = On



Step 2 : Avoid Listing files in Apache Directory. Edit file
                 nano gedit /etc/apache2/sites-available/default


#Add or Edit the following line in it .
                <Directory /var/www/>
                Options -Indexes FollowSymLinks MultiViews
                AllowOverride All
                Order allow,deny
                allow from all
                </Directory>

Add minus "-" infront of Indexes

Step 3: Install mod_evasive

sudo apt-get install liba…

Disable SSH remote login in Ubuntu 12.04

Before Disabling Remote SSH login, Check if sudo is working for normal users if not follow the procedure given below .

Step 1 :                 sudo gedit /etc/sudoers
                                              or
                               sudo visudo

This must be done as root user and add following line to it.
User ALL=(ALL:ALL) ALL
Replace "User" with the name of account which should have given sudo permission.

Step 2 :Edit file         sudo gedit /etc/ssh/sshd_config
and change line  PermitRootLogin to No like below
                                      PermitRootLogin no



Pfsense 2.0.1 Dual Wan Configuration

Image
Step 1 : After Installing pfsense in system access the pfsense panel through web browser by typing  ip
assigned






Step 2 : After that assign Interface to the Network Port.I have assigned 3 Interfaces



WAN-ISP1
OPT1-ISP2
LAN-OFFICE NETWORK


Step 3 :Assign ISP Lines to Interfaces , I had configured ISP1 and ISP2 in gateway mode .
1)First assign LAN interface  Description:LAN IP Address:192.168.1.1 Gateway:Leave it blank Don't tick Block private network and Block Bogon network option .
2)Assign WAN Interface 
Description:WAN
IP Address:Static ip ISP  provider given
Gateway:Click add a new one and give ISP1 Gateway ip








Don't tick Block private network and Block Bogon network option .


3)Assign OTP1 Interface 
Description:OPT1
IP Address:Static ip ISP2  provider given
Gateway:Click add a new one and give ISP2 Gateway ip












Don't tick Block private network and Block Bogon network option .

Step 4 : Creating Groups for load balancing or Fail-over Routing
  System--->Routing---->Groups














Group…