Re: Nginx service fails

2018-03-04 Thread Andreas Enge
Hello,

On Mon, Mar 05, 2018 at 12:43:35AM +0100, Andreas Enge wrote:
> $ guix system reconfigure AE/clementi.scm
> guix system: error: failed to load 'AE/clementi.scm':
> AE/clementi.scm:5:0: In procedure allocate-struct: Wrong type argument in 
> position 2: 25

I think I know the answer: .cache contains the compiled file for the operating
system declaration (clementi.go), and with the recent changes to how these are
parsed, it is incompatible.

> Is this normal? How are users supposed to know they should delete .cache?

Hopefully, this does not occur with "guix pull", and then it might be
considered normal... Is .cache actually necessary, since we generally
recompile from make files? Or is it needed since the make files do not
encode the precise dependency graph of the modules, as they usually do
for C code? If it is not necessary, could it be disabled by the project?

Andreas




Re: bug#30706: Nginx service fails

2018-03-04 Thread Andreas Enge
On Mon, Mar 05, 2018 at 08:23:18AM +0100, Ricardo Wurmus wrote:
> I had the same error when updating my i686 netbook after a long while.
> After a reboot everything seemed to be fine, though.

Ah, thanks for the information! A reboot made things worse in my case -
I rebooted the virtual machine, and now I cannot ssh into it any more.
So it looks like I will have to set it up from scratch again...

In my case, the problem occurred between February 28 and March 4.

Andreas




Re: bug#30706: Nginx service fails

2018-03-04 Thread Ricardo Wurmus

Andreas Enge  writes:

> Well, I am turning this into a bug report, since it still occurs with
> the latest git commit ac1a9ce8b07f3b80900ee08436ff6e683e8dc195 .
>
> This is the result of "./pre-inst-env guix system reconfigure ...",
> where "..." is my configuration file:
>
> ...
> creating nginx log directory '/var/log/nginx'
> creating nginx run directory '/var/run/nginx'
> creating nginx temp directories 
> '/var/run/nginx/{client_body,proxy,fastcgi,uwsgi,scgi}_temp'
> nginx: [alert] could not open error log file: open() 
> "/gnu/store/pp71iff1qxwhh82vm34g18h9kmn0xrg5-nginx-1.13.9/logs/error.log" 
> failed (2: No such file or directory)
> nginx: the configuration file 
> /gnu/store/5ixkryw6jl32cm6d1g9jb8dm9rbz8csc-nginx.conf syntax is ok
> nginx: configuration file 
> /gnu/store/5ixkryw6jl32cm6d1g9jb8dm9rbz8csc-nginx.conf test is successful
> `/gnu/store/zchh8s3r1bbmia3zfxsyhsz3c4b9fmps-openssh-authorized-keys/root' -> 
> `/etc/ssh/authorized_keys.d/root'
> `/gnu/store/zchh8s3r1bbmia3zfxsyhsz3c4b9fmps-openssh-authorized-keys/andreas' 
> -> `/etc/ssh/authorized_keys.d/andreas'
> guix system: loading new services: user-homes term-auto nginx...
> shepherd: Evaluating user expression (register-services (primitive-load 
> "/gnu/st?") ?).
> guix system: error: exception caught while executing 'eval' on service 'root':
> find-long-options: unbound variable

I had the same error when updating my i686 netbook after a long while.
After a reboot everything seemed to be fine, though.

--
Ricardo

GPG: BCA6 89B6 3655 3801 C3C6  2150 197A 5888 235F ACAC
https://elephly.net




Re: Posts in languages other than English on help-guix?

2018-03-04 Thread Eric Bavier
On Fri, 02 Mar 2018 17:02:40 +0100
l...@gnu.org (Ludovic Courtès) wrote:

> What about allowing posts on help-guix in one of the languages that
> regular contributors know, in addition to English?

Sounds like a good idea to me.

> Of course it’s hard to tell what a multilingual mailing list will be
> like, but I think it’s worth experimenting (and I don’t expect a
> significant change overnight).  If we are to reach out to more people,
> allowing them to use the language they know best is the minimum we can
> do IMO.

Indeed, it should be an interesting experiment.

Thanks for the proposal,
`~Eric


pgpjuFjZLLGGL.pgp
Description: OpenPGP digital signature


Re: Nginx service fails

2018-03-04 Thread Andreas Enge
PS: I rebooted the virtual machine, and now it looks as if even the
openssh service did not start:
... port 22: Connection refused
:-(




Re: Nginx service fails

2018-03-04 Thread Andreas Enge
Hello Danny,

thanks for your quick reply!

On Mon, Mar 05, 2018 at 12:07:44AM +0100, Danny Milosavljevic wrote:
> find-long-options is supposed to be in gnu/build/linux-boot.scm and
> gnu/services/base.scm is using it.
> 
> It's in there for some weeks now...
> 
> You can find out where guix is by:
> readlink $(which guix)
> and then examine the scm files there...

It should not matter, since I am using "./pre-inst-env" in a current
git checkout. But "guix --version" is at 0.14.0-9.bdf0c64, which also
has find-long-options. I did a successful reconfigure on February 28.

Trying to use the old guix (without ./pre-inst-env), I am also running
into trouble:
$ guix system reconfigure AE/clementi.scm
guix system: error: failed to load 'AE/clementi.scm':
AE/clementi.scm:5:0: In procedure allocate-struct: Wrong type argument in 
position 2: 25

The configuration file looks like this:
(use-modules (gnu))
(use-service-modules networking ssh web)
(use-package-modules screen ssh vim)

(operating-system
  (host-name "clementi")

So line 5 is "operating-system". I think there is a problem with caching
somewhere:
$ rm -rf ~/.cache
$ guix system reconfigure AE/clementi.scm
Now things happen. (But they hang when contacting the substitute server.)

It has also bitten me in the other direction:
When I run "guix system reconfigure...", press "Ctrl-C" immediately, and then
run "./pre-inst-env guix system reconfigure...", I get almost the same message:
guix system: error: failed to load 'AE/clementi.scm':
/home/andreas/guix/AE/clementi.scm:5:0: In procedure allocate-struct: Wrong 
type argument in position 2: 24

Is this normal? How are users supposed to know they should delete .cache?
And when is this actually necessary?

Andreas




Re: Nginx service fails

2018-03-04 Thread Danny Milosavljevic
Hi Andreas,

> shepherd: Evaluating user expression (register-services (primitive-load 
> "/gnu/st?") ?).
> guix system: error: exception caught while executing 'eval' on service 'root':
> find-long-options: unbound variable

find-long-options is supposed to be in gnu/build/linux-boot.scm and
gnu/services/base.scm is using it.

It's in there for some weeks now...

(define agetty-shepherd-service
  (match-lambda
...
 (modules '((ice-9 match) (gnu build linux-boot)))
...
 (start #~(let ((tty #$(default-serial-port)))
...

You can find out where guix is by:

readlink $(which guix)

and then examine the scm files there...


pgpo_XvY34SoN.pgp
Description: OpenPGP digital signature


Re: Nginx service fails

2018-03-04 Thread Andreas Enge
Well, I am turning this into a bug report, since it still occurs with
the latest git commit ac1a9ce8b07f3b80900ee08436ff6e683e8dc195 .

This is the result of "./pre-inst-env guix system reconfigure ...",
where "..." is my configuration file:

...
creating nginx log directory '/var/log/nginx'
creating nginx run directory '/var/run/nginx'
creating nginx temp directories 
'/var/run/nginx/{client_body,proxy,fastcgi,uwsgi,scgi}_temp'
nginx: [alert] could not open error log file: open() 
"/gnu/store/pp71iff1qxwhh82vm34g18h9kmn0xrg5-nginx-1.13.9/logs/error.log" 
failed (2: No such file or directory)
nginx: the configuration file 
/gnu/store/5ixkryw6jl32cm6d1g9jb8dm9rbz8csc-nginx.conf syntax is ok
nginx: configuration file 
/gnu/store/5ixkryw6jl32cm6d1g9jb8dm9rbz8csc-nginx.conf test is successful
`/gnu/store/zchh8s3r1bbmia3zfxsyhsz3c4b9fmps-openssh-authorized-keys/root' -> 
`/etc/ssh/authorized_keys.d/root'
`/gnu/store/zchh8s3r1bbmia3zfxsyhsz3c4b9fmps-openssh-authorized-keys/andreas' 
-> `/etc/ssh/authorized_keys.d/andreas'
guix system: loading new services: user-homes term-auto nginx...
shepherd: Evaluating user expression (register-services (primitive-load 
"/gnu/st?") ?).
guix system: error: exception caught while executing 'eval' on service 'root':
find-long-options: unbound variable
Installing for i386-pc platform.
/gnu/store/1dnbfda2p1bxwyl0rcm96ka9pmi0wb88-grub-2.02/sbin/grub-install: 
warning: disk does not exist, so falling back to partition device /dev/xvda2.
/gnu/store/1dnbfda2p1bxwyl0rcm96ka9pmi0wb88-grub-2.02/sbin/grub-install: 
warning: disk does not exist, so falling back to partition device /dev/xvda2.
/gnu/store/1dnbfda2p1bxwyl0rcm96ka9pmi0wb88-grub-2.02/sbin/grub-install: 
warning: disk does not exist, so falling back to partition device /dev/xvda2.
/gnu/store/1dnbfda2p1bxwyl0rcm96ka9pmi0wb88-grub-2.02/sbin/grub-install: error: 
cannot find a GRUB drive for /dev/sda.  Check your device.map.
guix system: error: failed to install bootloader 
/gnu/store/9iv63jm07klxvrr4fpwv6q5vpnca13ja-bootloader-installer

The final error is "normal", since I am installing in a Xen virtual machine,
where /dev/sda does not exist; it did not matter before.
The real error occurs above, the "uncaught exception".

But:
# herd status nginx
herd: service 'nginx' could not be found

Then I do a
# ./pre-inst-env guix system roll-back
# herd status nginx
herd: service 'nginx' could not be found

Otherwise said, I can go back, but my previously running web server has
definitely gone! How do I get it back?

Andreas




Nginx service fails

2018-03-04 Thread Andreas Enge
Hello,

writing to guix-devel first, since I am not sure whether I should file
a bug report. When reconfiguring my virtual machine today after I had
added a virtual host to nginx, it failed with the following error message:

...
creating nginx log directory '/var/log/nginx'
creating nginx run directory '/var/run/nginx'
creating nginx temp directories 
'/var/run/nginx/{client_body,proxy,fastcgi,uwsgi,scgi}_temp'
nginx: [alert] could not open error log file: open() 
"/gnu/store/pp71iff1qxwhh82vm34g18h9kmn0xrg5-nginx-1.13.9/logs/error.log" 
failed (2: No such file or directory)
nginx: the configuration file 
/gnu/store/5ixkryw6jl32cm6d1g9jb8dm9rbz8csc-nginx.conf syntax is ok
nginx: configuration file 
/gnu/store/5ixkryw6jl32cm6d1g9jb8dm9rbz8csc-nginx.conf test is successful
`/gnu/store/zchh8s3r1bbmia3zfxsyhsz3c4b9fmps-openssh-authorized-keys/root' -> 
`/etc/ssh/authorized_keys.d/root'
`/gnu/store/zchh8s3r1bbmia3zfxsyhsz3c4b9fmps-openssh-authorized-keys/andreas' 
-> `/etc/ssh/authorized_keys.d/andreas'
guix system: loading new services: user-homes term-auto nginx...
shepherd: Evaluating user expression (register-services (primitive-load 
"/gnu/st?") ?).
guix system: error: exception caught while executing 'eval' on service 'root':
find-long-options: unbound variable

And then the nginx service had disappeared. Even "guix system roll-back"
did not bring it back.

Since then I am trying to recompile a more recent git checkout, so I can
probably not reproduce the problem. But does it ring a bell?

Andreas




Re: Orchestration working group (before: Guix orchestration notes)

2018-03-04 Thread Chris Marusich
Devan  writes:

> Hi all,
>
> Pjotr Prins transcribed 0.6K bytes:
>> Hi Chris,
>> 
>> That was a lengthy writeup, thanks :). I think the first step is to
>> think in terms of (container/VM) provisioning. Then build that up towards
>> orchestration and workflows.
>
> I agree. I think a good start would be figuring out ways to
> essentially replace what you can do with Dockerfiles. Which to me 
> mainly means having the ability to arbitrarily copy files into, and 
> further manipulate the tarballs made from using `guix pack`.

With "guix pack", you can already create a Docker image that contains
arbitrary files.  Just define whatever packages you need in order to
install the things you want, and "guix pack --format=docker" will create
a Docker image of exactly what you declare, without building upon any
existing Docker image.  Is this different from what you had in mind?

Once "guix system docker-image" gets added, you will be able to do the
same thing for an entire GuixSD system:

https://debbugs.gnu.org/cgi/bugreport.cgi?bug=30572

-- 
Chris


signature.asc
Description: PGP signature


Re: Statistics and --rounds

2018-03-04 Thread Gábor Boskovits
2018-03-03 14:17 GMT+01:00 Gábor Boskovits :

> I will write here a short notice of the statistical implications of
> building software multiple times in general. I hope you will find this
> information useful.
>
> Hypothesis: the probability of successfully building the software is
> greater than or equal to p.
>
> This hypothesis can be accepted with a confidence level c=1-p^(k+1), where
> k is the number of rounds the software was built, and all the builds were
> succcesful.
>

Here is a spreadsheet that shows this in a more useful form. In the
spreadsheet you can see, that what is the probability of a successful build
give that a rounds n build succeeds and given the confidence level. I used
two of the most commonly use confidence levels, but this can be extended if
needed.


Build success probabilities.ods
Description: application/vnd.oasis.opendocument.spreadsheet


New Chinese (simplified) PO file for 'guix-packages' (version 0.14.0)

2018-03-04 Thread Translation Project Robot
Hello, gentle maintainer.

This is a message from the Translation Project robot.

A revised PO file for textual domain 'guix-packages' has been submitted
by the Chinese (simplified) team of translators.  The file is available at:

http://translationproject.org/latest/guix-packages/zh_CN.po

(We can arrange things so that in the future such files are automatically
e-mailed to you when they arrive.  Ask at the address below if you want this.)

All other PO files for your package are available in:

http://translationproject.org/latest/guix-packages/

Please consider including all of these in your next release, whether
official or a pretest.

Whenever you have a new distribution with a new version number ready,
containing a newer POT file, please send the URL of that distribution
tarball to the address below.  The tarball may be just a pretest or a
snapshot, it does not even have to compile.  It is just used by the
translators when they need some extra translation context.

The following HTML page has been updated:

http://translationproject.org/domain/guix-packages.html

If any question arises, please contact the translation coordinator.

Thank you for all your work,

The Translation Project robot, in the
name of your translation coordinator.





0.14.1?

2018-03-04 Thread Efraim Flashner
We now have aarch64 build machines, but there wasn't one when 0.14.0 was
released. This means that if someone installs guix on aarch64 and tries
to run 'guix pull' then they have to build from the bootstrap binaries
to guix before pulling and then compiling HEAD.  I tried this myself on
Scaleway, which offers aarch64 VMs, and was met by test errors.

Also, for aarch64 at least, berlin.guixsd.org should be added to the
default substitute servers.

-- 
Efraim Flashner      אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted


signature.asc
Description: PGP signature


system test for kmod and/or pure-Guile Linux module loader

2018-03-04 Thread Danny Milosavljevic
Hi,

so I'm trying to write system tests for kmod (for now).

The tests of the kmod package are disabled because they load/unload kernel
modules - which is not what a build container is supposed to be
doing.

gnu/tests/linux.scm is attached.

I get this message:

guix build: error: build failed: creating directory `/gnu/store/.links': 
Read-only

although I tried to use my own store fs.  What am I doing wrong?
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2018 Danny Milosavljevic 
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix.  If not, see .

(define-module (gnu tests linux)
  #:use-module (gnu packages base)
  #:use-module (gnu packages compression)
  #:use-module (gnu packages linux)
  #:use-module (gnu packages package-management)
  #:use-module (gnu tests)
  #:use-module (gnu system)
  #:use-module (gnu system file-systems)
  #:use-module (gnu system shadow)
  #:use-module (gnu system vm)
  #:use-module (gnu services)
  #:use-module (gnu services base)
  #:use-module (guix gexp)
  #:use-module (guix store)
  #:export (%test-linux))

(define (operating-system-with-current-guix-marionette os)
  "Return a variant of OS that uses the current Guix."
  (operating-system
(inherit os)
(services (cons (service marionette-service-type
 (marionette-configuration
  (imported-modules '((gnu services herd)
  (guix combinators)
   (modify-services (operating-system-user-services os)
 (guix-service-type config =>
(guix-configuration
 (inherit config)
 (guix (current-guix)

(define* %linux-os
  ;; Return operating system under test.
  (let ((base-os (simple-operating-system)))
(operating-system
  (inherit (operating-system-with-current-guix-marionette base-os))
  (packages (cons* (operating-system-packages base-os))

(define (run-linux-test linux-os)
  "Run tests in LINUX-OS."
  ;(define os
  ;  (marionette-operating-system
  ;   linux-os
  ;   #:imported-modules '((guix combinators
  (define vm
(virtual-machine
  (operating-system (operating-system (inherit linux-os)

  (file-systems (cons* (file-system
(device "root-fs")
(title 'label)
(mount-point "/")
(type "ext4"))
   (file-system
(device "store-fs")
(title 'label)
(mount-point "/gnu")
(type "ext4"))
   %base-file-systems)))

  )
  (memory-size 512)))

  (define (test kmod)
"Test the given KMOD package.  KMOD is the name of the kmod package."
(with-imported-modules '((gnu build marionette))
  #~(begin
  (use-modules (srfi srfi-11) (srfi srfi-64)
   (gnu build marionette))

  (define marionette
(make-marionette (list #$vm)))

  (mkdir #$output)
  (chdir #$output)

  (test-begin #$kmod)
  (test-assert "kmod tests work"
(marionette-eval
 '(begin
(use-modules (ice-9 popen) (ice-9 rdelim) (ice-9 ftw))
(system* "guix" "build" "--keep-failed" "-e"
 (string-append "((@ (guix packages) test-failing-package) " #$kmod ")"))
(display " ")
(display (scandir "/tmp"))
(newline)
(force-output)
(chdir
 (car
  (filter-map (lambda (basename)
(if (string-prefix? "guix-build-kmod-" basename)
(string-append "/tmp/" basename)
#f))
  (scandir "/tmp"
(zero? (system* "make" "check")))
 marionette))
  (test-end)
  (exit (= (test-runner-fail-count (test-runner-current)) 0)

  (gexp->derivation "linux-test" (test "kmod")))

(define %test-linux
  (system-test
   (name "linux")
   (description 

Re: Posts in languages other than English on help-guix?

2018-03-04 Thread Marco van Hulten
Hei Marius,

Marius Bakke schreef op 3 maart 2018 21:06:27 CET:
> Marco van Hulten  writes:
> 
> >  ("nb"
> >   "Abonner på diskusjonlisten «Help» for å få hjelp om GuixSD og
> > GNU Guix via e-post.  Du kan legge inn meldinger på norsk.")
> 
> Takk!  I think "diskusjonliste" should be "diskusjonsliste" as
> "diskusjon" is used in a passive infinite form (though good resources
> regarding this online was surprisingly difficult to come by).
> 
> "om" is also not the best preposition here, but I wonder if it's
> better
> to avoid "hjelp" altogether:
> 
>   ("nb"
>"Meld deg på diskusjonslisten «Help» for å få råd og tips fra
> andre GuixSD- og GNU Guix-brukere via e-post.  Du kan legge inn
> meldinger på norsk.")
> 
> "Råd" here is used as a kind of advice that is "sought for", implying
> support.  Tips is..well, general advice.  WDYT?

Sounds very good, let's go with your translation!

Marco