Message ID | 20241017075749.101476-1-amikan@ilbers.de |
---|---|
State | Accepted, archived |
Headers | show
Return-Path: <isar-users+bncBCHIPONZWECRBC4HYO4AMGQEE2RFJCA@googlegroups.com> Received: from shymkent.ilbers.de ([unix socket]) by shymkent (Cyrus 2.5.10-Debian-2.5.10-3+deb9u2) with LMTPA; Thu, 17 Oct 2024 09:58:14 +0200 X-Sieve: CMU Sieve 2.4 Received: from mail-pj1-f57.google.com (mail-pj1-f57.google.com [209.85.216.57]) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPS id 49H7w9nX009522 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for <iupwgm@isar-build.org>; Thu, 17 Oct 2024 09:58:10 +0200 Received: by mail-pj1-f57.google.com with SMTP id 98e67ed59e1d1-2e3b9fc918fsf901536a91.2 for <iupwgm@isar-build.org>; Thu, 17 Oct 2024 00:58:10 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1729151884; cv=pass; d=google.com; s=arc-20240605; b=C2Wg53tn31pMT84J28mV3OqK2BjGab34PS3RkS6/nr54MmD1ibvRi2CakddHMt4q+s z5HZi/DPL8sOEClavQbSRxAfK9vxstFuW1/Qv1WyWFuM97/8Lc7VBVg+9RQJt8v/HWBe 4WrF6WF/DbSnZeqH6g4aJqPOqxbHy+CDNOkv8+DF34CaXrOE2rwhHDnb2ti5bm8mAqGS v9EDteSuB7L1i5v5bUKubRGg367fO3uTkbMcfxOWO846dzK1zb2LAQ3EYbUq68LPmOrL 5nB/dSU4hLX5ZwjgN24LtPXbpB1W4pmKYFzqkOfwQpehbHaDHrt1jqWsn8k7v2fr9ITO d3zw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:mime-version:message-id:date :subject:cc:to:from:sender:dkim-signature; bh=Sja4JvdTX+66H0f2fyyNKwNZAVO4mlkOHFWoyNoIjJ0=; fh=e4K1NoTYSUPb+a9g2jf/gkRt2L3j6GteA/VLzvGxxnk=; b=FxpcU4XWSm07zs2KGDCUyxyDXZAJ59K7judoU/fvT5/aqrUdwXXdloI2Kgw2oSQ3Yh osHGqJlXAS+2MZwpo9+/hBZr0AfnWkUO/EKIe6ubdTXOwniNcdpoQlllXYuQ5kk98Xlv Yjv0umyD8Bty5GPlNaWK8uH0npF/t2CX13VnCfxfA8Xe7QRVvYb/03VuZqUc39XLTbuK fYq2FVXfbGpX6gFqScm6P92A4ICkKlBiQxMYHRF7rb78WKCC0wDCVOg0BFhLkO2B9gYO f1xfG8H8pPzoJ//kamHgavlpkrQnGDl6ZTjdlq1fvcq+dsJlNMWycHyiolV0YLeplMzL 93AQ==; darn=isar-build.org ARC-Authentication-Results: i=2; gmr-mx.google.com; spf=pass (google.com: domain of amikan@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=amikan@ilbers.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1729151884; x=1729756684; darn=isar-build.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:x-original-authentication-results :x-original-sender:mime-version:message-id:date:subject:cc:to:from :sender:from:to:cc:subject:date:message-id:reply-to; bh=Sja4JvdTX+66H0f2fyyNKwNZAVO4mlkOHFWoyNoIjJ0=; b=ll2C/tHgt+Qzoza0gm86WkF3sP8qi9I+Q8LWnhJ0FKTlct2YpNFwffuxsIokA9kyM4 DtafXz7tpHubE6jxdxIV0YaHFeDb/QyHctKGpfPkHQf8Hr8Jyj6+JSjBC+3YcwQAkOW+ v3LTfhROHyFFnGhEo7+1dm7wouEws/DvBUj8L1MFW95loPyZjR76FmSKI6gUQxg13s2f SpssRpWYMWYd+o7yn2+aFMbsis5eZoJNvTlYX311Rrbz/QoHbsDF7lpVRadxCq/MfGoa BFI+e7BKZCu5SCHuhRmTB/mAx+hfQ55Ztp3igfqDu0ILcvyxVhOQV0LlyiW7RR+9XrFk AJUg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729151884; x=1729756684; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender:mime-version :message-id:date:subject:cc:to:from:x-beenthere:x-gm-message-state :sender:from:to:cc:subject:date:message-id:reply-to; bh=Sja4JvdTX+66H0f2fyyNKwNZAVO4mlkOHFWoyNoIjJ0=; b=SIx4l7sv8hqKVoVT30NOw4fR1pDENSu3G0eweFKcr86SETc/jgkJHgb3qmaFrGLm3z mDk/2IG8l6NZg7uoc6zdHMVScEux7z6D+DuTVBn8xkCrXefmx+/F+8Fvys1vzqCHE1SY nl7ogMBelwycu0sSzUG5JkcIk9H8IG12ba0d5wOAIhqYkUf6Q7FRVT/f7qVTte1yUnnA Dasx5sNmqbrHSwSjwDq+gn9No0fZn1krrnqhp5qtXR5nr+yX5E0HVN5JfIgJK+JTSmNa gStf/0vvVhQ+JrDAyl10UjFGftM4PK3AVg45vLuVJ9Z33amn8TktfAdpox84ibwubOPn v6LQ== Sender: isar-users@googlegroups.com X-Forwarded-Encrypted: i=2; AJvYcCVZvo8i7VTYx+yYlRlkI0hzg91XAsnqOnOfomztSdKQIuVyuyDde/PwPCjIsPGYJa2ZU/HFw7U=@isar-build.org X-Gm-Message-State: AOJu0YyziBR2kEgp8YRS5NzZYxzwc2GMdmDTCaTrwn5k8RtPyBihuq7n zinzSdK6B4qkNzr+w7l3lARnLxZt8Yr1xeU0wf2NQC67L7AQUO9f X-Google-Smtp-Source: AGHT+IEfe2VNAxl4VgEAcT2dy4WmnUncbLECBai2CkbYz6cc8V2OHUnD+1rR0zTGC2wIL+63r6VmDA== X-Received: by 2002:a17:90a:5c81:b0:2e2:da81:40c3 with SMTP id 98e67ed59e1d1-2e3ab7c59bdmr9005665a91.1.1729151883379; Thu, 17 Oct 2024 00:58:03 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a17:90a:6549:b0:2d8:7c42:a28d with SMTP id 98e67ed59e1d1-2e3dbf35794ls528338a91.0.-pod-prod-08-us; Thu, 17 Oct 2024 00:58:02 -0700 (PDT) X-Received: by 2002:a17:90b:3504:b0:2e2:8472:c350 with SMTP id 98e67ed59e1d1-2e3ab81c448mr8052015a91.17.1729151882179; Thu, 17 Oct 2024 00:58:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1729151882; cv=none; d=google.com; s=arc-20240605; b=HBQgM/uuAOLWrhMbglSGHpAATmfvMj/3TYFptKuokpUc4lvmB9tRjFM5aCbljqs7bL 1VIrvb/Q2Wsa4Pvfg/9O/4EMApbVKffq4gcjiLI6O88jiR6sWuAJbAobuYwOkYuhMVbG rVdm1FzwjDCfjQy7Mzr/xyeAYjdOsx8etkCc+pik3FzLCbBBvQwGKUV7VFITBST9FGeU DBUlxxsU10OmI1x+j4aa6ogETar13CuxCRgv3DM6jFstCj3+sT3ZNOAjLEpbbgVzWCuG RAqzyYI4BGmCKZYFQSAuB1oavetnEYmVe8CXE96JDk7H+6Ggq2eYCSqcZYYhmKdYwyze X8cA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from; bh=MT1c06pnSonx7rDgcmrgmLNgW64O9xth8P5yDAW6Xgg=; fh=/h9QQkzJ8EboVkWg45aWwpaUro6WMavIVd2OhN45RtE=; b=QfvTD37jG2aSiMTC0vlPNHhp/tfWnhyDXAs5ndxHvpCv3FMueKBMI6bm/Rca2Nmx3k Uhpdc5DZdWShykKiqTQ/r9b8nQItuaQx1FzW6zLz+PFwNuACpIkPZVm2o4/7MyiXaXrP Dp0Msy9hdFpZiK+XZAwG281cRZwEBbf7fVAWAKZVXTOrRsU5LyP3C77RR+N0Jc3e8rG/ LRF0Q3PcfJqd8roBUzgayvU0xrOs+UOs6J3/PfeF4NXcjwNyv2r++M5DycJU/X9VkSg0 bJwYALDrYYN+P5BHisWe/bn3uEXc27E3AZJ5vtaSPFphtvTv0KdpQfj9H9PFnF3bA72s 6Ozw==; dara=google.com ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of amikan@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=amikan@ilbers.de Received: from shymkent.ilbers.de (shymkent.ilbers.de. [85.214.156.166]) by gmr-mx.google.com with ESMTPS id 98e67ed59e1d1-2e3e0913afesi56497a91.2.2024.10.17.00.58.01 for <isar-users@googlegroups.com> (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 17 Oct 2024 00:58:01 -0700 (PDT) Received-SPF: pass (google.com: domain of amikan@ilbers.de designates 85.214.156.166 as permitted sender) client-ip=85.214.156.166; Received: from user-B660.promwad.corp ([159.148.83.114]) (authenticated bits=0) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPSA id 49H7vtDe009482 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 17 Oct 2024 09:57:56 +0200 From: Anton Mikanovich <amikan@ilbers.de> To: isar-users@googlegroups.com Cc: Anton Mikanovich <amikan@ilbers.de> Subject: [PATCH] initramfs: Avoid hanging mounts on failed update-initramfs Date: Thu, 17 Oct 2024 10:57:49 +0300 Message-Id: <20241017075749.101476-1-amikan@ilbers.de> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Spam-Status: No, score=-4.6 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,RCVD_IN_RP_CERTIFIED,RCVD_IN_RP_RNBL,RCVD_IN_RP_SAFE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shymkent.ilbers.de X-Original-Sender: amikan@ilbers.de X-Original-Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of amikan@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=amikan@ilbers.de Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list isar-users@googlegroups.com; contact isar-users+owners@googlegroups.com List-ID: <isar-users.googlegroups.com> X-Spam-Checked-In-Group: isar-users@googlegroups.com X-Google-Group-Id: 914930254986 List-Post: <https://groups.google.com/group/isar-users/post>, <mailto:isar-users@googlegroups.com> List-Help: <https://groups.google.com/support/>, <mailto:isar-users+help@googlegroups.com> List-Archive: <https://groups.google.com/group/isar-users List-Subscribe: <https://groups.google.com/group/isar-users/subscribe>, <mailto:isar-users+subscribe@googlegroups.com> List-Unsubscribe: <mailto:googlegroups-manage+914930254986+unsubscribe@googlegroups.com>, <https://groups.google.com/group/isar-users/subscribe> X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= |
Series |
initramfs: Avoid hanging mounts on failed update-initramfs
|
expand
|
diff --git a/meta/classes/initramfs.bbclass b/meta/classes/initramfs.bbclass index 42013356..0197a60b 100644 --- a/meta/classes/initramfs.bbclass +++ b/meta/classes/initramfs.bbclass @@ -35,6 +35,10 @@ do_generate_initramfs[sstate-inputdirs] = "${DEPLOYDIR}" do_generate_initramfs[sstate-outputdirs] = "${DEPLOY_DIR_IMAGE}" do_generate_initramfs() { rootfs_do_mounts + + trap 'exit 1' INT HUP QUIT TERM ALRM USR1 + trap 'rootfs_do_umounts' EXIT + rootfs_do_qemu sudo -E chroot "${INITRAMFS_ROOTFS}" sh -c '\
If update-initramfs fails during do_generate_initramfs task execution there will be mounts left behind. Protect it with a trap for cleanup in case of failure. Signed-off-by: Anton Mikanovich <amikan@ilbers.de> --- meta/classes/initramfs.bbclass | 4 ++++ 1 file changed, 4 insertions(+)