2017-05-12

<clever> pulling up a link for the logs
<clever> i think something wasnt working, cant remember what
<clever> dhess: looks like i was helping jophish with it
<clever> 2017-04-24 09:20:52< jophish> clever: /nix/store/2w1iigapdnnpcqsrh0ck86kga9m6qcm8-ghc-8.3/lib/ghc-8.3/bin/ghc: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /nix/store/vjh76sili9y1yq93yyy74ibnsnjyqiax-glibc-2.25-arm-linux-gnueabihf/lib/ld-linux-armhf.so.3, for GNU/Linux 3.2.0, not stripped
<clever> checking my irc logs
<clever> nope
<clever> i cant remember who, but somebody in #nixos was doing that about a month ago
<clever> dhess: so somebody needs to crosscompile an arm ghc to start everything
<clever> dhess: nixpkgs builds ghc by downloading a pre-built ghc for the right platform, and then using it to bootstrap
<clever> what you got?
<clever> none currently
<clever> morning

2017-05-11

<clever> and if storage is your thing: http://b2b.gigabyte.com/Rack-Server/D120-S3G-rev-220#ov
<clever> its much more normal motherboard shaped
<clever> dhess: i havent even found a place that lists a price on the above arm
<clever> so thats 384 cores....
<clever> gchristensen: oh, yeah, damn!
<clever> 8 in total, with 64 ram slots
<clever> dhess: 2U, but it has a crap-ton of thunderx cores
<clever> while x86 and iphone are a lot more standardized
<clever> anybody can make an arm (or android) device, but they are also free to make it a special snowflake of a device
<clever> could compare arm to android
<clever> while the rpi3 is v6/v7/aarch64
<clever> aarch64 only i think?
<clever> but a different arm board may be faster or have more ram
<clever> simpson: so rpi3's in a cluster would give the best arch coverage
<clever> simpson: the rpi2 can run v6 and v7 code, and the rpi3 can do all of v6/v7/aarch64
<clever> simpson: the rpi1 is armv6, so the v7 cache wont help
<clever> dhess: are they in the modules dir?
<clever> yeah
<clever> yeah, not sure why i didnt use them here
<clever> qknight_: dates = "*:00:00"; would be hourly
<clever> qknight_: this tells it to gc every night at midnight, and to stop when it hits 20gig free
<clever> options = ''--max-freed "$((20 * 1024**3 - 1024 * $(df -P -k /nix/store | tail -n 1 | ${pkgs.gawk}/bin/awk '{ print $4 }')))"'';
<clever> automatic = true;dates = "0:00:00";
<clever> nix.gc = {
<clever> set the gc to run more often, and aim for a higher target
<clever> so once it does that, its dead until you manualy start it
<clever> sadly, there is no auto-start
<clever> journalctl -f -u hydra-check-space
<clever> qknight_: how much free disk space?
<clever> looks like the dvi was being reconnected a bit, but nothing error like
<clever> oops, yeah
<clever> it may say more in the "journal -f -u display-manager"
<clever> sounds like a problem with the xorg drivers
<clever> fresheyeball: are you setting ld_librarypath?
<clever> zfs also has some assertions
<clever> yep
<clever> and i know that has an example, because its one of the first things to fail when you make configuration.nix empty
<clever> Infinisil: https://nixos.org/nixos/options.html#grub.de and click on devices, it has a link to grub.nix
<clever> Infinisil: you can probably use assert to throw errors, one sec
<clever> type = lib.types.enum ["a" "b" "c"];
<clever> oops
<clever> type = lib.types ["a" "b" "c"]; if i'm reading it right
<clever> Infinisil: oh, and there is already an enum type pre-written
<clever> and merge handles if several modules try to all set it
<clever> the check attribute will be a function that checks if its valid
<clever> or a direct reference to one of those pre-written types
<clever> Infinisil: the type field must be something similiar to one of these: https://github.com/NixOS/nixpkgs/blob/master/lib/types.nix#L95
<clever> Infinisil: probably using a custom type, let me see
<clever> it had 64mb of read cache(normal ram) on the hdd, and 3 arm cores, so thats a "simple" task
<clever> then he went a little crazy, and ran linux on the hdd
<clever> on the cpu that controls the hdd
<clever> jsgrant_om: he also put malicious firmware into the drive, so he could write a magic string to a file, and it would overwrite /etc/shadow
<clever> the hdd he looked into has 3 arm cores on it
<clever> jsgrant_om: this is also something you may want to read: http://spritesmods.com/?art=hddhack
<clever> but if you hack the hdd firmware, you can probably bypass that
<clever> jsgrant_om: sata drives might have the old ata lock command, that can be accessed via hdparm i think, and some bios may prompt for it before starting the boot
<clever> jsgrant_om: biggest problem, is that the rpi boot rom must load bootcode.bin from the sd card, so it cant boot until a pw has been entered
<clever> jsgrant_om: its not clear, but it may not even encrypt the data, it would be possible to implement it by just turning reads off until a password has been given
<clever> jsgrant_om: thats what the S in SD is for, secure digital
<clever> jsgrant_om: have you heard about how SD cards have onboard crypto?
<clever> maurer: even more fun when its a private gist: https://gist.github.com/cleverca22/43d0576b427fa85ce0efab81e99a84a8
<clever> jsgrant_om: Dezgeg also has a .img for an sdcard he built recently
<clever> jsgrant_om: i believe i ran unstable back in 2016
<clever> sphalerite: slim works for me
<clever> so you cant gc any input or output from that many evals
<clever> qknight_: and hydra will root the entire build-time closure of the last <number of evals to keep>: http://hydra.earthtools.ca/jobset/hydra-example/example-master#tabs-configuration
<clever> qknight_: check latest steps in the hydra gui
<clever> qknight_: what does "journalctl -f -u hydra-queue-runner" say?
<clever> qknight_: you need to configure a build slave
<clever> sphalerite: ah, so logfile is being set twice
<clever> qknight_: you can set it hide on the front page, but it leaks it everywhere
<clever> sphalerite: what do you see in the arguments passed to the running xorg?
<clever> rcschm: "sudo -i" will run a shell as root
<clever> sphalerite: what does nixos-version say?
<clever> rcschm: so you would need to run nix-shell, use the bash functions, then manualy run zsh
<clever> rcschm: part of the issue is that nix-shell pre-loads a large number of bash functions into the shell you get, and those likely wont work right with zsh
<clever> sphalerite: yeah, looks like different config on your end
<clever> nh2: ah, the differing bytes are a simple timestamp: https://nedbatchelder.com/blog/200804/the_structure_of_pyc_files.html
<clever> sphalerite: nixos routed all logs to /dev/null on my instance of nixpkgs
<clever> May 11 01:15:16 amd-nixos display-manager[5116]: (++) Log file: "/dev/null", Time: Thu May 11 01:15:16 2017
<clever> sphalerite: one of the first lines i see
<clever> May 11 01:15:16 amd-nixos display-manager[5116]: X.Org X Server 1.19.3
<clever> sphalerite: ah, it should be in "journalctl -u display-manager'
<clever> sphalerite: what unit did you filter the journal on?
<clever> sphalerite: and in the case of nixos, systemd routes stdout/stderr to the journal by default
<clever> nice
<clever> you could also give it ssh keys to access the git repo you keep configuration.nix stuff in
<clever> then i can just nix-channel --update and nixos-rebuild the usb stick to have an up to date install media
<clever> dtzWill: i tend to keep a full nixos install on a usb stick
<clever> dtzWill: i would expect that to work
<clever> qknight_: that doesnt sound right, can you gist more of the log output, from the start of a clone to the end?
<clever> ah
<clever> nh2: id just try using it, chances are, its the man page thats wrong, not the version
<clever> man pages are broken outside of nixos
<clever> maybe older, not sure how to read the tag thing in github
<clever> it was added in 1.11.9 i think?, 2014
<clever> i cant see it in the man page for 1.11.9
<clever> realpath $(which nix-build)
<clever> nh2: what version does "which nix-build" show?
<clever> qknight_: hmm, what does this say: journalctl -f -u hydra-evaluator
<clever> qknight_: is the hydra gui public?
<clever> hyper_ch: what does "ip -6 addr" and "ip -6 route" say?
<clever> orbekk: yeah, manual git pull/push to sync the machines up and nixos-rebuild
<clever> hyper_ch: that paste was from a nixos 16.03 netboot
<clever> orbekk: so desktop.nix does stuff for my desktop, laptop.nix does my laptop, router.nix does the router, and core.nix covers common things to all of them
<clever> nh2: jan 1st 1970, minus your timezone offset
<clever> orbekk: currently, i have a /etc/nixos/nixcfg in git, configuration.nix just does imports = [ ./nixcfg/laptop.nix ]; and then laptop.nix imports ./core.nix and so on
<clever> ping6 is within iputils on my machine
<clever> lrwxrwxrwx 3 root 1013 70 Dec 31 1969 /run/current-system/sw/bin/ping6 -> /nix/store/d02gqnm3qx5akd4fbcjshf16jqahyqjh-iputils-20121221/bin/ping6
<clever> the router nixos box
<clever> i do similiar, i have radvd running on my nixos box
<clever> sitwon: if your on nixos, you can just services.docker.enable = true; and it runs
<clever> so you can just make a key on the main hydra user
<clever> but hydra just runs nix-pretch-git as the hydra user, to fetch each input
<clever> yeah, its not in the hydra docs
<clever> in that case, you can just run ssh-keygen as the hydra user, not encrypt it, and put an ssh url into the hydra config
<clever> qknight_: if hydra is doing the checkout itself (an input to hydra), then you can just run ssh-keygen as hydra
<clever> qknight_: fetchgit runs in a nix sandbox, so it cant use the stuff on the hydra user
<clever> qknight_: and you need to ensure that the ssh agent is running on the build slave that hydra tries to do the build on
<clever> qknight_: is it a hydra input or a normal fetchgit?
<clever> magneticduck: which sets up symlinks in /etc for every enrivonment.etc entry
<clever> magneticduck: that just runs setup-etc.pl on the etc derivation
<clever> which needs some ssh access from a 2nd box
<clever> tricky question, you really need to strace the runner to see what its trying to read
<clever> for the login to work
<clever> it probably needs the pam modules in /etc/pam.d/
<clever> so youll need to redirect it somewhere or run it over ssh
<clever> the runner script just prints them to stdout/stderr
<clever> they probably went to stdout
<clever> the xorg logs may say
<clever> magneticduck: yeah, its unknown how much of it depends on things being in /etc or /run/current-system
<clever> magneticduck: this attribute will contain a perl script that runs the systemd unit without relying on systemd
<clever> magneticduck: systemd.services.display-manager.runner

2017-05-10

<clever> let me find that old convo
<clever> and half the time, they want to ignore my advice and just install it anyways
<clever> and once you install it, even though the files are in the profile, pkgconfig cant find it
<clever> the last time, it was because a setup hook adds the pkgconfig dirs to the pkgconfig path
<clever> i answer that at least once a week
<clever> yep
<clever> --no-out-link can stop that, or -o libc to rename it
<clever> that will overwrite the result symlink in the current directory
<clever> cant merge a lamda and an attrset with //
<clever> lol
<clever> :)
<clever> yeah
<clever> and then b wont need to exist
<clever> i think if you lack the echo, it will just check 0 files
<clever> nh2: oops, wrong name
<clever> dash: might want to look into that warning also
<clever> Making all in protocol
<clever> /tmp/nix-build-glusterfs-3.10.1.drv-0/glusterfs-3.10.1-runner-log/xlators/storage/posix/src/posix.c:351: warning: lchmod is not implemented and will always fail
<clever> heh
<clever> nope
<clever> and 2, including argv[0], when it isnt, just <dirpath>
<clever> it wants 3, including argv[0], when stdin IS a tty
<clever> oh, that not in the if
<clever> double-checking things
<clever> it asks for 3 arguments when stdin isnt a tty
<clever> testing something on this end
<clever> but if stdin isnt a tty, it wants a <dirpath>, 2 other things it doesnt appear to use, and then takes filepaths on stdin
<clever> if stdin is a tty, it wants a <dirpath> and a <filepath>
<clever> oh no
<clever> and if stdin isnt a tty, it also needs a dir that it will chdir into
<clever> oops, with a space between touch and b
<clever> this returns 0
<clever> mkdir a;touchb;gfid_to_path.py a b
<clever> nh2: harder to use the diff's on a gist when you keep renaming the files
<clever> its not using sed to apply pattern changes
<clever> substituteInPlace is written purely in bash
<clever> yeah, ran the unwrapped one by mistake
<clever> oh wait
<clever> ImportError: No module named xattr
<clever> that explains why i dont remember it having an exclude option
<clever> it was changed to perl at some point
<clever> correction, it was using sed
<clever> except, its running sed on compiled ELF files, lol
<clever> and then run everything to confirm they still work
<clever> it will then use nuke-refs to literaly sed out all storepaths except $out
<clever> so they are still dynamic, but they are missing share and other fat files, and the closure has been flattened down to 1 directory
<clever> and then re-patchelf them to all use $out/lib/
<clever> it will copy every library and executable from a set of inputs to $out
<clever> nh2: this is how nixos does the initrd generation
<clever> it will keep the last working build as active
<clever> and nix will stop and not let you boot with a broken glusterfs
<clever> then hydra cant ship broken builds
<clever> and if they return a non-zero code, the entire build will fail
<clever> nh2: oh something else you can do, just run the python scripts directly in postFixup
<clever> nh2: ive moved most of the deps to the python env
<clever> 18 (python2.withPackages (pkgs: [ pkgs.flask pkgs.requests pkgs.prettytable ]))
<clever> 62 wrapProgram $out/bin/glusterfind --set PYTHONPATH "$(toPythonPath $out)"
<clever> i'm using nix-build so i dont spam grub up with 200 revisions of testing
<clever> ah, because it wants a python library from $out/lib, not from its inputs
<clever> hmmm, glusterfind currently fails with no args, cant import glusterfind.main, checking...
<clever> need a simple way to test them all
<clever> do most of the programs try to load deps even with --help or --version?
<clever> if thats still needed
<clever> so that has to go after the withPackages
<clever> nh2: oh, i think python2 was providing toPythonPath
<clever> Guest89871: both of them will produce the exact same thing when installed to the system, given the same configuration.nix file
<clever> Guest89871: the minimal iso had no xorg, while the graphical iso has kde on startup
<clever> that pythonhome should also entirely eliminate the need to set pythonpath
<clever> removing the duplicate python2 from buildInputs should also fix it
<clever> nh2: and nativeBuildInputs is scanned before buildInputs, thats why it had a higher priority and fixed things
<clever> nh2: and it takes the first python it can find to patch into the #!
<clever> nh2: you have python2 AND python2.withPackages in the buildInputs
<clever> nh2: yep, there it is
<clever> nh2: oh, i think i see the problem
<clever> nh2: and what about the first line of .eventsdash.py-wrapped?

2017-05-09

<clever> ok, i see how its currently working, let me see what i can debug with it
<clever> can you gist the relevant nix expressions and maybe i can look at it?
<clever> when your not doing a crosscompile, the buildInputs will just be silently renamed (and appended to) the nativeBuildInputs
<clever> but if you have a 2nd package that depends on X and other python stuff, it may need to make a new python2.withPackages over [ X other python stuff];
<clever> what i said before will embed the result of $(which python) into the #!, so that gets the wrapper
<clever> you need to embed the paths of things into the final output
<clever> nh2: it helps to keep in mind, buildInputs and propagatedBuildInputs will not just be available in the search path at runtime
<clever> nh2: i dont think it would be able to merge the 2 python wrappers correctly, so it might be better to put python2Packages.flask into the propagatedBuildInputs, in addition to withPackages in the buildInputs
<clever> which you probably dont want/need
<clever> if you put the withPackages into propagatedBuildInputs, then that python will leak into every derivation your package is in the buildInputs of
<clever> which should be the python2.withPackages python
<clever> nh2: this will basicaly replace /usr/bin/env python with the output of $(which python)
<clever> so it might be far simpler to just do that, and ignore pythonpath entirely
<clever> nh2: and patch-shebangs may even swap that python wrapper in for #!/usr/bin/env python
<clever> nh2: i think python2.withPackages would create a python shell wrapper that handles all of PYTHONPATH for you
<clever> toPythonPath might not handle that right, so you would need to loop over its contents
<clever> nh2: the deps of flask are in ${python2Packages.flask}/nix-support/propagated-native-build-inputs
<clever> and freenode just doesnt allow it to keep 200 bots online at once
<clever> it appears to disconnect from irc after the message, i'm guessing it reconnects with a different nick for each project
<clever> that forces you to join the room before you can msg into it
<clever> matthewbauer: the channel is now +n to stop spam
<clever> just link the archive.net version in the issue
<clever> mark-willem: that also looks normal, cant see any reason for it to break shutdown
<clever> garbas: yeah, but the firefox addon wont trigger, because this url doesnt 404, https://nixos.org/wiki/Encrypted_Root_on_NixOS
<clever> garbas: so no 404 to trigger things
<clever> garbas: that sounds great, except the wiki now redirects to a page explaining things
<clever> mark-willem: all looks pretty normal
<clever> mark-willem: can you pastebin the configuration.nix file?
<clever> but it leaves the result from nix-build alone, so i can re-run ./result ./game and it re-patches it
<clever> the game expects the data and binary to be writable for updates, and undoes the patching
<clever> ive used it for self-updating linux games
<clever> sudoreboot[m]: yeah, thats a good place
<clever> sudoreboot[m]: this nix expression will compile into a bash script that can be used to patchelf the binary manualy
<clever> sudoreboot[m]: if you just want to run an ELF file a few times, you can also use https://gist.github.com/cleverca22/8cae5bc9c02c12099a3bf5e20e75161f
<clever> not entirely sure, windows 64bit is a bit weird
<clever> philipp[m]: and the nixos option hardware.opengl.driSupport32Bit gives you 32bit opengl libs, which you may still need for 32bit exe's under wine
<clever> philipp[m]: wine.override { wineBuild = "wineWow"; }; will create a 64bit capable wine build
<clever> same
<clever> strange, it appears that rec has a higher priority then with
<clever> tywkeene: channels are documented some on http://howoldis.herokuapp.com/
<clever> you may also want to update the system to the next stable release channel, 16.09 is a bit old now
<clever> you can delete the nixos channel on the non-root account, and it should still be able to use the nixos on root
<clever> while the nix-env command you gave, uses the nixpkgs-unstable version of google-chrome
<clever> so the nixos-rebuild command as root, use roots version of the 16.09 channel
<clever> tywkeene: and you have a nixpkgs channel on your user, that follows nixpkgs-unstable
<clever> tywkeene: you have 2 copies of the nixos channel (with and without root), that follow nixos-16.09, but on different versions (each user has to nix-channel --update)
<clever> tywkeene: then you have 3 different channels on your system
<clever> tywkeene: what does "nix-channel --list" say?
<clever> that at least needs a valid github account, which will cut down on some of the spam
<clever> it had spam problems, and after going read-only, it suffered from being more wrong as time went on
<clever> the wiki was just put out of its misery today
<clever> tywkeene: testing the 16.09 version of google-chrome now
<clever> the nixos-unstable channel is the latest you can safely use
<clever> yeah
<clever> what does "sudo nix-channel --list" say?
<clever> which channel are you on?
<clever> but i got .133, while you where getting .110
<clever> it downloaded just fine
<clever> i'm building google-chrome on this end now
<clever> ah