Tuesday, March 9, 2010

discuz !7.2登陆后台一直需要输入密码的解决方法?

A:由于开启了验证管理员的 IP ,在用户更换本地网络的 IP 或者换个网络后,导致进入后台要求一直输入密码。
解决方法:
使用记事本打开 config.inc.php 文件,在 config.inc.php 文件内,查找

 $admincp['checkip'] = 1;        // 后台管理操作是否验证管理员的 IP, 1=是[安全], 0=否。仅在管理员无法登陆后台时设置 0。修改为
 

修改为:

 
$admincp['checkip'] = 0;        // 后台管理操作是否验证管理员的 IP, 1=是[安全], 0=否。仅在管理员无法登陆后台时设置 0。

Monday, March 8, 2010

if get Error No 1130 while connecting from your client to your mysql server

check whether the mysql user you are using have permission to connect from your current IP / host

to grant access to the USER;

grant all privileges on *.* to 'user'@'%';

'%' - here is indicating, the 'user' are able to connect via any host

to create a mysql user, 

CREATE USER 'user'@'%' IDENTIFIED BY 'pswd123';



SAMPLE: To create User with "Select" access only
Case 1: to create a user "report" that can access the dabatase from any IPRange

> CREATE USER 'report'@'%' IDENTIFIED BY 'p@ssw0rd';
> GRANT select ON *.* to 'report'@'%';

Case 2: to create a user "report" that can access the dabatase from localhost only
> CREATE USER 'report'@'localhost' IDENTIFIED BY 'p@ssw0rd';
> GRANT select ON *.* to 'report'@'localhost';


NOTE: after create the user, don't forget to flush the privileges.

> FLUSH PRIVILEGES;