A SMALL INTRODUCTION TO DATABASE
I have seen that many members have problems with Database.
Here is a small INFO which should give you the IDEA.
mySQL is a DATABASE server. You can access it using the [MySQL Database] link in Cpanel. Cpanel can be accessed by "http://forums.xisto.com/no_longer_exists/;
There you have 4 Main Options :-
1> CREATE A DATABASE
2> CREATE A USER
3> ADD USER TO DATABASE
CREATE : IT ALLOWS YOU TO CREATE A DATABASE
CREATE USER : IT ALLOWS YOU TO CREATE A USER. USING THIS, YOU CAN ACCESS THE DATABASE. A DATABASE CANNOT BE ACCESSED BY ANYONE. AND ONLY THE USERS WHICH YOU SPECIFY CAN ACCESS IT.
SO AFTER YOU CREATE A DATABASE, YOUR NEXT STEP SHOULD BE TO CREATE A USER AND ADD HIM TO THAT DATABASE ( BY GIVING PERMISSIONS )
ADD USER TO DATABASE : THIS WILL ALLOW YOU TO ADD OR PERMIT YOUR CREATED USER TO A PARTICULAR DATABASE.
PHPMYADMIN : A graphical Tool for managing your Created Database
====== STEPS FOR ACCESSING THE DATABASE ======
Create a DATABASE. The names are automatically prefixed by the name of your user account. You will have to access the database hence forth by using that prefixed name. It is done for security reasons. Suppose you create a database "register" then and your username is "abc", then the database created would be "abc_register".
NEXT, Create a USER. ( This user is not your Cpanel username. It is a diffrent one for accessing your database. You are supposed to create this account)
The usernames are also automatically prefixed. So creating a user "tom", creates a user like "abc_tom" where abc is your Cpanel username, you must also specify a password. This will be used for accessing the database using this particular user. Suppose you give the password "timmy". [ PASSWORDS ARE NOT PREFIXED!!! ]
Then you are supposed to give permissions to this USER to access the database.
Go to the respective option and select the USER and the DATABASE and click ADD USER. Most of the times, you will give "ALL" permissions to that user.
Now, when using PHP SCRIPTs, when it prompts for DATABASE Settings, these will be your settings (for above procedure )
[ DATABASE SERVER is the location and it will always be LOCALHOST ]
1 > DATABASE SERVER : localhost
2> Database Name : abc_register
3> Database User : abc_tom
4> Database Password : timmy
SETTINGS LIKE DATABASE PORT are all DEFAULT. So Leave those fields BLANK. The REST all the settings can be anything ( your choice ).
+=========== DATABASE ERRORS ===================
+ ONLY THE FOLLOWING ERRORS SHOW THAT THE PROBLEM IS FROM THE SERVER! + THE REST ALL ERRORS ARE DUE TO YOUR OWN MISCONFIGURATION.
Too many Connection : This means that server is being killed by many people accessing it and you will have to wait before the load decreases. This message is usually because of someone else abusing the server. The Servers are very powerful and it is only the ABUSE by some members, the entire service is affected.
Warning: MySQL Connection Failed: Can't connect
to local MySQL server through socket '/var/lib/mysql/mysql.sock
THIS IS also caused when someone abuses the server. This error has to be handled by our TECHS.
+ DATABASE LOST, DELETED, REMOVED!!
PLEASE KEEP THIS INFORMATION AT THE BACK OF YOUR HEAD.
WE DO **NOT** DELETE ANY DATA.
The Cpanel Will not SHOW your DATABASE if :-
1> The SQL server has been shutdown.
2> SQL server is undergoing upgrades or any other maintananace tasks
3> The SQL server is halted or freezed due to any other reason or abuse.
THIS DOES NOT MEAN that your DATA is GONE. As soon as the Database Server is bought up online, Your database will appear again. Dont take foolish steps or get alarmed by this. Stay cool and calm.
+ WHAT ARE THE REASONS FOR ERRORs!
The main reasons are Noobs who try to execute Faulty scripts. Or Rivals who try to execute Dangerous scripts on purpose.
We have given you a commitment for Quality. It is because of this, We cannot :-
1> Put restrictions on PHP, Perl...
2> We cannot activate safe modes
3> We cannot impose shorter timeouts
4> We cannot Block access to critical controls.
5> We cannot limit your per user CPU usage.
and many more...
If we do this, you will no doubt enjoy a better service, but then there will be no diffrence between the rest and us. You as a talented member chose us because we give you the opportunity to show it and give you all the necesary tools you require.
The Server RESOURCES ARE SHARED! So it is better we use and share it peacefully.
Any member, who affects the server or cause HARM is immediately TERMINATED!