Jump to content
  • 0
chryxt

Installing FluxCP

Question

Hello,

I use unmanaged VPS from DigitalOcean and already installing LAMP so my server already runs well

But now i want to make website for it using FluxCP and i already buy webhost for it that have phpmyadmin too on the cPanel.

 

My question is,

1. Is it better use phpMyAdmin from webhost or use from VPS?

2. How to connect it? If im using phpMyAdmin from webhost how to connect it into my VPS server and If using phpMyAdmin from VPS how to connect it into webhost? Because i tried it and got this message

Error: PDOException

Message: SQLSTATE[HY000] [1130] Host 'srv12.niagahoster.com' is not allowed to connect to this MariaDB server

 

I tried to allowing VPS IP to my webhost already but it still like this.

 

I still learning on this please kindly teach me on this :) Thank You

Share this post


Link to post
Share on other sites

4 answers to this question

Recommended Posts

  • 0

Well basically u have to link website with your server database, no need to link with your Web host database it just meaningless because your server database is located in VPS, so just link your server database with your site using servers.php which u can find in Config folder. 
 
In your servers.php

 

 

            'Hostname'   => 'Your vps ip',
            'Username'   => 'Sql Username', //bassically create another user and assign him permissions
            'Password'   => 'Sql user password',
            'Database'   => 'Database name',
       
This is your main config in your servers.php DbConfig, do same with LogsDbConfig and in your application.php use your web host IP.
 
Also even after doing this your VPS server SQL Database does not accept outside host to manipulate it, so there is one sql file you have to edit (i don't remember name right now, so u have to search google for it or maybe someone here know) after that your flux start working.

Check here for remote connection to mySql, just change bind-address = 0.0.0.0 and restart and check

Share this post


Link to post
Share on other sites
  • 0

Well basically u have to link website with your server database, no need to link with your Web host database it just meaningless because your server database is located in VPS, so just link your server database with your site using servers.php which u can find in Config folder. 

 

In your servers.php

 

 

            'Hostname'   => 'Your vps ip',
            'Username'   => 'Sql Username', //bassically create another user and assign him permissions
            'Password'   => 'Sql user password',
            'Database'   => 'Database name',
       
This is your main config in your servers.php DbConfig, do same with LogsDbConfig and in your application.php use your web host IP.
 
Also even after doing this your VPS server SQL Database does not accept outside host to manipulate it, so there is one sql file you have to edit (i don't remember name right now, so u have to search google for it or maybe someone here know) after that your flux start working.

Check here for remote connection to mySql, just change bind-address = 0.0.0.0 and restart and check

Thank You @caspe it's work perfectly!

What i do

1.  mysql_secure_installation

2.  GRANT ALL ON *.* TO '(user )'@'(webhost IP)' IDENTIFIED BY '(passwd)' WITH GRANT OPTION;

3. GRANT ALL ON *.* TO '(user)'@'%' IDENTIFIED BY '(passwd)' WITH GRANT OPTION;

4. FLUSH PRIVILEGES;

5. EXIT;

Share this post


Link to post
Share on other sites
  • 0

 

Well basically u have to link website with your server database, no need to link with your Web host database it just meaningless because your server database is located in VPS, so just link your server database with your site using servers.php which u can find in Config folder. 

 

In your servers.php

 

 

            'Hostname'   => 'Your vps ip',

            'Username'   => 'Sql Username', //bassically create another user and assign him permissions

            'Password'   => 'Sql user password',

            'Database'   => 'Database name',

       

This is your main config in your servers.php DbConfig, do same with LogsDbConfig and in your application.php use your web host IP.

 

Also even after doing this your VPS server SQL Database does not accept outside host to manipulate it, so there is one sql file you have to edit (i don't remember name right now, so u have to search google for it or maybe someone here know) after that your flux start working.

Check here for remote connection to mySql, just change bind-address = 0.0.0.0[/size] and restart and check

Thank You @caspe it's work perfectly!

What i do

1.  mysql_secure_installation

2.  GRANT ALL ON *.* TO '(user )'@'(webhost IP)' IDENTIFIED BY '(passwd)' WITH GRANT OPTION;3. GRANT ALL ON *.* TO '(user)'@'%' IDENTIFIED BY '(passwd)' WITH GRANT OPTION;4. FLUSH PRIVILEGES; 5. EXIT;

Never ever grant user access to all database, (for security reasons), I would recommend only grant to db which is required

Share this post


Link to post
Share on other sites
  • 0

 

 

Well basically u have to link website with your server database, no need to link with your Web host database it just meaningless because your server database is located in VPS, so just link your server database with your site using servers.php which u can find in Config folder. 

 

In your servers.php

 

 

            'Hostname'   => 'Your vps ip',

            'Username'   => 'Sql Username', //bassically create another user and assign him permissions

            'Password'   => 'Sql user password',

            'Database'   => 'Database name',

       

This is your main config in your servers.php DbConfig, do same with LogsDbConfig and in your application.php use your web host IP.

 

Also even after doing this your VPS server SQL Database does not accept outside host to manipulate it, so there is one sql file you have to edit (i don't remember name right now, so u have to search google for it or maybe someone here know) after that your flux start working.

Check here for remote connection to mySql, just change bind-address = 0.0.0.0[/size] and restart and check

Thank You @caspe it's work perfectly!

What i do

1.  mysql_secure_installation

2.  GRANT ALL ON *.* TO '(user )'@'(webhost IP)' IDENTIFIED BY '(passwd)' WITH GRANT OPTION;3. GRANT ALL ON *.* TO '(user)'@'%' IDENTIFIED BY '(passwd)' WITH GRANT OPTION;4. FLUSH PRIVILEGES; 5. EXIT;

Never ever grant user access to all database, (for security reasons), I would recommend only grant to db which is required

@Dastgir

Is it like this?

GRANT ALL ON (dbfolder).* TO '(user )'@'(webhost IP)' IDENTIFIED BY '(passwd)' WITH GRANT OPTION;

GRANT ALL ON (dbfolder).* TO '(user)'@'%' IDENTIFIED BY '(passwd)' WITH GRANT OPTION;

FLUSH PRIVILEGES;

 

If i already grant user access to all database what i need to do to redo that?

Thank You :)

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.