JMeter Beginner Tutorial 8 - How to create a Database Test Plan
Вставка
- Опубліковано 8 лип 2016
- more about Raghav - automationstepbystep.com/
How to create a Database Test Plan
Step 1 - Add mysql jdbc jar to Jmeter lib folder | Restart Jmeter
dev.mysql.com/downloads/conne...
How to create free DB - • How to create free SQL...
Step 2 - Add Thread Group
Step 3 - Add JDBC Conn Config | Provide the details of our DB
JDBC URL Format
Useful Tip:
The general format for a JDBC URL for connecting to a MySQL server is as follows, with items in square brackets ([ ]) being optional:
jdbc:mysql://[host1][:port1][,[host2][:port2]]...[/[database]] »
[?propertyName1=propertyValue1[&propertyName2=propertyValue2]...]
Here is a simple example for a connection URL:
jdbc:mysql://localhost:3306/sakila?profileSQL=true
Ref : dev.mysql.com/doc/connector-j...
Step 4 - Add JDBC Request
Step 5 - Add Listeners
Step 6 - Run and validate
JMeter Beginner Playlist : bit.ly/2Q0AJG3
JMeter Intermediate Playlist : bit.ly/2M6AiIS
JMeter Advanced Playlist: bit.ly/38T8KR5
_______ ONLINE COURSES TO LEARN _______
Visit - automationstepbystep.com/
----------- UI TESTING -----------
Selenium Beginners - bit.ly/2MGRS8K
Selenium Java Framework from Scratch - bit.ly/2N9xvR6
Selenium Python - bit.ly/2oyMp5x
Selenium Tips - bit.ly/2owxc50
Selenium Builder - bit.ly/2MKNtlq
Katalon Studio - bit.ly/2wARFdi
Robot Framework - bit.ly/2Px6Ue9
----------- API TESTING -----------
Web Services (API) - bit.ly/2MGafL7
SoapUI - bit.ly/2MGahmd
Postman - bit.ly/2wz8LrW
General - bit.ly/2PYdwmV
----------- MOBILE TESTING -----------
Mobile Playlist - bit.ly/2PxpeUv
----------- CI | CD | DEVOPS -----------
Jenkins Beginner - bit.ly/2MIn8EC
Jenkins Tips & Trick - bit.ly/2LRt6xC
Docker - bit.ly/2MInnzx
----------- VERSION CONTROL SYSTEM -----------
Git & GitHub - bit.ly/2Q1pagY
----------- PERFORMANCE TESTING -----------
JMeter Beginner - bit.ly/2oBbtIU
JMeter Intermediate - bit.ly/2oziNVB
JMeter Advanced - bit.ly/2Q22Y6a
JMeter Tips & Tricks - bit.ly/2NOfWD2
Performance Testing - bit.ly/2wEXbLS
----------- JAVA -----------
Java Beginners - bit.ly/2PVUcXs
Java Tips & Tricks - bit.ly/2CdcDnJ
----------- MAVEN -----------
Maven - bit.ly/2NJdDRS
----------- OTHERS -----------
Redis- bit.ly/2N9jyCG
Misc - bit.ly/2Q2q5xQ
Tools & Tips - bit.ly/2oBfwoR
QnA Friday- bit.ly/2NgwGpw
Sunday Special - bit.ly/2wB23BO
Ask Raghav- bit.ly/2CoJGWf
Interviews - bit.ly/2NIPPxk
All Playlists - bit.ly/2LSiezA
----------- Follow -----------
Facebook - / automationstepbystep
Twitter - / automationsbs
UA-cam - / automationstepbystep
this is awesome man..I have been working with jmeter as part-time for my projects..but now with the help of ur tutorials I am now able to do it more efficiently and is helping me a lot
Great to know this Akhil. Keep learning.
I loved these tutorials really, simple & informative. Thanks!
you're welcome Sara.
Hi Raghav, This tutorial was really helpful and it is extremely crisp and clear. Excellent stuff!!!
Hi Prashanth, great to know this. Keep learning.
Hi raghav.... your Jmeter beginner tutorials are really helpful. You explained all in very understandable manner..
Revathy, i am glad it helped. Thanks for watching. Keep learning.
Thank you so much for such a descriptive session, very helpful. Thanks for your effort.
You're welcome Sahana
Your tutorials are very clear and helpful. Thanks a lot!!!
You're welcome Slava
Excellent explanation and content. Thank you so much Raghav.
you're welcome Ashish
After this video, my BE engs at work may start crying! By the way, your videos are very well structured - a lot of Profs would have to implement your pattern into their lectures.
Hi Phil, I am humbled and honored by your message. Thank you.
Thank you sir Raghav, your channel helps me a lot. I started to learn Jmeter from your channel few days ago, and I can write scripts cater a lot of scenarios. For this JDBC session, if cover a little bit more info. like the assertion of jdbc response will be more helpful. Anyway, thanks pal!
Hi Wenjie, so happy to see your message I will add more videos, There is JDBC assertion video in the JMeter Beginner playlist. Check here automationstepbystep.com/
very powerful app and very clear explanations. Thanks a lot!
You're welcome Daniel
Muy buena explicación, muchas gracias.
Saludos desde México
Muy bienvenido
Great work !
عراسي الحجي راجاف والله
Thanks a lot Raghaw. So like that can we test DB for checking response time with peak load..???
Yes Arjun
Thanks for this meaningful session
Most welcome Deepti
good sir,
love you for your work
Glad and humbled to see your message Ajay
Very useful session
Keep watching :)
Hi, I would like to test the Redis db. I want to insert/update a key in the redis db every 0.2s. Is it possible? if yes, how? I'm new on Jmeter. Thanks in advance!
If you can create a request in a sampler can do it
Hi Raghav, I have did exactly like what is shown. created test db in db4free and placed the jar file like you said. But when i run I got the error "Cannot load JDBC driver class 'com.mysql.jdbc.Driver'". Could you please help me. I am using jmeter 5.1.1.
Hi Faiz, you can check if your connection url and credentials are created properly. Sometime these public DBs do not work properly. You can try with your test DBs
Hey raghav,
Is there any plugin available for cassandra and go database like there is one for mysql?
Hi , check this
github.com/Netflix/CassJMeter
Hi, I have a scenario where I have to call a store proc for different users.. each user has to call the same stored proc with different input value? How can I achieve that? Thanks
Hi Anand, these is a typical case where you will need to put data in csv and have parametrisation done in jmeter
How to set up windows authentication in Jmeter for sql server any idea or thoughts?
Hi Prashant, Check this - mail-archives.apache.org/mod_mbox/jmeter-user/201401.mbox/%3CCACxbV9R2rAi_N87NkfOLxRZ=-z0CfmTSis+sDaHtQNy4DuNbRw@mail.gmail.com%3E
Hi Raghav,
Thanks for your great work . Could you please help in finding out database URL and the database you are currently using?
Hi, I did not get your question. Are you not able to follow the steps in the video.
WHere is the video for creating the simple mysql data base? and now the data base jar is not zip it is installer .exe so after intallation do i still need to do some configuration?
Hi Nenad, To create free DB you can see this - ua-cam.com/video/NkaJu1_VAWI/v-deo.html.
Once you install via installer, you can try to run your JMeter test plan, it should be able to take it if available universally within the system
Hi Raghav. Can you share the connection setting for connecting a SQL server DB like you have shown for mysql DB. Thanks
Hi Mustafa, I will need to do a hands-on and check, you can also get the same online
Dear Raghav , I am currently stuck with comparision of sql query output(results) with the csv test data values to check if the test data sent through csv file and the db results after the query is executed is matching using assertion
can you please help me with this or can just share steps here so that I can proceed further
Amit, if i understand correctly you want to create a JDBC Test Plan where the results of query are asserted against values present in a csv file.
You can make use of parametrisation here. There are sessions on the same.
Hi, Raghav, very good videos about JMeter. I have just one doubt. I have db file stored in my pc. Can I use that instead of connecting to the server?
Hi Suwarna, in case you are able to make a connection via a request you should be able to, but then that might not be a performance test.It may work as a functional test.
Hi Raghav, Could you kindly post some videos to do performance testing using Postgre SQL DB
Hi Anatte, surely i will but may take some time.
Hi Raghav,
I would like to know how do I run scripts for pg database. Also I need to run a set of queries on daily basis and need to create a report manually. Is there any way where I can execute multiple queries in jmeter and export result in file ?
Hi Sukhada, will need to check online, I will try to check too and if possible will add on this
Hi Raghav, I would like to do a mongo (no sql) request just for insert, update , delete on a free db anywhere for testing purposes. Would you consider this video for the community? Regards
Sure I will Franco
Hi Raghav, Thanks for the tutorial.
i'm facing one issue on running a JDBC request
"Uncaught Exception java.lang.NoClassDefFoundError: org/aspectj/lang/Signature in thread Thread[Thread Group 1-1,6,main]. See log file for details."
Please help me in resolving this.
Hi Darshan, pls check this - stackoverflow.com/questions/24033649/noclassdeffounderror-org-aspectj-lang-sign
Hi Raghav, thanks for the help, can you please elaborate what is the purpose of adding mysql jdbc jar file to the jmeter?
Hi Sunit, it is used to connect to the database
Thanks
what is the use of Validation Query in the JDBC connection Config screen ? pls help with out setting the value fr the field Im geting NULL exception after setting that im able to test SQL server
Hi Krishna, The sectionConnection Validation by Pool - These are settings, necessary to control session’s validity. Validation Query is sent regularly to the database and, in case if the session is invalid, pool will simply restart it. For example, if during the testing we restart the database, validation function will simply reload connections within the testing process.
blog.soft-industry.com/en/jmeter-databases-load-testing-part-ii/
@@RaghavPal thank you , it's clear now. In that case reason for null exception shld be that it test tried to validate session and no query was available to do so.
Yes, I hope it helped
Hi raghav this tutorial is very nice and clear . will you please show how to use performance metric listner.
Hi Shweta, thanks for watching. I will try to cover this.
hi can you help me why I'm getting an error "Response message:java.sql.SQLException: Cannot load JDBC driver class 'com.mysql.jbdc.Driver'"
Hi, check this sqa.stackexchange.com/questions/25615/cannot-load-jdbc-driver-class-com-mysql-jdbc-driver-in-jmeter
Hi Raghav,
i have given my database url as:"jdbc:mysql://localhost:8888/nidhisdb".And i have even loaded mysql.jdbc driver in the lib folder.
But i am getting this error on execution:Cannot create PoolableConnectionFactory (Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.)
Can u pls explain.
Hi Nidhi, just check your connection url is created properly and authentication is correct.
Hi Raghav,
I''m getting below in response:
Cannot create PoolableConnectionFactory (Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.)
Don't know where the issue is. Could you please help?
Hi Barbie, here are some possible causes and solutions stackoverflow.com/questions/6865538/solving-a-communications-link-failure-with-jdbc-and-mysql
Hello sir, did u made any videos on database testing.?.? M not able to find it . Please suggest. Thanks in advance.
Not ye Hritwik, You will find all existing here - automationstepbystep.com/
hi sir could u plz tell from where are we going to get the driver class information as driver class as I have put the same driver class in my jdbc connection as yours but m getting this error messge "Cannot load JDBC driver class 'com.mysql.jdbc.driver"...
Few things which I have tried i.e. restarting my Jmeter and also I checked the JAR file which I saved in my lib folder is 'mysql-connector-java-5.1.49-bin'.......but still m getting the same error..plz tell me the solution.
You will need to add the dbms java jars. if you are stuck with getting connector jar with MYSQL 8.0.X versions installed then you can go to the following path and copy paste the jdbc jar from = "C:\Program Files (x86)\MySQL\Connector J 8.0" to JMeter's lib folder.
If I'm using Oracle SQL developer, then will these jars work?
Yes, can also see some online examples
Can u pls help me with database url, jdbc driver class n jar file to b downloaded for microsoft SQL server
Hi Bandaru, I will try to make a session, but can take time. You can take online help meanwhile.
Hi Raghav, Thank you for this amazing course. I need a clarification. How to connect dynamoDB from JMeter and test.
Thank you in advance.
Hi Balan, can check this - www.blazemeter.com/blog/how-load-test-mongodb-jmeter/
Thanks, how to test a local database, in the same network our in my machine??
Hi Vinicius, for any database, you will need to connect to it as you do in java. Based on the database platform, you can search online to get connection strings
Hey, Can I Switch between different databases to test the performance of the web app to check response with different volume of db in Jmeter,
Please someone reply me.
Hi Deepak, i believe that you will have to do from backend OR if you have different urls pointing to different DB , than it can be done directly.
Thank you Bro :)
You're welcome Sumesh
Hi Raghav, your tutorials are very good and helpful ....
I am new to Jmeter , It could be great if you help me out of one problem. My question is I want to run some jdbc requests and save the results in single csv file and when I run again (second time) those results should compare with previous one. Can we achieve this ?
Hi Venkat, Try using jmeter merge results plugin. jmeter-plugins.org/wiki/MergeResults/
Thanks for your reply , Beanshell Post processor can do compare between two csv files, I started understanding it , if you have any tutorial of groovy can you please share it ...
I do not have it now. You can go ahead, its easy.
Thanks Raghav
Your videos are really helpful
I have one question - Do we need to take snapshot of database before run the DB test. if yes please tell how?
Thanks in advance.
Hi Sajal, depends on your needs, If you are creating bulk data in the test and want to restore it to earlier state, you can. I believe this should be done outside JMeter using some scripts or commands and you can chain it with the process
Hi Raghav , Thanks for tutorial , but I am getting error while establishing jdbc connection. "Response message: java.sql.SQLException: Cannot create PoolableConnectionFactory (Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.)" Could you please help?
Hi Vedika, pls check the connection url is created properly
The general format for a JDBC URL for connecting to a MySQL server is as follows, with items in square brackets ([ ]) being optional:
jdbc:mysql://[host1][:port1][,[host2][:port2]]...[/[database]] »
[?propertyName1=propertyValue1[&propertyName2=propertyValue2]...]
Here is a simple example for a connection URL:
jdbc:mysql://localhost:3306/sakila?profileSQL=true
Response from server : Cannot create PoolableConnectionFactory (Unknown character set index for field '255' received from server.)
why??
Hi, this is from your server and not JMeter. You may need to upgrade your jar. Check stackoverflow.com/questions/25136062/after-mysql-change-to-utf8mb4-error-unknown-character-set-index-for-field-224
Hi Raghav, can you please also provide JDBC Driver class for Oracle Database 11g ?
In case of oracle db, you can use:
Database url : jdbc:oracle:thin:@//IPAddressofdatabase:port/sid
JDBC Driver Class : oracle.jdbc.OracleDriver
or
JDBC Drver Class : : oracle.jdbc.driver.OracleDriver
Good morning Sir..Here You are doing database testing using MySQL server..if I want to do the database testing with SQL server is that same process or any other changes required
Hi, the process will be the same. You will need to use your db credentials and connection url to connect.
Wonderful Effort and Video :-)
@Raghav I have a question:
- If MS SQL server is installed in a remote app server and I do not install MS SQL Server on my own machine, will I be able to make jdbc connection through Jmeter+MS SQL Driver Jar ?
Or it's strictly required to install MSSQL Server in my own machine as well to make a JDBC conection through Jmeter.
I have followed all basic steps:
Go to Start->All Programs-> Microsoft SQL Server 2012-> Configuration Tool
Click SQL Server Configuration Manager
Expand SQL Server Network Configuration-> Protocol
Enable TCP/IP Right box
Double Click on TCP/IP and go to IP Addresses Tap and Put port 1433 under TCP port.
But getting error:
Cannot create PoolableConnectionFactory (The TCP/IP connection to the host 10.98.5.209, port 1433 has failed. Error: "connect timed out. Verify the connection properties. Make sure that an instance of SQL Server is running on the host and accepting TCP/IP connections at the port. Make sure that TCP connections to the port are not blocked by a firewall.".)
Hi Chandan, yes it should work, Just check that the 2 machines are connected over the network, or the communication is possible
hi im using oracle in my jmeter and instead of using SID we use service name. I always get this error: Cannot create PoolableConnectionFactory (Listener refused the connection with the following error:
ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
)
my config are:
jdbc:oracle:thin:@::
oracle.jdbc.OracleDriver
can you please help me w/ this?
He Decery, this might take some time and troubleshooting. Can you search and see if you get some information over internet.
i got error msg!
Cannot create PoolableConnectionFactory (Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.)
Hi Praveen, pls check your connection properties/values again carefully. Also check if you get any logs.
dev.mysql.com/doc/connector-j/5.1/en/connector-j-reference-configuration-properties.html
stackoverflow.com/questions/40336865/database-connection-for-jdbc-request-on-jmeter
I also encountered this issue. I replaced ojdbc14.jar with ojdbc6.jar and it worked. Don't forget to restart jmeter after you change the file.
Hi Raghav,
How many virtual users i can add in threads to test a web based application.
Hi Vikranth, it depends on the application and the requirements for testing. Ideally a load test with high number of virtual users should be done on dedicated machines with stable network and configuration to compare multiple runs.
Hi , i have sign up page having otp field..after enter the first name mob no in mob no field , i click on verify button ,it send a otp in database ..and i want to input this otp on sign up from for completing signup ptocess .how can it is possible performance test of this scenario in case of mupltiple users ..
Hi Pratik, ideally for testing this scenario you should get some pre-validated otp from your team so you do not have to go into the db at every step.
Hi Raghav .. this tutorial is really helpful...can you please also provide the link to your tutorial for database db4free? and i also wanted to know how i can assert the sql results? Thanks
Thanks, Rajwinder for liking.
I am yet to create video on db4free, you can watch this one:
ua-cam.com/video/wEOiYGtU9fY/v-deo.html
to assert, one quick way is to add ReponseAssertion and mention the value you are expecting in response string.
for sql results assertion:
ua-cam.com/video/SmSieTKYky8/v-deo.html
Hello Raghav - here i have one question - from where we need to find the jdbc driver class.
Hi Amit, you can download from internet
Hi Sir,
I did whatever you said but in may case I am using My Sql DB. For connecting that DB I need to provide .pem along with username and password. How to do that?
Hi Rajesh, check this - stackoverflow.com/questions/51873313/using-pem-file-for-jmeter-auth
www.blazemeter.com/blog/how-to-use-multiple-certificates-when-load-testing-secure-websites/
"Cannot create JDBC driver of class 'com.mysql.jdbc.Driver' for connect URL" - how to resolve this error?
Have you added the correct jar and restarted jmeter. Please also check the logs for more information.
Hi Raghav, Thanks for your tutorial, but please tell me if you know another website that provide free db service
Hi Teguh, as for FTP for DB too, I will have to check online, Try to see if you find some online public service
Response message:java.sql.SQLException: Cannot create PoolableConnectionFactory (Invalid object name 'dual'.)
how can i fix this issue!
Hi Sơn
The error message "Invalid object name 'dual'" usually occurs when the query is not able to find the required database object. The object "dual" is a system table that is present in Oracle and some other databases, but not in all databases.
To resolve this issue, you can try the following:
Verify the database connection details: Check if the database connection details such as the database URL, username, and password are correct.
Check if the database driver is installed: Make sure that the appropriate database driver is installed and configured correctly in the JMeter "lib" directory.
Check the SQL query: Verify if the SQL query that you are using is valid and correct for the particular database you are using.
Use a different SQL query: Instead of using "SELECT * FROM dual", try using a different query that is appropriate for the database you are using.
Verify the permissions: Check if the user has the necessary permissions to access the database objects.
Use a different database: If none of the above solutions work, you can try using a different database that supports the "dual" table or try using a different query.
By following the above steps, you can resolve the "Invalid object name 'dual'" error and continue with your JMeter database testing
Does Jmeter support Athena ?
I have added com.amazonaws.athena.jdbc.AthenaDriver jar to lib of jmeter, but it's throwing cannot load com.amazonaws.athena.jdbc.AthenaDriver.
Have not used it Roushan, need to check
@@RaghavPal thanks. Can u please create a tutorial for connecting and testing aws athena with Jmeter ? I am having difficulty in doing that.
Hi Raghav, can you please help me with my error? It shows an error such as "Notifying test listeners of end of test ; setRunning(false,*local*) ". I am using a free amazon database with host name 52.15.81.67 and port 5432. I need to enter my own username and password to access this DB.
hi Kieu, if you are able to get your results in listener, then it should be okay. This is normal output of JMeter, and it indicates that JMeter finished the thread.
In case you do not get your results, try to check the logs. You can access through the yellow triangle at the top right corner of JMeter UI.
Also check this - stackoverflow.com/questions/29252088/jmeter-test-not-running
What should I put in "Query Type" in JDBC Request if my query is a insert or delete?
You can try with Update Statement - stackoverflow.com/questions/42975704/jmeter-inserting-record-into-database-by-using-jdbc-request
I m finding the restart button still I m struggling on that Jar added on lib folder of Jmeter. Currently I m using Apache Jmeter4.0 where i have to find RESTART BUTTON.
2. Does DB testing suits for Micro Soft Visual Studio. Kindly, share the URL.
Thanks in Advance.
Hi, you can just close jmeter and start it again
Automation Step by Step - Raghav Pal Thank you .. Raghav
Your session very helpfull and your are doing great job actually I have one query while using badboy software for recording I am getting error that is object doesn't support property or method 'fill' error...
Hi Rajagopal, thanks for your message. BadBoy might not be a very good option now. Try using blazemeter plugin on chrome.
@@RaghavPal thank for quick reply....Can you please suggest me I am new in this technology
Sorry for late reply. In google chrome browser. Goto plugins and search for blazemeter. Can check this for help - ua-cam.com/video/zn1DSUZ6t64/v-deo.html
How to put the JDBC driver jar file in the LIB for ubuntu operating system
You can use linux commands for the same.
Please explain to me where the Database URL/ JDBC Driver/ Username/password is obtained?
Trần
The Database URL, JDBC Driver, Username, and Password for a JMeter Database Test Plan can be obtained from the Database Administrator (DBA) for the database that you are testing. This information is typically stored in a secure location, such as a configuration file or password manager.
Here is a brief explanation of each piece of information:
*Database URL:* The Database URL is a string that contains the information needed to connect to the database, such as the hostname, port number, and database name.
*JDBC Driver:* The JDBC Driver is a library that allows Java applications to connect to and interact with databases.
*Username:* The Username is the name of the user account that will be used to connect to the database.
*Password:* The Password is the password for the user account that will be used to connect to the database.
Once you have obtained the Database URL, JDBC Driver, Username, and Password, you can configure your JMeter Database Test Plan with this information. To do this, you will need to add a *JDBC Connection Configuration* element to your Test Plan. This element will contain all of the necessary information to connect to the database.
Once you have added the JDBC Connection Configuration element, you can add a *JDBC Request* sampler to your Test Plan. This sampler will allow you to execute SQL queries against the database. When configuring the JDBC Request sampler, you will need to specify the name of the JDBC Connection Configuration element that you created.
Here is an example of a simple JMeter Database Test Plan:
```
Test Plan
JDBC Connection Configuration
Database URL: jdbc:mysql://localhost:3306/test_database
JDBC Driver class: com.mysql.cj.jdbc.Driver
Username: root
Password: password
JDBC Request
Variable name: test_database_connection
Query Type: Select
SQL Query: SELECT 1
```
This Test Plan will create a connection to the MySQL database `test_database` using the `root` user account and the `password` password. The Test Plan will then execute the SQL query `SELECT 1` against the database.
You can use JMeter to create more complex Database Test Plans by adding multiple JDBC Connection Configuration elements and JDBC Request samplers. You can also use JMeter to execute parameterized SQL queries and to test the performance of your database under load.
Hi Raghav, i want to know if you can show, the process to create the DB, I created one but i´am not sure if is correct, and thank you so much, your tutorials are the best about JMeter, from Mexico
Hi Pepe, Do you need to create a DB for testing? You can check this - ua-cam.com/video/NkaJu1_VAWI/v-deo.html
ohhh thank you very much. I will to check. I will to take your tutorial about jenkins after and thanks again.
Hi Thanks for this video. Can you please tell me where the Database result will store and how can we see the result without using listener. This is one of the interview question. Plz reply..
Hi Gayathri, if you mean test results, that will get stored in Listeners and you can use any listeners as per you requirement. If you do not use listeners, you can either check your DB or DB server for logs.
Hi Raghav, much appreciated for all JMeter tutorials. I try to download Add mysql jdbc jar to Jmeter lib folder from the site you have mentioned, however, I'm having difficulty as I can only download: mysql-installer-community-8.0.20.0.msi and Unconfirmed 66255.crdownload. There is no ZIP I can download
URL: dev.mysql.com/downloads/connector/j/
Any help that would be great. Thanks in advance.
Hi Naresh, with the name of download, I guess the download was not complete and you tried using it before that.
@@RaghavPal Thanks Raghav, tried again and worked.
hello Naresh I faced same issue..actually the first link is not the the same link as mentioned by the trainer in this video. plz use this link -dev.mysql.com/downloads/connector/j/5.1.html
note : when u will search in google now its a third search result not the first one anymore.
Hey Raghav, why database testing is done from jmeter ?
Hi Tanu, it is not DB functional testing but performance. That is if you want to get some huge amount of data or if multiple users are querying the data. What is the response time
Hi Raghav, can you Create video with testing mongodb and redshift using jmeter.
I will check on this Neelima
Hi Raghav, i m using microsft sql server 2012 so how can i connect through JDBC connection to jmeter, mysql is open source o it is easily work but i want implement in sql server 2012.Please let me know its urgent for me to test database
Hi Bharat, you will need to:
1. Download Microsoft JDBC driver for SQL server - www.microsoft.com/en-in/download/details.aspx?id=11774
2. Put in JMeter lib folder
3. Restart JMeter
4. In TestPlan add Config Element > JDBC Connection Configuration
Inside this element provide the details as follows:
Variable Name : any unique name Database URL: jdbc:sqlserver://host:port;DatabaseName=dbname JDBC Driver class: com.microsoft.sqlserver.jdbc.SQLServerDriverUsername: username of dbPassword: password of db
Now add sampler JDBC request and test
_____________________________________________________________________________
@@RaghavPal raghav how do you configure sql server using windows authentication
Hi raghav...I am getting the below exception on executing JDBC script.
Error Count: 1
Data type ("text"|"bin"|""): text
Response code: null 0
Response message: java.sql.SQLException: Cannot load JDBC driver class 'com.mysql.jdbc.Driver'
Can you please help me out?
JDBC jar file I have added to the Jmeter lib folder too. Then I have restarted the J meter.
Hi Salma, database connection url correct. Please read the description notes
Hi Raghav,
I have xampp on my local server.I created database on xampp but while performing test through jmeter it is showing
Response message: java.sql.SQLException: Cannot create PoolableConnectionFactory (null, message from server: "Host 'KIRAN-PC' is not allowed to connect to this MariaDB server") how to fix it???? I provide valid credential's
Hi Kiran, hope the syntax for connection url is correct. Check the video description.
but how we actual test the database from server....its giving error.
.""Response message: java.sql.SQLException: Cannot create PoolableConnectionFactory (Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.)"
Hi Tejaswini, pls recheck your database configurations and values.
stackoverflow.com/questions/47198308/java-sql-sqlexception-cannot-create-poolableconnectionfactory-connection-refus
www.blazemeter.com/blog/mysql-database-and-jmeter-how-to-test-your-connection
Hi Raghav,
1. Is there anyway to display Response Data properly. Due to thousands of records, all data messed up.
2. How can I see in results number of rows returned executed by select query.
You can log the results in csv and then analyse
Exporting results to CSV is not showing number of rows
Can you try something like here - stackoverflow.com/questions/24133498/assertion-on-jmeter-jdbc-request-sampler
Hi Raghav,
It is possible to share the link while giving Load on Application. The Number of threads hitting the server on DB log. Please If possible upload Video for that.
Thanks.
I will check it Fouziya
@@RaghavPalThanks Raghav
Hi,
tried all the above video steps but getting error as
"Cannot create PoolableConnectionFactory (Access denied for user 'root'@'localhost' (using password: YES))"
tried changing password, granting all privileges in phpmyadmin sql database "user accounts"
still getting above error. Please guide.
Vivek
The error message "Cannot create PoolableConnectionFactory (Access denied for user 'root'@'localhost' (using password: YES))" indicates that the JMeter user does not have the necessary privileges to connect to the MySQL database.
There are a few possible reasons for this error:
* The JMeter user is not authorized to connect to the MySQL database.
* The JMeter user does not have the correct privileges to connect to the MySQL database.
* The JMeter user is trying to connect to the MySQL database using the wrong password.
To troubleshoot this error, you can try the following:
* Make sure that the JMeter user is authorized to connect to the MySQL database. You can do this by checking the `user` table in the MySQL database.
* Make sure that the JMeter user has the correct privileges to connect to the MySQL database. You can do this by granting the `ALL` privilege to the JMeter user.
* Make sure that the JMeter user is trying to connect to the MySQL database using the correct password. You can do this by checking the `password` field in the `user` table in the MySQL database.
If you are still having problems, you can try asking for help on the JMeter mailing list or IRC channel.
In addition to the above, you can also try the following:
* Make sure that the MySQL server is running.
* Make sure that the MySQL server is listening on the correct port.
* Make sure that the JMeter user is trying to connect to the MySQL server on the correct port.
I hope this helps
sir from where i can get the jdbc driver class,,,,,can i have to use the same one as you mention in the video bcoz its showing an loading error problem
Pankaj, you are talking about the jar, right. You can get it from any online site. e.g mvnrepository.com/artifact/mysql/mysql-connector-java/5.1.6
actually i had made some sytatical mistake while writting the jdbc driver class,,,,,,,and ya i know from where to download the jar file your video provide simple navigation to downlaod the file btw thnxx alot
hi i am beginner in this field can you explain how to find database URL whil mention in this vedio
hi, this is standard syntax for url, you can find it over the net for any database:
__________________________________________________________________________
MySQL com.mysql.jdbc.Driver jdbc:mysql://hostname/ databaseName
__________________________________________________________________________
ORACLE oracle.jdbc.driver.OracleDriver jdbc:oracle:thin:@hostname:port Number:databaseName
__________________________________________________________________________
DB2 COM.ibm.db2.jdbc.net.DB2Driver jdbc:db2:hostname:port Number/databaseName
__________________________________________________________________________
Sybase com.sybase.jdbc.SybDriver jdbc:sybase:Tds:hostname: port Number/databaseName
__________________________________________________________________________
Hi Raghav ,Nice explanation Could you please create a Video on Usage of Dbmon jmeter plugin
Hi Aditya, sure I will do that.
How can I perform the Volume Testing of My Web Application . Can you please guide me bro
Hi Ali, by volume, do you mean to send huge data or with huge user load. I will plan on this
@@RaghavPal no actually exposing your application with huge amount of data and then check the response of application
hi i m facing a problem i mailed you as well with my screenshots would you mind to have a look on them ?
sure Hanan, will look at it.
Cannot load JDBC driver class 'com.mysql.jdbc.Driver' plz help
Hi Faizan, check this stackoverflow.com/questions/47022095/cannot-load-jdbc-driver-class-com-mysql-jdbc-driver-jmeter
Hii, how to insert records present in CSV file to database table
Praveen
To insert records present in a CSV file to a database table using JMeter, you can use the following steps:
1. Create a JDBC Connection Pool in your JMeter test plan.
2. Create a JDBC Request sampler in your JMeter test plan.
3. Configure the JDBC Request sampler to insert data into the database table.
4. Add a CSV Data Set Config element to your JMeter test plan.
5. Configure the CSV Data Set Config element to read the CSV file that contains the data that you want to insert into the database table.
6. Add the JDBC Request sampler to a Thread Group.
7. Run the JMeter test plan.
Here is an example of a JMeter test plan that inserts records present in a CSV file to a database table:
```
Test Plan
JDBC Connection Pool
Name: my-jdbc-connection-pool
Driver Class: com.mysql.cj.jdbc.Driver
Database URL: jdbc:mysql://localhost:3306/mydb
Username: root
Password: password
CSV Data Set Config
File Name: data.csv
JDBC Request
Name: Insert Data into Database Table
SQL Statement: INSERT INTO users (name, email) VALUES (?, ?)
Variable Names: name, email
Thread Group
Threads: 1
Ramp-Up Period: 1
Loop Count: 1
JDBC Request: Insert Data into Database Table
```
The CSV file `data.csv` should contain the data that you want to insert into the database table. Each row in the CSV file should represent a single record. The columns in the CSV file should be in the same order as the columns in the database table.
When you run the JMeter test plan, the JDBC Request sampler will connect to the database and insert the data from the CSV file into the database table.
Here are some additional tips for inserting records present in a CSV file to a database table using JMeter:
* Use a prepared statement to insert the data into the database table. This will help to protect your database from SQL injection attacks.
* Use a transaction to insert the data into the database table. This will ensure that all of the data is inserted into the database table successfully.
* Test your JMeter test plan thoroughly before using it in production.
I hope this helps
Hi Raghav,
In my application I m using Only one Valid user ID and Password.And i m increasing the virtual users (load as 10 ) and here what will be the Numbers of hits on server.Does it hit only one (given user ID and password)"OR" hits along with the virtual Hits(10 Threads ) on DB log.Can please share and Upload the video ,based on application hitting on server along with the hits details of server.]
Thanks,
Will try to do a session on this
Hi Raghav,
How to Connect the oracle DB?
Hi Punit, you will need to provide your connection url according to the database. Check here:
stackoverflow.com/questions/43844202/how-to-connect-oracle-database-to-jmeter-if-we-have-service-name-instead-of-sid
My project done in php codeigniter frame work and mysql database how give databse connections
Can check some online examples - www.blazemeter.com/blog/mysql-database-and-jmeter-how-to-test-your-connection
@@RaghavPal Okay Thank you!!!
Excellent work, What about Oracle DB?
Thanks for watching Sudhakaran, you should be able to use similar steps for oracle db too.
Hi Raghav I really like your videos and its very helpful at the same time. I have one request, Can you please create a video or give me some reference for testing MongoDB in Jmeter? It will be really helpful Thanks.
Hi Sumit, www.blazemeter.com/blog/how-load-test-mongodb-jmeter
Hi Raghav,
Can you please help me out wit this issue, I am facing for extracting the data from the pdf. I tried to find with other sources also but its not working.
Message : Missing tika-app.jar in classpath. Unable to convert to plain text this kind of document.Download the tika-app-x.x.jar file from tika.apache.org/download.html
And put the file in /lib directory.
Is there any tutorial you have created for this?
hi Richa, i haven't created any video related to extracting data from pdf file. What steps you are doing?
can you help me with your email id I will provide you all the details
Richa, you can find the email in the about section of this channel. I might not be able to invest a lot of time, but will have a look at your issue.
thanks a lot 😀😀😀
Hi Raghav...As per your instructions, i have added jar file in jmeter and restarted jmeter and i am using Database URL- jdbc:mysql://192.168.1.139:3306/sofiyadb
JDBC driver class- com.mysql.jdbc.Driver but it shows connection timed out.
Hi Sofiya, what is the wait time-out value you have put in the controller. Try putting a higher value and check. Also see if there is any information in the logs.
I have increased wait time with 80000 but still getting Connection timeout.
looks like your db is not able to connect through jmeter. Is there any other information in the log.
how can i conect the oracle db conection in jmeter, sir?
Hi Huỳnh, once you have your connection details (url, credentials) you can add JDBC connection configuration element. follow this:
stackoverflow.com/questions/43844202/how-to-connect-oracle-database-to-jmeter-if-we-have-service-name-instead-of-sid
www.tutorialbyexample.com/2015/02/oracle-database-testing-jmeter-tutorials.html
Hi Raghav,
I have to connect database using SSH, can you please guide me how to do that? Already tried to find solution but didn't help.
Hi Malay. I hope you have already seen the google links. I will create a session on this
Yes Raghav.. I have seen that link but it is not feasible solution to go with Putty as per seniors. Please post a video ASAP it will be very helpful for us.
Sure, will try to be early
This task is done by writting Custom Utility in JSR223 Sampler
i have this error ""Cannot create PoolableConnectionFactory (Access denied for user 'malvino'@'183.82.35.81' (using password: YES)) "" help me
Pls check this Malvino - stackoverflow.com/questions/50114832/jmeter-showing-error-cannot-create-poolableconnectionfactory-access-denied-fo
Hey Raghav,
While implementing I am an encountered with this below error could you help me out in this
Response message:java.sql.SQLException: Cannot create PoolableConnectionFactory (Access denied for user 'com.mysql.jdbc.Driver'@'106.200.254.129' (using password: YES))
Hi Gunjan, this looks like permission issue. Pls check if this helps - stackoverflow.com/questions/3782197/cannot-create-poolableconnectionfactory-access-denied-for-user-localhost
Raghav,
But this is related to Tomcat version and for localhost , do I need to reinstall the new version of jmeter.
Hi Raghav,
This issue has been resolved. Thanks ...!!! :)
Cannot load JDBC driver class 'com.mysql.jdbc.Driver'
this error is not resolved please help me
restart jmeter but can not resolve this issue
Can you try getting some diff ver of jar file. Any more logs you have
@@RaghavPal - Tried with with mysql-connector-java-5.1.47 version and still getting same error