When an application execution fails, it usually returns an error code to specify the cause of the problem. Windows error codes Application Error code Cause Workaround Visual Studio -2147205120 The computer has a pending restart and must be rebooted before the execution. Restart your computer, and then rerun the application.
Author Archives: Laszlo Pinter
.NET Framework Detection in the Windows Registry
To determine which .NET framework is installed on the Windows computer check the values in the registry. The HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full key contains two values you can check: Release Version You can use InSpec, part of the Chef DK, to check the values: describe registry_key(‘HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full’) do it { should have_property ‘Release’ } it { …
Continue reading “.NET Framework Detection in the Windows Registry”
Chef exit codes
Chef uses the standard RFC 062 exit codes. In your .kitchen.yml file, you can supply an array of exit codes in the “retry_on_exit_code” option to retry the operation in case the Chef script execution is interrupted. The usual values are retry_on_exit_code: # An array of exit codes that can indicate that kitchen should retry the converge …
FATAL: Chef::Exceptions::Reboot: Rebooting server at a recipe’s request.
When your Chef recipe requests a reboot using the “reboot” Chef resource, the output window shows an error message: Chef Client finished, …/… resources updated in … seconds […] WARN: Rebooting server at a recipe’s request. Details: {:delay_mins=>1, :reason=>”…”, :timestamp=>…, :requested_by=>”…”} Running handlers: […] ERROR: Running exception handlers Running handlers complete […] ERROR: Exception handlers complete Chef …
Continue reading “FATAL: Chef::Exceptions::Reboot: Rebooting server at a recipe’s request.”
Unable to satisfy constraints on package
When you make a change to the version restrictions in the metadata.rb file and execute berks install in your Chef cookbook directory, you may get the error message: Unable to satisfy constraints on package … due to solution constraint (…). Solution constraints that may result in a constraint on …: [(…)], [(…) -> (…)] Demand that …
amazon-ebs: Error waiting for SSH: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
When you launch a Linux AWS EC2 instance with Terraform or create a Linux AWS image with Packer, one of the following errors are displayed: amazon-ebs: Error waiting for SSH: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain aws_instance.default: 1 error(s) occurred: * ssh: handshake failed: ssh: unable to …
Block comment in ASP.NET MVC Razor file
To comment out a block of lines in the ASP.NET MVC Razor file, enclose them in @* and *@ @* Commented out instructions, including HTML and Extension methods *@
Procedure or function ‘`…_Insert`’ cannot be found in database …
When you use the Microsoft .NET Entity framework to access a MySql database, the autogenerated code throws an error when you try to insert a row into the database with context.MY_TABLE.Add(MY_OBJECT); Server Error in ‘/’ Application. Procedure or function ‘`…_Insert`’ cannot be found in database ‘`…`’. Description: An unhandled exception occurred during the execution of …
Continue reading “Procedure or function ‘`…_Insert`’ cannot be found in database …”
No connection string named ‘…’ could be found in the application config file.
Two-tier applications separate the presentation layer and the data layer, and all database access related objects are located in the data-tier. When the application runs, the config file of the main project is read. In web applications, it is the web.config, in console applications the app.config file. When you get the following runtime exception Exception thrown: ‘System.InvalidOperationException’ in …
Continue reading “No connection string named ‘…’ could be found in the application config file.”
delimited by end-of-file (wanted `EOF’)
When you create a file in a script and use an end of file delimiter, if … cat <<EOF> $chef_dir/attrib.json $json EOF fi and you indent the word EOF to look nicer, you will get the error message warning: here-document at line … delimited by end-of-file (wanted `EOF’) STDERR> …: line …: syntax error: unexpected end of file …