[
https://issues.apache.org/jira/browse/HIVE-28339?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17860827#comment-17860827
]
Stamatis Zampetakis commented on HIVE-28339:
--------------------------------------------
The bulk of stateful content that is maintained by Jenkins is located under the
"/var/jenkins_home" directory.
{noformat}
kubectl exec jenkins-6858ddb664-sg6nl df
Filesystem 1K-blocks Used Available Use% Mounted on
overlay 98831908 4612016 94203508 5% /
tmpfs 65536 0 65536 0% /dev
tmpfs 6645236 0 6645236 0% /sys/fs/cgroup
/dev/sdb 308521792 279898320 28607088 91% /var/jenkins_home
/dev/sda1 98831908 4612016 94203508 5% /etc/hosts
shm 65536 0 65536 0% /dev/shm
tmpfs 10801128 12 10801116 1%
/run/secrets/kubernetes.io/serviceaccount
tmpfs 6645236 0 6645236 0% /proc/acpi
tmpfs 6645236 0 6645236 0% /proc/scsi
tmpfs 6645236 0 6645236 0% /sys/firmware
{noformat}
As expected the persistent volume used by the Jenkins pod is mounted to the
"/var/jenkins_home" directory (see kubectl describe
pod/jenkins-6858ddb664-sg6nl).
For testing purposes we need to obtain a backup of the jenkins_home directory
and try to mount it to the new (upgraded) Jenkins image to ensure that
everything will work smoothly.
Currently, the jenkins_home directory is 280GB which makes a complete local
backup and testing impractical. The majority of disk space is occupied by the
"jobs" directory and in particular by archives that are kept for each build,
test results, and log files for each run. These files are kept for archiving
and diagnosability purposes when users wants to consult the results of each
build. However, they are not indispensable for the correct functionality of the
Jenkins instance so for the sake of our experiments we can exclude them from
the backup. The command that was used to create the backup is given below.
{code:bash}
kubectl exec jenkins-6858ddb664-sg6nl -- tar cf - --exclude=junitResult.xml
--exclude=*log* --exclude=archive --exclude=workflow --exclude=*git/objects*
/var/jenkins_home > jenkins_home_backup.tar
{code}
The command took ~5 minutes to run and created an archive of 1.2GB. The
exclusions are referring to voluminous files that are nonessential for testing
the upgrade.
I am now in the process of testing the new Jenkins image locally by mounting
the unpacked jenkins_home_backup.tar directory to the /var/jenkins_home
directory of the container.
> Upgrade Jenkins version in CI from 2.332.3 to 2.452.2
> -----------------------------------------------------
>
> Key: HIVE-28339
> URL: https://issues.apache.org/jira/browse/HIVE-28339
> Project: Hive
> Issue Type: Task
> Reporter: Stamatis Zampetakis
> Assignee: Stamatis Zampetakis
> Priority: Major
>
> The Jenkins version that is used in [https://ci.hive.apache.org/] is
> currently at [2.332.3|https://www.jenkins.io/changelog-stable/#v2.332.3]
> which was released in 2022.
> The latest stable version at the moment is
> [2.452.2|https://www.jenkins.io/changelog-stable/#v2.452.2] and contains many
> improvements, bug and CVE fixes.
> The Dockerfile that is used to build the Jenkins file can be found here:
> [https://github.com/kgyrtkirk/hive-test-kube/blob/master/htk-jenkins/Dockerfile]
> The Kubernetes deployment files can be found here:
> [https://github.com/kgyrtkirk/hive-test-kube/tree/master/k8s]
--
This message was sent by Atlassian Jira
(v8.20.10#820010)