Kitz ADSL Broadband Information
adsl spacer  
Support this site
Home Broadband ISPs Tech Routers Wiki Forum
 
     
   Compare ISP   Rate your ISP
   Glossary   Glossary
 
Please login or register.

Login with username, password and session length
Advanced search  

News:

Author Topic: Setting Up A MySQL Data Base. Help Needed.  (Read 7456 times)

tickmike

  • Kitizen
  • ****
  • Posts: 3641
  • Yes Another Penguin !. :)
Setting Up A MySQL Data Base. Help Needed.
« on: October 27, 2010, 02:22:31 AM »

I want to run a MySQL data base on a local machine, I have installed it but cannot get past the logon screen . >:D
Any help please on logging on and setting it up.
« Last Edit: October 31, 2010, 12:40:07 AM by tickmike »
Logged
I have a set of 6 fixed IP's From  Eclipse  isp.BT ADSL2(G992.3) line>HG612 as a Modem, Bridge, WAN Not Bound to LAN1 or 2 + Also have FTTP (G.984) No One isp Fixed IP >Dual WAN pfSense (Hardware Firewall and routing).> Two WAN's, Ethernet LAN, DMZ LAN, Zyxel GS1100-24 Switch.

roseway

  • Administrator
  • Senior Kitizen
  • *
  • Posts: 43608
  • Penguins CAN fly
    • DSLstats
Re: Setting Up A mySQL Data Base. Help Needed.
« Reply #1 on: October 27, 2010, 07:33:21 AM »

I've never got involved with mySQL, but perhaps your OS has set a default password which is different from the regular system passwords. I have a vague feeling that there's a command which you can run as root to set the mySQL password.
Logged
  Eric

silversurfer44

  • Kitizen
  • ****
  • Posts: 4421
  • Lord Muck
    • Ben Novice Weather
Re: Setting Up A mySQL Data Base. Help Needed.
« Reply #2 on: October 27, 2010, 09:00:29 AM »

The password initially for root is empty, and root is the only user at that stage. The root user is NOT the same root user of your operating system. You need to set the password your self. From  memory I think the command line is:-
mysql passwrd -u root [enter]
[enter the password of choice at the prompt]

DON'T FORGET THE PASSWORD or you will have to re-install.

Not wishing to bypass helping, but Mysql has an excellent help system on their website. You will have access to the complete manual (which is massive) online and search for the command(s) you want, with examples on how to use it/them.
Logged
Colin II : It's no good being a pessimist, it wouldn't work anyway.

tickmike

  • Kitizen
  • ****
  • Posts: 3641
  • Yes Another Penguin !. :)
Re: Setting Up A mySQL Data Base. Help Needed.
« Reply #3 on: October 27, 2010, 11:16:46 AM »

This is my job for tonight ;), but what I forgot to say that it's a GUI logon screen that comes up, I put 127.0.0.1 for the address, root = username, blank= password, hit 'Enter' It then complains that it cannot find it and gives me an option to 'ping' it and that ping seems to work ok !.

Edit ... The bit of software I'm helping to test needs an 'Apache Server' as well, Can anyone give any help on setting that up to work with the MySQL data base.
« Last Edit: October 27, 2010, 11:39:31 AM by tickmike »
Logged
I have a set of 6 fixed IP's From  Eclipse  isp.BT ADSL2(G992.3) line>HG612 as a Modem, Bridge, WAN Not Bound to LAN1 or 2 + Also have FTTP (G.984) No One isp Fixed IP >Dual WAN pfSense (Hardware Firewall and routing).> Two WAN's, Ethernet LAN, DMZ LAN, Zyxel GS1100-24 Switch.

silversurfer44

  • Kitizen
  • ****
  • Posts: 4421
  • Lord Muck
    • Ben Novice Weather
Re: Setting Up A mySQL Data Base. Help Needed.
« Reply #4 on: October 27, 2010, 11:48:11 AM »

Ah! What are you using to connect to the database to get a gui?
May I suggest you use the command line?

The command is :-
mysql -u root -p [enter]
the reply should be
Enter Password:
you press enter.

This should get you the welcome to mysql and the mysql prompt.
It could be that the server is not actually running and the above command sequence will tell you that.
« Last Edit: October 27, 2010, 11:50:46 AM by silversurfer44 »
Logged
Colin II : It's no good being a pessimist, it wouldn't work anyway.

broadstairs

  • Kitizen
  • ****
  • Posts: 3700
Re: Setting Up A mySQL Data Base. Help Needed.
« Reply #5 on: October 27, 2010, 05:49:04 PM »

Since you need bot MySQL and Apache why not install XAMPP for Linux. It makes life very easy for new users. From what I remember I did not have to do anything to make Apache and MySQL work together, since they are both servers what normally happens is that you access a php coded web page from your browser which runs the script in the apache server and it talks to the MySQL server.

I'd get XAMPP installed and working first and they take it from there with whatever it is you are testing, especially as there are extensions in say php (and from memory Perl) which allow access to MySQL and most of the stuff you are likely to need comes in XAMPP.

Stuart
Logged
ISP:Vodafone Router:Vodafone Wi-Fi hub FTTP

silversurfer44

  • Kitizen
  • ****
  • Posts: 4421
  • Lord Muck
    • Ben Novice Weather
Re: Setting Up A mySQL Data Base. Help Needed.
« Reply #6 on: October 27, 2010, 07:01:17 PM »

I would suggest setting mysql up first. Set it up so that it is secure before putting any sort of web interface or access to it. Even on a Linux system it can be a huge security hole as far as your data goes. It is quite easy to set up. Likewise Apache can be an even bigger security hole to a system.
« Last Edit: October 27, 2010, 07:04:34 PM by silversurfer44 »
Logged
Colin II : It's no good being a pessimist, it wouldn't work anyway.

tickmike

  • Kitizen
  • ****
  • Posts: 3641
  • Yes Another Penguin !. :)
Re: Setting Up A mySQL Data Base. Help Needed.
« Reply #7 on: October 30, 2010, 11:34:14 PM »

Ah! What are you using to connect to the database to get a gui?
May I suggest you use the command line?

The command is :-
mysql -u root -p [enter]
the reply should be
Enter Password:
you press enter.

This should get you the welcome to mysql and the mysql prompt.
It could be that the server is not actually running and the above command sequence will tell you that.
[/quote

re. " What are you using to connect to the database to get a gui? "  from 'synaptic'  MySQL-gui-tools   and           MySQL-administrator 

Your Command worked ok, so I had a look at my GUI logon and instead of 127.0.0.1    I  put 'localhost' in the address 'root' as password and hit 'Enter'
It also opened the admin panel. :)

re ..  "Likewise Apache can be an even bigger security hole to a system" Yes it can and I'm only running these test machines on my network at the back of a 'Hardware Firewall' which is locked down on ports.  ;)

@ broadstairs  I did try 'Xampp' That installs ok and works, but The software I'm testing (To help Doctors and Vets around the world  :) ) wants to install in   /var/www/html     But 'Xampp' installs in   /opt/xampp.
I have tried to add a 'html' folder in   /var/www (there is none ! ) and have tried to add a 'Basic link' between the folders 'opt' and 'html'.
But the test software would not run. >:D
Logged
I have a set of 6 fixed IP's From  Eclipse  isp.BT ADSL2(G992.3) line>HG612 as a Modem, Bridge, WAN Not Bound to LAN1 or 2 + Also have FTTP (G.984) No One isp Fixed IP >Dual WAN pfSense (Hardware Firewall and routing).> Two WAN's, Ethernet LAN, DMZ LAN, Zyxel GS1100-24 Switch.

broadstairs

  • Kitizen
  • ****
  • Posts: 3700
Re: Setting Up A mySQL Data Base. Help Needed.
« Reply #8 on: October 30, 2010, 11:54:47 PM »

Once you have xampp working you can modify the apache config file to point to /var/www/html as the document root and restart apache and it will serve out the files from that location. The config file is httpd.conf and just change the Document Root to /var/www/html.

Stuart
Logged
ISP:Vodafone Router:Vodafone Wi-Fi hub FTTP

tickmike

  • Kitizen
  • ****
  • Posts: 3641
  • Yes Another Penguin !. :)
Re: Setting Up A mySQL Data Base. Help Needed.
« Reply #9 on: October 31, 2010, 01:53:11 AM »

Once you have xampp working you can modify the apache config file to point to /var/www/html as the document root and restart apache and it will serve out the files from that location. The config file is httpd.conf and just change the Document Root to /var/www/html.

Stuart

I tried that Stuart but no luck,  :( .
I have un-installed Xampp and from 'Synaptic' loaded 'task-lamp' and that works straight out of the box  ;D.
In /var/www it installs a few more folders as well, maybe some of these are needed to run this test software.
Logged
I have a set of 6 fixed IP's From  Eclipse  isp.BT ADSL2(G992.3) line>HG612 as a Modem, Bridge, WAN Not Bound to LAN1 or 2 + Also have FTTP (G.984) No One isp Fixed IP >Dual WAN pfSense (Hardware Firewall and routing).> Two WAN's, Ethernet LAN, DMZ LAN, Zyxel GS1100-24 Switch.

broadstairs

  • Kitizen
  • ****
  • Posts: 3700
Re: Setting Up A MySQL Data Base. Help Needed.
« Reply #10 on: October 31, 2010, 08:27:06 AM »

I dont know what it is you are testing but it is a little worrying if it has to have a particular directory structure above Document Root in apache. If this is something the users will have to install on their system, unless it is a complete turnkey solution, it will have to cope with many different directory structures.

Stuart
Logged
ISP:Vodafone Router:Vodafone Wi-Fi hub FTTP

tickmike

  • Kitizen
  • ****
  • Posts: 3641
  • Yes Another Penguin !. :)
Re: Setting Up A MySQL Data Base. Help Needed.
« Reply #11 on: October 31, 2010, 10:56:55 PM »

Good point, I will ask some questions, As far as I know the doctor I,m helping wants to get this software ( to be made open source) to run on PCLinuxOS so he can make / get copy's made to give out free to other doctors and vets in his country.

The good news is that I've had it running ok by using 'Lamp' installed via the package manager.

Edit.. Running his test software tonight, It sets up 'users' in MySQL data base and configures MySQL and Apache settings for safe working.
« Last Edit: November 01, 2010, 12:28:35 AM by tickmike »
Logged
I have a set of 6 fixed IP's From  Eclipse  isp.BT ADSL2(G992.3) line>HG612 as a Modem, Bridge, WAN Not Bound to LAN1 or 2 + Also have FTTP (G.984) No One isp Fixed IP >Dual WAN pfSense (Hardware Firewall and routing).> Two WAN's, Ethernet LAN, DMZ LAN, Zyxel GS1100-24 Switch.
 

anything