please wait while jenkins is restarting - jenkins

It is taking too much time (waiting from last hours). I have only 1 project with multiple jobs. I have updated plugings regarind security issues and few updatest no luck. I have restarted jenkins many times and worked fine but now it stucks. Is there any way out to kill/suspend jenkins to avoid this wait

After lot of reserach, I did not find any answer. So best way is to go to the jenkins folder in the drive, navigate to plugins directory and remove the folder which are installed and updated on the current date. Then strat teh jenkins and download the plugins which are deleted from the plugins folder

Related

Jenkins thinBackup scheduled backup is not running

I have installed thinBackup plugin to back up my Jenkins, and I have configured it as follows:
So, there should be a full backup everyday after 08:00 PM, unfortunately for some reason, the scheduled backups are not running at all.
But, manual backup (by clicking the Backup Now button in the main page) works:
Jenkins has write access to the backup directory.
Can anyone let me know what could be the problem here?
FYI: I got the same problem with Periodic Backup plugin as well.
Thanks in advance.
I faced the same problem, restarting Jenkins worked for me.

Jenkins Service vs Jenkins Jar File Permission

I have Jenkins 1.6 installed as a service on a CentOS machine.
At some point in the past the service stopped/crashed/? and Jenkins was restarted from the command line, java -jar jenkins.war, as the root user.
While it was running as root some plugins were updates/installed, and jobs created created/ran. Any new files created are now owned by the root user/group and not by the jenkins user/group.
Meaning, when the service was restarted Jenkins could not read these files. Resulting in plugins not running and most jobs not being loaded.
Manually restoring the permissions(chown, chgrp) to the plugins solves the plugin related issues.
For the jobs it's easy to spot new ones and fix them. Any existing ones that were re run and created new files are more difficult to find.
Then there may be other files which the Jenkins server created, not as part of a job or plugin which need to be changed. The errors are not always obvious, and crop up slowly over time.
Am I better adding the jenkins user to the root group? could this cause issues?
Or manually changing the permissions, hope i got them all! And fix others that come up?
Any suggestions appreciated.
In the end we manually changed the file permissions back to Jenkins. There were some immediate jobs that failed in the following days. And a few which only came up a few months later.
For the most part it worked well.

Jobs will not load when copied to new Jenkins server

I followed this documentation for moving jobs between Jenkins servers. After choosing to 'Reload Configuration from Disk' I am finding that the majority of jobs were migrated however a handful of jobs are not presented within the Jenkins dashboard. Looking at $JENKINS_HOME/jobs, I see directories for jobs which did not load and confirmed the config files are valid XML. I have looked at the System Log (via the Jenkins GUI) but find nothing pertinent. Rebooting the machine and reloading configuration from disk does not resolve the problem.
Interestingly, I can see the previous build history for a specific job if I choose to create a new job with the exact same name as a job which will not load. The config.xml is overwritten when this occurs. I am hoping to preserve the job configurations without manually recreating them.
For me I found it that I had copied the jobs over with the wrong permissions - once I ran chown -R jenkins:jenkins $JENKINS_HOME/jobs it solved the issue for me
I chose to investigate by comparing the config.xml content for loaded and unloaded jobs. I eventually identified the issue:
Jobs which used cron syntax similar to H/* (as well as H/[number]) would not load
The issue stemmed from the fact that I migrated to a previous release of Jenkins. This cron functionality was introduced within 1.5.10 via story Jenkins-17311.
Removing the noted syntax from config.xml content allowed jobs to load during subsequent 'Reload Configuration from Disk' executions.

pending - Waiting for next available executor

I am using Jenkins version 1.537 and I'm having issues running jobs on one of my slave systems. Even though there are no job in the queue for the system, Jenkins keeps showing 'pending - Waiting for next available executor'.
I searched around online and in other posts within stackoverflow, but the solutions are for older versions of Jenkins, and the resolutions do NOT solve my issues.
Thanks for any help,
Eric
I increased the number of available executors to 4 & restarted the instance. This solved the issue. Also I got faced with memory issue in the /var/lib/jenkins folder which I fixed by deleting the contents in ./m2 repository which amounted to free space
I was able to fix the issue by re-installing and copying my job folders to the new install. I tried a bunch of other things that did not help.

jenkins missing jobs after removal of plugins

I have a Jenkins Server (1.510) on Win 2008 with ~100 jobs.
After installing and then uninstalling the CloudBees (Plugin_1, Plugin_2) set of plugins + restart I have the following issues:
half of the Jobs are now missing.
many plugins are not functioning well, for example the green-balls plugin is not working and also the entry to launch the backup plugin is missing
many built in Jenkins buttons such the new "Credentials" is missing from the "Jenkins Configure" Menu.
Looking at the FS, i still see all the jobs.
I already tried :
Using the reload configuration
Reinstalling the plugins
Reinstalling Jenkins with the same version once again
Still the jobs are missing
Any idea how to solve it?
Thanks,
Doron
When job is loaded, many of the related Java classes get instantiated. If instantiation fails, usually because some plugin has been removed and that class is no longer available at all, then the job is hidden.
I suspect you have accidentally removed some other plugin too.
Note: Before actually doing anything, take full backup! Easiest is to backup entire Jenkins folder, where the jobs, configuration etc reside.
Easiest solution might be to just install Jenkins from scratch, install the plugins you do need (see below for troubleshooting if you're missing some), then copy the jobs subfolder to the new Jenkins. It might be best to do any configuration under Manage Jenkins by hand, but you can also just try copying the related XML config files.
If you are missing a plugin and can't figure out which one, you should look at jenkins.out.log and jenkins.err.log log files and search for exceptions happening after Jenkins is started. That may give you a clue on what plugin you are missing.
You can also try editing the job XML files to remove build steps you identified from the exceptions (remember to take backups first!), then restart Jenkins or select Reload configuration from disk from Manage Jenkins page.
If not solved, but you find relevant-looking exceptions or something else interesting, please update the question with details.
After I upgraded Jenkins, one of my jobs disappeared. I found out that although my job directory still existed, the config.xml file inside had somehow gone missing.
I restored this file from a backup, after updating all the plugins that needed updating, and reloaded the configuration, and the job reappeared in Jenkins.

Resources