<lopsided98> I figured it out - Linux 5.1 has grown big enough that it seems to be overwriting the beginning of the initramfs. I added 2MiB to ramdisk_addr_r and it boots correctly now
<clever> need a proper bootloader, that puts the ramdisk after the kernel, not at a fixed addr
<samueldr> sphalerite: through two trivial changes in nixpkgs, and then only configuration options to disable things that had trouble building, I built and booted an aarch64 image
<samueldr> cross-compiled*
<samueldr> so it's kind of close
<samueldr> (now trying armv7l)
<Ashy> lopsided98: any chance you could write up your steps to booting mainline kernel nixos on the rockpro64?
<Ashy> i have one but i've only successfully booted nixos with ayufan's kernel so far
<Ashy> though i'm not clear on what state ayufan's patches are in, have they been mainlined for 5.1?
<lopsided98> Ashy: I have never gotten mainline to boot. It always fails to initialize the eMMC.
<lopsided98> Maybe it would work with an SD card, but I haven't tried it
<Ashy> ah ok, i haven't tried an sdcard either sounds like a plan for this weekend
<Ashy> i had a look at ayufan's fork a while back and couldnt see a huge amount of changes for the rockpro64 specifically, not sure why they hadn't been mainlined at the time, maybe they have for 5.1 or 5.2
<samueldr> looks plausible
<Ashy> ah yeap
lopsided98 has quit [Quit: Disconnected]
lopsided98 has joined #nixos-aarch64
ryantrinkle has quit [Ping timeout: 246 seconds]
zupo has joined #nixos-aarch64
st4ll1_ has joined #nixos-aarch64
st4ll1 has quit [Ping timeout: 248 seconds]
st4ll1_ has quit [Quit: ZNC 1.7.3 - https://znc.in]
st4ll1 has joined #nixos-aarch64
st4ll1 has quit [Ping timeout: 272 seconds]
orivej has joined #nixos-aarch64
<sphalerite> samueldr: awesome!!
orivej has quit [Ping timeout: 248 seconds]
jackdk has quit [Ping timeout: 248 seconds]
cmacrae has joined #nixos-aarch64
<cmacrae> Hey peeps o/ I've just setup my DNS/DHCP server on a little Raspberry Pi 3 B+ with NixOS. Works really nice, but one problem I'm running into is using NixOps to deploy to it
<cmacrae> It seems the /boot partition of the image I got from hydra is too small
<cmacrae> So, when (what looks like) kernels are copied over (even though I'm using it as a remote build machine for itself...) it fails because /boot is filled up
<cmacrae> Does anyone have any information on where this image generation is done, and how I might tweak it to my liking?
orivej has joined #nixos-aarch64
<sphalerite> cmacrae: nixos/modules/installer/cd-dvd/sd-image-aarch64.nix
<sphalerite> cmacrae: it seems that you can increase your /boot size by setting sdImage.bootSize
<cmacrae> Wahooo! Thank you very much sphalerite!
<cmacrae> That's really helpful info
<cmacrae> Are there any docs on how I can then build this image? (I guess I should probably *actually* go and search...)
<cmacrae> Right there in the manual ;) I think I'll manage
<cmacrae> Thanks again sphalerite, much appreciated
<cmacrae> Aaaand there's even a comment on the first line detailing how to build, haha
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zupo has joined #nixos-aarch64
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
v0|d has quit [Ping timeout: 245 seconds]
ryantrinkle has joined #nixos-aarch64
zupo has joined #nixos-aarch64
<samueldr> cmacrae: you could also switch your /boot from being on FAT to being on the ext4 partition
<samueldr> this should become the new default with #62462
<{^_^}> https://github.com/NixOS/nixpkgs/pull/62462 (by samueldr, 5 days ago, open): sd-image: FAT free /boot
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zupo has joined #nixos-aarch64
zupo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<sphalerite> samueldr++ half for the contents and half for the title
<{^_^}> samueldr's karma got increased to 91
<samueldr> that title (and branch name) has been known to me for over a year since I initially tried doing that way back, but had less of a handle on how things fit together at the time
ryantrinkle has quit [Ping timeout: 248 seconds]
<cmacrae> samueldr: Just seen this, thanks for the advice, that's a good shout
<cmacrae> Thanks
<cmacrae> Running into problems building the image, sadly
<samueldr> what kind of problems?
ryantrinkle has joined #nixos-aarch64
<cmacrae> Summarised there
<cmacrae> Looks like a license assertion fails
<cmacrae> `FATAL: modpost: GPL-incompatible module zfs.ko uses GPL-only symbol 'preempt_schedule_notrace'`
<samueldr> right
<sphalerite> cmacrae: hang on, I have a fix for that :)
<{^_^}> #61162 (by lheckemann, 4 weeks ago, merged): Kernel config: use PREEMPT_VOLUNTARY
<cmacrae> Ah! Life saver sphalerite! Thanks! I'll give this a shot
<sphalerite> cmacrae: it should already be in current master and 19.03
<samueldr> cmacrae: if you want it built with /boot on ext4, also apply my PR to your work tree, in addition it would make a good third party test of my PR :)
<samueldr> curl -L https://github.com/NixOS/nixpkgs/pull/62462.patch | git apply # if it applies cleanly it's a great shortcut
<{^_^}> #62462 (by samueldr, 5 days ago, open): sd-image: FAT free /boot
<cmacrae> Even gave the me command! Haha, perfect, thank you - let me try that out. Happy to vouch for it in the PR if it works, too
<samueldr> (curling into git apply is a real timesaver to quickly test something without much commitment)
<cmacrae> Can you think of a "nice" way to do this declaratively? This is a nix-shell expression I was using to keep this easily repeatable: https://git.io/fjzV0
<cmacrae> Wondering if I can pull in your patch in that expression
<cmacrae> Also don't know if I'm doing this in a really stupid way, haha. But, it gives me a nice n easy repeatable build run
<cmacrae> Building on a darwin host, with my Raspberry Pi as the build machine
<samueldr> it'd have to apply the patch on `nixpkgsRepo`
<cmacrae> Yup, just trying to work out how I can do that
<cmacrae> Haven't used patch functionality in derivations before
<samueldr> people are doing things here https://github.com/NixOS/nixpkgs/pull/59990
<{^_^}> #59990 (by basvandijk, 6 weeks ago, open): Support patching nixpkgs
<samueldr> (the PR itself probably won't be accepted looking at the response)
<cmacrae> Thanks! Yeah just having a read through :)
<cmacrae> Sorry, been trying to get on with some cooking at the same time! So, I put this expression together:
<cmacrae> But it seems the 'sdImage.bootSize' option isn't there in sdimage.nix now... weird!
<sphalerite> cmacrae: you shouldn't use the 19.03 tag. That was the initial release, and doesn't contain any of the security fixes introduced since.
<sphalerite> prefer either pinning a recent revision of the nixos-19.03[-small] branch from nixos/nixpkgs-channels, or using builtins.fetchGit or builtins.fetchTarball to have a recent version fetched impurely
<sphalerite> then you also won't need to apply the preempt fix, since it's in recent 19.03s :)
<cmacrae> Ah! Okay, thank you!
<sphalerite> not sure what's up with bootSize not working? How exactly is that failing?
<cmacrae> Yeah it's weird, if I follow it through, the 'bootSize' param isn't even there in the sd-image.nix
<cmacrae> Either way, as you've pointed out, that's the wrong tree to be using
<cmacrae> So, I'm sure it'll be solved when I find the right place to track
<cmacrae> I just wanted a fresh but fairly stable version of NixOS
<cmacrae> So, figured 19.03 would make sense, but you've made a good point above :)
<sphalerite> yeah, use the latest nixos-19.03 or nixos-19.03-small :)
<cmacrae> Is nixos-19.03-small available as a tag, or something? Can't see it - sorry if I'm missing something obvious, haha
<sphalerite> it's a branch in https://github.com/nixos/nixpkgs-channels
<cmacrae> Ah! So I should be fetching nixos/nixpkgs-channels?
<sphalerite> yeah probably
<cmacrae> Okay, perfect
<sphalerite> nixpkgs-channels is essentially the same repo, but without any manually managed branches
<cmacrae> Thank you for all your help so far!
<sphalerite> only the automatic channel branches are placed there
<cmacrae> Okay, sure - that makes sense
<cmacrae> Sweet, got a build running now :) Will see how this goes!
<cmacrae> Many thanks for your help so far, really appreciate it!
<lopsided98> gcc lc
<lopsided98> oops
<samueldr> cmacrae: if you applied my patch, I removed bootSize :)
<samueldr> it's firmwareSize since it's the raspberry pi's firmware equivalent
<samueldr> and not a /boot partition
cmacrae` has joined #nixos-aarch64
cmacrae has quit [Ping timeout: 272 seconds]
ryantrinkle has quit [Ping timeout: 248 seconds]
orivej has quit [Ping timeout: 258 seconds]
jtojnar has joined #nixos-aarch64
ryantrinkle has joined #nixos-aarch64
orivej has joined #nixos-aarch64
ryantrinkle has quit [Ping timeout: 248 seconds]
jtojnar has quit [Remote host closed the connection]
<sphalerite> gchristensen: there seems to be a rather old version of nixpkgs deployed on the community box
<sphalerite> as in something 18.09-based
<sphalerite> don't know what's up there
<samueldr> your observation seems right
<sphalerite> ah so it's sort-of-expected
<sphalerite> thanks for tracking it down!
clever has quit [Ping timeout: 272 seconds]