2016-12-01

<clever> bigvalen: nix-shell -p androidenv.platformTools
<clever> bigvalen: one sec
<clever> avn: i booted the wrong disk, and didnt even notice
<clever> avn: heh, nix is pretty resilient, it just recovered from the hdd nearly being wiped, only /boot and /nix remained
<clever> i had to strace xorg just to see those logs
<clever> avn: and it prints the logs saying so, to the open file handle for logging
<clever> avn: so when i plug the keyboard in, it actively ignores it, thinking its already registered
<clever> avn: there is a race condition within xorg, where it thinks a usb keyboard is connected, but it isnt
<clever> avn: i think i also ran into a situation where the file logging was of use
<clever> avn: and with the file set to /dev/null, its lost forever
<clever> avn: ive heard that there are some things xorg only logs to the file, and doesnt log to stdout/err

2016-11-30

<clever> yeah, the store prevents that issue from happening entirely
<clever> x wont compile because y is installed, and y wont compile because it isnt compatible with the old x
<clever> and it sometimes leaves a mess behind in places like /usr, and updates become a pain
<clever> gentoo just compiles everything from source
<clever> its still faster then gentoo~
<clever> dsaa: then it has been ignoring every single change youve made to that file
<clever> dsaa: did you run "nixos-rebuild switch" after editing configuration.nix?
<clever> dsaa: by inspecting the output of lspci
<clever> dsaa: what does "systemctl status display-manager" say?
<clever> dsaa: did you also services.xserver.enable = true; ?
<clever> i usualy go with slim and xfce, but the example is kdm and kde
<clever> it already has examples in the default file
<clever> enable a window manager in configuration.nix
<clever> viric: the armv7 builds of the rpi kernel default to multiplatform, and dont even boot on an rpi3, but ive now got it partialy booting
<clever> viric: i think i'm making progress on the rpi and possibly your seccomp issues
<clever> Sonarpulse: and those can be glitchy
<clever> Sonarpulse: some cell providers force an http cache/proxy into your link
<clever> gchristensen: nice
<clever> Sonarpulse: thats normal, look at the url field after you "curl cache.nixos.org/2fnz2p0psjkjs8fkfk87pv2l7px20i45.narinfo"
<clever> try testing it on another pc if you can
<clever> mckeankylej: it should just work the instant you plug it in
<clever> mckeankylej: usb, ps2?
<clever> and it should automaticaly remove the routes as well
<clever> i think you can just "ip addr del <address> dev <eth0>"
<clever> and with accept_ra set to 0, it wont return
<clever> you can force it early by using "ip addr del" or just bringing the link down and back up
<clever> in my case, it would take 86,396 seconds before the ipv6 addr expires on its own and gets removed
<clever> valid_lft 86396sec preferred_lft 14396sec
<clever> double-check "ip addr" to see if you have a v6 addr or not
<clever> i was using that to disable ipv6 in my tablet, but to disable it in a normal linux machine, just: echo 0 > /proc/sys/net/ipv6/conf/wlan0/accept_ra
<clever> you can omit that part on if you can obtain a root shell normally
<clever> and its only to remotely run it on an android device
<clever> androidenv.platformTools
<clever> so i use the above adb command to neuter ipv6 support in my tablet
<clever> netflix thinks i'm trying to pirate content, and just shuts off entirely
<clever> but geolocation my v6 says american
<clever> in my case, i'm using an ipv6 tunnel, so geolocation my v4 says canadian
<clever> and when linux gets one, it will automaticaly add the IP
<clever> in most setups, the router is sending out route advertisement packets
<clever> i typicaly use a command like this, and then cycle the network link
<clever> adb shell su -c 'echo 0 > /proc/sys/net/ipv6/conf/wlan0/accept_ra'
<clever> ah
<clever> how did you disable ipv6?
<clever> once you form the connection, its stuck on the protocol&ip it used, so ipv6 can turn back on without breaking it
<clever> where you watching my monitor? lol
<clever> Resolving cache.nixos.org (cache.nixos.org)... 2600:9000:201a:6a00:10:dfa4:b0c0:93a1, 2600:9000:201a:9600:10:dfa4:b0c0:93a1, 2600:9000:201a:7e00:10:dfa4:b0c0:93a1, ...
<clever> and yes
<clever> do "curl cache.nixos.org/2fnz2p0psjkjs8fkfk87pv2l7px20i45.narinfo" (the hash from the storepath)
<clever> Sonarpulse: downloads just fine on this end, when i do it manually
<clever> Dezgeg: and nixos gives no way to set the platform when it loads nixpkgs internaly, so PR incoming: https://gist.github.com/cleverca22/51853ca303d7e222ec1fcd6f43adaf68
<clever> Dezgeg: found a potential solution, you must import <nixpkgs> { platform = platforms.raspberrypi2; }; (or change the default for v7 and break every other v7 platform)
<clever> Sonarpulse: what error are you getting?
<clever> gchristensen: the login attempt is on tty2 i think
<clever> gchristensen: without more info on how exactly that host is messing up, it may be imposible to reproduce, but we can reasonably assume it was timing, and that vcs2 checks will solve it
<clever> viric_: oh, and i see something related to your systemd issues too
<clever> viric_, Dezgeg: got around to confirming it and bingo: ("kernelBaseConfig","multi_v7_defconfig")
<clever> but if gtk2 ever gets deleted, it will silently build without gtk2, rather then failing
<clever> so it currently only serves as a hint to people reading the source
<clever> so you would need to use an override to force gtk2 to null
<clever> but callPackage will always supply it
<clever> sorta, it allows gtk2 to default to null if its not supplied
<clever> glines: i got 4 or 5 rows from sparkfun in one of my last orders, and thats plenty for now
<clever> glines: also, my soldering is so rusty, i got a cold joint on my raspberry pi, and managed to drip a huge glob of solder directly onto the decoupling caps under the cpu, the caps the size of a grain of sand :P
<clever> glines: first thing i did was put some header pins on it, so i could use it without too much soldering
<clever> :D
<clever> and nix-shell needs the bash functions to convert buildInputs into $PATH
<clever> unpackPhase and configurePhase are 2 i can see being usefull
<clever> rardiol: but you can just manualy run zsh under nix-shell (and loose access to those functions)
<clever> rardiol: it needs to source a large number of scripts that define bash functions, that wont like a different shell
<clever> one path to rule them all!
<clever> ah
<clever> then nix could detect the rpath
<clever> looks like jar 0uvf $out/${jar} ${file} would disable compression for that 1 entry
<clever> it wont get that much until it asks for it
<clever> so it can prevent the thing your worried about
<clever> i believe the special driver in my mobo, was to detect when a device asks for more current, and cranks up the current limits in the hardware
<clever> yeah
<clever> the voltage regulation prevents such issues, when its not shorted
<clever> amps dont work like that
<clever> the above bluescreen, turns out to be a combination of the high power usb charging driver in my mobo, the teensy, and a hub between the pc and teensy
<clever> glines: it scans the contents of $out when the build is finished, and the compression in the jar can mask the paths
<clever> avn: jar's can be made with zero compression, that would let nix find things still, and some stuff like android requires it (it just mmap's the files without unpacking)
<clever> glines: then furniture got moved, and it needed to be on a usb extension, so i plugged it into a 1 port hub (an extension with a hub in it), and bam, blue screen of death!!
<clever> glines: so i just leave the teensy plugged in 24/7 and it works fine!
<clever> glines: but, the teensy claims to be a mouse with a wheel!
<clever> and goes nuts when it gets a wheel event
<clever> the game detected, that no wheeled mouse is present at startup
<clever> glines: and i discovered, certain games go nuts when i hit the mouse wheel
<clever> glines: at one point, i was controlling said windows machine purely thru synergy (windows/keyboard sharing software), so it had no mouse/keyboard plugged in
<clever> glines: slap a pair of https://www.sparkfun.com/products/9179 onto it, and now you can watch stuff with your hands full
<clever> which mapped to pause and rewind in VLC
<clever> i had programmed it so 1 button was space bar, and the other was alt+left arrow
<clever> i also just remembered another weird bug the teensy has caused, back when i ran windows
<clever> the teensy can emulate a usb keyboard, and could be programmed to just spam the same events
<clever> which was going to a different system
<clever> and i swear, the bloody thing is watching me on the webcam, one day, it recovered after i unplugged the charger for my headset
<clever> at which point i have to move the keyboard back :P
<clever> and if i unplug a usb keyboard to better control my laptop, it recovers
<clever> i have an extremely weird bug with my filesystem, it constantly locks up under high IO load
<clever> i was also just thinking of installing the teensy stuff on this end today
<clever> nix will automaticaly trim out entries that arent needed
<clever> its also simpler to just have a single rpath you set on all of the binaries
<clever> and that can be done in many places
<clever> rather then making it an env variable and leaving it up to bash
<clever> then nix will substitute the variable for a string at eval time
<clever> glines: i would move teensyloader_libpath into a let block, and use ${teensyloader_libpath}
<clever> can you gist the nix expression?
<clever> glines: and patchelf --print-rpath says?
<clever> glines: is that a 32 or 64bit program in the teensy file?
<clever> viric_: are you able to "modprobe configs" ?

2016-11-29

<clever> gchristensen: oh god, and load avg!! http://ext.earthtools.ca/export/graph_270.html
<clever> it pulls enough watts that my UPS overload alarm goes off
<clever> and cpu
<clever> gchristensen: and look at what chrome has done to my swap: http://ext.earthtools.ca/export/graph_269.html
<clever> thats perfect, lol
<clever> whoa
<clever> gchristensen: even with a load average of 50 on my desktop, the test passed
<clever> it must have been swap on the slaves?
<clever> gchristensen: lol, even with a load average of 50, the test passed
<clever> load average is 50!
<clever> mouse is stuttering on the host, thats a good sign
<clever> gchristensen: ah, its enough to stop all active vbox guests, the drivers dont have to be unloaded
<clever> simplest thing, just compile a c program with while(true) {} and spawn 2 or 3 times as many cores you have
<clever> so i know all kinds of odd corners that nobody has ever seen
<clever> vcs1 was in one of them
<clever> gchristensen: i think this is a result of being overly bored when i first got into linux, i just read every man page i could find :P
<clever> gchristensen: i think virtualbox is conflicting?
<clever> machine# ioctl(KVM_CREATE_VM) failed: 16 Device or resource busy
<clever> 50% of my swap is already in use
<clever> i'm redoing that test locally, and i'm doing nixos-install under virtualbox, and chromium is resuming
<clever> and i just noticed how crazily i'm taxing tthis box right now
<clever> and any characters you type before that, go to the stdin buffer, which login doesnt read
<clever> to bypass any potential redirects (sudo also does this, allowing echo | sudo tee)
<clever> and as for the exact cause of the problem on "login"'s side, it opens /dev/tty for reading
<clever> so in theory, you can modify the testcase to wait for the password prompt
<clever> but linux clears the scrollback when you change tty
<clever> i think that special node also includes the scrollback history
<clever> it doesnt not look to see what the result is
<clever> the problem, is that it waits for a "login" process, then waits 2 seconds for a password prompt
<clever> all tty's have one
<clever> gchristensen: /dev/vcs1 is a raw text dump of tty1
<clever> gchristensen: oh, and i just had an idea for something that can make the test more robust
<clever> i can already see it on the realtime graphs
<clever> oops, opened chromium
<clever> avn: i just opened cacti, and the cpu is pulling so many watts that the UPS has gone into overload
<clever> i have trouble closing tabs, over 800 are open.....
<clever> do i dare open it while testing? lol
<clever> i have a chrome profile that can max out my cpu for 40 minutes on startup and pushes over 40gig of data thru swap
<clever> because your not taxing the machine very hard
<clever> gchristensen: this comment implies that it has had issues before: https://github.com/NixOS/nixpkgs/blob/master/nixos/tests/login.nix#L39-L40
<clever> trying to reproduce it locally
<clever> that has some more details like exact timestamps of each step
<clever> i usualy also have access to the journal when debuging these things on my end
<clever> implying that maybe the 16.09-small job was restarted, and failed a second time
<clever> but the 16.09-small job says it tried again on kyle, and failed again
<clever> but i do see something odd, the 16.09 job is referencing the failure on lucifer
<clever> the "finished at" field on both
<clever> you asked for the rebuild at 9:52, doesnt seem to line up with timestamps on either
<clever> hydra assumes the failures are consistant, and wont try again
<clever> you have to force a restart of that build to make it try again
<clever> yeah
<clever> it knows its already bad and wont waste resources trying again
<clever> that exact derivation failed in a different jobset
<clever> Failed (log, raw, tail) (propagated from build 44215841)
<clever> bash never gets started under the user alice
<clever> gchristensen: reading the logs, it appears to be getting stuck after entering the password
<clever> so the non-small jobset just skipped it
<clever> looks like release-16.09 hasnt even tried it, release-16.09-small already did the exact same derivation and failed
<clever> but you cant view the logs of when it failed, it picks the newest instance of that step
<clever> and show the step twice under build steps
<clever> gchristensen: if you restart a failed one, it should reuse the id
<clever> and its entirely not in the chroot
<clever> adnelson: and only root has write perms
<clever> adnelson: nix will try to open it in a read/write mode by default, so it can obtain the proper locks and prevent concurent modification
<clever> the /nix/var/nix/db/db.sqlite is also not available under most builds
<clever> its disabled by default, but the hydra slaves all have chroot enabled
<clever> under arch, its not configured fully, and your user can just write to the store directly without having to use a daemon
<clever> normally, they contact a nix-daemon running as root, that does the job for them
<clever> it tells non-root users that lack write permissions to /nix/store how to gain write
<clever> if you lack build users entirely, then nix-store works without any fuss, because the builder can just open the db
<clever> if the chroot is turned off, you can just NIX_REMOTE=daemon nix-store --query
<clever> adnelson: see also: https://github.com/NixOS/nix/issues/1134
<clever> i think the command for that just reads the entire directory, so not better then the existing stuff
<clever> ah, there is no way to access the db or daemon when sandboxes are enabled
<clever> adnelson: what kind of information on which paths?
<clever> but*
<clever> LnL: bug yeah, if the hook wasnt set, and then gets added, nix-daemon will need a restart
<clever> LnL: the existing build hook will check that file on startup
<clever> LnL: i think nix will read /etc/nix/machines at the start of each job, so it never has to restart
<clever> alex9222: heh, dueling issues? lol
<clever> domenkozar: opened an issue for anybody that knows more about kexec
<clever> domenkozar: http://imgur.com/a/HKuk4 any idea?
<clever> kexec -p is failing, relocation errors
<clever> and "kexec -e" says nothing has been loaded, hmmm
<clever> yeah, it just isnt running the crashdump kernel at all
<clever> domenkozar: it does reserve the correct amount of memory, but x is interfering, trying without x
<clever> testing under qemu to confirm it still works fully
<clever> domenkozar: https://github.com/NixOS/nixpkgs/commit/a04a7272aa38ada45e694281071b720d4abbd0df and this type of commit implies less testing was done
<clever> domenkozar: it does evaluate if i delete the type and make it match the main kernelPackages
<clever> domenkozar: wait, pkgs.linuxPackages is an attrset, not a package
<clever> domenkozar: the funny thing is that i havent touched boot.crashDump.kernelPackages, and it has a sane default
<clever> while evaluating the option `boot.crashDump.kernelPackages':
<clever> joko: i'm guessing it is, dont see a daemon.conf in there
<clever> fpletz: your welcome :)
<clever> joko: hardware.pulseaudio.extraConfig
<clever> i thought i saw something like that recently, heh
<clever> FRidh: try nix-store --add-fixed sha512 ?
<clever> domenkozar: this would be a good PR to test the hydra stuff on, since its changing an artifact under nixos/release.nix, rather then nixpkgs, so travis likely wont know what to do
<clever> gchristensen: and PR is open!
<clever> gchristensen: and it now has nearly the identical unionfs that the ISO's have, PR incoming!
<clever> the store on the host is read-only, so this fails hard
<clever> gchristensen: has nix-store --check-validity always wanted to create /nix/store/.links?
<clever> and in other netboot adventures, nixos is mounting a tmpfs over /mnt-root, and covering up the squashfs mount point
<clever> there is a header on the rpi for a reset button, and with it network booting, i can fully generate every single file from nix-build
<clever> arcade*
<clever> Dezgeg: i have it fully network booting, so i can just run nix-build on the router, and punch a large arcane button to test it
<clever> Dezgeg: i'm testing on an rpi3 at the moment
<clever> Dezgeg: sounds likely
<clever> Dezgeg: and when i checked the config nixpkgs was generating, it had some device-tree options wrong, and was compiled for any arm chip
<clever> Dezgeg: ah, ive been unable to get any kernel from nixpkgs to boot
<clever> Dezgeg: when is the last time you tried booting a rpi from nixos-unstable?
<clever> and it looks like the netboot image i mentioned is criticaly broken, /nix/store is read-only, and nix-store --check-validity within nixos-install wants to create /nix/store/.links/
<clever> oh
<clever> and it will insert the mac of the 0th NIC
<clever> Zvieratko: with ipxe, you can just insert ${net0/mac} into almost any command i believe
<clever> Zvieratko: ah
<clever> Zvieratko: and with 2gig of ram, it can boot
<clever> Zvieratko: http://pastebin.com/nnQL4u29
<clever> Zvieratko: heh, 300mb initrd, with 256mb of ram, *doh*
<clever> Zvieratko: aha, the vbox ipxe has an empty version string, my build has a version of 1.0.0+
<clever> trying to minimize how much i change in the ipxe file provided by nixos
<clever> so it doesnt make an infinite loop
<clever> i already have ipxe on my tftp, i just need to chainload ipxe conditionaly
<clever> heh
<clever> Zvieratko: this should be fun...
<clever> Zvieratko: dang, the ipxe embeded into virtualbox lacks bzImage support!
<clever> Zvieratko: ah
<clever> Zvieratko: the syntax reminds me a bit of asp, but its probably just some basic turing complete substitution
<clever> Zvieratko: and i have a custom nixos module that can mount the rootfs over iscsi
<clever> Zvieratko: and i'm using a mix of both on my laptop, ipxe hijacks the legacy bios hdd api, so grub thinks the iscsi device is a local drive
<clever> Zvieratko: heh, i found ipxe simpler then grub on this end
<clever> Zvieratko: ipxe and my bios havent had that issue
<clever> Zvieratko: i also have a raspberry pi that claims to be PXE booting, but it ignores the next-server field in dhcp, and tries to tftp the dhcp host
<clever> Zvieratko: ah, so it would probably spin up its own vm's on-demand
<clever> Zvieratko: do you happen to know of any simple tools to simulate a datacenter, or should i just spin up a dozen virtualbox instances?
<clever> so its just a matter of being able to configure it from software
<clever> Zvieratko: in nix, its pretty simple to put an entire OS into the initrd
<clever> but kexec would run from the initrd, so nothing is mounted
<clever> nixos-in-place is limited to whatever partitions are existing
<clever> so i could run that kexec thing on any cloud provider, and hijack the machine
<clever> the kexec is more for when you have an existing OS you dont want, and lack control of the boot process
<clever> ah, so id just make a nixos image that can netboot, and fetch config from foreman
<clever> a kexec-able nixos installer image
<clever> and that reminds me, another idea ive had
<clever> yeah, it does sound like something i would want to add support for in nixos-installer
<clever> much simpler, since its just a dummy to allow booting different images
<clever> here is my current boot.php: http://pastebin.com/mgGYdefM
<clever> then spit out the ipxe script that refers to the newly made file
<clever> in theory, the php code could generate a new initrd (concat the base, and config), while stalling
<clever> Zvieratko: this is part of my dhcp config, it tells ipxe to fetch its config file over http, and to embed its mac addr into the query
<clever> Zvieratko: filename "http://c2d.localnet/boot.php?mac=';'${net0/mac}&asset=''${asset:uristring}";
<clever> you could just use a bash script that fdisks's /dev/sda, formats, mounts, copies configuration.nix in, and runs nixos-install
<clever> so you then partition and nixos-install as normal
<clever> that basicaly gives you the same env as if you had booted from a CD
<clever> Zvieratko: nixos has something similar, one sec
<clever> heh, didnt think they could get that small, but i am working on a ~40mb nixos installer image
<clever> the /boot on my NAS is <64mb
<clever> heh
<clever> i was able to update it to nixos 32bit, and then with a few more tweaks, 64bit-ize it
<clever> Zvieratko: in my case, all it had left was a nix-build copy from 2015 and a few shreds of init.d that could still boot
<clever> the second time, i was on the road, and all i had was half a gentoo system (most of it had been mv'd out to the NAS, and i didnt have time to finish)
<clever> Zvieratko: the first time i did it, was as an experiment, and because i cant put a cd drive into my netbook, lol
<clever> i just ran the nix-build command above, and then forced it to update the MBR and keep using the same rootfs
<clever> without booting install media or repartitioning
<clever> on related subjects, i have also made nixos consume a gentoo install twice
<clever> complete with grub in the MBR of the iSCSI device
<clever> Zvieratko: i do have my laptop booting over iSCSI as we speak
<clever> the above command would build a given configuration.nix file, so its already present in /nix/store for later use
<clever> things go smoother if the host is also nixos, using another distro isnt officialy supported