Webmin - Associate a subdomain to more than one DB - mysql

I'm pretty new to server configuration and I'm stucked with this situation. I have a domain and a couple of subdomain for test. From each one i can connect to the database that have been created toghether with the subdomain. Now i would like to acces another DataBase (created with phpMyAdmin) from one of this subdomains, but my script (it is working) report me that "Cannot Find Database".
Is possible to make this database reachable from that domanain?
Thanks in advance.

By default all database in webmin can be access from any site, double check database access I mean make sure your use username have access to this database and some times webmin truncate username go to user and copy it as it's in webmin.

Related

Connecting a Lightsail instance of WordPress to a Lightsail MySQL Database

This is my first go at AWS. I’m trying to install a WordPress site. Here’s what I’ve done so far:
Created a LAMP instance in Lightsail. I’m able to:
SSH into the webroot with Terminal
SFTP into the webroot with Filezilla
Successfully uploaded and expanded the latest version of WP
in the webroot
Using the public IP, accessed the WP setup screen
Created an instance of a MySQL database in Lightsail. I’m able to:
Use Terminal to tunnel into and access it in the browser with
PHPMyAdmin
Successfully create an empty database and user with full
access permissions
Additionally:
Both instances are running in the same region: Virginia, Zone A
(us-east-1a)
I have enabled both Data migration and Public Mode
At the WordPress setup screen I enter the database name, user, password and host. I believe the database host is what the instance calls the endpoint? After all that, I get the following error:
We were able to connect to the database server (which means your username
and password is okay) but not able to select the publicUser database.
I’m quite sure the required credentials are correct, so it must be something with how I’m doing the setup? Any ideas? If anyone has this same setup, can you please post your WordPress config file with the sensitive information removed so I can see how you're connecting?
You've done everything correctly so far. WordPress is now looking for a database with the name publicUser which it cannot find. You either did not create that database (via PHPMyAdmin) yet, or are using the wrong database name.
Once you have either created the database or corrected the configured database name, it should work.

MySQL Workbench - Define database in connection settings

I was wondering whether there is a way to define a specific database in the connection setup of MySQL Workbench (I know this works with other database software). Sometimes I have a lot of different databases on one server and I only want to access one with one connection. Can I specify the database in the connection settings somehow?
YES, On the home tab Click the + in MySQL Connections. And put the database name in the Default Schema: when you fill in all the usual info about ip address etc
Now if you only want to see the one database, then create a new MySQL user account and only allow this new account access to this single database. Then change the connection to the database to use the newly created MySQL account.
I guess you are seeing all the databases because you are using the root account.

old web host doesn't have phpmyadmin, remote access?

A new client of mine has a site hosted on netnation (boo). Their account manager doesn't have a way to access phpmyadmin or anyway to access the database. I'm not a programer, I'd just like to be able to view a stored password so I can give it to my client. I have the database host, user, password, and database name in the php files of the site.
Is there a program that I can use to view the database? No command line please it's not my thing and I'd probably break something.
Thanks
Most live databases don't allow direct access from outside the server, so if you're unlucky it can't work unless you can configure mysql to allow access from remote clients, too.
But at least you can try. Just configure any phpmyadmin installation (locally or on another server) to connect to that database. You do that in the file config.inc.php in the phpmyadmin root directory.
Look for the line that says "$cfg['Servers'][$i]['host'] = 'localhost';". Just replace 'localhost' with the url or IP your database is running (usually the same as the website). If your mysql allows remote access, you should be good to go. Otherwise you will have to re-configure your mysql installation first to allow that.
MySQL Workbench is a GUI program that allows access to MySQL database. It can work directly or using SSH. Most likely you won't be able to connect directly so your best chance is to get SSH access and connect using it. If it's not an option you can get FTP access and install phpMyAdmin (simply by uploading it to server).
Also, it's considered a bad practice to store password in DB, so it's very likely that the password itself is not stored, just its hash.

Installing phpmyadmin to be able to manage the mysql database the admin created for me

I dont have access to cPanel. I only can access the root of the site I am working on using FTP, with the domain name, user and password. I want to install phpmyadmin on the root so that I can manage the mysql database the admin created for me. I have the db name, user and password. What do I need to do? Do I need to download phpmyadmin, upload install it? Please give me some details and howto.
Will I actually be able to use it for such?
Also, how to migrate all contents of another mysql databse that I have also access to (having its: db name, user and password) to this one, that was created for the site I am working with.
Download phpmyadmin from the following site: http://sourceforge.net/projects/phpmyadmin/files/phpMyAdmin/3.5.8.1/phpMyAdmin-3.5.8.1-all-languages.zip/download#!md5!a65d444787645735c75bca49cdb558cb
Upload it in a seperate folder on your webserver via FTP
Go to this folder and login with your database username and password
Correct the warnings and error on the bottom of the screen
(mostly security issues)
done :)
When you have any questions with errors or warnings please post a new question.

PHPMYADMIN User Access

Ok so I got one linux(centos) dedicated server. I was paying someone to look after my server. Now I remember for security purpose I asked him to disable access to PHPMYADMIN for all user exvept root. Now I want to enable access to phpmyadmin for one user only.
how can I do that, so that specific user can access phpmyadmin through cpanel/whm ?
Thanks
Why don't you simply create a new user in phpmyadmin? Then you have root and the new user who can connect to the database. Unless you meant that the restriction is on server side (server user), that's a whole different story.