During in a audit task, I am going to delete few mysql users. Before delete I want to check, when the last time these user access the database server. I want to know if we have this information stored in information_schema or mysql databases. If not how can we achieve this?
mysql user last login / access date time
19.1k views Asked by Faizan Younus At
1
There are 1 answers
Related Questions in MYSQL
- How to Retrieve Data from an MySQL Database and Display it in a GUI?
- How to change woocomerce or full wordpress currency with value from USD to AUD
- window.location.href redirects but is causing problems on the webpage
- Error: local variable 'bramka' referenced before assignment
- Products aren't displayed after fetching data from mysql db (node.js & express)
- status table for all entries (even in different dates) in database changing value when all checkboxes are checked
- Can't Fix Mariadb & Mysql ERROR 2002 (HY000): Can't connect to local server through socket '/tmp/mysql.sock' (2) On MacOs
- Express Mysql getting max ID from table not working cought in a promise
- failed to upload a table from sql file
- Update a MySQL row depending on the ID in Google Sheets Apps Script
- Use row values from another table to select them as columns and establish relations between them (pivot table)
- SQL: Generate combination table based on source and destination column from same table
- How to display the column names which have only unique non-null values in MySQL table?
- mysql query takes too long because of wrong indexes usage
- Multitable joining in Sql
Related Questions in LINUX
- Is there some way to use printf to print a horizontal list of decrementing hex digits in NASM assembly on Linux
- Why does Hugo generate different taxonomy-related HTML on different OS's?
- Writes in io_uring do not advance the file offset
- Why `set -o pipefail` gives different output even though the pipe is not failing
- what really controls the permissions: UID or eUID?
- Compiling eBPF program in Docker fails due to missing '__u64' type
- Docker container unable to make HTTPS requests to external API
- Whow to use callback_query_handler in Python 3.10
- Create kea runtime directory at startup in Yocto image
- Problem on CPU scheduling algorithms in OS
- How to copy files into the singularity sandbox?
- Android kernel error: undefined reference to `get_hw_version_platform'
- Is there a need for BPF Linux namespace?
- Error when trying to execute a binary compiled in a Kali Linux machine on an Ubuntu system
- Issue with launching application after updating ElectronJs to version 28.0.0 on Windows and Linux
Related Questions in MYSQLADMIN
- MYSQL where to set password for mysqladmin?
- Wordpress plugin development and Gitlab pipeline Mysql service error
- mariadb state wise where case clause inside view
- Is there a tool to show schema/definition changes between two dump files for MySQL?
- Checking when a MySQL server is ready to run queries without interrupting them
- Is there a way to change MySQL root password during re-installation (Windows 10)?
- BLOB/TEXT column 'bought_furniture' can't have a default value
- Using Roles in MySQL Azure - Privileges Issues on Admin Account
- MySql Admin User lost Privileges
- rows missing in mysql
- How to debug "ER_HOST_IS_BLOCKED: Host 'abc' is blocked because of many connection errors" error
- creating MySQL Trigger to insert into second table
- mysqladmin Access Denied when using -defaults-file=/etc/mysql/debian.cnf
- MySQL table listed twice with different case name
- Cannot set password for MySQL root user
Related Questions in MYSQLADMINISTRATOR
- HTML Encoding Issue During MySQL Backup in MySQL Administrator Tool
- Getting count of filtered rows from all the tables in MySQL
- Best way to write MySQL Events to run after every second if previous run is completed?
- mariadb state wise where case clause inside view
- MySql Admin User lost Privileges
- how to get select sub-query in which another table whole data get in json format
- MySQL table listed twice with different case name
- How to enable --general-log without restarting the MYSQL server?
- Failed to find valid data directory. MySQL generic binary installion
- MySQL Database Server Is Utilizing More Than 85 % Of Memory
- mysqld: Could not create or access the registry key needed for the MySQL application to log to the Windows EventLog
- How to delete data from database after select query excuted successfully
- mysql user last login / access date time
- How to fix high memory usage of MariaDB?
- Mysql database size reported differently in query level and folder level in ubuntu
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Popular Tags
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
You can look in the general log for any unsuccessful connection attempts to MySQL however out-of-the-box, MySQL typically does not log successful DB connections. This could become a very, very large log and that activity may quickly overwhelm the I/O subsystem and cause problems for the DB.
You can setup this sort of logging however it will result in quite a LOT of data! have a look at this post over in the DBA Exchange: https://dba.stackexchange.com/questions/668/audit-logins-on-mysql-database
If you are using a DB server that is yours and yours alone, you should be able to do this. If you have a DBaaS type thing, multi-tenant DB systems would die logging each connect. This may not be possible?
You may also find some steps on enabling usertracking in MySQL from the Percona blog: https://www.percona.com/blog/2012/12/28/auditing-login-attempts-in-mysql/