2016-12-14

<clever> Mic92: yeah, that path would do a fully proper shutdown
<clever> cares*
<clever> Mic92: though if the goal is to format, who ares! :D
<clever> Mic92: i also noticed, you lack a sync call in the kexec -e side of things, that might corrupt the host FS
<clever> havent tried it on real hardware yet
<clever> i tried it and it didnt help in vbox
<clever> but the whole point of kexec is to bypass the bios
<clever> and its up to the bios to handle it correctly
<clever> every motherboard does it differently
<clever> xen has similar problems with pci passthru
<clever> which only the bios knows how to do
<clever> its mostly a matter of the GPU needing a hard-reset
<clever> but the GPU state doesnt mean much for the target use
<clever> without that, the fake gpu is in a weird mode, and the stock vesa drivers get upset and render garbage
<clever> Mic92: i also figured out how to not break the video in vbox, vboxvideo.ko must be present in the new rootfs, then it recovers just fine
<clever> Mic92: i was using that with virtualbox, it can be removed
<clever> yeah, you could do that, but then you loose any kind of feedback about the install progress
<clever> Mic92: line 28 and 41 are a recent change i did, that allows the ssh key to be configured just before you kexec, so the tar is more generic
<clever> the PR has been on my todo list
<clever> Mic92: yeah, i have an override for that
<clever> this is how i was enabling it
<clever> systemd.services.sshd.wantedBy = mkForce [ "multi-user.target" ];
<clever> ah
<clever> the config example on line 10-13 will start ssh, but its not in the defaults
<clever> Mic92: and a minor thing missing from your version, ssh wont start on bootup, so you have no way to get into the system
<clever> Mic92: and i wasnt sure what systemd would do with "systemctl kexec", i thought that would load a new kernel from the units
<clever> Mic92: one thing i noticed when gchristensen was testing it, one of the environments he was on had a kexec kernel, but no kexec in $PATH, so including a copy from nixpkgs would help there
<clever> Mic92: yah
<clever> Dezgeg: are any of your ARM boards allwinner based?
<clever> kmicu: it says NO-CARRIER and UP in the <> section, so the interface is online, but it isnt getting a link
<clever> kmicu: thats because its not connected to anything
<clever> i havent done anything with connman, i just run raw wpa_supplicant
<clever> then the drivers arent the issue
<clever> jazzencat: what about "iwlist scan"
<clever> jazzencat: i would try doing "ip link set wlp3s0 up" and then check the last ~15 lines of dmesg
<clever> jazzencat: anything related in dmesg?
<clever> jazzencat: there is no difference between the 2 files, but nixos-generate-config will overwrite hardware-configuration.nix without asking
<clever> jazzencat: ive had no problems with slim
<clever> jazzencat: that will drop you in a text console
<clever> oops, ctrl+alt+f1
<clever> jazzencat: while at the login prompt, hit ctrl+alt=f1
<clever> sphalerite: although, it has been over 9 years since i last looked into fmod...
<clever> sphalerite: the licensing on fmod has radicaly changed since i last looked at it
<clever> the // operator is a shalow merge, while recursiveUpdate is a deep merge
<clever> i believe that takes 2 attrsets
<clever> Baughn: and fold
<clever> Baughn: // or lib.recursiveUpdate
<clever> it doesnt even have the option to turn pxe off!
<clever> i can see why you cant find anything
<clever> jazzencat: wth?, 90% of the options are missing! lol
<clever> can you take some photos of the bios settings?
<clever> or anything else with the word secure
<clever> does anything say compatability support module?
<clever> those are not related
<clever> or not, no usefull info in there
<clever> look thru every option
<clever> so it does have a CSM option, somewhere
<clever> jazzencat: thats UEFI
<clever> thats not likely to fix it and is sometimes risky
<clever> if your not even seeing GRUB, then something is wrong in the bios settings
<clever> the VERY FIRST thing grub does, before it has gotten close to reading the config, is to print GRUB to the screen
<clever> grub would tell you so after reading the file
<clever> everything says it should be working, so until we find out why it isnt, you are likely to recreate the same problem every time
<clever> yep, its all MBR
<clever> jazzencat: pastebin the output of "blkid /dev/sd*"
<clever> jazzencat: no way connman broke this, and grub is in the MBR, so it should have at least said GRUB on startup, even if the partitions are goofed
<clever> jazzencat: out of ideas, everything says it should be booting
<clever> not currently, a few people are working on that
<clever> jazzencat: do you see any options in the bios like secure boot or CSM?
<clever> jazzencat: yep, grub is correctly installed, it should be booting
<clever> and then just run nix-shell without any arguments
<clever> digitalmentat: simplest thing would be to make a shell.nix containing your entire expression
<clever> if you boot from the iso again, what does this output: "hexdump -C /dev/sda | head -n50"
<clever> jazzencat: check it again just incase
<clever> are you sure the bios is configured to boot from the hdd?
<clever> that sounds normal
<clever> jazzencat: and what about the output from "ls /mnt/boot ; umount /mnt/boot ; ls /mnt/boot"
<clever> jazzencat: and what is inside hardware-configuration.nix?
<clever> jazzencat: can you boot from the ISO again and pastebin the output of "mount" and your configuration.nix?
<clever> JonReed: id try just rebooting without any more changes first
<clever> jazzencat: is it doing anything at all when it tries to boot the hdd?
<clever> JonReed: now that you have the module in extraModulePackages, udev should find it on bootup
<clever> JonReed: modprobe just loads a module, bypassing udev entirely
<clever> nope
<clever> and it will also get any related drivers that it also needs, probably
<clever> JonReed: udev will try to load it via those aliases, when it detects the pci device
<clever> JonReed: when you do "modinfo wl" you should see a crap-ton of aliases, there is one for every pci device it claims to support
<clever> JonReed: all i can think of is to reboot, udev does some magic to load the right drivers on startup
<clever> that is strange
<clever> JonReed: what is the output of "ip link"?
<clever> JonReed: line 133 says that the wl driver did connect to that pci device
<clever> JonReed: and can you pastebin lspci -v?
<clever> JonReed: check dmesg
<clever> that file is immutable, so it has to restart to change the path
<clever> Mic92: and reload on config change is tricky if your passing it the config on the cmdline
<clever> Mic92: ah, not sure how you would do that
<clever> Mic92: and the restart trigger causes the foo.service file to get re-compiled, causing the symlink to change
<clever> Mic92: no, switch-to-config checks if the old foo.service symlink differs from the new foo.service symlink
<clever> JonReed: it needs to reference the exact package set that your kernel came from
<clever> JonReed: boot.extraModulePackages = [ config.boot.kernelPackages.v4l2loopback ];
<clever> Mic92: and nixos-rebuild detects the .service changing
<clever> Mic92: so if a trigger is modified, the service file changes
<clever> JonReed: ah, i see what you did wrong
<clever> Mic92: i think it will embed all of the triggers into the .service file
<clever> Mic92: { X-Restart-Triggers = toString config.restartTriggers; }
<clever> JonReed: probably, how did you add it to your system?
<clever> jazzencat: it has to be /dev/sda
<clever> but it was on sale!
<clever> sphalerite: the last time i did that (with an amazon kindle) it refused to even install a free app, until i gave it an american credit card
<clever> sphalerite: and to make it extra crazy, the banana pi is shipping from isreal, lol
<clever> sphalerite: newegg.ca has the headset for over $200, and doesnt have the banana pi
<clever> sphalerite: ugh, newegg.com has the items i want, for $160 total, but refuses to ship to canada
<clever> jazzencat: id say you only need ~9gig of swap for hibernate, assuming very little actualy goes into swap when running
<clever> i just use GPT on everything now
<clever> i have one system running with a 64mb boot partition
<clever> jazzencat: should be plenty
<clever> sphalerite: all i did was turn off the DHCP server and give it a static ip thats out of the main dhcp range
<clever> sphalerite: due to various things causing problems, ive been getting wifi thru an old d-link router for years
<clever> ah
<clever> sphalerite: the R1 appears to have b/g/n wifi
<clever> sphalerite: this also has room for 1 sata drive, so you could make it into a 2tb NAS at a later date, it appears to also be able to run from SD
<clever> vs the specs on http://www.banana-pi.org/r1.html
<clever> CPUA20 ARM Cortex™-A7 Dual-CoreGPUARM Mali400MP2 Complies...
<clever> newegg*
<clever> so now words are just smushed together, lol
<clever> sphalerite: *doh*, somebody copy/pastad the specs from the banana pi site into amazon, and all of the linebreaks vanished
<clever> sphalerite: looks like you have 3 options in the UK: http://www.banana-pi.org/shop.html
<clever> sphalerite: and they are both on newegg!
<clever> sphalerite: dang, the R1 is only ~double the cost of the headset i need to replace
<clever> sphalerite: in theory, the banana-pi r1 could meet everything you need
<clever> sphalerite: its an arm system, so you could run nixos on it (i have nixos on my rpi's), and my x86 router is running nixos also
<clever> sphalerite: this board has 5 ethernet ports and a dual core processor
<clever> sphalerite: aha, remembered the right keywords: http://www.banana-pi.org/r1.html
<clever> avn: the new version can create partitions with a full ui, but it cant format them, or run nixos-install
<clever> avn: the old version has no controls right now, it so its about as usefull as a bash script that has been linked here a few times before
<clever> sphalerite: something has been acting up with my internet lately, it takes forever to connect to something
<clever> sphalerite: still digging for the right option
<clever> ssh -vvvv can give a lot more details
<clever> you may need to enable an older insecure key algo in the ssh client
<clever> let me check my bookmarks, i had something interestign saved
<clever> so ssh and nfs are useless
<clever> the the junk my ISP supplied doesnt allow wifi and wired to connect
<clever> "proper" router hardware would last far longer
<clever> the only downside, the power went out yesterday, and it sucks enough power to kill a UPS in ~8mins
<clever> and it runs nixos
<clever> my router is a proper server with 3gig of ECC ram, dual-processor, and a couple gigabit ports
<clever> it booted on both platforms, and shared a large chunk of the configuration.nix
<clever> debian wouldnt like that :P
<clever> in the past, i have made a usb stick, that had both x86-64, and armv6l on it
<clever> if you can point it at the data files in $HOME
<clever> it would be neat to make a proper nixos package that compiles the game
<clever> ah
<clever> nixos at least makes it trivial to get the 32bit libs installed
<clever> teamspeak appears to support both
<clever> it might have been an upstream choice, lol
<clever> the nixos skype package avoids that, by going 32bit only
<clever> yeah, you would need to have 2 download urls, to grab the 32 or 64bit build
<clever> so it just works on all arches
<clever> $NIX_CC/nix-support/dynamic-linker is a file that has the correct path in it
<clever> sphalerite: that will work on 64bit, but break on 32bit
<clever> sphalerite: the interpreter field in an ELF file is almost identical to the #! in a shell script, you can even run the dynamic linker on an unpatched ELF file
<clever> sphalerite: so it cant find the linker in rpath
<clever> sphalerite: the dynamic linker is what reads the rpath and obeys it
<clever> arianvp: and this is how you beta test unstable for your server!
<clever> sphalerite: which lets you access the gcc behind the bash script
<clever> sphalerite: there is also gcc.cc.lib
<clever> sphalerite: usualy, you just want --interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)"
<clever> sphalerite: pkgs.gcc is a bash script that wraps gcc
<clever> gchristensen: id rather just not have an ubuntu user, and the directions say to disable root instead
<clever> Mic92: ubuntu kind of defeats the whole point :P
<clever> gchristensen: as long as passwords are off, i cant see any real harm in root being enabled
<clever> and turning root login off, just forces the attackers to have to guess 2 variables at once
<clever> i think the reason most distro's disable root login, is because its easyer to guess the login is 'root' then to figure out if its arianvp, clever, Mic92 or something else
<clever> so the only way in is by brute-forcing a keypair thats probably 2048 bits long
<clever> arianvp: services.openssh.passwordAuthentication = false; and it will never accept another password
<clever> you can set it so root login wont accept a password, only an ssh public key pair
<clever> it needs root to activate the configuration
<clever> you need to remove the quotes on this
<clever> "./arianvp.me/configuration.nix"
<clever> arianvp: what error does it give when it doesnt work?
<clever> lewo: make-disk-image.nix does the bulk of the work for vbox, then the postvm script will convert the qemu image into a vbox image
<clever> heh, that exact storepath is still in my store, and still has the same inode#
<clever> 652323 dr-xr-xr-x 4 root root 8 Dec 31 1969 .
<clever> [root@amd-nixos:~]# ls -lhia /nix/store/j28g21z97pqasrhhqxlgxzcrxij2rbxj-dbus-libs-1.8.20/lib/
<clever> gchristensen: i have no idea what caused that, but restarting qemu had no effect, it just vanished when the host rebooted
<clever> gchristensen: yeah
<clever> domenkozar: gchristensen: http://i.imgur.com/zd1fpWG.png
<clever> gchristensen: can you see how the probelm i ran into would just break everything that runs into it?
<clever> gchristensen: but the cross-link was constant between restarts of qemu
<clever> gchristensen: so the directory contained files from a totally different directory
<clever> gchristensen: i ran into a very weird bug with qemu's virtfs and 9p stuff a few months back, some of the nix store directories got cross-linked at some point
<clever> gchristensen: and i now have partition create working
<clever> wine and gstreamer are up next
<clever> and it looks like pango changed in master, so now my hydra is busy rebuilding things
<clever> and why do i have it set to 0? that job has no point if its 0, lol
<clever> http://hydra.earthtools.ca/jobset/hydra-example/netboot#tabs-configuration doesnt have a time option right now, "Number of evaluations to keep"
<clever> assuming foo hasnt been changed since
<clever> angerman: and then as long as the users are within 20 changes of the latest nixos-unstable, it will be in that cache
<clever> angerman: hmmm, and if you setup your own hydra, that always follows nixos-unstable, and builds foo against it at every change, you can set it to keep the last 20 builds
<clever> angerman: depends a lot on how long it takes to compile and how many users will be using it
<clever> but for private things, id just eat the compile time, its not that bad
<clever> angerman: i would generaly try to get my code into nixpkgs, so hydra is building it for me, and is always going to be matched to the nixpkgs revisions
<clever> angerman: yeah
<clever> angerman: so every time nixos-unstable-small changes, this has a new eval and a new build
<clever> angerman: this job is setup to follow nixos-unstable-small, and it depends on the nixpkgs expression
<clever> angerman: oh, just remembered, i have a better answer
<clever> angerman: correct\
<clever> angerman: the git history will be identical to the history of master, it will simply stop at the revision that is known-good
<clever> angerman: we have the latest change, but no historical data
<clever> angerman: http://howoldis.herokuapp.com/ links to the job on hydra
<clever> angerman: and a small number of basic tests pass
<clever> angerman: nixpkgs-unstable should update any time hydra has finished building everything, for x86 and darwin
<clever> gchristensen: here is an example of what i can do with this RPC code i made: http://pastebin.com/fcpB7Bj6
<clever> gchristensen: once i get create partition and delete partition working, i can port forward it and let you play with the UI
<clever> gchristensen: what? lol
<clever> gchristensen: http://imgur.com/a/AQVfx
<clever> jazzencat: other then that, its pretty much the same as normal, just use a usb hdd
<clever> jazzencat: i would change boot.loeader.grub.device to "nodev"; after installing, or it may try to mess with the MBR on the wrong hdd during an upgrade
<clever> ixxie: 0 AD?
<clever> ixxie: i had reverse engineered that game, and wrote an android UI for it, to avoid having to deal with 6mb of js on mobile: http://gallery.earthtools.ca/index.py/android/device-2013-01-16-212828.png
<clever> ixxie: the partition editor ive written currently compiles down to 866kb of JS
<clever> jazzencat: nixos needs to have full control of the bootloader to work right, and i dont trust windows to not break things during install :P
<clever> jazzencat: and windows first
<clever> jazzencat: id say nixos should be last
<clever> ixxie: so they could theme the progress bar as that whole beast loads
<clever> ixxie: they they broke it up into a series of <script>s("1024 bytes");</script>'s in a single html file, that gets loaded in an iframe
<clever> ixxie: in that game, they compiled all of the UI logic and QX into a single JS file, then minified it, resulting in a solid 6mb of JS
<clever> ixxie: yeah
<clever> jazzencat: it will also work with a GPT based install if you create the bios boot partition
<clever> jazzencat: GPT does
<clever> jazzencat: MBR doesnt need the special bios boot partition i kept telling you you had to create
<clever> arianvp2: and as long as the keys in your config dont depend on the config argument, it will work perfectly
<clever> yep
<clever> arianvp2: yep
<clever> yeah
<clever> after it has been merged with all other modules
<clever> arianvp2: so you are getting your own output passed in as an argument
<clever> arianvp2: that final config is then passed as an argument into every module
<clever> arianvp2: every nixos module will return a fragment of the config, and then nixos will merge all of them together, to create the final config
<clever> arianvp2: all config entries are in the config attribute set, your already using it correctly on lines 37 and 38
<clever> arianvp2: you want config.security.acme
<clever> arianvp2: root ${security.acme.certs."arianvp.me".webroot}; is invalid
<clever> ixxie: dns will take 5mins to propagate, assuming your ISP is obeying the rules of dns
<clever> ixxie: havent reconfigured that on the nixos router
<clever> ixxie: the old linux from scratch router did, i had a script that would fix the dynamic ip's
<clever> jazzencat: what is the output of "blkid /dev/sd*" now that its working?
<clever> ixxie: i forgot to update my dns after the ip changed
<clever> ixxie: oh, *doh*
<clever> ixxie: let me debug it on this end
<clever> ixxie: might have been broken by the recent power outage, need to get everything setup to run on bootup still
<clever> ixxie: my router doesnt support handling port forwards from inside the lan, so i need to use /etc/hosts to re-route the internal websites to the LAN ip's
<clever> avn: yep, ive done that before
<clever> ixxie: that image is a game i played before, that used QX for its entire ui
<clever> arianvp2: can you pastebin you configuration.nix?
<clever> ixxie: ah, kk
<clever> ixxie: http://gallery.earthtools.ca/android/Screenshot.png does this work from outside my LAN?
<clever> arianvp2: oops, -Q
<clever> angerman: -Q makes it much cleaner
<clever> ixxie: and now comes the double-edged sword of nixos, i want to edit /etc/hosts, but i was putting off a nixos-rebuild to update, now i get all the updates!!
<clever> ixxie: QX also has a fairly complex theming framework, oh, and it seems one of my websites died in the power outage
<clever> ixxie: yeah, i can just google it some, i also know some people elsewhere that do graphics work
<clever> all of this is the defaults for TreeFolder and TreeFile
<clever> ixxie: yeah, i'll need to get better icons, i havent opened an image editor once while creating this
<clever> ixxie: i dont think ive seen any other framework with docs this detailed
<clever> you can also click js code in that page, to see how simple its implemented
<clever> yep
<clever> ixxie: would that layout work better>
<clever> ixxie: yeah, i am thinking of switching it to http://www.qooxdoo.org/5.0.1/demobrowser/#widget~Tree_Columns.html
<clever> ixxie: libparted
<clever> angerman: most packages have a checkPhase, that just runs between make install and make i believe
<clever> ixxie: let me grab some screenshots to show what im basing it on roughly
<clever> and QX for the frontend
<clever> ixxie: yeah, QT for the backend
<clever> ixxie: the screenshot i linked is running entirely in chrome, and remote-controlling the installer
<clever> ixxie: it has to run over http
<clever> ixxie: i'm basing it loosly on the ubuntu installer, which i recently had to run while testing kexec stuff
<clever> angerman: here is an expression i wrote that does not directly use nixpkgs itself: https://github.com/cleverca22/nix-tests/blob/master/bare-env.nix
<clever> ixxie: i'm also working on a GUI for nixos-install, how does this look as a start? http://imgur.com/a/AQVfx
<clever> it will internaly hold onto a reference to the un-called version of the lamba (immutable evaluation ftw!) and you can call it again with different args
<clever> and the arguments its supplying are what .override affects
<clever> callPackage is also responsible for adding .override to things
<clever> angerman: so you can do pkgs.callPackage { stdenv, hello }: stdenv.mkDerivation { name = "foo"; buildInputs = [ hello ]; } {};
<clever> angerman: callPackage will also accept a lambda directly
<clever> and it will return the contents, rather then error out
<clever> so you could have a bare file that doesnt start with { something }:
<clever> callPackage will also detect if it even needs arguments
<clever> yeah
<clever> so callPackage ./foo.nix { bar = 42; } will always set bar to 42