[Nix-dev] HP Network Printer (CUPS + HPLIP)

2016-03-14 Thread Sergiu Ivanov

Hello,

I'm trying to set up CUPS to use a HP LaserJet Enterprise 600 M602 [0]
on my NixOS system.  Here is the relevant snippet of my
configuration.nix (taken from the wiki [1]):

  services.printing = {
enable = true;
drivers = [ pkgs.hplip ];
  };

hp-setup does not detect the printer and says "No devices found on this
bus: net".

In Web administration interface for CUPS, I click "Add Printer" then I
select HP Printer (HPLIP) and I specify socket://192.168.0.11 as
connection string (I can ping this address). Then, when I get to the
screen giving the list of models, I *cannot* see the model of my
printer, even though the directory

  $(nix-build '' --no-out-link -A hplip)/share/ppd/HP/

contains a file hp-laserjet_600_m601_m602_m603-ps.ppd.gz .

I gunzip this file in a temporary folder and load it explicitly via the
CUPS Web interface.  Then, when I tell the Web interface to print a test
page, the job fails with the message 'stopped "Filter failed"'.

How would you normally set up HPLIP to work correctly with CUPS?

(I think I used to install foomatic on Arch Linux, but I'm not sure any
more.)

-- 
Sergiu

[0] 
http://hplipopensource.com/hplip-web/models/laserjet/hp_laserjet_600_m602.html

[1] https://nixos.org/wiki/Printers


signature.asc
Description: PGP signature
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Amazon EC2 rebuild switch causes kernel panic

2016-03-14 Thread Domen Kožar
Fixed in git, wait for channel update.

On Mon, 14 Mar 2016, 15:58 Roger Qiu,  wrote:

> What's happening is the transition from stage 1 booting to stage 2 booting
> is failing. The error reported is that the init script that is be executed
> once switch_root is executed is non existent. Which could mean your initrd
> is corrupted or the build failed for some reason or some other config
> problem at stage 1.
>
> If you could inspect the initrd to check if the init script is there...
> On 15/03/2016 2:31 AM, "Paul Cooley"  wrote:
>
>> I brought up an AWS instance using nixos-15.09.git.87b377dM-x86_64-pv-ebs
>> . After modifying /etc/nixos/configuration.nix to use the
>> "amazon-init.nix" rather than "amazon-image.nix" and performing a
>> 'nixos-rebuild switch' command, the instance reports the following error.
>>
>> [fsck.ext3 (1) -- /mnt-root/disk0] fsck.ext3 -a /dev/xvdb
>> /dev/xvdb: recovering journal
>> /dev/xvdb: clean, 116502/262144 files, 579900/1047168 blocks
>> mounting /dev/xvdb on /disk0...
>> switch_root: can't execute 
>> '/nix/store/z9rp9hzs19pi1788fj8kdkw81mnxsgf1-nixos-15.09.1119.f6d1666/init': 
>> No such file or directory
>> [0.652277] Kernel panic - not syncing: Attempted to kill init! 
>> exitcode=0x0100
>> [0.652277]
>> [0.652287] CPU: 0 PID: 1 Comm: switch_root Not tainted 3.18.26 #1-NixOS
>> [0.652291]  880002c81880 8800e8e23e28 814bc251 
>> 818541b8
>> [0.652296]  81713d68 8800e8e23ea8 814bb43e 
>> 0001
>> [0.652300]  0010 8800e8e23eb8 8800e8e23e58 
>> 8185dd80
>> [0.652304] Call Trace:
>> [0.652313]  [] dump_stack+0x46/0x58
>> [0.652316]  [] panic+0xc1/0x1eb
>> [0.652321]  [] do_exit+0xac5/0xad0
>> [0.652327]  [] ? vfs_write+0x15c/0x1f0
>> [0.652331]  [] do_group_exit+0x45/0xb0
>> [0.652335]  [] SyS_exit_group+0x14/0x20
>> [0.652338]  [] system_call_fastpath+0x12/0x17
>> [0.652344] Kernel Offset: 0x0 from 0x8100 (relocation range: 
>> 0x8000-0x9fff)
>>
>>
>> Can someone explain to me what I'm doing wrong during the rebuild?
>>
>> _
>>
>> [image: Bazaarvoice]
>>
>> Paul Cooley
>> Senior Dev Ops Engineer
>> o:   m: 281-435-2328
>> e: paul.coo...@bazaarvoice.com
>> Site   |  Blog
>>   |  Twitter
>> 
>>
>>
>>
>>
>>
>> ___
>> nix-dev mailing list
>> nix-dev@lists.science.uu.nl
>> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>>
>> ___
> nix-dev mailing list
> nix-dev@lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Amazon EC2 rebuild switch causes kernel panic

2016-03-14 Thread Roger Qiu
What's happening is the transition from stage 1 booting to stage 2 booting
is failing. The error reported is that the init script that is be executed
once switch_root is executed is non existent. Which could mean your initrd
is corrupted or the build failed for some reason or some other config
problem at stage 1.

If you could inspect the initrd to check if the init script is there...
On 15/03/2016 2:31 AM, "Paul Cooley"  wrote:

> I brought up an AWS instance using nixos-15.09.git.87b377dM-x86_64-pv-ebs
> . After modifying /etc/nixos/configuration.nix to use the
> "amazon-init.nix" rather than "amazon-image.nix" and performing a
> 'nixos-rebuild switch' command, the instance reports the following error.
>
> [fsck.ext3 (1) -- /mnt-root/disk0] fsck.ext3 -a /dev/xvdb
> /dev/xvdb: recovering journal
> /dev/xvdb: clean, 116502/262144 files, 579900/1047168 blocks
> mounting /dev/xvdb on /disk0...
> switch_root: can't execute 
> '/nix/store/z9rp9hzs19pi1788fj8kdkw81mnxsgf1-nixos-15.09.1119.f6d1666/init': 
> No such file or directory
> [0.652277] Kernel panic - not syncing: Attempted to kill init! 
> exitcode=0x0100
> [0.652277]
> [0.652287] CPU: 0 PID: 1 Comm: switch_root Not tainted 3.18.26 #1-NixOS
> [0.652291]  880002c81880 8800e8e23e28 814bc251 
> 818541b8
> [0.652296]  81713d68 8800e8e23ea8 814bb43e 
> 0001
> [0.652300]  0010 8800e8e23eb8 8800e8e23e58 
> 8185dd80
> [0.652304] Call Trace:
> [0.652313]  [] dump_stack+0x46/0x58
> [0.652316]  [] panic+0xc1/0x1eb
> [0.652321]  [] do_exit+0xac5/0xad0
> [0.652327]  [] ? vfs_write+0x15c/0x1f0
> [0.652331]  [] do_group_exit+0x45/0xb0
> [0.652335]  [] SyS_exit_group+0x14/0x20
> [0.652338]  [] system_call_fastpath+0x12/0x17
> [0.652344] Kernel Offset: 0x0 from 0x8100 (relocation range: 
> 0x8000-0x9fff)
>
>
> Can someone explain to me what I'm doing wrong during the rebuild?
>
> _
>
> [image: Bazaarvoice]
>
> Paul Cooley
> Senior Dev Ops Engineer
> o:   m: 281-435-2328
> e: paul.coo...@bazaarvoice.com
> Site   |  Blog
>   |  Twitter
> 
>
>
>
>
>
> ___
> nix-dev mailing list
> nix-dev@lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>
>
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


[Nix-dev] Amazon EC2 rebuild switch causes kernel panic

2016-03-14 Thread Paul Cooley
I brought up an AWS instance using nixos-15.09.git.87b377dM-x86_64-pv-ebs . 
After modifying /etc/nixos/configuration.nix to use the "amazon-init.nix" 
rather than "amazon-image.nix" and performing a 'nixos-rebuild switch' command, 
the instance reports the following error.


[fsck.ext3 (1) -- /mnt-root/disk0] fsck.ext3 -a /dev/xvdb
/dev/xvdb: recovering journal
/dev/xvdb: clean, 116502/262144 files, 579900/1047168 blocks
mounting /dev/xvdb on /disk0...
switch_root: can't execute 
'/nix/store/z9rp9hzs19pi1788fj8kdkw81mnxsgf1-nixos-15.09.1119.f6d1666/init': No 
such file or directory
[0.652277] Kernel panic - not syncing: Attempted to kill init! 
exitcode=0x0100
[0.652277]
[0.652287] CPU: 0 PID: 1 Comm: switch_root Not tainted 3.18.26 #1-NixOS
[0.652291]  880002c81880 8800e8e23e28 814bc251 
818541b8
[0.652296]  81713d68 8800e8e23ea8 814bb43e 
0001
[0.652300]  0010 8800e8e23eb8 8800e8e23e58 
8185dd80
[0.652304] Call Trace:
[0.652313]  [] dump_stack+0x46/0x58
[0.652316]  [] panic+0xc1/0x1eb
[0.652321]  [] do_exit+0xac5/0xad0
[0.652327]  [] ? vfs_write+0x15c/0x1f0
[0.652331]  [] do_group_exit+0x45/0xb0
[0.652335]  [] SyS_exit_group+0x14/0x20
[0.652338]  [] system_call_fastpath+0x12/0x17
[0.652344] Kernel Offset: 0x0 from 0x8100 (relocation range: 
0x8000-0x9fff)


Can someone explain to me what I'm doing wrong during the rebuild?

_

[Bazaarvoice]

Paul Cooley
Senior Dev Ops Engineer
o:   m: 281-435-2328
e: paul.coo...@bazaarvoice.com
Site  |  Blog  |  
Twitter




___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] How to use binaries from other hosts?

2016-03-14 Thread Matthias Beyer
Worked for me, btw.

On 14-03-2016 13:03:25, Matthias Beyer wrote:
> That should be:
> 
> sudo nix-store --import < example.closure
> 
> (note the '<').
> 
> Worked perfectly. Where can I add documentation?
> 
> On 14-03-2016 22:39:02, Brian McKenna wrote:
> > That should be:
> > 
> > sudo nix-store --import example.closure
> > 
> > On 14 March 2016 at 22:35, Brian McKenna  wrote:
> > > You can skip signature checking by using root:
> > >
> > > sudo nix-copy-closure --import example.closure
> > >
> > > I found this on the Nix issue tracker somewhere. It might not be
> > > documented behaviour.
> > >
> > > On 14 March 2016 at 20:07, Matthias Beyer  wrote:
> > >> Hi,
> > >>
> > >> I'm on nixos unstable. As racket does not build and my thinkpad takes 
> > >> hours to
> > >> build it, I got myself a debian VM in my university cloud and compiled 
> > >> racket
> > >> there.
> > >>
> > >> How can I retrieve the closure from there?
> > >>
> > >> I tried _everything_. I cannot nix-copy-closure, as this one does not 
> > >> allow me
> > >> to set the SSH port (which isn't 22 but something above 1).
> > >>
> > >> I tried to nix-store --export, copy via SCP and then nix-store --import, 
> > >> but it
> > >> fails as the closure is not signed...
> > >>
> > >> Can someone please help me with this?
> > >>
> > >> I normally install racket with a nix-shell for my blog environment. I 
> > >> guess I
> > >> should make this shell env persistent to be save of GC, though I cannot 
> > >> find
> > >> documentation on how to _remove_ a persistent shell env... and I want to 
> > >> know
> > >> how to remove it, before making it permanent.
> > >>
> > >> --
> > >> Mit freundlichen Grüßen,
> > >> Kind regards,
> > >> Matthias Beyer
> > >>
> > >> Proudly sent with mutt.
> > >> Happily signed with gnupg.
> > >>
> > >> ___
> > >> nix-dev mailing list
> > >> nix-dev@lists.science.uu.nl
> > >> http://lists.science.uu.nl/mailman/listinfo/nix-dev
> > >>
> 
> -- 
> Mit freundlichen Grüßen,
> Kind regards,
> Matthias Beyer
> 
> Proudly sent with mutt.
> Happily signed with gnupg.



> ___
> nix-dev mailing list
> nix-dev@lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev


-- 
Mit freundlichen Grüßen,
Kind regards,
Matthias Beyer

Proudly sent with mutt.
Happily signed with gnupg.


signature.asc
Description: PGP signature
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] How to use binaries from other hosts?

2016-03-14 Thread Matthias Beyer
That should be:

sudo nix-store --import < example.closure

(note the '<').

Worked perfectly. Where can I add documentation?

On 14-03-2016 22:39:02, Brian McKenna wrote:
> That should be:
> 
> sudo nix-store --import example.closure
> 
> On 14 March 2016 at 22:35, Brian McKenna  wrote:
> > You can skip signature checking by using root:
> >
> > sudo nix-copy-closure --import example.closure
> >
> > I found this on the Nix issue tracker somewhere. It might not be
> > documented behaviour.
> >
> > On 14 March 2016 at 20:07, Matthias Beyer  wrote:
> >> Hi,
> >>
> >> I'm on nixos unstable. As racket does not build and my thinkpad takes 
> >> hours to
> >> build it, I got myself a debian VM in my university cloud and compiled 
> >> racket
> >> there.
> >>
> >> How can I retrieve the closure from there?
> >>
> >> I tried _everything_. I cannot nix-copy-closure, as this one does not 
> >> allow me
> >> to set the SSH port (which isn't 22 but something above 1).
> >>
> >> I tried to nix-store --export, copy via SCP and then nix-store --import, 
> >> but it
> >> fails as the closure is not signed...
> >>
> >> Can someone please help me with this?
> >>
> >> I normally install racket with a nix-shell for my blog environment. I 
> >> guess I
> >> should make this shell env persistent to be save of GC, though I cannot 
> >> find
> >> documentation on how to _remove_ a persistent shell env... and I want to 
> >> know
> >> how to remove it, before making it permanent.
> >>
> >> --
> >> Mit freundlichen Grüßen,
> >> Kind regards,
> >> Matthias Beyer
> >>
> >> Proudly sent with mutt.
> >> Happily signed with gnupg.
> >>
> >> ___
> >> nix-dev mailing list
> >> nix-dev@lists.science.uu.nl
> >> http://lists.science.uu.nl/mailman/listinfo/nix-dev
> >>

-- 
Mit freundlichen Grüßen,
Kind regards,
Matthias Beyer

Proudly sent with mutt.
Happily signed with gnupg.


signature.asc
Description: PGP signature
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] How to use binaries from other hosts?

2016-03-14 Thread Brian McKenna
That should be:

sudo nix-store --import example.closure

On 14 March 2016 at 22:35, Brian McKenna  wrote:
> You can skip signature checking by using root:
>
> sudo nix-copy-closure --import example.closure
>
> I found this on the Nix issue tracker somewhere. It might not be
> documented behaviour.
>
> On 14 March 2016 at 20:07, Matthias Beyer  wrote:
>> Hi,
>>
>> I'm on nixos unstable. As racket does not build and my thinkpad takes hours 
>> to
>> build it, I got myself a debian VM in my university cloud and compiled racket
>> there.
>>
>> How can I retrieve the closure from there?
>>
>> I tried _everything_. I cannot nix-copy-closure, as this one does not allow 
>> me
>> to set the SSH port (which isn't 22 but something above 1).
>>
>> I tried to nix-store --export, copy via SCP and then nix-store --import, but 
>> it
>> fails as the closure is not signed...
>>
>> Can someone please help me with this?
>>
>> I normally install racket with a nix-shell for my blog environment. I guess I
>> should make this shell env persistent to be save of GC, though I cannot find
>> documentation on how to _remove_ a persistent shell env... and I want to know
>> how to remove it, before making it permanent.
>>
>> --
>> Mit freundlichen Grüßen,
>> Kind regards,
>> Matthias Beyer
>>
>> Proudly sent with mutt.
>> Happily signed with gnupg.
>>
>> ___
>> nix-dev mailing list
>> nix-dev@lists.science.uu.nl
>> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>>
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] How to use binaries from other hosts?

2016-03-14 Thread Brian McKenna
You can skip signature checking by using root:

sudo nix-copy-closure --import example.closure

I found this on the Nix issue tracker somewhere. It might not be
documented behaviour.

On 14 March 2016 at 20:07, Matthias Beyer  wrote:
> Hi,
>
> I'm on nixos unstable. As racket does not build and my thinkpad takes hours to
> build it, I got myself a debian VM in my university cloud and compiled racket
> there.
>
> How can I retrieve the closure from there?
>
> I tried _everything_. I cannot nix-copy-closure, as this one does not allow me
> to set the SSH port (which isn't 22 but something above 1).
>
> I tried to nix-store --export, copy via SCP and then nix-store --import, but 
> it
> fails as the closure is not signed...
>
> Can someone please help me with this?
>
> I normally install racket with a nix-shell for my blog environment. I guess I
> should make this shell env persistent to be save of GC, though I cannot find
> documentation on how to _remove_ a persistent shell env... and I want to know
> how to remove it, before making it permanent.
>
> --
> Mit freundlichen Grüßen,
> Kind regards,
> Matthias Beyer
>
> Proudly sent with mutt.
> Happily signed with gnupg.
>
> ___
> nix-dev mailing list
> nix-dev@lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] How to use binaries from other hosts?

2016-03-14 Thread Matthias Beyer
See:

nix-copy-closure --from --use-substitutes -v  banane 
/nix/store/pamgbxci7n1q1s0r3y438k7zc7z3ig1k-racket-6.3
bash: nix-store: command not found
unable to connect to ‘banane’

My host is named "banane", the port and user is set in my .ssh/config file.

On 14-03-2016 10:15:41, Adrien Devresse wrote:
> > I tried _everything_. I cannot nix-copy-closure, as this one does not allow 
> > me
> > to set the SSH port (which isn't 22 but something above 1).
> 
> You can define any host / port matching through the configuration file
> "~/.ssh/config" for any program using SSH.
> 
> Something like
> 
> ""
> Host [youHost]
> port 1
> 
> """
> 
> should do the trick
> 
> Adrien
> 
> 
> Le 14/03/2016 10:07, Matthias Beyer a écrit :
> > Hi,
> >
> > I'm on nixos unstable. As racket does not build and my thinkpad takes hours 
> > to
> > build it, I got myself a debian VM in my university cloud and compiled 
> > racket
> > there.
> >
> > How can I retrieve the closure from there?
> >
> > I tried _everything_. I cannot nix-copy-closure, as this one does not allow 
> > me
> > to set the SSH port (which isn't 22 but something above 1).
> >
> > I tried to nix-store --export, copy via SCP and then nix-store --import, 
> > but it
> > fails as the closure is not signed...
> >
> > Can someone please help me with this?
> >
> > I normally install racket with a nix-shell for my blog environment. I guess 
> > I
> > should make this shell env persistent to be save of GC, though I cannot find
> > documentation on how to _remove_ a persistent shell env... and I want to 
> > know
> > how to remove it, before making it permanent.
> >
> >
> >
> > ___
> > nix-dev mailing list
> > nix-dev@lists.science.uu.nl
> > http://lists.science.uu.nl/mailman/listinfo/nix-dev
> 



> ___
> nix-dev mailing list
> nix-dev@lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev


-- 
Mit freundlichen Grüßen,
Kind regards,
Matthias Beyer

Proudly sent with mutt.
Happily signed with gnupg.


signature.asc
Description: PGP signature
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] How to use binaries from other hosts?

2016-03-14 Thread Adrien Devresse
> I tried _everything_. I cannot nix-copy-closure, as this one does not allow me
> to set the SSH port (which isn't 22 but something above 1).

You can define any host / port matching through the configuration file
"~/.ssh/config" for any program using SSH.

Something like

""
Host [youHost]
port 1

"""

should do the trick

Adrien


Le 14/03/2016 10:07, Matthias Beyer a écrit :
> Hi,
>
> I'm on nixos unstable. As racket does not build and my thinkpad takes hours to
> build it, I got myself a debian VM in my university cloud and compiled racket
> there.
>
> How can I retrieve the closure from there?
>
> I tried _everything_. I cannot nix-copy-closure, as this one does not allow me
> to set the SSH port (which isn't 22 but something above 1).
>
> I tried to nix-store --export, copy via SCP and then nix-store --import, but 
> it
> fails as the closure is not signed...
>
> Can someone please help me with this?
>
> I normally install racket with a nix-shell for my blog environment. I guess I
> should make this shell env persistent to be save of GC, though I cannot find
> documentation on how to _remove_ a persistent shell env... and I want to know
> how to remove it, before making it permanent.
>
>
>
> ___
> nix-dev mailing list
> nix-dev@lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev



signature.asc
Description: OpenPGP digital signature
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] How to use binaries from other hosts?

2016-03-14 Thread Oliver Charles
On Mon, Mar 14, 2016 at 9:08 AM Matthias Beyer 
wrote:

> Hi,
>
> I'm on nixos unstable. As racket does not build and my thinkpad takes
> hours to
> build it, I got myself a debian VM in my university cloud and compiled
> racket
> there.
>
> How can I retrieve the closure from there?
>
> I tried _everything_. I cannot nix-copy-closure, as this one does not
> allow me
> to set the SSH port (which isn't 22 but something above 1).
>

Can you change the port by adding an entry to .ssh/config? That should
allow you to set the port, and I believe nix-copy-closure just calls SSH.
You might need to use /etc/sshd/config, as I'm not sure what user it's
actually making the ssh connection as.

- ocharles
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


[Nix-dev] How to use binaries from other hosts?

2016-03-14 Thread Matthias Beyer
Hi,

I'm on nixos unstable. As racket does not build and my thinkpad takes hours to
build it, I got myself a debian VM in my university cloud and compiled racket
there.

How can I retrieve the closure from there?

I tried _everything_. I cannot nix-copy-closure, as this one does not allow me
to set the SSH port (which isn't 22 but something above 1).

I tried to nix-store --export, copy via SCP and then nix-store --import, but it
fails as the closure is not signed...

Can someone please help me with this?

I normally install racket with a nix-shell for my blog environment. I guess I
should make this shell env persistent to be save of GC, though I cannot find
documentation on how to _remove_ a persistent shell env... and I want to know
how to remove it, before making it permanent.

-- 
Mit freundlichen Grüßen,
Kind regards,
Matthias Beyer

Proudly sent with mutt.
Happily signed with gnupg.


signature.asc
Description: PGP signature
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev