Thursday, 31 December 2015

Error Solution


Delete a Database in MySQL on command's 

ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near

:- mysql -u root -p

:- mysql>

:- DROP DATABASE name_database;

                     Or

:- mysqladmin -u[username] -p[password] drop [database]

                 Or 

:- DROP DATABASE 'name-database';



 max_input_vars

Error-
Warning: a form on this page has more than 1000 fields. On submission, some of the fields might be ignored, due to PHP's max_input_vars configuration.

Solution :- 
1) go to directory where you installed xampp
2) open php directory
3) find php.ini file and open it
4) now you must edit line:

 max_input_vars = 1000

set higher value of this variable.

5) save php.ini file
6) restart your xampp server


if it helps, add to the title of topic [SOLVED] 



Access to the requested object is only available from the local network phpmyadmin

Access to the requested object is only available from the local network phpmyadmin

Old File.............
## New XAMPP security concept#<LocationMatch "^/(?i:(?:xampp|security|licenses|phpmyadmin|webalizer|server-status|server-info))">        #Require local    ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var

Solution :- 

:- $ sudo /opt/lampp/etc/extra/httpd-xampp.conf
     Comment "Deny from all" in the following section,

     Change file

    #
    # New XAMPP security concept
    #
<LocationMatch "^/(?i:(?:xampp|security|licenses|phpmyadmin|webalizer|server-status|server-info))">
        Order deny,allow
       #Deny from all
       #Require local
        Allow from ::1 127.0.0.0/8 \
                fc00::/7 10.0.0.0/8 172.16.0.0/12 192.168.0.0/16 \
                fe80::/10 169.254.0.0/16

        ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var

</LocationMatch>

How to Solve the XAMPP 1.7.7 - PHPMyAdmin - MySQL Error #2002 in Ubuntu

PHPMyAdmin - MySQL Error #2002 in Ubuntu
#2002 - The server is not responding (or the local MySQL server's socket is not correctly configured)

Connection for controluser as defined in your configuration failed.

Solution :- 
It turns out that the solution is to stop all the services and solve the “Another daemon is already running” issue.  
The commands i used to solve the issue are as follows:

:- $ su
:- $ passwd *******
:- # sudo /opt/lampp/lampp stop              
:- # sudo /etc/init.d/apache2 stop    
:-# sudo /etc/init.d/mysql stop
You can also type instead:
:- # sudo service apache2 stop 
:- # sudo service mysql stop 
      After that, we start again the lampp services:
:- # sudo /opt/lampp/lampp start   
Now, there must be no problems while opening:
http://localhost                   
http://localhost/phpmyadmin        

MySQL ERROR 1231 (42000):Variable 'character_set_client' can't be set to the value of 'NULL'


MySQL ERROR 1231 (42000):Variable 'character_set_client' can't be set to the value of 'NULL'

I did some search in internet and fixed it finally.
Solution :- Added the following text at the beginning of the mysqldump file and the restore was successful.

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

500 Internal Server Error is a generic error message, given when no more specific message is suitable. There are a number of causes for a 500 Internal Server Error to display in a web browser. Below is a sample error message


THE SERVER ENCOUNTERED AN INTERNAL ERROR OR MISCONFIGURATION AND WAS UNABLE TO COMPLETE YOUR REQUEST.

Please contact the server administrator, support@supportwebsite.com and inform them of the time the error occurred, and anything you might have done that may have caused the error.


More information about this error may be available in the server error log.


INTERNAL SERVER ERROR

Solution :- That is a not a meager issue ........ first step --------->>>> Go to root user then change folder permission step......
:- $ su 
:- $ password *********  
:- # sudo chmod 755 -R folder path ......

Then check your side (error solve). (Other Opstion)

MySQL import got a packet bigger than max_allowed_packet bytes

#1153 - Got a packet bigger than 'max_allowed_packet' bytes

#1153 - Got a packet bigger than 'max_allowed_packet' bytes

Solution :-

Step 1 :- Connect server ssh.telnet.localhost.terminal.etc......

Step 2 :- $ su

Step 3 :- $ ******

Step 4 :- # cd /etc/

Step 5 :- # sudo nano my.cnf

[mysqld]

datadir=/var/lib/mysql

socket=/var/lib/mysql/mysql.sock

user=mysql

max_allowed_packet = 128M (Add this line)

# Disabling symbolic-links is recommended to prevent assorted security risks

symbolic-links=0

[mysqld_safe]

log-error=/var/log/mysqld.log

pid-file=/var/run/mysqld/mysqld.pid

Then press Ctrl+x+y+Enter

Restart mysql

Step 6 :- # /etc/init.d/mysqld restart

change limit phpmyadmin import database

go file system /opt/lampp/etc/php.ini (open terminal & change limit) Find now this text & set limit,

memory_limit

post_max_size

upload_max_filesize

&

restart apache

:- $ sudo /opt/lampp/lampp restart

Cannot access copied folder in htdocs of lampp in Ubuntu ?
Example                 

:- $ sudo s 

:- $ cd /opt/htdocs (Folder Pathe)

:- $ sudo chmod 777 -R Folder name
                  or
:- $ sudo chmod 777 Folder name

Inner Pages Error



 Inner Pages Error

:- $ su
:- $ password *****
:- # nano /etc/apache2/sites-available/default
<VirtualHost *:80>
        ServerAdmin webmaster@localhost

        DocumentRoot /var/www
        <Directory />
                Options FollowSymLinks
                AllowOverride None
        </Directory>

        <Directory /var/www/>
                Options Indexes FollowSymLinks MultiViews
                AllowOverride All    (Change this line)
                Order allow,deny
                allow from all
        </Directory>
         Save & 
:- # sudo service apache2 restart

Update error 
:- uesr:root# sudo apt-get update
W: Failed to fetch gzip:/var/lib/apt/lists/partial/mirrors.linode.com_ubuntu_dists_trusty_universe_source_Sources Hash Sum mismatch
W: Failed to fetch gzip:/var/lib/apt/lists/partial/mirrors.linode.com_ubuntu_dists_trusty_main_binary-amd64_Packages Hash Sum mismatch

E: Some index files failed to download. They have been ignored, or old ones used instead.

Answer 

press Alt+Ctrl+t

:- $ su

:- $ passwd *****

:- # apt-get clean

:- # rm -rf /var/lib/apt/lists/*

:- # apt-get clean

:- # apt-get update 

.
.
.
.
.
.
Reading package lists... Done

Initramfs error
What is initramfs?

initramfs, abbreviated from "initial ram file system", is the successor of initrd. It is a cpio archive of the initial file system that gets loaded into memory during the Linux startup process. The Linux kernel mounts it as root file system and starts the init process from it. This will complete certain tasks before the real root file system is loaded; thus, initramfs needs to contain all of the device drivers and tools needed to mount the real root filesystem.

Do I need an initramfs?

The reason to build a kernel with an initramfs is mostly for interoperability (e.g. live-cd's) and special features like an included busybox, ssh, etc. But mostly, and that's why we are doing this here now, to have a proper kernel up and running quick'n dirty in a reasonable time without fighting hours and days until a more or less exotic hardware is perfectly run by the kernel. After having a proper basic kernel running with the help of an initramfs, I really recommend you to go a step further and build a true kernel with all features includes without an initramfs. However, relying only on a kernel to boot a system can be quite time consuming, so we have provided several initramfs options for Funtoo. If you have decided to use an initramfs, not just a kernel, check out the options below and choose the one that you like the most.

Solution :- 

Solve initramfs Error link 1 
Solve initramfs Error link 2

Ubuntu “Checking Battery State” Fix

OK guys, I want to get in a quick blog before dinner. The “checking battery state” problem 
seems to affect a large amount of Ubuntu users, usually after an upgrade of some sort. Basically the computer boots fully but gets stuck on “checking battery state”. This happens on both desktops and laptops alike. There is many reports of this problem online(some dating back to around 2008) but few (if any) solutions.

The problem has to do with Xorg and not with some sort of “battery state” issue. I had this problem before and was forced to reformat my machine and was faced with it again last week. The fix is surprisingly simple. Press ctrl+alt+f1 to drop to a shell prompt, and type:

:- $ sudo apt-get install gdm
Problem solved.
Hide all Taskbar Solution

Open terminal type :- 

:- $ sudo add-apt-repository ppa:freyja-dev/unity-tweak-tool-daily

:- $ sudo apt-get update


:- $ sudo apt-get install unity-tweak-tool


      To reset Unity, do

:- $ unity-tweak-tool --reset-unity
If you have any trouble on the installation procedures contact me on www.facebook.com/solveubuntu  server support