From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 6482748637851942912 X-Received: by 10.80.170.148 with SMTP id q20mr6826255edc.5.1509382537754; Mon, 30 Oct 2017 09:55:37 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 10.80.147.19 with SMTP id m19ls6691159eda.1.gmail; Mon, 30 Oct 2017 09:55:37 -0700 (PDT) X-Google-Smtp-Source: ABhQp+T99X0bA8ayXdgxE7Z/qr1H8IHmNf57zdPHbez/KD4fG8K7DsVceChynoGPtOYEGQ5b+ZS+ X-Received: by 10.80.163.214 with SMTP id t22mr7446405edb.12.1509382537468; Mon, 30 Oct 2017 09:55:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1509382537; cv=none; d=google.com; s=arc-20160816; b=SsooT2Y3kOV/1TYP1rlamdZNgYwWYp+SB+UVipaAhIH+3R8ta1ipIAQs1zguSh2Iox iD0uTpxDNF7jtN1GUtQiBxJnx1kVTn6mHzI5iHltKluKwfs32/aHApS97M6/sTMxUCji Fs9HLH9xl0zgRDFV4xxHVjm5V5PfKhvu4CgAD/TbTLki5/Q3fI4VrttuS+KwbyhE1hku Bp7yx62f0jqyoI0OuBLdifDBa5DyT20BbXzf2ZG6VMX2dtuo41ScYWms+nMbj/gtTh4m WlNpciCqdm5CgbyQ35vk69RpsWbd9gKf7OrVEVQ09UVLe6ENhzpwvg+KyGv6Oxp00xhS vyOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=message-id:date:subject:cc:to:from:arc-authentication-results; bh=hui8w1PEMQfOwnk13dvUpW2ttS7lIUYDFnmLjZhCrZw=; b=cTM5D5k2yDuI8UJVHhT82esLIy8lJ6Kbioh4/TovK6zH+IawfeCwPersTgtBCWF5pe WqA++n7ldYAq2eBuuUwh5fVfy5fJCYGWsz4qN4WPjlCtE7y0BSm4x3kFKtlIbmBYFmTf ZlY/tlPlJVpEG5OwI/8xcxskWGjg3kPl0mv+eNK3ZmK46nkLYx2Lu6jsPilv2MKfATgl WsWLsj5Fq9a/+XBj5iej+XBRxhy1co8tvGuq/sNjrIuNiv3YASbDw6BznWeZ3K0iHT/p DDsHixBGn4UStV1Zdc2j8u0GQhTI83Inf4ukCmbYttXkMOug/S6acPwQFZ3/vSV9WxpN XbnQ== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of henning.schild@siemens.com designates 192.35.17.2 as permitted sender) smtp.mailfrom=henning.schild@siemens.com Return-Path: Received: from thoth.sbs.de (thoth.sbs.de. [192.35.17.2]) by gmr-mx.google.com with ESMTPS id m13si971547edc.2.2017.10.30.09.55.37 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 30 Oct 2017 09:55:37 -0700 (PDT) Received-SPF: pass (google.com: domain of henning.schild@siemens.com designates 192.35.17.2 as permitted sender) client-ip=192.35.17.2; Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of henning.schild@siemens.com designates 192.35.17.2 as permitted sender) smtp.mailfrom=henning.schild@siemens.com Received: from mail3.siemens.de (mail3.siemens.de [139.25.208.14]) by thoth.sbs.de (8.15.2/8.15.2) with ESMTPS id v9UGtbnP011218 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Mon, 30 Oct 2017 17:55:37 +0100 Received: from md1em3qc.ww002.siemens.net ([139.25.68.40]) by mail3.siemens.de (8.15.2/8.15.2) with ESMTP id v9UGtb2f010375; Mon, 30 Oct 2017 17:55:37 +0100 From: Henning Schild To: isar-users@googlegroups.com Cc: Henning Schild Subject: [PATCH] image: copy INITRD_IMAGE out with sudo Date: Mon, 30 Oct 2017 17:55:34 +0100 Message-Id: <20171030165534.2642-1-henning.schild@siemens.com> X-Mailer: git-send-email 2.13.6 X-TUID: okyDriKpNEpq Issue: do_copy_boot_files can fail to read initrd if certain packages are installed in the image. One example package causing that issue is "dropbear", it is probably connected with the initrd being rebuild during installation. The file will have mode 0600 instead of the expected 0644. Fix: use sudo to copy the file Impact: There is one more sudo in the Isar codebase. People that faced the issue are now be able to build their images, others will not see a difference. Signed-off-by: Henning Schild --- meta/classes/image.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass index 4bfd39c..2c2bafc 100644 --- a/meta/classes/image.bbclass +++ b/meta/classes/image.bbclass @@ -92,7 +92,7 @@ do_copy_boot_files() { INITRD_IMAGE=${@get_image_name(d, 'initrd.img')} if [ -n "${INITRD_IMAGE}" ]; then - cp -f ${IMAGE_ROOTFS}/boot/${INITRD_IMAGE} ${DEPLOY_DIR_IMAGE} + sudo cp -f ${IMAGE_ROOTFS}/boot/${INITRD_IMAGE} ${DEPLOY_DIR_IMAGE} fi } -- 2.13.6