[Nix-dev] Amazon EC2 rebuild switch causes kernel panic
Roger Qiu
roger.qiu at matrix.ai
Mon Mar 14 16:57:58 CET 2016
What's happening is the transition from stage 1 booting to stage 2 booting
is failing. The error reported is that the init script that is be executed
once switch_root is executed is non existent. Which could mean your initrd
is corrupted or the build failed for some reason or some other config
problem at stage 1.
If you could inspect the initrd to check if the init script is there...
On 15/03/2016 2:31 AM, "Paul Cooley" <Paul.Cooley at bazaarvoice.com> wrote:
> I brought up an AWS instance using nixos-15.09.git.87b377dM-x86_64-pv-ebs
> . After modifying /etc/nixos/configuration.nix to use the
> "amazon-init.nix" rather than "amazon-image.nix" and performing a
> 'nixos-rebuild switch' command, the instance reports the following error.
>
> [fsck.ext3 (1) -- /mnt-root/disk0] fsck.ext3 -a /dev/xvdb
> /dev/xvdb: recovering journal
> /dev/xvdb: clean, 116502/262144 files, 579900/1047168 blocks
> mounting /dev/xvdb on /disk0...
> switch_root: can't execute '/nix/store/z9rp9hzs19pi1788fj8kdkw81mnxsgf1-nixos-15.09.1119.f6d1666/init': No such file or directory
> [ 0.652277] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000100
> [ 0.652277]
> [ 0.652287] CPU: 0 PID: 1 Comm: switch_root Not tainted 3.18.26 #1-NixOS
> [ 0.652291] ffff880002c81880 ffff8800e8e23e28 ffffffff814bc251 ffffffff818541b8
> [ 0.652296] ffffffff81713d68 ffff8800e8e23ea8 ffffffff814bb43e 0000000000000001
> [ 0.652300] 0000000000000010 ffff8800e8e23eb8 ffff8800e8e23e58 ffffffff8185dd80
> [ 0.652304] Call Trace:
> [ 0.652313] [<ffffffff814bc251>] dump_stack+0x46/0x58
> [ 0.652316] [<ffffffff814bb43e>] panic+0xc1/0x1eb
> [ 0.652321] [<ffffffff8106a045>] do_exit+0xac5/0xad0
> [ 0.652327] [<ffffffff811aed3c>] ? vfs_write+0x15c/0x1f0
> [ 0.652331] [<ffffffff8106a0e5>] do_group_exit+0x45/0xb0
> [ 0.652335] [<ffffffff8106a164>] SyS_exit_group+0x14/0x20
> [ 0.652338] [<ffffffff814c1fc9>] system_call_fastpath+0x12/0x17
> [ 0.652344] Kernel Offset: 0x0 from 0xffffffff81000000 (relocation range: 0xffffffff80000000-0xffffffff9fffffff)
>
>
> Can someone explain to me what I'm doing wrong during the rebuild?
>
> _________________________
>
> [image: Bazaarvoice]
>
> Paul Cooley
> Senior Dev Ops Engineer
> o: m: 281-435-2328
> e: paul.cooley at bazaarvoice.com
> Site <http://www.bazaarvoice.com/> | Blog
> <http://www.bazaarvoice.com/blog> | Twitter
> <http://twitter.com/Bazaarvoice>
>
>
>
>
>
> _______________________________________________
> nix-dev mailing list
> nix-dev at lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.science.uu.nl/pipermail/nix-dev/attachments/20160315/420a4134/attachment.html
More information about the nix-dev
mailing list