Jmeter java.sql.SQLException: No suitable driver found for jdbc:mysql:

时间:2021-03-16 15:39:07

Response message: java.sql.SQLException: No suitable driver found for jdbc:mysql://192.168.1.201:3306/taskmanagement

解决办法:

下载MySQL的官方JDBC连接器mysql-connector-java-5.1.18-bin.jar

1、将mysql-connector-java-5.1.18-bin.jar放入下面目录中

E:\apache-jmeter-2.11\lib

C:\Program Files (x86)\Java\jdk1.6.0_21\jre\lib\ext\mysql-connector-java-5.0.8-bin.jar 
C:\Program Files (x86)\Java\jdk1.6.0_21\jre\lib\mysql-connector-java-5.0.8-bin.jar 

2、将路径加入到环境变量CLASSPATH中

E:\apache-jmeter-2.11\lib\mysql-connector-java-5.0.8-bin.jar ;C:\Program Files (x86)\Java\jdk1.6.0_21\jre\lib\mysql-connector-java-5.0.8-bin.jar ;

参考网址:http://jmeter.512774.n5.nabble.com/java-sql-SQLException-No-suitable-driver-found-for-jdbc-mysql-td4553152.html