Find knowledge base article(s) by searching for keywords in the title e.g. type linux in the search box below
Find knowledge base article(s) by browsing the subject categories of articles
Technology quick references, cheatsheets, user manuals etc.
Shop Online through ShopifyLite
Tutorials on various IT applications.
Search Title    (UL:0 |SS:f)

Software >> Services >> RDBMS >> MySQL >> Command Line >> How to run mysql from command line without being prompted for password using .my.cnf

in the user's home directory, create

.my.cnf

with following entries

 

[client]
# for local server use localhost
host=mysqlhost
user=mysqluser
password=mysqlpassword
 
[mysql]
pager=/usr/bin/less

e.g. for login using root to the mysql on localhost use

[client]
# for local server use localhost
host=localhost
user=root
password=mysqlpassword
 
[mysql]
pager=/usr/bin/less

 

 

 

 

 

[ © 2008-2021 myfaqbase.com - A property of WPDC Consulting ]