• xampp服务器搭建和使用


    1.安装完XAMPP后会出现Apache端口被占用的问题,一下方法解决

    1. 错误信息如下:

      Error: Apache shutdown unexpectedly.

      9:37:01  [Apache] This may be due to a blocked port, missing dependencies, 

      9:37:01  [Apache] improper privileges, a crash, or a shutdown by another method.

      9:37:01  [Apache] Press the Logs button to view error logs and check

      9:37:01  [Apache] the Windows Event Viewer for more clues

      9:37:01  [Apache] If you need more help, copy and post this

      9:37:01  [Apache] entire log window on the forums

      xampp启动出错:This may be due to a blocked
    2. 2

      应该是端口的问题,这里使用程序提供的设置功能设置一下端口,具体需要点击程序界面上的【config】按钮。

      xampp启动出错:This may be due to a blocked
    3. 3

      在新窗口中点击【server and por setting】,在设置窗口上输入对应的对应的端口,需要记得通常情况下80窗口及443窗口可以一起修改。

      xampp启动出错:This may be due to a blocked
      xampp启动出错:This may be due to a blocked
    4. 4

      回到后,再次点击启动,还是出错。。。。会不会是没有被修改,只能看一下程序下的配置文件,点xampp后的config,需要注意的是80端口及443端口需要分别设置。

      xampp启动出错:This may be due to a blocked
      xampp启动出错:This may be due to a blocked
    5. 5

      打开配置文件后,直接使用搜索功能找到80端口的配置,将端口修改为801之类的,443端口同样,需要修改为其它端口,保存文件。

      xampp启动出错:This may be due to a blocked
    6. 6

      配置好后,点击启动,可以正常了。这里需要注意的事情是,第一次配置用的端口要与第二次手动配置的保持一致,因为点击界面上的【admin】启动管理界面时,使用的是第一次配置时使用的端口,只有保持一致才能打开网页管理界面。

      xampp启动出错:This may be due to a blocked
      xampp启动出错:This may be due to a blocked
       
       
       
      数据库密码块

      如果想把密码改成别的,可以直接执行西面的SQL 语句,把new_password改成自己的密码即可:

      1
      UPDATE user SET password=PASSWORD('new_password') WHERE user='root';

      另外既然mysql的root用户密码已经修改了,那么phpmyadmin中的对应密码配置也要修改,找到配置文件,如我的是

      F: mppphpMyAdminconfig.inc.php

      找到如下代码

       代码如下 复制代码

       Authentication type and info */$cfg['Servers'][$i]['auth_type']
       = 'config';$cfg['Servers'][$i]['user']
       = 'root';$cfg['Servers'][$i]['password']
       = '';$cfg['Servers'][$i]['extension']
       = 'mysql';$cfg['Servers'][$i]['AllowNoPassword']
       = true;

      修改为

       代码如下 复制代码


       Authentication type and info */$cfg['Servers'][$i]['auth_type']
       = 'config';$cfg['Servers'][$i]['user']
       = 'root';$cfg['Servers'][$i]['password']
       = '123456';$cfg['Servers'][$i]['extension']
       = 'mysql';$cfg['Servers'][$i]['AllowNoPassword']
       = true;

      这样就会需要重启登录phpmyadmin了。

      忘记密码怎么办

      1. 关闭正在运行的MySQL服务
      2. 打开DOS窗口,转到mysqlin目录
      3. 输入mysqld --skip-grant-tables 回车       --skip-grant-tables 的意思是启动MySQL服务的时候跳过权限表认证
      4. 再开一个DOS窗口(因为刚才那个DOS窗口已经不能动了),转到mysqlin目录 
      5. 输入mysql回车,如果成功,将出现MySQL提示符 >
      6. 连接权限数据库: use mysql;
      6. 改密码:update user set password=password("root") where user="root"; 
         mysql5.7以上版本-->    UPDATE user SET authentication_string=PASSWORD("root") WHERE User="root";
      7. 刷新权限(必须步骤):flush privileges; 
      8. 退出 quit。 
      9. 注销系统,再进入,使用用户名root和刚才设置的新密码123登录。

       
  • 相关阅读:
    深入Java集合学习系列:ConcurrentHashSet简单实现
    深入Java集合学习系列:TreeSet 详解
    深入Java集合学习系列:TreeMap实现
    深入Java集合学习系列:ConcurrentHashMap之实现细节
    深入Java集合学习系列:WeakHashMap的实现原理
    深入Java集合学习系列:Hashtable的实现原理
    深入Java集合学习系列:LinkedList的实现原理
    深入Java集合学习系列:ArrayList的实现原理
    深入Java集合学习系列:LinkedHashSet的实现原理
    深入Java集合学习系列:LinkedHashMap的实现原理
  • 原文地址:https://www.cnblogs.com/graveliang/p/9294219.html
Copyright © 2020-2023  润新知