Re: How to use jack and qjackctl on GuixSD?

2017-04-11 Thread Leo Famulari
On Tue, Apr 11, 2017 at 01:33:20PM -0700, Drew C wrote:
> Hey,
> 
> I am a musician that produces a lot of things, and I use Ardour with jackd
> for the most part.
> 
> On most of the other distros I've tried, installing and running qjackctl is
> enough. On GuixSD it will not seem to work. It does seem to start it as
> there is a PID, but cannot connect to the socket, does not run in
> real-time, etc.
> 
> Any direction on where to go? I am a software developer as well and do not
> mind getting my hands dirty at all, so let me know.

Here is some earlier discussion of JACK on GuixSD:

https://lists.gnu.org/archive/html/guix-devel/2016-10/msg00479.html

Hope it helps!



Re: Bad parameter to boot GuixSD in a VM

2017-04-11 Thread Leo Famulari
On Tue, Apr 11, 2017 at 10:38:44PM +0200, Miroslav Rovis wrote:

Hi, thanks for the detailed feedback!

In general, the instructions in the manual related to QEMU are the
simplest QEMU invocations that will work for basic use cases. They are
intended to be something that a person without QEMU experience can use
to boot GuixSD in a virtualized environment. We assume that users will
adapt these examples to their use case if they plan to virtualize GuixSD
in production.

> root@gnu ~# ping www.gnu.org
> ping: unknown host
> root@gnu ~#
>
> Previously I ran "ip a", nothing really shows... And afterwards I tried:
> 
> root@gnu ~# curl https://www.gnu.org
> root@gnu ~# links https://www.gnu.org
> root@gnu ~# elinks https://www.gnu.org
> root@gnu ~# lynx https://www.gnu.org
> 
> but none of those seems to be installed.
> 
> In short, no network in the Guix guest...

There is a built-in network client `guix download` that you could try.

There was (is?) a bug related to name resolution failures being cached
for too long in certain cases:



So, I connect to a well-known IP address like 8.8.8.8 in order to test
the network.

As an aside, the unprivileged "user mode" QEMU networking system doesn't
support ICMP, so if you were using that, ping won't work.

> And I was courious, why are you suggesting/recommending (in that manual)
> the old:
>  -net ...
> instead of the new:
>  -netdev ...
> ? The Qemu devs are firm that the new is better, IIUC.

I looked into this previously, and I decided to keep the old '-net user'
syntax in the examples we provide.

My reason is that '-netdev user' requires the user to specify a unique
'id' parameter, while '-net user' does not.

Since both syntaxes provide the same "user mode network stack", I
thought that the older and simpler syntax was better for the examples in
the manual. Remember, these are supposed to be the simplest examples
that will boot GuixSD with a network connection.

Is there some limitation with '-net user' that we should consider for
the examples in the manual?

> Let me try another script:
> 
> =-=--===-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
> 
> #!/bin/sh
> exec qemu-system-x86_64 \
>   -machine type=q35,accel=kvm \
>   -enable-kvm \
>   -cpu host \
>   -device virtio-net,netdev=internet \
>   -netdev \
>   
> bridge,br=br0,id=internet,helper=/usr/libexec/qemu-bridge-helper \
>   -m 4196M \
>   -monitor stdio \
>   -boot menu=on \
>   -drive file=guixsd.img \
>   -drive file=guixsd-usb-install-0.12.0.x86_64-linux 
> 
> =-=--===-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
> 
> Oh, yes! This is maybe 10 times faster!

Yes, KVM will do that :)

> But, still no network... Hmmmh!

Hm, I'm not sure what's wrong. I assume that the TAP device is properly
configured in your host system?

The nice thing about the user-mode QEMU networking is that it doesn't
require any special configuration on the host. But of course it's very
limited...


signature.asc
Description: PGP signature


qjackctl wrong jack version (was: Re: How to use jack and qjackctl on GuixSD?)

2017-04-11 Thread Mark Meyer
> "Drew" == Drew C  writes:


Drew> Yes! I am running XFCE and/or also have Gnome installed.

Drew> I will try xmonad ... is there an easy way to add it to
Drew> config.scm so I can F1 to choose it, and if not, where/how to
Drew> I configure GuixSD's X to use it?

Drew> Otherwise, there is a pulseaudio jack sink that may work if I
Drew> can be told where to put it.

*grml* I think I messed up.

First note: 

https://www.gnu.org/software/guix/manual/html_node/Base-Services.html#Base-Services

See the bottom of the page. It defines a `realtime' group and it's
permissions. You might need to create this group and add yourself to it
or you might simply use the `@audio' for the `audio' group, where you
might already be a member.

Second note: It still doesn't work, but it's too late to look into
this. :( Could take care of this tomorrow.

Crazy, I had this running.

Cheers, Mark



Re: How to use jack and qjackctl on GuixSD?

2017-04-11 Thread Drew C
Hey Mark,



On Tue, Apr 11, 2017 at 2:06 PM, Mark Meyer  wrote:

> > "Drew" == Drew C  writes:
>
> Drew> Any direction on where to go? I am a software developer as
> Drew> well and do not mind getting my hands dirty at all, so let me
> Drew> know.
>
> qjackctl should have a log, can you post this? It should say something
> about adding stuff to limits for the realtime issue and I'd be
> interested in the message about the socket.
>

Here it is :
---

14:37:30.171 Statistics reset.

Cannot connect to server socket err = No such file or directory

Cannot connect to server request channel

jack server is not running or cannot be started

14:37:33.768 JACK is starting...

14:37:33.768 /home/drewc/.guix-profile/bin/jackd -dalsa -dhw:0 -r48000
-p1024 -n2

Cannot connect to server socket err = No such file or directory

Cannot connect to server request channel

jack server is not running or cannot be started

jackd 0.124.1

Copyright 2001-2009 Paul Davis, Stephane Letz, Jack O'Quinn, Torben Hohn
and others.

jackd comes with ABSOLUTELY NO WARRANTY

This is free software, and you are welcome to redistribute it

under certain conditions; see the file COPYING for details

JACK is running in realtime mode, but you are not allowed to use realtime
scheduling.

grep: /etc/security/limits.conf: No such file or directory

Please check your /etc/security/limits.conf for the following line

and correct/add it if necessary:

@audio - rtprio 99

After applying these changes, please re-login in order for them to take
effect.

You don't appear to have a sane system configuration. It is very likely
that you

encounter xruns. Please apply all the above mentioned changes and start
jack again!

14:37:34.087 JACK was started with PID=22880.

14:37:34.088 JACK was stopped

14:37:36.101 Could not connect to JACK server as client. - Overall
operation failed. - Unable to connect to server. Please check the messages
window for more info.

Cannot connect to server socket err = No such file or directory

Cannot connect to server request channel

jack server is not running or cannot be started




>
> Do you run a Desktop Environment? I run with bare xmonad, which doesn't
> start any sound servers, but if I log into XFCE I'll have a connection
> problem. Even when you don't start any programs that use it, some applet
> may start PulseAudio (for example).
>

Yes! I am running XFCE and/or also have Gnome installed.

I will try xmonad ... is there an easy way to add it to config.scm so I can
F1 to choose it, and if not, where/how to I configure GuixSD's X to use it?

Otherwise, there is a pulseaudio jack sink that may work if I can be told
where to put it.

Thanks a bunch!

-- drewc

>
> Cheers, Mark
> --
>Mark Meyer
>m...@ofosos.org
>


Re: Bad parameter to boot GuixSD in a VM

2017-04-11 Thread Miroslav Rovis
On 170410-14:50+0200, Ludovic Courtès wrote:
> Hello,
> 
> 良ϖ  skribis:
> 
> > I've followed instructions on this page:
> > https://www.gnu.org/software/guix/manual/html_node/Installing-GuixSD-in-a-VM.html
> >
> > Howeverpoint 3 ("Boot the USB installation image in an VM: ") gets:
> >
> > qemu-system-x86_64: -net default: Invalid parameter 'default'
> 
> This section should read:
> 
>   qemu-system-x86_64 -m 1024 -smp 1 \
> -net user -net nic,model=virtio -boot menu=on \
> -drive file=guixsd.img \
> -drive file=guixsd-usb-install-@value{VERSION}.@var{system}
> 
> (It’s a typo in the manual fixed in commit
> d36b8457d04286b4db0543656eed69ae050ac783.)
> 
> > If I remove that parameter I get another error:
> >
> > WARNING: Image format was not specified for
> > 'guixsd-usb-install-0.12.0.x86_64-linux' and probing guessed raw.
> >  Automatically detecting the format is dangerous for raw
> > images, write operations on block 0 will be restricted.
> >  Specify the 'raw' format explicitly to remove the restrictions.
> 
> This is just a warning.
> 
> However, you really need networking support in the VM to install GuixSD.

Trying to understand the above (such as the manual in question
is probably where I'll link to below...), but...

..But I followed the guide to try and run Guix from VM:
https://www.gnu.org/software/guix/manual/html_node/Installing-GuixSD-in-a-VM.html#Installing-GuixSD-in-a-VM

and, this is from yesterday when I did my tentative installing and
running:

$ ls -ltrh guixsd.img
-rw-r--r-- 1 miro miro 193K 2017-04-10 04:45 guixsd.img
$

( created as the page says:
qemu-img create -f qcow2 guixsd.img 5G
)

And this is the script (installed in /usr/local/bin) that I used, and
will try and use again so the question is more complete:

=-=--===-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

#!/bin/sh
exec qemu-system-x86_64 \
-m 1024 -smp 1 \
-device virtio-net,netdev=internet \
-netdev \

bridge,br=br0,id=internet,helper=/usr/libexec/qemu-bridge-helper \
-boot menu=on \
-drive file=guixsd.img \
-drive file=guixsd-usb-install-0.12.0.x86_64-linux \
-monitor stdio

=-=--===-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

... (let me retry before sending this) ...

So, it goes like this:

$ GuixVM02.sh
WARNING: Image format was not specified for 
'guixsd-usb-install-0.12.0.x86_64-linux' and probing guessed raw.
 Automatically detecting the format is dangerous for raw images, write 
operations on block 0 will be restricted.
 Specify the 'raw' format explicitly to remove the restrictions.
QEMU 2.8.0 monitor - type 'help' for more information
(qemu)

and I press Esc (not F12 like the manual says, or is that changed/corrected
now?, let me see, no it's not, it still says F12, and my Qemu said Esc), and I 
chose 2, like the manual says, and it is booting now...

But it's so slow...

I think I need to add "-enable kvm". That got the VM's of Devuan, Heads,
Refracta, Gentoo very fast.

But, even though, and I'll paste agin from the prompt of the host (the
host is my Gentoo machine):

(qemu) info network
virtio-net-pci.0: 
index=0,type=nic,model=virtio-net-pci,macaddr=52:54:00:12:34:56
 \ internet: index=0,type=tap,helper=/usr/libexec/qemu-bridge-helper,br=br0
(qemu)

[even though] the network is there, I still have, now I have to manually
copy (I mean: by typing):

root@gnu ~# ping www.gnu.org
ping: unknown host
root@gnu ~#

Previously I ran "ip a", nothing really shows... And afterwards I tried:

root@gnu ~# curl https://www.gnu.org
root@gnu ~# links https://www.gnu.org
root@gnu ~# elinks https://www.gnu.org
root@gnu ~# lynx https://www.gnu.org

but none of those seems to be installed.

In short, no network in the Guix guest...

And I was courious, why are you suggesting/recommending (in that manual)
the old:
 -net ...
instead of the new:
 -netdev ...
? The Qemu devs are firm that the new is better, IIUC.

Let me try another script:

=-=--===-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

#!/bin/sh
exec qemu-system-x86_64 \
-machine type=q35,accel=kvm \
-enable-kvm \
-cpu host \
-device virtio-net,netdev=internet \
-netdev \

bridge,br=br0,id=internet,helper=/usr/libexec/qemu-bridge-helper \
-m 4196M \
-monitor stdio \
-boot menu=on \
-drive file=guixsd.img \
-drive file=guixsd-usb-install-0.12.0.x86_64-linux 

=-=--===-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

Oh, yes! This is maybe 10 times faster!

But, still no network... Hmmmh!

It's similar to the already reported above, regarding the network, basically.

Also the guixsd hasn't changed in the least. Same size, same timestamp.
Untouched by my 

Re: How to use jack and qjackctl on GuixSD?

2017-04-11 Thread Mark Meyer
Hi Drew!

> "Drew" == Drew C  writes:

Drew> On most of the other distros I've tried, installing and
Drew> running qjackctl is enough. On GuixSD it will not seem to
Drew> work. It does seem to start it as there is a PID, but cannot
Drew> connect to the socket, does not run in real-time, etc.

I think this did connect for me, but didn't run as realtime
out-of-the-box.

Drew> Any direction on where to go? I am a software developer as
Drew> well and do not mind getting my hands dirty at all, so let me
Drew> know.

qjackctl should have a log, can you post this? It should say something
about adding stuff to limits for the realtime issue and I'd be
interested in the message about the socket.

Do you run a Desktop Environment? I run with bare xmonad, which doesn't
start any sound servers, but if I log into XFCE I'll have a connection
problem. Even when you don't start any programs that use it, some applet
may start PulseAudio (for example).

Cheers, Mark
-- 
   Mark Meyer
   m...@ofosos.org



How to use jack and qjackctl on GuixSD?

2017-04-11 Thread Drew C
Hey,

I am a musician that produces a lot of things, and I use Ardour with jackd
for the most part.

On most of the other distros I've tried, installing and running qjackctl is
enough. On GuixSD it will not seem to work. It does seem to start it as
there is a PID, but cannot connect to the socket, does not run in
real-time, etc.

Any direction on where to go? I am a software developer as well and do not
mind getting my hands dirty at all, so let me know.

Cheers,

Drew Crampsie


Re: Hwo to debug and teacking builds?

2017-04-11 Thread myglc2
On 04/11/2017 at 18:36 Hartmut Goebel writes:

> Am 11.04.2017 um 17:40 schrieb Chris Marusich:
>> myglc2  writes:
>>
>>> On 03/28/2017 at 23:10 Chris Marusich writes:
>>>
>>> [...]
>>>
   export INFOPATH="$HOME/guix/doc${INFOPATH:+:}$INFOPATH"
>>> export INFOPATH="$HOME/guix/doc${INFOPATH:+:$INFOPATH}"
>> Yes, you're correct.  I mis-typed that.
>
> But isn't the result the same?

Duh... Yes. 



Re: Hwo to debug and teacking builds?

2017-04-11 Thread Hartmut Goebel
Am 11.04.2017 um 17:40 schrieb Chris Marusich:
> myglc2  writes:
>
>> On 03/28/2017 at 23:10 Chris Marusich writes:
>>
>> [...]
>>
>>>   export INFOPATH="$HOME/guix/doc${INFOPATH:+:}$INFOPATH"
>> export INFOPATH="$HOME/guix/doc${INFOPATH:+:$INFOPATH}"
> Yes, you're correct.  I mis-typed that.

But isn't the result the same?


-- 
Regards
Hartmut Goebel

| Hartmut Goebel  | h.goe...@crazy-compilers.com   |
| www.crazy-compilers.com | compilers which you thought are impossible |




Re: Hwo to debug and teacking builds?

2017-04-11 Thread Chris Marusich
myglc2  writes:

> On 03/28/2017 at 23:10 Chris Marusich writes:
>
> [...]
>
>> To view your changes, it's helpful to add the 'guix/doc' directory from
>> your local Guix checkout to your INFOPATH.  I've put the following line
>> in my ~/.bash_profile to do this automatically:
>>
>>   export INFOPATH="$HOME/guix/doc${INFOPATH:+:}$INFOPATH"
>
> Hi Chris, don't you mean ...
>
> export INFOPATH="$HOME/guix/doc${INFOPATH:+:$INFOPATH}"
>
> - George

Yes, you're correct.  I mis-typed that.

-- 
Chris


signature.asc
Description: PGP signature


Re: Hwo to debug and teacking builds?

2017-04-11 Thread myglc2
On 03/28/2017 at 23:10 Chris Marusich writes:

[...]

> To view your changes, it's helpful to add the 'guix/doc' directory from
> your local Guix checkout to your INFOPATH.  I've put the following line
> in my ~/.bash_profile to do this automatically:
>
>   export INFOPATH="$HOME/guix/doc${INFOPATH:+:}$INFOPATH"

Hi Chris, don't you mean ...

export INFOPATH="$HOME/guix/doc${INFOPATH:+:$INFOPATH}"

- George