zoukankan      html  css  js  c++  java
  • Penrose连接Mysql解决方案Mysql 设置

     最近一直在进行Penrose连接Mysql的尝试,可总是提示无法连接到Mysql,无论是检查端口是否开启,设置Mysql远程访问权限等都不管用,后来在Penrose的官网找到一个建立样例数据库及设置远程连接的文档,没想到一举成功,痛快啊!

    下面就把文档和大家共享一下!(是英文,大家就凑合着看下吧!因为最近搞Penrose太累了,懒的再去翻译了!)

    我安装的Penrose版本是2.0的,Mysql是5.0

    The following are the instructions to setup the sample database. The instructions were written for MySQL 4.x, but you can use other database systems.

    Create Database

    Make sure you have a MySQL server running on your local machine. Create a MySQL database called "penrose_demo". Exececute the following commands inside a MySQL client:

    create database penrose_demo;

    Create Database User

    Create a MySQL user called "penrose" with password "penrose". Exececute the following commands inside a MySQL client:

    grant all privileges on *.* to 'penrose'@'<hostname>' identified by 'penrose' with grant option;

    grant all privileges on *.* to 'penrose'@'localhost' identified by 'penrose' with grant option;

    grant all privileges on *.* to 'penrose'@'%' identified by 'penrose' with grant option;

    注:主要是这边关于权限的设置导致我总是连接不成功!有高手能详细解释下不?

    Change the <hostname> with your machine name.

    Create Database Tables

    Populate the database with the SQL script provided in PENROSE_HOME/samples/sql. Exececute the following commands inside a MySQL client:

    use penrose_demo;

    source PENROSE_HOME/samples/sql/example.sql;

    注:此脚本在相应目录中没有,需自己准备sql脚本!可在mysql官网上下载到!

    The script was written for MySQL 4.x. If you are using a different database system, you might need to modify the script.

  • 相关阅读:
    ##MySql数据库表的操作与应用
    ##如何根据一个端口号,建立BS架构,在网页中打开我们要想的网站
    ##MySql数据库的增删改查方法
    ##MySql数据库的环境配置
    ##安装MySql数据库并解决如果安装出错卸载的注意事项
    ##什么是MySql数据库?它的基本用法
    ##网络编程的优化:如何利用线程优化服务端和客户端
    #XML
    ##如何在IDea中创建一个mxl文件模板
    Java多层嵌套异常处理的基本流程
  • 原文地址:https://www.cnblogs.com/jizha/p/2231130.html
Copyright © 2011-2022 走看看