2018-11-01

<clever> lrwxrwxrwx 1 root root 9 Oct 31 15:36 /dev/disk/by-id/wwn-0x5000cca33ad2b4c7 -> ../../sda
<clever> turion: its /dev/disk you want
<clever> turion: hmmm no, not block
<clever> turion: you need to find a symlink under /dev/block that points to sdb
<clever> turion: sdb still
<clever> turion: gpt makes things more fun, by allowing labels on the partitions as well as the filesystems
<clever> turion: the label is part of the filesystem, not the parititon tables
<clever> infinisil: ah
<clever> turion: yeah, thats not even partitioned, "partition 1" starts at offset 0
<clever> infinisil: ,pastebin doesnt work
<clever> ,pastebin turion
<clever> also
<clever> turion: i dont think its even partitioned right now, so you need to create an mbr partition
<clever> can you switch it back to english?, just need to tweak one of the LC_ vars i think
<clever> turion: can you pastebin `fdisk -l /dev/sdb` ?
<clever> as-in, not-gpt
<clever> ext4 on an mbr partition table
<clever> grub2 supports both legacy and efi
<clever> turion: by legacy, i mean not-efi
<clever> turion: if you only want legacy booting, then you could just make the entire usb stick ext4 on mbr
<clever> turion: the boot partition can be vfat, but the rootfs must support +x and chown
<clever> emily: at runtime or nix build time?
<clever> i just added pkgs.steam to systemPackages and it works

2018-10-31

<clever> but if you fail to meet the output hash you claimed, the build finishes
<clever> so the sandbox is relaxed and allows network access
<clever> fixed-output derivations declare the hash of the output in the nix, so $out is based purely on that declared hash, not the inputs
<clever> so as long as its not using rng and date/time to decide things during the build, its pure, and reproducible
<clever> those derivations are also pure when the sandbox is on, so the only thing that they can possibly access, is the inputs, that are hashed
<clever> so if any input changes, $out changes, and it will usually not find it in /nix/store, and rebuild
<clever> a non-fixed-output derivation, has the $out path based on a hash of every input
<clever> by default, derivations are not fixed-output
<clever> davidak: https://www.youtube.com/watch?v=8M6yvJC00J4 is the main source ive seen so far
<clever> not really
<clever> chris|: but then multiple non-defaults will concat to eachother
<clever> chris|: the only time its not, is when the service has a default value, any non-default will overwrite it
<clever> chris|: all list options are append by default
<clever> yes
<clever> so you have to set it in the file the error tells you to set it in
<clever> boxscapeR: nix-shell only obeys the main config.nix file
<clever> it sounds like it may be a bug in `nix eval`
<clever> tnks: ls -lh /home/tnks/.nix-defexpr/channels/nixpkgs/
<clever> tnks: ls -lh /home/tnks/.nix-defexpr/channels/nixpkgs
<clever> tnks: NIX_PATH=/home/tnks/.nix-defexpr/channels nix-instantiate --find-file nixpkgs
<clever> tnks: also, does /home/tnks/.nix-defexpr/channels/nixpkgs exist?
<clever> then you can test with things that arent a full nixpkgs
<clever> tnks: it helps a lot to instead use `nix-instantiate --find-file nixpkgs`
<clever> __red__: the history button for that dir reveals this commit deleted things
<clever> > lib.version
<clever> > avrgcc.meta.position
<clever> but you could look at how avrgcc handles things
<clever> ah, dont have that one memorized
<clever> __red__: which microcontroller is are you on?
<clever> > avrgcc
<clever> arianvp: and 5 minutes later, due to a lack of services in dom0, the hypervisor watchdog assumes the world is ending, and forces a hard reset
<clever> arianvp: also, when you nixos-rebuild under xen, and i tries to restart xen services, they fail in weird ways
<clever> arianvp: maybe when updating things in /etc/ can break a running service
<clever> Mic92: delete all the old flags, and document it!
<clever> arianvp: sure
<clever> yeah
<clever> arianvp: havent heard of that
<clever> i want a base nixos install to not have perl in the closure!!
<clever> remove all perl!
<clever> arianvp: :D
<clever> arianvp: same, but i forgot that minor detail
<clever> arianvp: no reload support in this service
<clever> arianvp: ahh
<clever> __red__: thats one way to fix it
<clever> arianvp: ive also been wanting to know, how to make it restart, not stop+start
<clever> emerij: yeah
<clever> emerij: ah
<clever> just give it a clearly wrong hash and read the error
<clever> not really
<clever> so thats the hash of the raw patch, not the cleaned up patch
<clever> nix-prefetch-url doesnt do the cleanup fetchpatch does
<clever> you gave it the hash of something else, with a similar name, and it kept using that file, because you claimed thats what the hash was
<clever> qyliss^work: and if you temporarily make the hash invalid (just change 1 digit) what hash do you get?
<clever> if your using nixos
<clever> just that its a nixpkgs level option, so it has to go under nixpkgs.config
<clever> but its not clear what it does from there
<clever> emerij: its a bool that gets passed into this derivation
<clever> Synthetica: it has to be done in the nix files
<clever> Synthetica: allow port 22 to your deployer, and 80/443 to everyone else
<clever> lol
<clever> > (import <nixpkgs> { config.allowUnfree = false; }).minecraft
<clever> > (import <nixpkgs> { config.allowUnfree = true; }).minecraft
<clever> Synthetica: when you import nixpkgs, set config.allowUnfree = true;
<clever> its an entire package manager
<clever> i have found the android-sdk to work very nicely, on other distro's
<clever> clefru: so its bypassing that
<clever> clefru: internally, ldd is just a bash script, that runs the right ld-linux on the binary, with some env vars set
<clever> patchelf and --set-interpreter have to be ran
<clever> clefru: yep, its /lib64/ld-linux-x86-64.so.2 thats not found
<clever> clefru: what about file on the binary?
<clever> and its half written in nix!
<clever> cant think of anything else that would cause the error you had
<clever> detran: thats a bit strange
<clever> detran: nix-store --verify --check-contents
<clever> detran: wait, exe format error....
<clever> detran: thats a weird one
<clever> what was the exact error it had?
<clever> and then the cryptkey = ...; device becomes useless, so it can be removed
<clever> so the keyFile=..; has to be removed
<clever> if a keyFile is specified in the nix, it wont ask for a password, i think
<clever> yeah
<clever> and any slot can be used to unlock the disk
<clever> each slot can be used by a passphrase or a keyfile
<clever> slot 0 is used on all, and slot 1 on one of them
<clever> your devices have 8 keyslots
<clever> in the output of luksDump
<clever> yep
<clever> yeah
<clever> but you can easily transition to just a normal passphrase on both devices
<clever> nope
<clever> i also refused to do that, and just put lvm on luks
<clever> and just ignore it
<clever> so if you can use that old cryptkey to add a password to both devices, you can then change the nixos config and upgrade
<clever> stage-1 will remember the passphrase you enter, and try it again on all other disks
<clever> thats not needed at all on modern nixos
<clever> ah, you have that messy setup with a cryptkey device
<clever> on nixos, fdisk supports both seamlessly
<clever> gdisk i think, or parted maybe
<clever> detran: your fdisk doesnt support GPT, so the output isnt complete
<clever> detran: https://github.com/cleverca22/nix-tests/blob/master/kexec/justdoit.nix#L58-L74 is how i format the disk, and lines 123-125 is the extra configuration.nix entries it needs to boot
<clever> detran: ive not had any troubles with upgrading and luks
<clever> detran: i use luks on all of my installs now
<clever> __red__: you could also clone it elsewhere, and then symlink foo.nix to your default.nix
<clever> __red__: the hydra server is also a binary cache
<clever> 2018-10-30 20:34:50 < clever> __red__: with import <nixpkgs> { overlays = [ (import ./foo.nix) ]; }; { inherit foo bar baz; }
<clever> and a ;
<clever> __red__: the with is missing

2018-10-30

<clever> thats enough of a release.nix to make it build things from an overlay
<clever> __red__: with import <nixpkgs> { overlays = [ (import ./foo.nix) ]; }; { inherit foo bar baz; }
<clever> and this showed the drv for it
<clever> [clever@amd-nixos:~]$ nix-store -q --deriver /nix/store/a0d6q18gxggcvb5x24nrdg6nvhbnipnb-glibc-2.27
<clever> but in my case, it did nothing, which signaled i already had it
<clever> this let me fetch the same glibc you where fetching
<clever> [clever@amd-nixos:~]$ nix-store -r /nix/store/a0d6q18gxggcvb5x24nrdg6nvhbnipnb-glibc-2.27
<clever> and what it builds first, is what hydra was stuck on
<clever> nix-store ignores all those rules, and just builds whatever hydra was going to build
<clever> thats the same way i check for missing required system features
<clever> just add ,i686-linux to the platforms for the build slave, in the hydra config
<clever> you dont need substituters on to fix this
<clever> https://hydra.iohk.io/queue_summary shows 39 darwin jobs and 20 64-bit-linux jobs
<clever> on the queue, it shows jobs per arch
<clever> hydra should show this
<clever> the system field in the build slave file is a , seperated list
<clever> builder@192.168.2.126 armv6l-linux,armv7l-linux /etc/nixos/keys/distro 1 1 big-parallel
<clever> yes
<clever> Lisanna: do you have any 32bit build slaves?
<clever> Lisanna: thats a 32bit glibc
<clever> then it has to build its own glibc, and cant use the cache
<clever> oh, do you have binary cache support enabled in hydra?
<clever> thats somewhat normal
<clever> Lisanna: what is the name of what it started?
<clever> Lisanna: try again with nix-store -r /nix/store/foo.drv -j 1 -Q, and then ctrl+c it when it starts a build
<clever> Lisanna: yeah
<clever> Lisanna: can you pastebin that whole output?
<clever> Lisanna: if you `nix-store -r /nix/store/foo.drv --dry-run` on that builds drv, what does it say?
<clever> Lisanna: check `journalctl -f -u hydra-queue-runner`
<clever> __red__: and a let block can be used to clean that up if you want to
<clever> Lisanna: looks like hydra needs further patching then
<clever> Lisanna: yeah, it looks like i'm mis-remembering how it handles git stuff
<clever> Lisanna: deep is the oposite of shallow, and it has to do with how much history is left in .git
<clever> Lisanna: deep clone is unrelated to submodules
<clever> Lisanna: oh wait, i think something has changed..
<clever> thats why putting a branch name in the string even works
<clever> without any escaping
<clever> Lisanna: it just blindly passes the entire string from the build inputs config
<clever> writeScriptBin is the one that doesnt
<clever> steveeJ: pretty sure thats the default for writeScript
<clever> Lisanna: all i did in my patch was copy the nixpkgs version of nix-prefetch-git to hydra
<clever> __red__: only if thats a top-level input to hydra
<clever> __red__: that works when your at the nix level, but hydra has a different way of fetching the initial inputs
<clever> Lisanna: yeah
<clever> Lisanna: yep
<clever> Lisanna: you want --fetch-submodules, not deep clone
<clever> Lisanna: try turning that off temporarily
<clever> Lisanna: is any kind of automatic GC setup?
<clever> __red__: every attribute in the derivation is an env var at runtime
<clever> __red__: yeah, just make the buffer 128 bytes too big, thatll be plenty!
<clever> __red__: https://github.com/cleverca22/nixos-configs/blob/master/nas-hydra.nix is an example of how i configured a hydra in my NAS
<clever> __red__: yep
<clever> hyperfekt: you could also do both in the same pr
<clever> hyperfekt: so arbitrary things can be added to the default for all pam services
<clever> hyperfekt: the next best thing would be to add an extraConfig to pam, and include it in that string
<clever> hyperfekt: that file is already full of conditional things, so why not just re-open the pr, but make it optional this time?
<clever> __red__: but if the nixpkgs your applying the overlay to changes, nix will still want to build a new copy
<clever> __red__: you would either need to run your own hydra or use cachix, but then you run into the issue that the cache only works if somebody is on the exact same niiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiixpkgs you built things for
<clever> hyperfekt: whhich file exactly are you trying to modify?
<clever> hyperfekt: you can usually do that by just assigning the right valuuue under security.pam.services
<clever> i dont think the module framework allows refering to the previous value at all, why exactly do you need to do that?
<clever> but not the nixos config itself
<clever> hyperfekt: that will only impact keys under the pkgs tree, when used within nixos modules
<clever> hyperfekt: overlays cant affect nixos options
<clever> romildo: i think ryantm is involved in that
<clever> wirew0rm: yeah
<clever> wirew0rm: what is the eval error?
<clever> wirew0rm: lists behave a bit weirdly, you need to wrap each item with () to make it parse the way your expecting
<clever> Acou_Bass: its more about querying the xorg state before you login, and normal security doesnt let you run arbitrary things then
<clever> and then start things like xrandr or even xterm, and inspect the current config and layout
<clever> if you mess with DISPLAY and XAUTHORITY, you should be able to connect to X from an ssh session
<clever> ah
<clever> by chance, the login is on one of the main monitors
<clever> Acou_Bass: i just never bothered getting it configured right on the login page, and i let xfce fix things after login
<clever> lukego: gummiboot doesnt exist anymore
<clever> lukego: what boot.loader.X.enable=true; is setup?
<clever> ah
<clever> srhb: all of those failures are epyc again, another restart is in order?
<clever> locallycompact: whenever it passes a set of tests
<clever> nix-repl> haskell.packages.ghc861.callHackage "th-desugar" "1.9" {}
<clever> you can try just `:b haskell.lib.doJailbreak pkgs.haskell.packages.ghc861.th-desugar` in the repl, to confirm if thats enough
<clever> that channel last updated 6 days ago
<clever> RyanGlScott: which channel are you on?
<clever> but it was removed 5 days ago
<clever> RyanGlScott: an 861 specific override did exist, to make it ignore the versions in the cabal file
<clever> RyanGlScott: and if you :b it, does it fail?
<clever> though multiple PR's may share some things, its a complex thing when it gets to that scale
<clever> nix caching can help, but if something deep in the dep-chain changes, its a mass mass rebuild
<clever> 1200 jobs, at a rough guess
<clever> etu: https://hydra.iohk.io/project/serokell but, that means every single job (30+) in every open pr (40+ ?) will re-run every time master is pushed to
<clever> with all the normal nix caching
<clever> and if there are any changes in the code, it will re-test everything
<clever> and because hydra is poll based, it will check (and get a new merge commit) each time
<clever> https://github.com/input-output-hk/iohk-ops/blob/master/jobsets/default.nix#L78-L88 just duplicate the code, but use pull/1234/merge instead
<clever> but hydra can be configured to build one or both, and then re-test every time master moves
<clever> so when master changes in a breaking way, you never notice, you merge the pr, and then everyhting breaks :P
<clever> many ci sytems can build both, but they only build the merge comit once
<clever> one is the tip of the pr, the other is a dummy merge commit, simulating what would happen if you where to merge it
<clever> and pull/1234/merge i think
<clever> pull/1234/head
<clever> and reverse to that, only /commit tells you what branches a commit is in
<clever> but /commits does
<clever> one anoying thing, is that /commit doesnt shut status's from CI systems
<clever> and all commits from forks also exist in the parent repo, so you can use either for the owner/repo pair above
<clever> then you could get just a piece of my pr
<clever> Lisanna: you can also https://github.com/<owner>/<repo>/commit/<rev>.patch to get a patch for any rev
<clever> but also, my pr has conflicts, so that patch wont apply to master
<clever> Lisanna: https://github.com/input-output-hk/iohk-ops/blob/master/modules/hydra-fork.nix and insert the rev from the last commit in the PR
<clever> nrNotificationsPending from https://hydra.iohk.io/queue-runner-status
<clever> internally, it keeps a queue of pending notifications, and runs 2 in parallel
<clever> it could still loose notifications
<clever> ah
<clever> its also going to result in a loss of github notifications
<clever> restarting it like that is going to interupt any job that takes over a minute to build, causing them to never finish
<clever> but it may also fix that
<clever> Lisanna: the main goal was to fix cached evals not re-notifying github
<clever> but it has a got conflict with another change that claims to fix the same submodule issue
<clever> Lisanna: https://github.com/NixOS/hydra/pull/597 has that and a number of other fixes
<clever> so just creating a single submodule entry broke hydra and made your project untestable
<clever> Lisanna: there was a seperate bug in hydra's copy of nix-prefetch-git, that caused the entire clone to fail if any submodules existed in the repo, even if your not cloning them

2018-10-28

<clever> i'm going to get some sleep, send me a PM if you get it all working, i'm interested in fpga stuff as well
<clever> jophish: that help much?
<clever> show-backtrace-all-active-cpus(l) and show-task-states(t) can give useful debug
<clever> sync and poweroff give you a sorta cleanish shutdown
<clever> jophish: sysrq + ? would print the help, and confirm the kernel is at least responding
<clever> jophish: if you send a break signal over the serial port (depends on the client), you can trigger sysrq's over the serial
<clever> jophish: oh, sysrq
<clever> jophish: or an activation script
<clever> jophish: yeah, that should be all you need, this example is working: https://github.com/input-output-hk/iohk-ops/blob/master/modules/cardano-service.nix#L178-L190
<clever> jophish: double-checking things
<clever> feep: every attribute in a derivation is an env var
<clever> hyper_ch: then use the date of the commit as a version
<clever> dramforever: yeah, it might be, but the only way to confirm if its enough or not is to try
<clever> feep: you can put the -E string into a .nix file, and then just run nix-build on the file
<clever> feep: this will build the package in nixpkgs, but change the src to come from the current dir
<clever> nix-build -E 'with import <nixpkgs> {}; cataclysm-dda.overrideAttrs (old: { src = ./.; })'
<clever> so its more for short-lived testing binaries
<clever> just keep in mind that nix may break the resulting binaries next time you run a garbage-collection
<clever> then just ./configure and make, as usual
<clever> that will drop you into a shell suitable for building the version in nixpkgs
<clever> feep: nix-shell '<nixpkgs>' -A cataclysm-dda
<clever> oh, if you want to develop it more, you probably want nix-shell initially
<clever> feep: ls -ltrh result/bin/
<clever> hyper_ch: there is also the contributing.md file, and adding it to all-packages.nix
<clever> feep: nix-build '<nixpkgs>' -A cataclysm-dda
<clever> hyper_ch: have you read the nixpkgs manual?
<clever> feep: do you want to install it, modify it, or depend on it?
<clever> /home/clever/nixpkgs/pkgs/tools/backup/duply/default.nix: postPatch = "patchShebangs .";
<clever> feep: run patchShebangs on the dir they are in
<clever> and then nix itself will build max-jobs seperate packages, in parallel
<clever> so if enableParallelBuilding is on, make will obey cores from nix.conf
<clever> cores is also at the make level
<clever> max-jobs is at the nix level
<clever> enableParallelBuilding is for the make level
<clever> there is both make and nix level parallism
<clever> but it needs some more work
<clever> yeah, `nix build` is the newer interface
<clever> feep: there is also `nix-store -l /nix/store/foo` to view the logs of something that has previously passed
<clever> feep: i just use `nix-build` when i want logs
<clever> jophish: you will obviously want a shorter interval, and maybe test it on a working machine first, systemctl list-timers
<clever> jophish: i think that handles the wantedby for you
<clever> 2018-10-28 04:15:27 < clever> Arahael: you can define a custom timer by just setting systemd.services.foo = { script = ''....''; startAt = "nightly"; }; in configuration.nix i believe