How would someone clean up a Jenkins job such that the build stability rating is reset and not affected by previous builds? I created a build job and through trial and error, I finally got the job to compile/build correctly. However, I don't want all the previous test builds to affect the build stability rating. I tried deleting all the builds and restarting Jenkins but it still says 20 of the last 25 builds failed. I looked in the $JENKINS_HOME directory (~/.jenkins) and couldn't find anything regarding build stability. Thanks.
When you configure the job you can tell it how long to keep the logs for - either days or build. Set this to one build to clear it out then reset it back again
Related
I have installed- https://plugins.jenkins.io/changes-since-last-success/ in my jenkins. But now, when my build has failed then the commits done for that particular build are not visible in the next successful build.
I can't see this changes since last success option in UI-
Am I required to do anything else other than this plugin installation. I mean do I have to perform any configuration to use it or make it work?
Your answer will help me a lot.
I have a job running on a WindowsServer2012R2 agent. The job is pausing between 2 plugins (BuildNameSetter v1.6.8 and DiscardOldBuilds v1.0.5) as you can see below:
13:05:25 Set build name.
13:05:25 New build name is '5.0.811.0'
13:20:21 Discard old builds...
I've started to notice this strange behavior after upgrading Jenkins Master from 2.89 to 2.190.3.
It's frustrating to see your job taking a 15 minutes nap!
Is this a server side issue or a agent side one?
Can someone give me some hints about how to tackle this problem?
Did you experience something similar?
you could have a look at jenkins central logs /log/all to see if there is any java stacktrace error in there
Then you should first try to isolate the issue. try deactivating the build name setter step first. then try to disable the discard old build. then enable build name setter again and keep discard old build deactivated
now you know which plugin is causing the issue try to downgrade or upgrade the plugin that makes your build hang
if the issue comes from discard old build, I would try to remove clean the job's workspace and remove builds manually
look for your issue on jenkins's jira system, upvote. create a ticket if you have not found another user experiencing the same issue
Finally you should be able to find workarounds for these plugins
Today I've upgraded Jenkins to a newer version (2.263.2) on the Jenkins server and the 15 minutes pause dissapeared.
I know that a build had run for a Jenkins job (I received an e-mail with the results and the build number #9).
But, when I open Jenkins to check the Build History, the build in question (Build #9) is not there. When I try to trigger a new build, it is counted as Build #10. So, somebody must have deleted Build #9 manually from Jenkins (my guess).
If yes, how do I get the details of the user who deleted that build?
Is there a log I can refer to?
Do you have the Jenkins Audit Trail Plugin installed?
You can use it to keep an audit of "most actions with significant effect such as creating/configuring/deleting jobs and views or delete/save-forever/start a build".
So it looks like the example you gave of deleting a build would be covered.
See https://wiki.jenkins.io/display/JENKINS/Audit+Trail+Plugin
The Job Configuration History plugin will keep track of all changes (delta+user) AND let you roll back, but only after you install it.
Our Release Managemeng has a job that is stuck "In Progress".
The error is
Communication with the deployer was lost during the deployment. Please
make sure (1) the deployer machine has not rebooted during
installation and (2) the component timeout is sufficient to copy the
files from the drop location to the deployer machine and install the
package.
I can't stop or abandon the release. The buttons are all disabled. How can I kill this?
From the Release Manager, go to the Release tab. Enter in the details of the actual release, go to the step that is pending and you will see a a "Stop" Button at the top. That will stop the step and change the step of the Release.
Is the build stuck? Can you restart the build controller and / or the build agent? You can look for them by editing the build definition.
Don't trust me as Release Management is pretty new, but the error is about the connection between the RM Server and the RM Deployer service (i.e. the RM agent). RM Server don't know anything more about the agent, so your option is to connect to the target machine(s) and manually check deployment status. If completed, restart the RM Deployer service and cross fingers.
I faced the same issue of the release being stuck in 'In Progress' state. Turned out, the password of the credentials I was using, changed. Once the new password was specified in the deployment agent, the release managed to complete. This was months ago, and now I am facing same issue on other server. No clue what is the reason this time.
We has had this problem in which all releases got stuck on TFS 2018
As there is a connectivity issue with SQL when release is completed , it may not update the status in DB in some cases if load is more, so the release is stuck in InProgress state and started consuming pipeline in SQL . Other releases will also not move ahead, as there is blockage in pipeline. Once we increase the pipeline count, the problematic release could move out as processing of releases started happening.
Once the problematic release is canceled by the system, we set the pipeline back to original count of 1, then you could see their releases progressing and not being stuck.
Solution:
You need to increase the count of pipeline to let say 25 after this create a new Release Pipeline and queue this pipeline this will push all those pipeline which got stuck .Once pipeline start queuing make the count back to one or original count.
Reference - https://blogs.msdn.microsoft.com/tfssetup/2017/11/14/understanding-build-and-release-pipelines-visual-studio-team-servicesteam-foundation-server/
On TFS 2010 we set up a build script to automatically run and deploy to our test environment no more than every 4 hours. So the trigger of the build definition is "Rolling builds - accumulate check-ins until the prior build finishes" with the check box checked for "Build no more often than every [240] minutes". The way I'm interpreting this is that if a build happens at 16:25, and there's 3 check-ins in the next 30 minutes (the last happening at 16:52), then the next build will happen at 20:25.
The issue we're seeing is that if this sequence of events happens on a Friday, then the next triggered build doesn't occur until Monday morning. We do have two build agents on their own separate virtual machine from TFS, but all machines are up and running 24/7.
There's nothing that anybody on the team is aware of that would cause this behavior, so we're at a loss for why we're seeing it. Are we simply misunderstanding the meaning of Rolling Build, or is there configuration setting we forgot to check?
EDIT: For what it's worth, the entirety of the build & deployment process takes all of 90-120 seconds. So there were not any check-ins that occurred while it was still building.
The Accumulate check-ins means that when you check-in a changeset, if there is no build of this build definition in 240 minutes, TFS will queue a build automatically. But if do not check-in a changeset, no builds will be queued.
Builds should be triggered as you wrote. 3rd build should be triggered after the first check-in after 20:25 build not before 0:25 on Saturday. :)
Try to check if changesets were not checked into the location cloaked in the build definition workspace (or checked into the location not mapped by build definition workspace).