Received: from out1.migadu.com (out1.migadu.com [91.121.223.63]) by nld3-dev1.alpinelinux.org (Postfix) with ESMTPS id 62305782C66 for <~alpine/devel@lists.alpinelinux.org>; Sun, 14 Jun 2020 06:23:23 +0000 (UTC) X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dereferenced.org; s=default; t=1592115802; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=iA2xUiTFZ6dH+CidPP7uq7TxmjH89UD3dXop/r1I89Q=; b=knfJnjI7QChOyDrmDw6DaK2mXqJhCItJo2KtowpW6SeWfZUl4UhkA58Zc3G8BTX/MZjlUH ICq1qO2mtBrkcDCkv9xKntVW79rskVraAIzAYVQnJFg83CLF3uscRtRAAe6+MHXqFu7SDq /8vaEJwHgiXUyHyP5AtoUYrmx2YIfgk= From: Ariadne Conill To: ~alpine/devel@lists.alpinelinux.org Subject: Re: Failed to execute /init (error -13) Date: Sun, 14 Jun 2020 00:23:16 -0600 Message-ID: <1807823.gzgkiQsVPL@localhost> In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Spam-Score: 0.90 On Sunday, June 14, 2020 12:25:56 AM MDT kok leong soo wrote: > Hi all, > I'm stuck on this error Failed to execute /init (error -13) when i'm trying > to create a custom pxe boot using chroot method. > I have verified that the file existed in the image and boot using the > following kernel option in my ipxe script. > > kernel tftp://192.168.1.80/linux initrd=initrd.gz vga=788 > initrd tftp://192.168.1.80/initrd.gz > > Can anyone advise what might have happened? > > Thanks. The way the kernel handles launching the init process is, unfortunately, not very transparent when it fails. In the error message, errno -13 means "permission denied." This means your initrd either does not have the correct permission on /init itself, or Alpine's ELF interpreter (provided by musl) lacks correct permissions. Check the permissions on /lib/ld-musl-x86_64.so.1 as well. If you are using a different architecture than x86_64, the ELF interpreter path will be slightly different, but you should be able to find it in the initramfs. It should be present and executable. Once you fix these two problems, your initrd image should work correctly. Ariadne