SonarRunner Unrecognized option: views - plugins

We are running an "Invoke Standalone SonarQube Analysis" build step on Jenkins with following configurations:
Target: views
JDK: (Inherited from Job)
sonar-runner-2.4
General infos:
SonarQube Version: 4.3
Jenkins Version: 1.606
SonarQube Plugin (in Jenkins): 2.2
Until a few days ago everything works fine, but since then the build is always failing. We are not able to reconstruct if any (plugin-)changes were done on the Jenkins server back then. Nevertheless we ar running nowadays into ERROR: Unrecognized option: views. Using other goals works fine, so the runner works in general.
18:03:38 Started by user myUser
18:03:38 [EnvInject] - Loading node environment variables.
18:03:38 Building on master in workspace c:\Jenkins\jobs\myRunnerJob\workspace
18:03:38 [workspace] $ c:\sonar-runner-2.4\bin\sonar-runner.bat -e views -Dsonar.jdbc.url=myDatabaseURL ******** ******** -Dsonar.host.url=myHostUrl ******** ******** -Dsonar.projectBaseDir=c:\Jenkins\jobs\myRunnerJob\workspace
18:03:38 d:\Programs\sonar-runner-2.4
18:03:38 ERROR: Unrecognized option: views
18:03:38 INFO:
18:03:38 INFO: usage: sonar-runner [options]
18:03:38 INFO:
18:03:38 INFO: Options:
18:03:38 INFO: -D,--define <arg> Define property
18:03:38 INFO: -e,--errors Produce execution error messages
18:03:38 INFO: -h,--help Display help information
18:03:38 INFO: -v,--version Display version information
18:03:38 INFO: -X,--debug Produce execution debug output
18:03:38 Started calculate disk usage of build
18:03:38 Finished Calculation of disk usage of build in 0 seconds
18:03:38 Started calculate disk usage of workspace
18:03:38 Finished Calculation of disk usage of workspace in 0 seconds
18:03:38 Finished: SUCCESS
Running "-v" instead of "views" is resulting the following:
[...]
17:30:12 d:\Programs\sonar-runner-2.4
17:30:12 SonarQube Runner 2.4
17:30:12 Java 1.7.0_71 Oracle Corporation (64-bit)
17:30:12 Windows Server 2008 R2 6.1 amd64
17:30:12 Started calculate disk usage of build
17:30:12 Finished Calculation of disk usage of build in 0 seconds
17:30:12 Started calculate disk usage of workspace
17:30:12 Finished Calculation of disk usage of workspace in 0 seconds
17:30:13 Finished: SUCCESS
This means sonar-runner is installed correctly.
I checked the installation of "Views" on SonarQube too. The lisence is activ and if I am running an "sonar-runner views" locally everything runs perfectly.
Any ideas for this strange behavior?

The reason for the problem is still unkown, but after re-installing the SonarQube plugin on Jenkins everything went back to normal. (Down-graded the plugin and updated it afterwards)

This issue was linked to a regression in Jenkins SonarQube Plugin 2.2
It has been fixed in Jenkins SonarQube Plugin 2.2.1.
See : http://jira.codehaus.org/browse/SONARJNKNS-214

Related

Azure pipeline Docker `all pipe instances are busy`

When running a build pipeline with maven and docker-maven-plugin sometimes(more than 50% of the time) it throws following error and pipeline fails.
Jun 18, 2019 1:57:12 AM org.apache.http.impl.execchain.RetryExec execute
INFO: I/O exception (java.io.FileNotFoundException) caught when processing request to {}->npipe://127.0.0.1:1: \\.\pipe\docker_engine (All pipe instances are busy)
Jun 18, 2019 1:57:12 AM org.apache.http.impl.execchain.RetryExec execute
I can see in the log that multiple retry attempts, but all fails. Is there any way that I can overcome this?
I just solved this problem:
I added the right version of docker-maven-plugin 1.4.10
dockerfile-maven-plugin

Hyperledger cli container does not bind volumes with host

I am trying to implement the BYFN Hyperledger example form my Windows 10 Linux Subsystem (Ubuntu Xenial). However, the ./byfn.sh -m up command fails with the following output:
$GOPATH/fabric-samples/first-network$ ./byfn.sh -m up
Starting with channel 'mychannel' and CLI timeout of '10' seconds and CLI delay of '3' seconds
Continue? [Y/n] y
proceeding ...
2018-04-24 22:12:44.343 UTC [main] main -> INFO 001 Exiting.....
LOCAL_VERSION=1.1.0
DOCKER_IMAGE_VERSION=1.1.0
Creating peer0.org1.example.com ... done
Creating orderer.example.com ... done
Creating peer1.org1.example.com ... done
Creating peer0.org2.example.com ... done
Creating peer1.org2.example.com ... done
Creating cli ... done
OCI runtime exec failed: exec failed: container_linux.go:348: starting container process caused "exec: \"scripts/script.sh\": stat scripts/script.sh: no such file or directory": unknown
ERROR !!!! Test failed
I see that only one container is built:
$GOPATH/fabric-samples/first-network$ dps
CONTAINER ID NAMES NETWORKS STATUS SIZE
3e66d31c6b9a cli net_byfn Up 27 minutes 17B (virtual 1.46GB)
From the output it seems that the cli container cannot see the script.sh script. Thinking this maybe a docker-compose volume-bind issue I tried to check the binds in the cli container:
$GOPATH/fabric-samples/first-network$ docker exec -ti cli bash
root#3e66d31c6b9a:/opt/gopath/src/github.com/hyperledger/fabric/peer# ls scripts/
root#3e66d31c6b9a:/opt/gopath/src/github.com/hyperledger/fabric/peer# exit
exit
$GOPATH/fabric-samples/first-network$ ls scripts/
capabilities.json script.sh step1org3.sh step2org3.sh step3org3.sh testorg3.sh upgrade_to_v11.sh utils.sh
Looking at the the docker-compose-cli.yaml file I see the following binds for the cli container:
volumes:
- /var/run/:/host/var/run/
- ./../chaincode/:/opt/gopath/src/github.com/chaincode
- ./crypto-config:/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/
- ./scripts:/opt/gopath/src/github.com/hyperledger/fabric/peer/scripts/
- ./channel-artifacts:/opt/gopath/src/github.com/hyperledger/fabric/peer/channel-artifacts
My Docker settings:
$GOPATH/fabric-samples/first-network$ docker version
Client:
Version: 18.03.0-ce
API version: 1.37
Go version: go1.9.2
Git commit: 0520e24
Built: Wed Mar 21 23:05:52 2018
OS/Arch: linux/amd64
Experimental: false
Orchestrator: swarm
Server:
Engine:
Version: 18.03.0-ce
API version: 1.37 (minimum version 1.12)
Go version: go1.9.4
Git commit: 0520e24
Built: Wed Mar 21 23:14:32 2018
OS/Arch: linux/amd64
Experimental: false
$GOPATH/fabric-samples/first-network$ docker-compose version
docker-compose version 1.21.0, build 5920eb0
docker-py version: 3.2.1
CPython version: 3.6.5
OpenSSL version: OpenSSL 1.0.1t 3 May 2016
My Go version:
$GOPATH/fabric-samples/first-network$ go version
go version go1.10.1 linux/amd64
Wondering if I'm missing something. I should mention that I used the following command to start form scratch, based on a fresh set of images (no prior images) as outlined in this script:
curl -sSL https://raw.githubusercontent.com/hyperledger/fabric/master/scripts/bootstrap.sh | bash -s 1.1.0
Thanks
Its most probably the version of golang---Fabric needs go version 1.9.x and the error message exec failed: container_linux.go:348: indicates the same thing.
In my case, it was the first Note on this page https://hyperledger-fabric.readthedocs.io/en/latest/install.html
I'm running on Windows 10, but Docker won't work since i need Windows 10 Pro or better to run it. So i'm using Docker Toolbox, and must follow the Windows 7 trick of cloning the sources anywhere under C:\Users

"bosh create-env concourse-lite.yml" fails while Creating VM for instance 'concourse/0' from stemcell

I am trying to spin up Concourse using "bosh create-env concourse-lite.yml".
I am using a VM with Ubuntu to setup Concourse. Below are the sytem details and the command output.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.3 LTS
Release: 16.04
Codename: xenial
4.4.0-101-generic #124-Ubuntu SMP Fri Nov 10 18:29:59 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Command Output:bosh create-env concourse-lite.yml
Deployment manifest: '/root/concourse-lite.yml'
Deployment state: '/root/concourse-lite-state.json'
Started validating
Downloading release 'concourse'... Skipped [Found in local cache] (00:00:00)
Validating release 'concourse'... Finished (00:00:03)
Downloading release 'garden-runc'... Skipped [Found in local cache] (00:00:00)
Validating release 'garden-runc'... Finished (00:00:03)
Downloading release 'bosh-virtualbox-cpi'... Skipped [Found in local cache] (00:00:00)
Validating release 'bosh-virtualbox-cpi'... Finished (00:00:03)
Validating cpi release... Finished (00:00:00)
Validating deployment manifest... Finished (00:00:00)
Downloading stemcell... Skipped [Found in local cache] (00:00:00)
Validating stemcell... Finished (00:00:03)
Finished validating (00:00:13)
Started installing CPI
Compiling package 'golang-1.8-linux/c97f9a00c26b34a3f59ca15b0f5a079d7f7e27c334cc8100248143c5dc0d4c0a'... Finished (00:00:00)
Compiling package 'golang-1.8-darwin/ee2bb46a25872469cd8fe0f4b0804bab5c39cc5512bbcc4335c8691a038d3e73'... Finished (00:00:00)
Compiling package 'virtualbox_cpi/cb3116b9b6c2111a873bb4ea14a1f3544ccdd2af'... Finished (00:00:00)
Installing packages... Finished (00:00:12)
Rendering job templates... Finished (00:00:00)
Installing job 'virtualbox_cpi'... Finished (00:00:00)
Finished installing CPI (00:00:12)
Starting registry... Finished (00:00:00)
Uploading stemcell 'bosh-vsphere-esxi-ubuntu-trusty-go_agent/3468.1'... Skipped [Stemcell already uploaded] (00:00:00)
Started deploying
Creating VM for instance 'concourse/0' from stemcell 'sc-6196df8a-6e26-411f-70b5-0cc0466a5adf'... Failed (00:01:19)
Failed deploying (00:01:19)
Stopping registry... Finished (00:00:00)
Cleaning up rendered CPI jobs... Finished (00:00:00)
Deploying:
Creating instance 'concourse/0':
Creating VM:
Creating vm with stemcell cid 'sc-6196df8a-6e26-411f-70b5-0cc0466a5adf':
CPI 'create_vm' method responded with error: CmdError{"type":"Bosh::Clouds::CloudError","message":"Creating VM with agent ID '{{559adf3b-c06e-4af0-5564-6e86f5d95d81}}': Starting VM: Retried '30' times: Running command: 'VBoxManage startvm vm-e9498e46-c2ef-4772-69f0-627f95044b4a --type headless', stdout: 'Waiting for VM \"vm-e9498e46-c2ef-4772-69f0-627f95044b4a\" to power on...\n', stderr: 'VBoxManage: error: The virtual machine 'vm-e9498e46-c2ef-4772-69f0-627f95044b4a' has terminated unexpectedly during startup with exit code 1 (0x1)\nVBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component MachineWrap, interface IMachine\n': exit status 1","ok_to_retry":false}
Exit code 1
Seems like an issue with VirtualBox on your machine. Some folks running on Ubuntu have also reported seeing this same error here

Orientdb fails to shut down

This fails:
$ sudo service orientdb stop
This fails as well:
$ sudo /data/db/orientdb/bin/shutdown.sh
Sending shutdown command to remote OrientDB Server instance...
Dec 19, 2015 6:50:09 PM com.orientechnologies.common.log.OLogManager log
INFO: OrientDB auto-config DISKCACHE=991MB (heap=869MB os=3,909MB disk=175,894MB)
Dec 19, 2015 6:50:09 PM com.orientechnologies.common.log.OLogManager log
INFO: Loading configuration from: /data/db/orientdb/config/orientdb-server-config.xml...
Error: Read timed out
The file permissions are correct:
12K -rwxrwx--- 1 orientdb orientdb 9.6K Dec 19 18:05 orientdb-server-config.xml
If have tried commenting out script that refers to "orientdb-server-config.xml" in the the shutdown.sh file and it makes no difference.
The System:
Ubuntu v14.04
OrientDB v2.1.8 (I upgraded from v2.1.6 to see if it would fix this problem)
Java v1.8
You may want to try this command. This worked for me when shutting down normally.
sh shutdown.sh localhost 2424
To stop a running server, press Ctrl+C in the open shell that runs the server instance, or soft kill the process to be sure that the opened databases close softly. Soft killing on Windows can be done by closing the window. On Unix-like systems, a simple kill is enough (do not use kill -9 unless you want to force a hard shutdown).

I had used Quartz in my Java web-application but when Quartz will execute after its execution, Tomcat is being off.

I wrote a code in Quartz that will update database on a daily basis exactly once a day.
I am using Eclipse in my web-application so had started the Tomcat through Eclipse.
But after updating the database from Quartz it is forcing the Tomcat to be terminated in Eclipse. So my application is not working after the Quartz portion is running (due to Tomcat termination). The messages I got in Eclipse 4 Quartz is displayed below:
Job name:Event Update1
Group name:mysql
Trigger name:cronTrigger4Event1
Firing Time:Mon Jan 24 14:30:00 IST 2011
dateFormat.format(calendar.getTime()) : 2011-01-24
Inserting values in Mysql database table!
1 row affected
Jan 24, 2011 2:30:00 PM org.apache.coyote.http11.Http11BaseProtocol pause
INFO: Pausing Coyote HTTP/1.1 on http-8080
[INFO] 24 Jan 2011 14:30:05.506 Thread-34 [org.quartz.core.QuartzScheduler]
Scheduler QuartzScheduler_$_NON_CLUSTERED shutting down.
[INFO] 24 Jan 2011 14:30:05.506 Thread-34 [org.quartz.core.QuartzScheduler]
Scheduler QuartzScheduler_$_NON_CLUSTERED paused.
[INFO] 24 Jan 2011 14:30:05.506 Thread-34 [org.quartz.core.QuartzScheduler]
Scheduler QuartzScheduler_$_NON_CLUSTERED shutdown complete.
Any help is appreciated.
i think your problem in tomcat and eclipse not in quartz itself so you have two solutions
1- get the tomcat out of eclipse and deploy you application manually, don't forget to give you application server more memory.
2- get you schedule jobs out of you application and use the Linux system cron jobs.