Install tomcat 7 on windows server 2008 using puppet ( master is ubuntu ) - windows

Has anyone installed tomcat and jdk7 packages on windows server 2008 using puppet.
puppet master is (Ubuntu)
puppet agent is (windows server 2008)
node 'puppetwindows' {
package {'jdk7 v7.0.79.1':
ensure => present,
source => 'puppet:///modules/jdk//jdk-7u79-windows-x64.exe',
path => “C:\jdk-7u79-windows-x64.exe”
install_options => ['/VERYSILENT'],
below is the output;
Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Could
not parse for environment production: invalid byte sequence in US-ASCII at /etc
/puppet/manifests/site.pp:1 on node puppetwindows.pramati.com
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run

Your file is using UTF-8 with BOM. Convert it to UTF-8 w/out BOM.
You should also use puppet parser validate path\to\manifest.pp so you can get an idea of whether the file contains good Puppet code and as a byproduct whether Puppet can read the file (are the encodings usable?).

I just restarted the puppet master and it worked fine.
installed chocolatey(package manager for windows same as apt-get on Ubuntu) on both Ubuntu(puppet master) windows(puppet agent)
and with the below code I was able to install tomcat successfully.
node 'puppetwindows.XXXX.com' {
package { 'tomcat':
provider => 'chocolatey',
ensure => 'latest',
}
}

Related

Run time issues with Ballerina Integrator

I am trying to run the sample File Integration with FTP which is given by Ballerina Integrator.
While running the service i am facing same issue each and every time.
I have installed Ballerina Integrator only. I have done uninstall and installation freshly after that also Same issue.
Please help me.
I could successfully run the sample with following configurations. (sample data are given). Here I have used a Secured FTP server to do the configuration.
listener ftp:Listener dataFileListener = new({
protocol: ftp:SFTP,
host: "18.156.78.137",
port: 22,
secureSocket: {
basicAuth: {
username: "cloudloc",
password: "fsf#$#213"
}
},
path: "/clouddir/"
});
ftp:ClientEndpointConfig ftpConfig = {
protocol: ftp:SFTP,
host: "18.156.78.137",
port: 22,
secureSocket: {
basicAuth: {
username: "cloudloc",
password: "fsf#$#213"
}
}
};
Make sure you set the path parameter correctly in the dataFileListener. Without this parameter I could reproduce your attached error.
Once this is correctly configured you would get a log printed like follows.
2020-01-24 15:13:23,758 INFO [wso2/ftp] - Listening to remote server at 18.156.78.137...
2020-01-24 15:13:24,333 INFO [wso2/file_integration_using_ftp] - Added file path: /clouddir/a1.txt
2020-01-24 15:13:24,415 INFO [wso2/file_integration_using_ftp] - Added file: /clouddir/a1.txt - 12
Just install Ballerina Integrator alone which is packed with Ballerina 1.0.2 so no need to install Ballerina again or separately. From VSCode why output is not coming means,VSCode's market place all are upgraded with latest version.
Locally installed "BI with Ballerina" is lower version, In VSCode "BI with Ballerina" is latest one. Mismatched version is the main problem which i was faced.

Icinga2 does not start because he could not load library "db_ido_mysql"

Here is the Error:
root#taurus:/etc/icinga2/features-available# service icinga2 checkconfig
* checking Icinga2 configuration
information/cli: Icinga application loader (version: r2.7.2-1)
information/cli: Loading configuration file(s).
critical/config: Error: Error while evaluating expression: Could not load library 'libdb_ido_mysql.so.2.7.2': libdb_ido_mysql.so.2.7.2: cannot open shared object file: No such file or directory
Location: in /etc/icinga2/features-enabled/ido-mysql.conf: 6:1-6:22
/etc/icinga2/features-enabled/ido-mysql.conf(4): */
/etc/icinga2/features-enabled/ido-mysql.conf(5):
/etc/icinga2/features-enabled/ido-mysql.conf(6): library "db_ido_mysql"
^^^^^^^^^^^^^^^^^^^^^^
/etc/icinga2/features-enabled/ido-mysql.conf(7):
/etc/icinga2/features-enabled/ido-mysql.conf(8): object IdoMysqlConnection "ido-mysql" {
* checking Icinga2 configuration. Check '/var/log/icinga2/startup.log' for details.
root#taurus:/etc/icinga2/features-available# icinga2 feature list
Disabled features: command compatlog debuglog gelf graphite influxdb livestatus opentsdb perfdata statusdata syslog
Enabled features: api checker ido-mysql ido-pgsql mainlog notification
Does anybody know what i did wrong during the installation?
there were no problems, i dont get the answer.
Do you want to use Icingaweb2 with your Icinga2 installation? Then you have to install the
icinga2-ido-mysql
Package for your distribution and configure it. Here you can find a step by step instruction on how to install and configure it. If not, disable the following features:
ido-mysql ido-pgsql
Regards,
Jan

Connecting to Websphere MQ Queue with Ruby for testing

I have been looking into the RubyWMQ gem trying to connect to a Websphere queue, but am having no luck. My ultimate goal is to connect to, read and put messages to the queue using Ruby. I have used the gem authors documentation and examples here with no luck as well. currently I have tried this:
queue = WMQ::QueueManager.connect(
:q_mgr_name => 'MYQUEUEMANAGERNAMEHERE',
:exception_on_error => true,
:trace_level => 2,
# :connect_options => WMQ::MQCNO_FASTBATH_BINDING, # this errors
:channel_name => 'MYQUEUEMANAGERNAMEHERE',
:connection_name => 'localhost(1414)',
:transport_type => WMQ::MQXPT_TCP,
:user_identifier => 'MYUSERNAMEHERE',
:password => 'MYPASSWORDHERE')
I believe the first error I am receiving has to do with the Webshpere MQ client itself, or the install of the gem. i installed RubyWMQ using this command:
gem install rubywmq --platform=ruby -- '--with-mqm-include="C:\Program Files\IBM\WebSphereMQ\tools\c\include"'
I am using IBM WebSphere MQ version 7.1.0.3, located in C:\Program Files\IBM\WebSphere MQ...
I get this error when running my code:
WMQ::QueueManager#connect(). Failed to load MQ Library:mqic32, rc=126 (WMQ::WMQException)
I can see the "mqic32.dll" file in C:\Program Files\IBM\WebSphere MQ\bin, so I am not sure exactly what the gem code is doing..
Managed to fix this by adding C:\Program Files\IBM\WebSphere MQ\bin64 to my user $Path.
Which was odd, because bin and bin64 had both been added to the System $path variable by the IBM install.
(This is with a mingw ruby install)

Issues trying to bootstrap Chef for windows client with knife-windows

I am having some problems trying to bootstrap a windows node for Chef. This node was initially able to be partially bootstrapped, it was getting through most of the process but however, failing near the end - on the windows client itself I can see a number of expected files under C:\Chef
However since upgrading my Ruby and Knife-Windows to remedy the original issue - I am now not able to bootstrap at all, I get the error below:
chefadmin#AUK-CHEFMGT1:~$ knife bootstrap windows winrm 10.28.154.61 -x chefadmin -P xxxxxx
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/mixin/path_sanity.rb:25:
warning: Insecure world writable dir /usr/local/bin in PATH, mode 040777
Waiting for remote response before bootstrap.10.28.154.61 .
10.28.154.61 Response received.
Remote node responded after 0.01 minutes.
Bootstrapping Chef on 10.28.154.61
ERROR: RuntimeError: Knife-Windows < 1.0 does not support validatorless bootstraps
I've tried a few different versions of knife-windows, initially 1.1.1, and most recently the pre-release version of 1.0.0 rc1, however, they are all giving me this error.
I am not sure why this is a problem, as the validation.pem does exist on the windows client in C:\Chef\
In case it matters, here is my knife.rb config file:
chefadmin#AUK-CHEFMGT1:~$
GNU nano 2.2.6 File: /home/chefadmin/chef-repo/.chef/knife.rb
current_dir = File.dirname(__FILE__)
log_level :info
log_location STDOUT
node_name "chefadmin"
client_key "#{current_dir}/ChefRSA.pem"
validation_client_name "company"
validation_key "#{current_dir}/companyvalidator"
chef_server_url "https://10.28.253.101/organizations/company"
syntax_check_cache_path "#{ENV['HOME']}/.chef/syntaxcache"
cookbook_path ["#{current_dir}/../cookbooks"]
"#{current_dir}/companyvalidator" Does that file exist? Usually that would be something ending in .pem. If that path isn't a thing, it would fall back to new-style bootstrapping which I don't think works on Windows yet.

error message at vagrant start with puppet provisioning

I wrote an automized puppet file for the installation with Vagrant.
It's just for a fast installation for a apache web server (with PHP5, MySQL)
and atm it is as simple as possible for the beginning.
Every time I start up my Vagrant I get these messages and couldn't interpret
by myself:
←[0;36mnotice: /Stage[main]/Lamp/Package[php5]/ensure: ensure changed 'purged' t
o 'present'←[0m
←[0;36mnotice: /Stage[main]/Lamp/Package[mysql-client]/ensure: ensure changed 'p
urged' to 'present'←[0m
←[0;36mnotice: /Stage[main]/Lamp/Package[mysql-server]/ensure: ensure changed 'p
urged' to 'present'←[0m
←[0;36mnotice: /Stage[main]/Lamp/Package[apache2]/ensure: ensure changed 'purged
' to 'present'←[0m
This is not an error at all.
It just says, that the state of those packages has changed from purged to present.
purged = not installed
present = installed
It just means, the package was installed successfully.

Resources