<clever>
pie_: `nixos-rebuild --install-bootloader switch` will force it to reinstall grub
<clever>
pie_: if that file doesnt agree with the current config when doing switch, it will reinstall grub
<clever>
pie_: this file contains the version of grub, and some critical cfg flags
<clever>
[root@amd-nixos:~]# cat /boot/grub/state
<clever>
pie_: one sec
<clever>
pie_: one min, something came up
<clever>
pie_: ?
<clever>
(warning, it prints binary to stdout)
<clever>
tilpner: you can do the same thing with `nix-store --dump /nix/store/foo`
<clever>
tilpner: i believe it does
<clever>
tilpner: but that still has the cost (IO and disk usage) that its going to duplicate the entire thing (21gig in matt`'s case), even if /nix/store already had it
<clever>
tilpner: then based on the hash, rename it to /nix/store/hash-name
<clever>
tilpner: one sink that hashes, the other that re-unpacks it to /nix/store/temp
<clever>
tilpner: one thought i had, is to make a source, that emits ./. as a nar, then run it thru a tee type class, which writes it to a pair of sinks
<clever>
but that still has the memory usage problems
<clever>
so it only pays that once once
<clever>
my solution was to switch it to requireFile, and then add it with nix-store --add-fixed
<clever>
tilpner: ive done data processing before with nix, with ~3gig of input files, and ./foo causes the eval to hang for 30+ seconds each time, as it re-hashes it in ram
<clever>
tilpner: yeah, ./foo is always a performance cost
<clever>
tilpner: should be possible, similar things have been done for the nix-copy-closure api already
<clever>
matt`: worst case, it could need 61gig of ram+swap
<clever>
matt`: i believe nix needs 2 or 3 std::string's, each holding the entire 21gig tar
2019-07-23
<clever>
Thra11: can you paste some logs, like when nix says "will download X and build Y" ?
<clever>
nix-store -qR
<clever>
then it has to always download it, even after its built
<clever>
Thra11: you may also want to double-check that your not depending on something at runtime
<clever>
then copy the already built product back
<clever>
then (try to) copy those deps to the slave
<clever>
if your build slave is not a cache, it will fetch the deps for a thing the slave already built
<clever>
then, in the reverse order (deps first), it will build them (possibly on a build slave)
<clever>
and once that phase is done, it will tell you what its fetching from a cache, and what it wants to build
<clever>
if it cant find that, it will (recursively) check the deps of it
<clever>
Thra11: basically, it will start at the thing you want to build, and check for it on caches
<clever>
Thra11: if its configured as a cache (not just a build slave), yeah, it can skip ahead
<clever>
and it doesnt know it will be copying it back up to that machine yet
<clever>
Thra11: it may also be trying to build the fixed-output drv, on the slave
<clever>
Thra11: nix doesnt know what the remote machine has, or even which remote machine its going to use, until after it has fetched all of the inputs
<clever>
Thra11: nix needs the deps locally before going out to a build slave
<clever>
Thra11: if i go under 3gig free, it will run nix-collect-garbage --max-freed automatically, targeting 6gig free
<clever>
fresheyeball: try running memtest on the machine
<clever>
fresheyeball: i think it had a kernel-side segfault, while in a segfault handler
<clever>
fresheyeball: need to sign in to see it
<clever>
selfsymmetric-mu: the new `nix` command will sort of do it, but uses \r to overwrite the line every time a line is printed
<clever>
selfsymmetric-mu: mostly not implemented
<clever>
fresheyeball: did it print more error?
<clever>
selfsymmetric-mu: dont think thats possible, but you can run `nix-store -l /nix/store/foo` to dump the logs for something after the fact
<clever>
fresheyeball: ctrl+alt+f1
<clever>
fresheyeball: not sure, if you repeat things from a text console, what happens?
<clever>
fresheyeball: how much ram on the machine?
<clever>
nilsirl[m]: cant remember what i was doing to fix it
<clever>
nilsirl[m]: that breaks cc-wrapper
<clever>
nilsirl[m]: scons has some "handy" utils to make the build env pure, and unsets all env vars it doesnt understand
<clever>
pbb: you should also be able to do several on one line
<clever>
pbb: it can use callPackage and import ../.. {} to load the nixpkgs its sitting inside
<clever>
pbb: ${toString ./.} gets you the dir the nix file was in
<clever>
pbb: you can then use buildInputs to get whatever you need (purely) and shellHook to run things impurely, and `exit 0` at the end to stop the shell from actually opening
<clever>
pbb: i like having update.nix files with a shellHook, where you just run `nix-shell update.nix`
<clever>
pbb: nix-shell and nix-build could even share intermediate products!
<clever>
pbb: then if foo.c matches a previously built thing, it builds instantly
<clever>
pbb: what if gcc was replaced with a shell script, that would pre-process the c code, and remove all comments (like ccache), then it just did `nix-build gcc.nix --arg source ./foo.c`
<clever>
pbb: another thing recursive nix can give you is a ccache replacement
<clever>
vaibhavsagar: not sure what the original issue was then, enless your overlays are messing with lib
<clever>
vaibhavsagar: that one is broken by the syntax error, but the overlays shouldnt impact other things, so it may be a false alarm, purify it and then see what happens next
<clever>
vaibhavsagar: ah yeah, your `inherit (import <nixpkgs>{}) lib;`
<clever>
vaibhavsagar: try the syntax error then, to see how its leaking in
<clever>
vaibhavsagar: is it an overlay, or config.nix ?
<clever>
vaibhavsagar: i would expect that to work, try putting a syntax error in an overlay from ~/.config/nixpkgs and then paste me the error it gives
<clever>
vaibhavsagar: at every place you import nixpkgs?
<clever>
copying path '/nix/store/dsh6szwrs21qv26p03y3wdyqhss1lwdc-pandoc-2.7.3' from 'http://nas.localnet:8081'...
<clever>
[clever@amd-nixos:~/apps/nixpkgs-master]$ nix-build -A pandoc
<clever>
samueldr: pkgs.pandoc?
<clever>
samueldr: oops, ^^^
<clever>
symphorien: justStaticExecutables makes things not depend on ghc
<clever>
network namespaces cant be joined as easily
<clever>
symphorien: i think tthats part of what android is using
<clever>
but its also always the default gateway
<clever>
and at no point do you get root, so you can run any vpn you want on android, securely
<clever>
then you just read packets from that /dev/tun handle, and write them out the FD# you specially flagged
<clever>
and the OS will specially flag it to ignore the default route, which goes into the /dev/tun handle you are given
<clever>
the android vpn interface, requires that you run a special function on the FD# for the upstream connection
<clever>
gchristensen: so you can have several sets of routes, and multiple default gateways, then flag a socket to use a certain one
<clever>
gchristensen: there is also a kernel feature android uses, but ive not looked into yet, it can support multiple routing tables
<clever>
gchristensen: wireguard would need to dynamically figure out the remote ip, and add a route entry at runtime, to ensure it still goes via the gateway
<clever>
wg*
<clever>
gchristensen: the main prolem is adding a route override, to force the wg peer to not go over wf
<clever>
gchristensen: yep, havent done much with changing the default route
<clever>
gchristensen: i need to go over your wireguard changes, and update tgt_service, it has similar bugs to what your wireguard recently had (which got fixed)
<clever>
nh2: it should also be possible to use a dynamic ghc for Setup but a static one for building, like the cross-compile stuff
<clever>
nh2++
<clever>
Netsu: can you pastebin the nix exprs?
<clever>
Netsu: if you make a $out/home/foo and add it to the contents of the docker image, it will wind up in /home/foo
<clever>
Netsu: for example?
<clever>
repeat
<clever>
then i open another 10 tabs
<clever>
then i run out of time and leave it for later
<clever>
DigitalKiwi: because i dont want to save X forever, i want to read it and close it
<clever>
DigitalKiwi: a plugin called vimium. T will let you search by the title of tabs
<clever>
nh2: 2092 open right now
<clever>
nh2: i have 32gig of ram, 64gig of swap, and i'm running out of both
<clever>
nh2: youll also inherit my in-ability to close tabs
<clever>
nh2: i dont know how i discovered that option, lol
<clever>
nh2: this line of code will either run $curPhase (a bash function by the name in the var), or eval $curPhase, (a bash var, named after the contents of a bash var)
<clever>
nh2: nix-shell should source setup.sh for you
<clever>
gyroninja__: if using the initial stuff, you need to delete the old qemu disk image in the dir you launched it from
<clever>
gyroninja__: you must set a password in the configuration.nix file, either with non-mutable users, or initial(hashed)password
<clever>
nh2: you can also do `phases="compileBuildDriver" genericBuild` to run just one phase
<clever>
nh2: and compileBuildDriverPhase has newlines in it, `eval $compileBuildDriverPhase` strips all of them and ruins it
<clever>
nh2: runHook is part of setup.sh
<clever>
nh2: when i nix-shell into .env, i typically do `cabal configure ; cabal build`, and since cabal-install isnt present, i replace cabal with `runhaskell Setup.hs`, nixpkgs builds it with normal ghc though
<clever>
nh2: what is the exact error? which package is it?
<clever>
nh2: if the build fails under normal nix-shell, then you can also use unpackPhase to make the source, and then just `runhaskell Setup.hs configure` then build
<clever>
nh2: you need to figure out the right attrpath in the nixexpr that made it, and add .env to the end, and shell into that
<clever>
nh2: nix-shell on the .drv wont give a usable shell, ive not yet looked into why
<clever>
ivan: there isnt much point in having a localhost nix-serve in the binary cache list, so i would just try to remove that
<clever>
and `sudo rm -rf ~/.cache/nix/binary-cache*` wont delete it from roots home
<clever>
ivan: you may need to delete that file on other users too
<clever>
ivan: as root, run `rm -rf ~/.cache/nix/binary-cache*` to make it forget
<clever>
ivan: and a GC will hard-break things
<clever>
ivan: once nix discovers that a binary cache has something, it will assume it still has it for up to 30 days
<clever>
ivan: is that nix-serve? was garbage collection ran?
<clever>
tA-: yeah, display-manager.service
<clever>
tA-: { pkgs, lib, ... }:
<clever>
iqubic: firewalls on each machine can slow it down
<clever>
iqubic: this will take 52 mins to complete, go find some popcorn
<clever>
tA-: im using xfce, and i think if i turn off the effects stuff, the tearing goes away, but i also loose the window preview during alt+tab
<clever>
0so you want `nmap -Pn 10.0.0.0/24`
<clever>
iqubic: your on 10.0.0.0
<clever>
nothing exists on 192.168.1.0
<clever>
iqubic: you scanned the wrong network
<clever>
iqubic: and what nmap command did you run?
<clever>
iqubic: if you login and find the WAN settings, what do they say?
<clever>
iqubic: the general status page to start with
<clever>
iqubic: and what does a screenshot of the router status page say?
<clever>
iqubic: what is the output of `ifconfig` and the nmap command you ran?
<clever>
i find enter does it
<clever>
ajs124: at least your not printing pdf's to pdf
<clever>
gchristensen: i can now google cloud-print (bypassing cups entirely) from anywhere, and it comes out of his printer, despite the fact that he ran off with it :P
<clever>
gchristensen: my dad found a used printer/scanner at a yard sale, and the http server within it let me link it to a google account
2019-07-20
<clever>
iqubic: what does `file` say when ran on it?
<clever>
infinisil: yeah
<clever>
its a thunk, that will load&parse the given file later
<clever>
`set = import ./foo.nix` for ex
<clever>
infinisil: builtins.attrNames would force all the keys at once, before returning the names
<clever>
infinisil: but the entire attrset could have been a thunk
<clever>
and the screensaver daemon is responsible for knowing when all blocks have been cleared, and managing the `xset dpms` level switch
<clever>
every time i (un)pause a youtube video, it tries to talk to the screensaver over dbus, to block dpms
<clever>
karetsu: i also notice this in my chromium stderr
<clever>
[5628:6057:0720/162027.676438:ERROR:object_proxy.cc(619)] Failed to call method: org.freedesktop.ScreenSaver.UnInhibit: object_path= /org/freedesktop/ScreenSaver: org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.ScreenSaver was not provided by any .service files
<clever>
karetsu: yep
<clever>
karetsu: i think xscreensaver acts as a daemon, that tracks which applications are trying to block dpms (youtube, mplayer, vlc), and if none are blocking, will re-enable it within xorg