How to access Mysql DB variables in Serverspec? can we do it using PowerShell? -


i want access db variables using serverspec, in serverspec windows not supported trying using powershell got following issues

tried using below powershell command:

"cd program\ files\\mysql\\mysql\ server\ 5.5\\bin"; "\.\mysql.exe --user=root --password=atmf" 

but not recognized due escape characters issue , later if give command in double quotes powershell prints string.

just have commandline client output variable:

$mysql  = "c:\path\to\mysql.exe"  $dbuser = "root" $dbpass = "..." $dbname = "database" $dbvar  = "innodb_buffer_pool_size"  $value = & $mysql -u "$dbuser" -p "$dbpass" -b -d "$dbname" -e "select @@$dbvar" 

Comments

Popular posts from this blog

inversion of control - Autofac named registration constructor injection -

verilog - Systemverilog dynamic casting issues -

ios - Change Storyboard View using Seague -