Re: [ *** ] Job anacron.service/stop running (15min 49s / no limit)

2024-02-12 Thread Rainer Dorsch
Hi David and Max,

many thanks for the precise and very helpful answers. I will check the anacron 
status before the next reboot.

Thanks again
Rainer

Am Montag, 12. Februar 2024, 05:20:16 CET schrieb David Wright:
> On Sun 11 Feb 2024 at 20:41:51 (+), Darac Marjal wrote:
> > On 11/02/2024 11:21, Rainer Dorsch wrote:
> > > - How do I set a timeout/limit for anacron, that it cannot block forever
> > > during a reboot?
> > 
> > It may be germane to point out that anacron.service already explicitly
> > sets "TimeoutStopSec=Infinity". So, in the opinion of the developers,
> > the service shouldn't be prematurely killed. Of course you, as the
> > system administrator, always have the right to countermand that sort
> > of decision, but it would be curious to find out why the developers
> > thought they needed to override the systemd default in the first
> > place?
> 
> Bug #915379 explains all: long-running cron jobs, like backups, can
> get killed, and there was also an issue with exim.
> 
> There's mention there of an anacron replacement called cronie, but
> I don't know what the status of this is, besides being in trixie.
> 
> Cheers,
> David.


-- 
Rainer Dorsch
http://bokomoko.de/




[ *** ] Job anacron.service/stop running (15min 49s / no limit)

2024-02-11 Thread Rainer Dorsch
Hello,

I saw during a reboot

[  *** ] Job anacron.service/stop running (15min 49s / no limit)

eventually I did a hard reset, since I was not sure if the system simply hang.

I have two quick questions: 
- How can I found out which process anacron is still running?
- How do I set a timeout/limit for anacron, that it cannot block forever 
during a reboot?

Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




Re: serial-getty@ttyS0.service does not start

2024-01-08 Thread Rainer Dorsch
Hi Michael,

thanks for your quick reply.

Am Sonntag, 7. Januar 2024, 15:06:22 CET schrieb Michael Biebl:
> Am 07.01.24 um 14:45 schrieb Rainer Dorsch:
> 
> > Hello,
> > 
> > I tried to start a serial console on ttyS0, but when I try to start the
> > serial-getty service, it does not return:
> 
> 
> Looks like the service is waiting for the device to appear.
> Do you have a /dev/ttyS0 device?

I get kernel messages through that device on the serial interface using 
console=ttyS0,115200n8 as kernel parameter.

> Can you show the output of
> 
> ls -la /dev/ttyS0
> systemctl status dev-ttyS0.device
> udevadm info /dev/ttyS0

root@master:~# ls -la /dev/ttyS0
crw-rw 1 root dialout 4, 64 Jan  8 22:14 /dev/ttyS0
root@master:~# systemctl status dev-ttyS0.device
● dev-ttyS0.device - /dev/ttyS0
Follows: unit currently follows state of sys-devices-pnp0-00:06-tty-
ttyS0.device
 Loaded: loaded
 Active: active (plugged) since Sun 2024-01-07 14:35:33 CET; 1 day 7h ago
 Device: /sys/devices/pnp0/00:06/tty/ttyS0

Jan 07 14:35:33 master systemd[1]: Found device dev-ttyS0.device - /dev/ttyS0.
root@master:~# udevadm info /dev/ttyS0
P: /devices/pnp0/00:06/tty/ttyS0
M: ttyS0
R: 0
U: tty
D: c 4:64
N: ttyS0
L: 0
E: DEVPATH=/devices/pnp0/00:06/tty/ttyS0
E: DEVNAME=/dev/ttyS0
E: MAJOR=4
E: MINOR=64
E: SUBSYSTEM=tty
E: USEC_INITIALIZED=3388940
E: ID_MM_CANDIDATE=1
E: TAGS=:systemd:
E: CURRENT_TAGS=:systemd:

root@master:~# 


Do you see anything suspicious in the output?

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




serial-getty@ttyS0.service does not start

2024-01-07 Thread Rainer Dorsch
Hello,

I tried to start a serial console on ttyS0, but when I try to start the 
serial-getty service, it does not return:

root@master:~# systemctl status serial-getty@ttyS0.service  
○ serial-getty@ttyS0.service - Serial Getty on ttyS0 
Loaded: loaded (/lib/systemd/system/serial-getty@.service; enabled; 
preset: enabled) 
Active: inactive (dead) 
  Docs: man:agetty(8) 
man:systemd-getty-generator(8) 
https://0pointer.de/blog/projects/serial-console.html 
root@master:~# systemctl start serial-getty@ttyS0.service  

Printing kernel messages on the same console works flawless:

rd@master:~$ cat /proc/cmdline 
BOOT_IMAGE=/vmlinuz-6.1.0-17-amd64 root=/dev/mapper/master--vg-root ro 
console=tty0 console=ttyS0,115200n8 quiet
rd@master:~$ 

Any hint or idea why the serial console is not working is welcome.

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Libreoffice in Debian bookworm-backports starts with 1 pixel wide window

2023-10-30 Thread Rainer Dorsch
Hi,

just FYI:

I hit

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1019423

with Debian bookworm-backports

rd@h370:~/.config/libreoffice/4/user$ apt-cache policy libreoffice
libreoffice:
  Installiert:   4:7.5.6-1~bpo12+1
  Installationskandidat: 4:7.5.6-1~bpo12+1
  Versionstabelle:
 4:7.5.8~rc1-2 100
100 http://deb.debian.org/debian sid/main amd64 Packages
 *** 4:7.5.6-1~bpo12+1 110
110 http://ftp.de.debian.org/debian bookworm-backports/main amd64 
Packages
100 /var/lib/dpkg/status
 4:7.4.7-1 500
500 http://deb.debian.org/debian bookworm/main amd64 Packages
rd@h370:~/.config/libreoffice/4/user$

again.

The same procedure as in 

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1019423#91

solved the problem again.

Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Enter passphrase for SSL/TLS keys for 192.168.0.30:443 (RSA)

2023-10-08 Thread Rainer Dorsch
Am Sonntag, 8. Oktober 2023, 17:32:37 CEST schrieb Jeffrey Walton:
> On Sun, Oct 8, 2023 at 7:53 AM Rainer Dorsch  wrote:
> > I have one machine on which I see during upgrade messages like:
> > 
> > Setting up udev (252.17-1~deb12u1) ...
> >  Enter passphrase for SSL/TLS keys for 192.168.0.30:443 (RSA):
> > Setting up linux-image-6.1.0-13-armmp (6.1.55-1) ...
> > 
> > /etc/kernel/postinst.d/initramfs-tools:
> > update-initramfs: Generating /boot/initrd.img-6.1.0-13-armmp
> > 
> > Broadcast message from root@home (Sun 2023-10-08 13:45:07 CEST):
> > 
> > Password entry required for 'Enter passphrase for SSL/TLS keys for
> > 192.168.0.30:443 (RSA):' (PID 25235).
> > Please enter password with the systemd-tty-ask-password-agent tool.
> > 
> > Does anybody know where they (could) come from?
> 
> It looks like it comes from Apache via debian/ask-for-passphrase :
> <https://janitor.debian.net/git/apache2/commit/5e0a02b0fc6f1928dcf4dc8fc7b98
> 4ba3b8d1f7c/>. It looks like the message was changed recently.
> 
> It looks like the former message was "Apache needs to decrypt your SSL
> Keys for $sitename ($keytype)".

Many thanks. for the useful response.

For me the previous message would have been more useful :-/

Thanks again
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Enter passphrase for SSL/TLS keys for 192.168.0.30:443 (RSA)

2023-10-08 Thread Rainer Dorsch
Hello,

I have one machine on which I see during upgrade messages like:

Setting up udev (252.17-1~deb12u1) ...
 Enter passphrase for SSL/TLS keys for 192.168.0.30:443 (RSA): 

Setting up linux-image-6.1.0-13-armmp (6.1.55-1) ...

/etc/kernel/postinst.d/initramfs-tools:
update-initramfs: Generating /boot/initrd.img-6.1.0-13-armmp

Broadcast message from root@home (Sun 2023-10-08 13:45:07 CEST):

Password entry required for 'Enter passphrase for SSL/TLS keys for 
192.168.0.30:443 (RSA):' (PID 25235).
Please enter password with the systemd-tty-ask-password-agent tool.

Does anybody know where they (could) come from?

Thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




Microphone not recognized on HP Laptop 17-cp2xxx

2023-08-05 Thread Rainer Dorsch
Hi,

I installed bookworm on a HP Laptop 17-cp2xxx, everything works perfectly, 
except the microphone does not show up in alsamixer, KDE plasma and Chromium.

pactl lists two cards, in card #1 I see a analog-input-mic:

rd@laptop:~$ pactl list cards
Card #0
Name: alsa_card.pci-_03_00.1
Driver: module-alsa-card.c
Owner Module: 6
Properties:
alsa.card = "0"
alsa.card_name = "HD-Audio Generic"
alsa.long_card_name = "HD-Audio Generic at 0xc04c8000 irq 82"
alsa.driver_name = "snd_hda_intel"
device.bus_path = "pci-:03:00.1"
sysfs.path = "/devices/pci:00/:00:08.1/:03:00.1/
sound/card0"
device.bus = "pci"
device.vendor.id = "1002"
device.vendor.name = "Advanced Micro Devices, Inc. [AMD/ATI]"
device.product.id = "1640"
device.product.name = "Rembrandt Radeon High Definition Audio 
Controller"
device.string = "0"
device.description = "Rembrandt Radeon High Definition Audio 
Controller"
module-udev-detect.discovered = "1"
device.icon_name = "audio-card-pci"
Profiles:
output:hdmi-stereo: Digital Stereo (HDMI)-Ausgabe (sinks: 1, 
sources: 0, priority: 5900, available: no)
output:hdmi-surround: Digital Surround 5.1 (HDMI)-Ausgabe 
(sinks: 1, sources: 0, priority: 800, available: no)
output:hdmi-surround71: Digital Surround 7.1 (HDMI)-Ausgabe 
(sinks: 1, sources: 0, priority: 800, available: no)
off: Aus (sinks: 0, sources: 0, priority: 0, available: yes)
Active Profile: off
Ports:
hdmi-output-0: HDMI / DisplayPort (type: HDMI, priority: 5900, 
latency offset: 0 usec, not available)
Properties:
device.icon_name = "video-display"
Part of profile(s): output:hdmi-stereo, output:hdmi-
surround, output:hdmi-surround71

Card #1
Name: alsa_card.pci-_03_00.6
Driver: module-alsa-card.c
Owner Module: 7
Properties:
alsa.card = "1"
alsa.card_name = "HD-Audio Generic"
alsa.long_card_name = "HD-Audio Generic at 0xc04c irq 83"
alsa.driver_name = "snd_hda_intel"
device.bus_path = "pci-:03:00.6"
sysfs.path = "/devices/pci:00/:00:08.1/:03:00.6/
sound/card1"
device.bus = "pci"
device.vendor.id = "1022"
device.vendor.name = "Advanced Micro Devices, Inc. [AMD]"
device.product.id = "15e3"
device.product.name = "Family 17h/19h HD Audio Controller"
device.string = "1"
device.description = "Family 17h/19h HD Audio Controller"
module-udev-detect.discovered = "1"
device.icon_name = "audio-card-pci"
Profiles:
input:analog-stereo: Analog Stereo-Eingabe (sinks: 0, sources: 
1, priority: 65, available: no)
output:analog-stereo: Analog Stereo-Ausgabe (sinks: 1, 
sources: 0, priority: 39268, available: yes)
output:analog-stereo+input:analog-stereo: Analog Stereo Duplex 
(sinks: 1, sources: 1, priority: 6565, available: yes)
off: Aus (sinks: 0, sources: 0, priority: 0, available: yes)
Active Profile: output:analog-stereo
Ports:
analog-input-mic: Microphone (type: Mic, priority: 8700, 
latency offset: 0 usec, not available)
Properties:
device.icon_name = "audio-input-microphone"
Part of profile(s): input:analog-stereo, output:analog-
stereo+input:analog-stereo
analog-output-speaker: Speakers (type: Speaker, priority: 
1, latency offset: 0 usec, availability unknown)
Properties:
device.icon_name = "audio-speakers"
Part of profile(s): output:analog-stereo, 
output:analog-stereo+input:analog-stereo
analog-output-headphones: Headphones (type: Headphones, 
priority: 9900, latency offset: 0 usec, not available)
Properties:
device.icon_name = "audio-headphones"
Part of profile(s): output:analog-stereo, 
output:analog-stereo+input:analog-stereo
rd@laptop:~$ 

Any advice or hint how to enable the mic is welcome.

Many thanks
Rainer



signature.asc
Description: This is a digitally signed message part.


linphone and address books

2023-06-02 Thread Rainer Dorsch
Hello,

I am using linphone since quite some time and it works very reliable for me. 
One feature I am missing is the import of existing address books (either from 
a vcf file, a carddav server or similar). Read only is sufficient for me. I see 
in settings, there is an advanced menu, which has an entry address book 
sources. But then it seems I need a plugin for that? Can anybody tell if and 
how that works?

Another minor issue I have is that an ongoing call in linphone does not 
prevent KDE to go into suspend mode, if there is no user input.

Alternatively, are there in bookworm alternative SIP clients, which you are 
recommending and integrate well with KDE Plasma?

Any hint or advice is welcome.

Many thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




virt-manager guest does not start anymore after upgrade to bookworm / opengl is not available

2023-05-07 Thread Rainer Dorsch
 5.0 seconds = 30.001 FPS
151 frames in 5.0 seconds = 29.998 FPS
151 frames in 5.0 seconds = 30.005 FPS


I configured a virtio video device, if I remove 3D acceleration, the guest 
starts w/o a problem.

Can anybody tell what broke in the 3D acceleration during the upgrade?

Any hint or advice is welcome :-)

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Hibernate in bookworm

2023-04-22 Thread Rainer Dorsch
Am Samstag, 22. April 2023, 20:21:03 CEST schrieben Sie:
> Try running a `sync` first to write all contents of RAM to disk.

That does not change anything. Screen becomes black, but then it feels like it 
is resuming immediately (without going through book, if feels more like a 
resume as you would expect it from suspend-to-RAM.

I get an error, but this looks like the error is reported during the what 
feels like a resume phase.

root@h370:~# echo disk > /sys/power/state
-bash: echo: write error: Device or resource busy
root@h370:~#

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Hibernate in bookworm

2023-04-22 Thread Rainer Dorsch
Hi,

I just tried to hibernate a system which I upgraded from bullseye to bookworm 
and it resumed and never reached the off state. I don't recall that there were 
hibernation problems in bullseye on that system. 

I tried out of KDE Plasma, but I also tried from the cmdline

root@h370:~# echo disk > /sys/power/state
-bash: echo: write error: Device or resource busy
root@h370:~# 

Since

https://wiki.debian.org/Hibernation

looks somewhat outdated (describes Jessie and Lenny configurations), I followed 
Arch and kernel documentation

https://wiki.archlinux.org/title/Power_management#Power_management
https://docs.kernel.org/admin-guide/pm/sleep-states.html?
highlight=image_size#basic-sysfs-interfaces-for-system-suspend-and-hibernation

Both

# systemctl hibernate

and 

# echo disk > /sys/power/state

do not bring the system in hibernate mode (=suspend to disk).

The config I see on my system:

root@h370:~# swapon
NAME   TYPE   SIZE USED PRIO
/dev/dm-2  partition 15.9G 8.1G   -2
/dev/zram0 partition  256M 256M  100
root@h370:~# cat /sys/power/resume
254:2
root@h370:~# lsblk /dev/dm-2 
NAMEMAJ:MIN RM  SIZE RO TYPE MOUNTPOINTS
b370--vg-swap_1 254:20 15.9G  0 lvm  [SWAP]
root@h370:~# cat /proc/cmdline 
BOOT_IMAGE=/vmlinuz-6.1.0-7-amd64 root=/dev/mapper/b370--vg-root ro quiet
root@h370:~# cat /sys/power/image_size 
13375987712
root@h370:~# 

Any hints are welcome
Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




Re: Permission Questions

2021-08-31 Thread Rainer Dorsch
Am Dienstag, 31. August 2021, 00:00:02 CEST schrieb Greg Wooledge:
> On Mon, Aug 30, 2021 at 09:29:14PM +, Andy Smith wrote:
> > Hello,
> > 
> > On Mon, Aug 30, 2021 at 05:07:16PM -0400, Greg Wooledge wrote:
> > > unicorn:~$ strace bash -c 'echo stuff >> /tmp/123'
> > > [...]
> > > openat(AT_FDCWD, "/tmp/123", O_WRONLY|O_CREAT|O_APPEND, 0666) = -1
> > > EACCES (Permission denied)
> > > 
> > > As far as I can see, this is a kernel bug.  Unless I'm overlooking
> > > something...?
> > 
> > I think it's the sysctl fs.protected_regular:
> > https://unix.stackexchange.com/a/503169
> 
> I think you're right.  The changed behavior doesn't happen in /srv (only
> in /tmp), nor does it happen on a buster system.
> 
> According to <https://www.spinics.net/lists/fedora-devel/msg252453.html>
> and <https://github.com/systemd/systemd/blob/main/NEWS>, the change
> actually happened in... wait for it... systemd.
> 
> *sigh*

Hi Andy and Greg,

many thanks for you very helpful replies, that explains the behavior fully.

Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Permission Questions

2021-08-30 Thread Rainer Dorsch
Am Montag, 30. August 2021, 21:58:47 CEST schrieb Greg Wooledge:
> On Mon, Aug 30, 2021 at 09:01:33PM +0200, Rainer Dorsch wrote:
> > rd@h370:~/tmp.nobackup$ ls -l /tmp/123
> > -rw-rw-r-- 1 rd users 0 30. Aug 20:42 /tmp/123
> > 
> > User ka overwrites it with the content of another file (atomically):
> > 
> > ka@h370:~$ echo test > 123
> > ka@h370:~$ mv 123 /tmp/123
> > mv: cannot move '123' to '/tmp/123': Operation not permitted
> 
> In order to perform this move, ka would first need to unlink the
> existing /tmp/123 file.  ka cannot do that, because the /tmp directory
> is "sticky".  Only "rd" (or root) can do it.
> 
> > Maybe moving removes a node in /tmp,
> 
> Yes.  You can verify with strace if you're curious enough.
> 
> > so I am trying to append to the file as a
> > test:
> > 
> > -rw-rw-r-- 1 rd users 0 30. Aug 20:35 /tmp/123
> > 
> > ka@h370:~$ id
> > uid=1401(ka) gid=1401(ka) Gruppen=1401(ka),20(dialout),21(fax),24(cdrom),
> > 30(dip),44(video),46(plugdev),100(users),1000(sispmctl)
> > ka@h370:~$ ls -l /tmp/123
> > -rw-rw-r-- 1 rd users 0 30. Aug 20:35 /tmp/123
> > ka@h370:~$ echo test >> /tmp/123
> > -bash: /tmp/123: Permission denied
> 
> That one should have worked, due to the secondary group membership.
> 
> unicorn:~$ sudo touch /tmp/123; sudo chgrp video /tmp/123; sudo chmod 664
> /tmp/123 [sudo] password for greg:
> unicorn:~$ ls -l /tmp/123
> -rw-rw-r-- 1 root video 0 Aug 30 15:56 /tmp/123
> unicorn:~$ id
> uid=1000(greg) gid=1000(greg)
> groups=1000(greg),24(cdrom),25(floppy),27(sudo),29(audio),30(dip),44(video)
> ,46(plugdev),108(netdev) unicorn:~$ echo stuff >> /tmp/123
> unicorn:~$
> 
> It works for me.  Is your /tmp a non-Unix file system, or is it mounted
> with any unusual options?

Thanks for testing and your quick response.

Hmm...your example works for me as well

rd@h370:~/tmp.nobackup$ sudo touch /tmp/123; sudo chgrp video /tmp/123; sudo 
chmod 664 /tmp/123
[sudo] Passwort für rd: 
rd@h370:~/tmp.nobackup$ ls -l /tmp/123
-rw-rw-r-- 1 root video 0 30. Aug 22:52 /tmp/123
rd@h370:~/tmp.nobackup$ id
uid=2809(rd) gid=2809(rd) Gruppen=2809(rd),4(adm),20(dialout),21(fax),
24(cdrom),25(floppy),27(sudo),30(dip),44(video),46(plugdev),100(users),
114(lpadmin),118(scanner),126(docker),127(vboxusers),130(i2psvc),
131(wireshark),141(libvirt),1000(sispmctl)
rd@h370:~/tmp.nobackup$ echo stuff >> /tmp/123
rd@h370:~/tmp.nobackup$ 

As soon as I do a chown to a non-root user on /tmp/123 it does not work for me 
anymore.

Is root somehow treated differently as other users?

I am not aware of special mount options for /tmp, it should be a standard 
installation:

rd@h370:~/tmp.nobackup$ mount
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs 
(rw,nosuid,relatime,size=16342996k,nr_inodes=4085749,mode=755)
devpts on /dev/pts type devpts 
(rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs 
(rw,nosuid,nodev,noexec,relatime,size=3273064k,mode=755)
/dev/mapper/b370--vg-root on / type ext4 (rw,relatime,errors=remount-ro)
securityfs on /sys/kernel/security type securityfs 
(rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
cgroup2 on /sys/fs/cgroup type cgroup2 
(rw,nosuid,nodev,noexec,relatime,nsdelegate,memory_recursiveprot)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs 
(rw,nosuid,nodev,noexec,relatime)
none on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs 
(rw,relatime,fd=30,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=13462)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
fusectl on /sys/fs/fuse/connections type fusectl 
(rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
sunrpc on /run/rpc_pipefs type rpc_pipefs (rw,relatime)
/dev/sda2 on /boot type ext2 (rw,relatime)
/dev/sda1 on /boot/efi type vfat 
(rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-
ro)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc 
(rw,nosuid,nodev,noexec,relatime)
-hosts on /mnt/net type autofs 
(rw,relatime,fd=6,pgrp=1674,timeout=60,minproto=5,maxproto=5,indirect,pipe_ino=19859)
tmpfs on /run/user/113 type tmpfs 
(rw,nosuid,nodev,relatime,size=3273064k,n

Permission Questions

2021-08-30 Thread Rainer Dorsch
Hi,

I am looking for advice how to implement best this kind of usecase:

User rd creates a file on /tmp:

rd@h370:~/tmp.nobackup$ touch /tmp/123
rd@h370:~/tmp.nobackup$ chgrp users /tmp/123
rd@h370:~/tmp.nobackup$ chmod g+w /tmp/123
rd@h370:~/tmp.nobackup$ ls -l /tmp/123
-rw-rw-r-- 1 rd users 0 30. Aug 20:42 /tmp/123
rd@h370:~/tmp.nobackup$ 

User ka overwrites it with the content of another file (atomically):

ka@h370:~$ echo test > 123
ka@h370:~$ mv 123 /tmp/123
mv: cannot move '123' to '/tmp/123': Operation not permitted
ka@h370:~$ id
uid=1401(ka) gid=1401(ka) groups=1401(ka),20(dialout),21(fax),24(cdrom),
30(dip),44(video),46(plugdev),100(users),1000(sispmctl)
ka@h370:~$ 

Although ka has write permissions as group member, this does not work.

Maybe moving removes a node in /tmp, so I am trying to append to the file as a 
test:

rd@h370:~/tmp.nobackup$ touch /tmp/123 
rd@h370:~/tmp.nobackup$ chgrp users /tmp/123 
rd@h370:~/tmp.nobackup$ chmod g+w /tmp/123 
rd@h370:~/tmp.nobackup$ ls -l /tmp/123 
-rw-rw-r-- 1 rd users 0 30. Aug 20:35 /tmp/123 
rd@h370:~/tmp.nobackup$ 

ka@h370:~$ id 
uid=1401(ka) gid=1401(ka) Gruppen=1401(ka),20(dialout),21(fax),24(cdrom),
30(dip),44(video),46(plugdev),100(users),1000(sispmctl) 
ka@h370:~$ ls -l /tmp/123 
-rw-rw-r-- 1 rd users 0 30. Aug 20:35 /tmp/123 
ka@h370:~$ echo test >> /tmp/123 
-bash: /tmp/123: Permission denied 
ka@h370:~$ 

Even that does not work. Why not?

Is there something special with /tmp?

kan@h370:~$ ls -ld /tmp
drwxrwxrwt 26 root root 32768 Aug 30 20:51 /tmp
ka@h370:~$ 


Now attempting to do the same in a regular home directory:

rd@h370:~/tmp.nobackup$ touch 123
rd@h370:~/tmp.nobackup$ chgrp users 123
rd@h370:~/tmp.nobackup$ chmod g+w 123
rd@h370:~/tmp.nobackup$ 

ka@h370:~$ echo test >> /home/rd/tmp.nobackup/123
ka@h370:~$

Appending works!

But replacing the file with a mv command does not work in the /home directory:

rd@h370:~/tmp.nobackup$ touch 123   
rd@h370:~/tmp.nobackup$ ls -l 123 
-rw-rw-r-- 1 rd users 5 30. Aug 20:39 123 
rd@h370:~/tmp.nobackup$ 

ka@h370:~$ mv 123 /home/rd/tmp.nobackup/123 
mv: cannot move '123' to '/home/rd/tmp.nobackup/123': Permission denied 
ka@h370:~$ 

If I redirect the output and overwrite the file instead of using mv,  the 
system allows me to do that:

rd@h370:~/tmp.nobackup$ touch 123
rd@h370:~/tmp.nobackup$ chgrp users 123
rd@h370:~/tmp.nobackup$ chmod g+w 123
rd@h370:~/tmp.nobackup$ ls -l 123
-rw-rw-r-- 1 rd users 0 30. Aug 20:51 123
rd@h370:~/tmp.nobackup$ 

ka@h370:~$ echo test > 123
ka@h370:~$ cat 123 > /home/rd/tmp.nobackup/123 
ka@h370:~$ cat /home/rd/tmp.nobackup/123
test
ka@h370:~$ 

It is weird that mv is forbidden, but redirecting the output is allowed. The 
end result on the file system would be the same!

Downside of redirecting is that /home/rd/tmp.nobackup/123 is not updated 
atomically (assuming another process is reading it asynchronically).

So essentially what I want to achieve:
- Updating a file atomically
- Preferably in /tmp

Any advice or hint is welcome.

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Strange emacs behavior after upgrade to bullseye

2021-04-22 Thread Rainer Dorsch
Hi David,

I did some more testing, you can see the effect on bullseye without vboxsf even 
on a ext4 filesystem.

Am Mittwoch, 21. April 2021, 20:49:14 CEST schrieb David Wright:
[...deleted a lot of history]
> > -> buster emacs did not care at all about .# on filesystems which do not
> > support symlinks. Somehow the permissions changed while the system was on
> > buster, possibly by virtualbox or by me myself in an accidential or
> > intended chmod -R a-w  or something similar. I noticed the error but
> > reverted it only for the visible files. But since buster emacs did not
> > care nobody noticed.
> I can't reproduce that. I get locks (that are files) and autosave
> files, both these being listed in the usual manner in each user's own
> respective ~/.emacs.d/.saves--~ files.
> However, AIUI locks only get created by the user who owns the directory
> (I assume), and not by others. In your case, the owner was root, and
> you were not running emacs as root.
> 
> Also bear in mind that locks aren't created until a need arises.
> Opening a file in emacs is not enough: you have to modify the buffer.
> 
> Upon attempting to save a file being edited by several users, I get
> the expected response with the user@host and PID of any valid lock.
> I also observe the use of ~/.emacs.d/%backup%~ when an instance won't
> overwrite the normal backup file, filename~, which it realises it
> didn't write itself, perhaps.

I did go to a buster system with btrfs:

rd@master:~$ touch test.txt
rd@master:~$ touch .#test.txt
rd@master:~$ chmod a-w .#test.txt
rd@master:~$ emacs test.txt
 
works without emacs complaining about anything.

.# files are created as symlinks. I had no filesystem which does not support 
symlinks on that system.

> > -> bullseye emacs not does not create the .# files on file systems, if
> > they
> > don't have symlink support. But it finds them and puts the file in
> > read-only mode, if it is there. In addition, it tries to cleanup and
> > delete these files, which failed due to the wrong permission.
> > 
> > Even on a file system which supports symlinks, the problem can be easily
> > reproduced by
> > 
> > rd@h370:~$ touch test.txt
> > rd@h370:~$ touch .#test.txt
> > rd@h370:~$ chmod a-w .#test.txt
> > rd@h370:~$ emacs test.txt
> > 
> > What is somewhat ugly is that after toggling read-only mode and editing
> > the
> > file, I cannot leave emacs anymore, it hangs.
> > 
> > I am undecided if that is a bug and I should report it or a real corner
> > case which is not worth to invest more time.
> 
> When I start (buster) emacs with a fake, empty lock(file), even one
> that I own like the above, it's not refreshed, but merely ignored.
> Nor is the fake lock removed when emacs exits. I would assume that
> a lock only works if the information it holds is valid, as far as
> can be determined. I haven't bothered to check what happens with
> manifestly stale locks (ie holding verifiable information).
> 
> I don't know how vboxsf is implemented, but I think it would be
> necessary to disentangle the effects of the underlying components,
> filesystem, OS, access method, before attributing strange behaviour
> to emacs.

On the bullseye system with ext4 (but I do not expect that ext4 vs btrfs makes 
a difference):

rd@h370:~$ touch test.txt
rd@h370:~$ touch .#test.txt
rd@h370:~$ chmod a-w .#test.txt
rd@h370:~$ emacs test.txt
 
opens test.txt as read only and if I modify it and try to leave emacs it even 
hangs.

Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Strange emacs behavior after upgrade to bullseye

2021-04-20 Thread Rainer Dorsch
Am Dienstag, 20. April 2021, 17:08:57 CEST schrieb Stefan Monnier:
> > Because the error says it cannot use LOCKS.
> > Because you can't do Unix file locking on a non-Unix file system.
> > The error does NOT say "Permission denied".
> 
> FWIW, the error comes from Emacs's own locking code which doesn't seem
> to use unix file locking, so the problem comes from elsewhere.
> 
> Emacs implements its locking protocol using symlinks with names
> that look like `.#` and whose content looks like
> `u...@host.pid:BOOT_TIME`.
> 
> 
> Stefan "still not sure exactly where it goes wrong"

Hi Stefan,

many thanks for that excellent diagnosis, that really helped to trace it down:

- indeed vboxsf does not support symlinks (at least if ntfs is shared). But 
instead of the symlinks there were real files. I assume a prior version of 
emacs created them and used this as backup if the symlinks did not work on a 
filesystem

- These files had permission 555 instead of 777. Changing this back (?) to 777 
resolved the problem.

How that happened I cannot tell. I do not even understand what these 
permissions mean on vboxsf, apparently they do at least something.

Maybe one explanation model:

-> I noticed that the timestamp of the .# lock files were super old (2019) on 
the vboxsf file system even for files which I touched many times with emacs 
since then
-> I noticed that if I edit these files with emacs the .# lock files are not 
created anymore on the vboxsf filesystem by bullseye's emacs, but they get 
removed if I close bullseye's emacs

So I speculate

-> stretch emacs used .# files instead of .# symlinks, if the file system did 
not support symlinks. The content of the file contains the information which is 
otherwise encoded in the symlink target

-> buster emacs did not care at all about .# on filesystems which do not 
support symlinks. Somehow the permissions changed while the system was on 
buster, possibly by virtualbox or by me myself in an accidential or intended 
chmod -R a-w  or something similar. I noticed the error but reverted it only 
for the visible files. But since buster emacs did not care nobody noticed.

-> bullseye emacs not does not create the .# files on file systems, if they 
don't have symlink support. But it finds them and puts the file in read-only 
mode, if it is there. In addition, it tries to cleanup and delete these files, 
which failed due to the wrong permission.

Even on a file system which supports symlinks, the problem can be easily 
reproduced by

rd@h370:~$ touch test.txt
rd@h370:~$ touch .#test.txt
rd@h370:~$ chmod a-w .#test.txt
rd@h370:~$ emacs test.txt

What is somewhat ugly is that after toggling read-only mode and editing the 
file, I cannot leave emacs anymore, it hangs.

I am undecided if that is a bug and I should report it or a real corner case 
which is not worth to invest more time.

Thanks again, that was a great help.
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Strange emacs behavior after upgrade to bullseye

2021-04-20 Thread Rainer Dorsch
Am Dienstag, 20. April 2021, 13:50:14 CEST schrieb to...@tuxteam.de:
> On Tue, Apr 20, 2021 at 07:28:19AM -0400, Greg Wooledge wrote:
> > On Tue, Apr 20, 2021 at 12:39:13PM +0200, to...@tuxteam.de wrote:
> > > On Tue, Apr 20, 2021 at 12:00:05PM +0200, Rainer Dorsch wrote:
> > > > For me the crucial message is
> > > > 
> > > > basic-save-buffer-2: Unlocking file: Operation not permitted,
> > > > /mnt/dor1rt/Local/ Managed/sb.blog
> > > 
> > > Anyway, this is a good hint. See
> > > 
> > >   "18.3.4 Protection against Simultaneous Editing"
> > > 
> > > in the Emacs user manual (or, if you prefer reading in a browser,
> > > here [1].
> > > 
> > > But your permissions set up is... strange. The above behaviour
> > > doesn't look plausible to me. Unless rd is actually root.
> > 
> > Or /mnt/dor1rt/Local/ is on a non-Unix file system.  Perhaps it's a
> > removable USB device with an NTFS or FAT type file system.  Or perhaps
> > it's some sort of network file system whose underlying implementation
> > is not Unix-based.
> 
> Yes, non-Unix file system os definitely a reasonable option: the
> /mnt/ part (and the 777 modes everywhere) could be seen as a
> hint :-)

Yes, correct, its mounted through virtualbox (vboxsf) and the host is a window 
system which uses NTFS (I think). From a permission perspective 777 should be 
sufficient though. The question is why does emacs think that is not enough, and 
opens it as read-only? And even if I toggle the read-only mode, it complains 
while writing...

thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




Re: Strange emacs behavior after upgrade to bullseye

2021-04-20 Thread Rainer Dorsch
Just another update which makes emacs behavior even stranger:

Even though emacs reports when saving

basic-save-buffer-2: Unlocking file: Operation not permitted,
 /mnt/dor1rt/Local/ Managed/sb.blog

the file gets saved!

I think somehow emacs gets out of sync with the real system.

Rainer


Am Dienstag, 20. April 2021, 12:00:05 CEST schrieb Rainer Dorsch:
> Am Montag, 19. April 2021, 22:25:44 CEST schrieb to...@tuxteam.de:
> > On Mon, Apr 19, 2021 at 06:48:41PM +0200, Rainer Dorsch wrote:
> > > Hello,
> > > 
> > > I hit a strange emacs issue, which appeared after upgrading to bullseye
> > > (I
> > > think):
> > > 
> > > I have a virtualbox filesystem mounted using the standard virtualbox
> > > mechanisms:
> > > 
> > > rd@Testing:~$ mount |grep dor1rt
> > > dor1rt on /mnt/dor1rt type vboxsf (rw,nodev,relatime)
> > > rd@Testing:~$
> > > 
> > > rd@Testing:~$ ls -l /mnt/dor1rt/Local/Managed/sb.blog
> > > -rwxrwxrwx 1 root root 47086 Apr 19 13:40
> > > /mnt/dor1rt/Local/Managed/sb.blog
> > > rd@Testing:~$
> > 
> > Perhaps Emacs is trying to write a backup file to the directory.
> > Does it have write access to the containing directory?
> > 
> > Cf. the variable `make-backup-files' and those linked in its doc
> > (for this, do C-h v make-backup-files).
> 
> There is nothing which would not allow emacs to write a backup file in that
> directory
> 
> rd@Testing:~/local/Managed$ touch test.txt
> rd@Testing:~/local/Managed$ ls -l test.txt
> -rwxrwxrwx 1 root root 0 Apr 20 11:48 test.txt
> rd@Testing:~/local/Managed$ rm -rf test.txt
> rd@Testing:~/local/Managed$
> 
> For me the crucial message is
> 
> basic-save-buffer-2: Unlocking file: Operation not permitted,
> /mnt/dor1rt/Local/ Managed/sb.blog
> 
> (~/local is a symlink to /mnt/dor1rt/Local/)
> 
> What does this message exactly mean and what is emacs trying to do here?
> 
> Other editors (vi, kate) don't report any issue when performain an edit
> operation. Is emacs trying to derive permissions in a different way?
> 
> Thanks
> Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




Re: Strange emacs behavior after upgrade to bullseye

2021-04-20 Thread Rainer Dorsch
Am Montag, 19. April 2021, 22:25:44 CEST schrieb to...@tuxteam.de:
> On Mon, Apr 19, 2021 at 06:48:41PM +0200, Rainer Dorsch wrote:
> > Hello,
> > 
> > I hit a strange emacs issue, which appeared after upgrading to bullseye (I
> > think):
> > 
> > I have a virtualbox filesystem mounted using the standard virtualbox
> > mechanisms:
> > 
> > rd@Testing:~$ mount |grep dor1rt
> > dor1rt on /mnt/dor1rt type vboxsf (rw,nodev,relatime)
> > rd@Testing:~$
> > 
> > rd@Testing:~$ ls -l /mnt/dor1rt/Local/Managed/sb.blog
> > -rwxrwxrwx 1 root root 47086 Apr 19 13:40
> > /mnt/dor1rt/Local/Managed/sb.blog
> > rd@Testing:~$
> 
> Perhaps Emacs is trying to write a backup file to the directory.
> Does it have write access to the containing directory?
> 
> Cf. the variable `make-backup-files' and those linked in its doc
> (for this, do C-h v make-backup-files).
> 

There is nothing which would not allow emacs to write a backup file in that 
directory

rd@Testing:~/local/Managed$ touch test.txt
rd@Testing:~/local/Managed$ ls -l test.txt
-rwxrwxrwx 1 root root 0 Apr 20 11:48 test.txt
rd@Testing:~/local/Managed$ rm -rf test.txt
rd@Testing:~/local/Managed$

For me the crucial message is

basic-save-buffer-2: Unlocking file: Operation not permitted, /mnt/dor1rt/Local/
Managed/sb.blog

(~/local is a symlink to /mnt/dor1rt/Local/)

What does this message exactly mean and what is emacs trying to do here? 

Other editors (vi, kate) don't report any issue when performain an edit 
operation. Is emacs trying to derive permissions in a different way?

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Strange emacs behavior after upgrade to bullseye

2021-04-19 Thread Rainer Dorsch
Hello,

I hit a strange emacs issue, which appeared after upgrading to bullseye (I 
think):

I have a virtualbox filesystem mounted using the standard virtualbox 
mechanisms:

rd@Testing:~$ mount |grep dor1rt
dor1rt on /mnt/dor1rt type vboxsf (rw,nodev,relatime)
rd@Testing:~$

rd@Testing:~$ ls -l /mnt/dor1rt/Local/Managed/sb.blog
-rwxrwxrwx 1 root root 47086 Apr 19 13:40 /mnt/dor1rt/Local/Managed/sb.blog
rd@Testing:~$

While e.g. the standard KDE editor has no problems opening, editing, and 
saving the file, emacs opens the file in read-only mode. I can disable 
read-only 
mode, but emacs refuses to write, I get "Unlocking file: Operation not 
permitted." Even worse, even if I try to save to ~/ I get the same unlocking 
error. 

Here is what I get in the *Messages* buffer:

Loading /etc/emacs/site-start.d/00debian.el (source)...done
Loading /etc/emacs/site-start.d/50asymptote.el (source)...done
Loading /etc/emacs/site-start.d/50autoconf.el (source)...done
Loading /etc/emacs/site-start.d/50cmake-data.el (source)...done
Loading /etc/emacs/site-start.d/50dictionaries-common.el (source)...
Loading debian-ispell...
Loading /var/cache/dictionaries-common/emacsen-ispell-default.el 
(source)...done
Loading debian-ispell...done
Loading /var/cache/dictionaries-common/emacsen-ispell-dicts.el (source)...done
Loading /etc/emacs/site-start.d/50dictionaries-common.el (source)...done
Loading /etc/emacs/site-start.d/50festival.el (source)...done
Loading /etc/emacs/site-start.d/50latex-cjk-common.el (source)...
Loading /usr/share/emacs/site-lisp/latex-cjk-common/cjk-enc.el (source)...done
Loading /etc/emacs/site-start.d/50latex-cjk-common.el (source)...done
Loading /etc/emacs/site-start.d/50latex-cjk-thai.el (source)...done
Loading /etc/emacs/site-start.d/50latexmk.el (source)...done
Loading /etc/emacs/site-start.d/50texlive-lang-english.el (source)...done
Loading /home/rd/.emacs.d/lisp/plantuml-helpers.el (source)...done
Loading /home/rd/.emacs.d/lisp/melpa.el (source)...done
For information about GNU Emacs and the GNU system, type C-h C-a.
File exists, but cannot be read
funcall-interactively: Buffer is read-only: #
C-M-g is undefined
completing-read-default: Command attempted to use minibuffer while in minibuffer
Quit
Read-Only mode disabled in current buffer
You can run the command ‘read-only-mode’ with C-x C-q
Read-Only mode disabled in current buffer
Saving file /home/rd/local/Managed/sb.blog...
basic-save-buffer-2: Unlocking file: Operation not permitted, /mnt/dor1rt/Local/
Managed/sb.blog
set-visited-file-name: Unlocking file: Operation not permitted, /mnt/dor1rt/
Local/Managed/sb.blog
Mark set

Any idea or hint how to fix or work around this issue is welcome.

Thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




Re: Sound issue in bulleye with USB Headset and Internal Audio

2021-04-07 Thread Rainer Dorsch
Am Mittwoch, 7. April 2021, 20:38:46 CEST schrieb Rainer Dorsch:
> Am Mittwoch, 7. April 2021, 19:47:47 CEST schrieb Andrei POPESCU:
> > On Mi, 07 apr 21, 18:39:21, Rainer Dorsch wrote:
> > > Hello,
> > > 
> > > I have a bullseye system with an on-board Intel sound device and a
> > > Logitech
> > > USB headset. Everything works perfect, if I boot without the USB headset
> > > plugged in. Both devices are detected and I can switch between them as
> > > expected. If I boot with the USB headset plugged in, inxi still finds
> > > both
> > > devices, but pacmd list-cards outputs only the USB headset. I am
> > > wondering
> > > if that is a pulseaudio feature or a bug.
> > 
> > Please post the output of 'aplay -l' in both cases.
> 
> [...]

Small update: I cannot really repro anymore that the on-board sound works, 
even if I boot w/o a headset, I saw this correlation several times in the 
past, but right now, pulseaudio always seems to be unhappy with on-board 
sound, e.g. if I boot without USB headset:

rd@h370:~$ pacmd list-cards
0 card(s) available.
rd@h370:~$ aplay -l
 List of PLAYBACK Hardware Devices 
card 0: PCH [HDA Intel PCH], device 0: ALC887-VD Analog [ALC887-VD Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 1: ALC887-VD Digital [ALC887-VD Digital]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 8: HDMI 2 [HDMI 2]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 9: HDMI 3 [HDMI 3]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 10: HDMI 4 [HDMI 4]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
rd@h370:~$ 

Any idea or hint is welcome.

Regards
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Sound issue in bulleye with USB Headset and Internal Audio

2021-04-07 Thread Rainer Dorsch
Am Mittwoch, 7. April 2021, 19:47:47 CEST schrieb Andrei POPESCU:
> On Mi, 07 apr 21, 18:39:21, Rainer Dorsch wrote:
> > Hello,
> > 
> > I have a bullseye system with an on-board Intel sound device and a
> > Logitech
> > USB headset. Everything works perfect, if I boot without the USB headset
> > plugged in. Both devices are detected and I can switch between them as
> > expected. If I boot with the USB headset plugged in, inxi still finds both
> > devices, but pacmd list-cards outputs only the USB headset. I am wondering
> > if that is a pulseaudio feature or a bug.
> 
> Please post the output of 'aplay -l' in both cases.

For me it looks identical, but see yourself:

If USB headset is plugged at boot:

rd@h370:~$ aplay -l
 List of PLAYBACK Hardware Devices 
card 0: PCH [HDA Intel PCH], device 0: ALC887-VD Analog [ALC887-VD Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 1: ALC887-VD Digital [ALC887-VD Digital]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 8: HDMI 2 [HDMI 2]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 9: HDMI 3 [HDMI 3]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 10: HDMI 4 [HDMI 4]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: Headset [Logitech USB Headset], device 0: USB Audio [USB Audio]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
rd@h370:~$ 

If USB headset is not plugged at boot, before plugging the headset:

rd@h370:~$ aplay -l
 List of PLAYBACK Hardware Devices 
card 0: PCH [HDA Intel PCH], device 0: ALC887-VD Analog [ALC887-VD Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 1: ALC887-VD Digital [ALC887-VD Digital]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 8: HDMI 2 [HDMI 2]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 9: HDMI 3 [HDMI 3]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 10: HDMI 4 [HDMI 4]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
rd@h370:~$ 

If USB headset is not plugged at boot, after plugging the headset:

rd@h370:~$ aplay -l
 List of PLAYBACK Hardware Devices 
card 0: PCH [HDA Intel PCH], device 0: ALC887-VD Analog [ALC887-VD Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 1: ALC887-VD Digital [ALC887-VD Digital]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 8: HDMI 2 [HDMI 2]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 9: HDMI 3 [HDMI 3]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 10: HDMI 4 [HDMI 4]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: Headset [Logitech USB Headset], device 0: USB Audio [USB Audio]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
rd@h370:~$ 

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Sound issue in bulleye with USB Headset and Internal Audio

2021-04-07 Thread Rainer Dorsch
t;0a44"
device.product.name = "Headset H390"
device.serial = "Logitech_Logitech_USB_Headset"
device.form_factor = "headset"
device.string = "1"
device.description = "Headset H390"
module-udev-detect.discovered = "1"
device.icon_name = "audio-headset-usb"
device.intended_roles = "phone"
profiles:
input:mono-fallback: Mono-Eingabe (priority 1, available: 
unknown)
input:multichannel-input: Mehrkanal-Eingabe (priority 1, 
available: unknown)
output:analog-stereo: Analog Stereo-Ausgabe (priority 6500, 
available: unknown)
output:analog-stereo+input:mono-fallback: Analog Stereo-
Ausgabe + Mono-Eingabe (priority 6501, available: unknown)
output:analog-stereo+input:multichannel-input: Analog Stereo-
Ausgabe + Mehrkanal-Eingabe (priority 6501, available: unknown)
off: Aus (priority 0, available: unknown)
active profile: 
sinks:
alsa_output.usb-Logitech_Logitech_USB_Headset-00.analog-
stereo/#1: Headset H390 Analog Stereo
sources:
alsa_output.usb-Logitech_Logitech_USB_Headset-00.analog-
stereo.monitor/#1: Monitor of Headset H390 Analog Stereo
alsa_input.usb-Logitech_Logitech_USB_Headset-00.mono-fallback/
#2: Headset H390 Mono
ports:
analog-input-mic: Microphone (priority 8700, latency offset 0 
usec, available: unknown)
properties:
device.icon_name = "audio-input-microphone"
analog-output-headphones: Headphones (priority 9900, latency 
offset 0 usec, available: unknown)
properties:
device.icon_name = "audio-headphones"
rd@h370:~$ 

If I boot with the USB headset plugged, inxi -F still reports both devices, 
but pulseaudio only knows one card:

rd@h370:~$ inxi -F
[...]
Audio: Device-1: Intel Cannon Lake PCH cAVS driver: snd_hda_intel 
   Device-2: Logitech Headset H390 type: USB driver: hid-generic,snd-
usb-audio,usbhid 
   Sound Server: ALSA v: k5.10.0-5-amd64 
[...]
rd@h370:~$ pacmd list-cards
1 card(s) available.
index: 0
name: 
driver: 
owner module: 6
properties:
alsa.card = "1"
alsa.card_name = "Logitech USB Headset"
alsa.long_card_name = "Logitech Logitech USB Headset at 
usb-:00:14.0-13.1, full speed"
alsa.driver_name = "snd_usb_audio"
device.bus_path = "pci-:00:14.0-usb-0:13.1:1.0"
sysfs.path = "/devices/pci:00/:00:14.0/
usb1/1-13/1-13.1/1-13.1:1.0/sound/card1"
udev.id = "usb-Logitech_Logitech_USB_Headset-00"
device.bus = "usb"
device.vendor.id = "046d"
device.vendor.name = "Logitech, Inc."
device.product.id = "0a44"
device.product.name = "Headset H390"
device.serial = "Logitech_Logitech_USB_Headset"
device.form_factor = "headset"
device.string = "1"
device.description = "Headset H390"
module-udev-detect.discovered = "1"
device.icon_name = "audio-headset-usb"
device.intended_roles = "phone"
profiles:
input:mono-fallback: Mono-Eingabe (priority 1, available: 
unknown)
input:multichannel-input: Mehrkanal-Eingabe (priority 1, 
available: unknown)
output:analog-stereo: Analog Stereo-Ausgabe (priority 6500, 
available: unknown)
output:analog-stereo+input:mono-fallback: Analog Stereo-
Ausgabe + Mono-Eingabe (priority 6501, available: unknown)
output:analog-stereo+input:multichannel-input: Analog Stereo-
Ausgabe + Mehrkanal-Eingabe (priority 6501, available: unknown)
off: Aus (priority 0, available: unknown)
active profile: 
sinks:
alsa_output.usb-Logitech_Logitech_USB_Headset-00.analog-
stereo/#0: Headset H390 Analog Stereo
sources:
alsa_output.usb-Logitech_Logitech_USB_Headset-00.analog-
stereo.monitor/#0: Monitor of Headset H390 Analog Stereo
alsa_input.usb-Logitech_Logitech_USB_Headset-00.mono-fallback/
#1: Headset H390 Mono
ports:
analog-input-mic: Microphone (priority 8700, latency offset 0 
usec, available: unknown)
properties:
device.icon_name = "audio-input-microphone"
analog-output-headphones: Headphones (priority 9900, latency 
offset 0 usec, available: unknown)
properties:
device.icon_name = "audio-headphones"
rd@h370:~$ 

Thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




Re: chromium: ERR_CONNECTION_REFUSED

2021-02-12 Thread Rainer Dorsch
Am Freitag, 12. Februar 2021, 21:39:10 CET schrieb Jeremy Ardley:
> On 13/2/21 4:15 am, Rainer Dorsch wrote:
> > Hi,
> > 
> > I suddenly cannot access my local managed switch anymore from chromium:
> > 
> > Chromium tries to swtich to the HTTPS protocol but the switch only
> > supports
> > HTTP protocol
> > 
> > The error message I get is
> > 
> > ERR_CONNECTION_REFUSED
> > 
> > Chromium 83 still worked.
> > 
> > Is there a way avoid this automatic switch for a site?
> > 
> > Thanks
> > Rainer
> 
> Chrome behaviour has become more intolerant of https and http over the
> past year or so - to the point it is unusable of there is any
> certificate problems.
> Firefox is going the same way.

Firefox still lets to log into the switch (Netgear JGS524PE). But here it 
seems that since ESR78 there is a (probably a javascript) incompatibility with 
the switch and it does not change settings.

> For problematic sites I use GNU Web instead. It will be perfectly
> adequate to access your switch web page.

I found the konqueror works as well. Usually it is the other way round.

Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




Re: chromium: ERR_CONNECTION_REFUSED

2021-02-12 Thread Rainer Dorsch
Am Freitag, 12. Februar 2021, 21:29:21 CET schrieb Roberto C. Sánchez:
> On Fri, Feb 12, 2021 at 09:15:35PM +0100, Rainer Dorsch wrote:
> > Hi,
> > 
> > I suddenly cannot access my local managed switch anymore from chromium:
> > 
> > Chromium tries to swtich to the HTTPS protocol but the switch only
> > supports
> > HTTP protocol
> > 
> > The error message I get is
> > 
> > ERR_CONNECTION_REFUSED
> > 
> > Chromium 83 still worked.
> > 
> > Is there a way avoid this automatic switch for a site?
> 
> Did you use the device IP or hostname without the protocol prefix?  From
> what I have observed, if I put just the IP or hostname, e.g.,
> "192.168.1.1" without specifying the protocol it defaults to HTTPS.
> However, if I include the protocol, e.g., "http://192.168.1.1; then the
> browser should respect that and try to default to HTTPS.
> 

Thanks for your quick reply. The first page load, but when I submit the 
password, I get the ERR_CONNECTION_REFUSED and I see that it tries to access 
https.

Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




chromium: ERR_CONNECTION_REFUSED

2021-02-12 Thread Rainer Dorsch
Hi,

I suddenly cannot access my local managed switch anymore from chromium:

Chromium tries to swtich to the HTTPS protocol but the switch only supports 
HTTP protocol

The error message I get is

ERR_CONNECTION_REFUSED

Chromium 83 still worked.

Is there a way avoid this automatic switch for a site? 

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Sound Issue

2021-02-07 Thread Rainer Dorsch
Thank you for your reply, Andrea.

Am Samstag, 6. Februar 2021, 23:52:24 CET schrieb Andrea Borgia:
> Il 06/02/21 20:53, Rainer Dorsch ha scritto:
> > sound was working for years on my Debian System w/o any issue with
> > pulseaudio. Since a few weeks I have problems with the on-board Intel
> > sound, listed as
> I'm having a similar issue and it might be because of this bug:
> https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=980836

I am on stable with 12.2-4+deb10u1
 
> 
> With this command I get the audio back, at least until the next reboot
> or plug/unplug cycle:
> 
> pacmd unload-module module-udev-detect && pacmd load-module
> module-udev-detect
> 

Does not work for me.

Maybe that is the sign to upgrade to bullseye :-)

Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




Sound Issue

2021-02-06 Thread Rainer Dorsch
total 0
lrwxrwxrwx 1 root root 12 Feb  6 20:42 usb-Logitech_Logitech_USB_Headset-00 -> 
../controlC1
rd@h370:~$ ls -l /dev/snd/by-path/
total 0
lrwxrwxrwx 1 root root 12 Feb  6 20:42 pci-:00:14.0-usb-0:13.1:1.0 -> ../
controlC1
lrwxrwxrwx 1 root root 12 Feb  6 20:19 pci-0000:00:1f.3 -> ../controlC0
rd@h370:~$ lspci |grep 00:1f.3
00:1f.3 Audio device: Intel Corporation Cannon Lake PCH cAVS (rev 10)
rd@h370:~$ 

Any idea or hint how to debug this issue is welcome.

Many thanks
Rainer



-- 
Rainer Dorsch
http://bokomoko.de/




Re: Screen scaling and 4k support in libvirt with qemu/kvm

2021-01-28 Thread Rainer Dorsch
Am Mittwoch, 27. Januar 2021, 10:55:53 CET schrieb Linux-Fan:
> Linux-Fan writes:
> > Rainer Dorsch writes:
> >> Hi,
> >> 
> >> with virtualbox, it is possible that the guest system rescales its screen
> >> if I change the window for the guest (and virtualbox guest tools are
> >> installed at
> >> least). Does anybody know if that is possible with
> >> virt-manager/libvirt/qemu/ kvm?
> > 
> > It is certainly possible to set the guest resolution to exactly match the
> > window size. I am not sure if it can be configured to _automatically_
> > adjust the guest resolution upon window size change though.
> > 
> > The protocol must support it, because I know that for Windows guest
> > systems, the Windows resolution adjusts to the window size. Unlike with
> > Linux guests, it does this in fixed steps of "common" monitor resolutions
> > and thus does not usually match the exact window size but something
> > smaller.
> > 
> > If you find out how to apply the sizes automatically on Linux, I'd be
> > interested to learn how that works :) If no „solution” exists yet, it
> > might
> > be easy to script (although I have not bothered to do that so far).
> 
> Update: I found out how to enable automatic resizing:
> 
>  * Install `qemu-guest-agent` in the VM in addition to running
>`spice-vdagent`
>  * Set Video model to VGA
> 
> This enables automatic resizing here although from "feeling" the graphics
> performance is worse than with QXL or virtio.

Many thanks for the quick response again.

I did not have spice-vdagent installed in the guest system. Installing spice-
vdagent and switching from QXL to virtio was sufficient here.

Interesting side effect:

On the host system, I get

rd@h370:~$ xrandr
Screen 0: minimum 320 x 200, current 3840 x 2160, maximum 8192 x 8192
HDMI-1 connected primary 3840x2160+0+0 (normal left inverted right x axis y 
axis) 609mm x 349mm
   3840x2160 30.00*   25.0024.0029.9723.98  
   2560x1440 59.95  
   2048x1280 59.99  
   2048x1080 24.00  
   1920x1080 60.0060.0050.0059.9430.0025.0024.00
29.9723.98  
   1920x1080i60.0050.0059.9450.00  
   1600x1200 60.00  
   1600x900  60.00  
   1280x1024 75.0260.02  
   1152x864  75.00  
   1280x720  60.0050.0059.94  
   1024x768  75.0360.00  
   800x600   75.0060.32  
   720x576   50.00  
   720x576i  50.00  
   720x480   60.0059.94  
   720x480i  60.0059.94  
   640x480   75.0060.0059.94  
   720x400   70.08  
HDMI-2 disconnected (normal left inverted right x axis y axis)
DP-1 disconnected (normal left inverted right x axis y axis)
rd@h370:~$ 

After installing spice-vdagent on the guest, I get there

rd@debianVM:~$ xrandr 
Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 8192 x 8192
Virtual-0 connected primary 1920x1080+0+0 0mm x 0mm
   3840x2160 60.00 +
   1920x1200 59.95  
   1920x1080 60.00* 
   1600x1200 59.95  
   1680x1050 60.00  
   1400x1050 60.00  
   1280x1024 59.95  
   1440x900  59.99  
   1280x960  59.99  
   1280x854  59.95  
   1280x800  59.96  
   1280x720  59.97  
   1152x768  59.95  
   1024x768  59.95  
   800x600   59.96  
   848x480   59.94  
   720x480   59.94  
   640x480   59.94  
Virtual-1 disconnected
Virtual-2 disconnected
Virtual-3 disconnected
rd@debianVM:~$


Note, the repetition rate (at least virtually) doubles in the guest at 4K.

Pretty cool!

Thanks again
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




Screen scaling and 4k support in libvirt with qemu/kvm

2021-01-26 Thread Rainer Dorsch
Hi,

with virtualbox, it is possible that the guest system rescales its screen if I 
change the window for the guest (and virtualbox guest tools are installed at 
least). Does anybody know if that is possible with virt-manager/libvirt/qemu/
kvm?

Also I noticed that I cannot scale my guest higher than 1920x1200. Is the max 
resolution configured somewhere or is this a fundamental limitation?

Both my host and guest are Debian 10.

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: audio support in libvirt with qemu/kvm

2021-01-25 Thread Rainer Dorsch
Am Montag, 25. Januar 2021, 13:28:30 CET schrieb Linux-Fan:
> Various screenshots can be found on my KVM+virt-manager page at:
> https://masysma.lima-city.de/37/how_to_transition_from_virtualbox_to_kvm.xht
> ml

I found it, thanks for sharing the URL, very useful.

Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: audio support in libvirt with qemu/kvm

2021-01-25 Thread Rainer Dorsch
Am Sonntag, 24. Januar 2021, 23:04:54 CET schrieb Linux-Fan:
> Rainer Dorsch writes:
> > Hi,
> > 
> > I created a virtual machine using libvirt with qemu/kvm. To make it
> > simple, I installed a Debian 10 guest on a Debian 10 host. I am
> > wondering, if it is possible to access (pulse-)audio from the guest.
> > 
> > Any hint or advice is welcome.
> 
> For me it works out of the box in the way that I can hear sound played
> inside the VM and the VM can record from the microphone attached to the PC.
> 
> In virt-manager it appears as "Sound ich9" device added to the respective
> VMs. Host and guest both use Pulseaudio. In case you do not use GUI, it
> might be enough to add the following device in the VM's XML:
> 
> 
>function='0x0'/> 
> 
> I do not know if it can be made to work in a way that just a single pulse
> audio server is running -- in my configuration, the guest and host both have
> their respective pulse audio instances although the sound itself passes
> from the one to the other wihtout explicit configuration :)
> 

Thanks for the quick reply. I tried again and it seems sound works now :-) 

I also used virt-manager, but I did not find any sound devices in there. Are 
you using Debian 10? virt-manager from stable or stable-backports? Where do 
you see the "Sound ich9" device?

Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




audio support in libvirt with qemu/kvm

2021-01-24 Thread Rainer Dorsch
Hi,

I created a virtual machine using libvirt with qemu/kvm. To make it simple, I 
installed a Debian 10 guest on a Debian 10 host. I am wondering, if it is 
possible to access (pulse-)audio from the guest.

Any hint or advice is welcome.

Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




Why is idle not detected?

2021-01-06 Thread Rainer Dorsch
Hi,

I am running Debian 10 and sometimes idle is not detected correctly on my 
(KDE) system and the desktop is not going to suspend.

A typical candidate is a not correctly terminating vlc process which does not 
have a screen anymore but is still alive. Sometimes I cannot find out what 
causes the problem.

Is there a way to find out what is the holding back the idle detection?

I am thinking of something like doing a dry-run of the idle detection by cron 
with a report every few minutes and log the report (without actually 
triggering suspend if idle is detected). Whenever idle is not detected 
properly, the log file would tell the reason.

Any idea or hint is welcome.

Many thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




acpi bios error: could not resolve symbol in Tuxedo Aura 15

2020-12-26 Thread Rainer Dorsch
Hi,

I have a Tuxedo Aura 15 and after installing Debian bullseye, I see during 
boot a few

acpi bios error: could not resolve symbol

messages.

See https://nc.d5x.de/s/3BYL8Fg88Xb5GRJ for a "screenshot".

Does anybody understand what these messages want to tell me (so far I did not 
see anything not working).

Any hint is welcome.

Thanks
Rainer

Full machine data:

rd@aura:~$ inxi -F 
System:Host: aura Kernel: 5.9.0-5-amd64 x86_64 bits: 64 Console: tty 3 
Distro: Debian GNU/Linux bullseye/sid  
Machine:   Type: Laptop System: TUXEDO product: TUXEDO Aura 15 Gen1 v: N/A 
serial:   
  Mobo: TUXEDO s model: AURA1501 serial:  UEFI: 
INSYDE v: 1.07.03RTR2 date: 11/13/2020  
Battery:   ID-1: BAT0 charge: 20.4 Wh condition: 50.3/48.3 Wh (104%)  
CPU:   Info: 8-Core model: AMD Ryzen 7 4700U with Radeon Graphics bits: 64 
type: MCP L2 cache: 4 MiB  
  Speed: 1398 MHz min/max: 1400/2000 MHz Core speeds (MHz): 1: 1398 2: 
1396 3: 1397 4: 1397 5: 1401 6: 1399 7: 1397  
  8: 1396  
Graphics:  Device-1: Advanced Micro Devices [AMD/ATI] Renoir driver: amdgpu v: 
kernel  
  Device-2: Acer BisonCam NB Pro type: USB driver: uvcvideo  
  Display: server: X.org 1.20.10 driver: amdgpu,ati unloaded: 
fbdev,modesetting,vesa tty: 293x80  
  Message: Advanced graphics data unavailable in console. Try -G --
display  
Audio: Device-1: Advanced Micro Devices [AMD/ATI] driver: snd_hda_intel  
  Device-2: Advanced Micro Devices [AMD] Raven/Raven2/FireFlight/
Renoir Audio Processor driver: N/A  
  Device-3: Advanced Micro Devices [AMD] Family 17h HD Audio driver: 
snd_hda_intel  
  Sound Server: ALSA v: k5.9.0-5-amd64  
Network:   Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet 
driver: r8169  
  IF: enp2s0 state: down mac: 80:fa:5b:8a:20:da  
  Device-2: Intel Wi-Fi 6 AX200 driver: iwlwifi  
  IF: wlo1 state: up mac: 78:2b:46:2a:e2:48  
Drives:Local Storage: total: 465.76 GiB used: 6.07 GiB (1.3%)  
  ID-1: /dev/nvme0n1 vendor: Samsung model: SSD 970 EVO Plus 500GB 
size: 465.76 GiB  
Partition: ID-1: / size: 447.02 GiB used: 5.94 GiB (1.3%) fs: btrfs dev: /dev/
dm-0  
  ID-2: /boot size: 473.5 MiB used: 124.1 MiB (26.2%) fs: ext2 dev: /
dev/nvme0n1p2  
  ID-3: /boot/efi size: 511 MiB used: 8.4 MiB (1.7%) fs: vfat dev: /
dev/nvme0n1p1  
Swap:  ID-1: swap-1 type: partition size: 17.73 GiB used: 0 KiB (0.0%) 
dev: /dev/dm-1  
Sensors:   System Temperatures: cpu: 24.1 C mobo: N/A gpu: amdgpu temp: 23.0 C  
  Fan Speeds (RPM): N/A  
Info:  Processes: 283 Uptime: 8h 24m Memory: 30.81 GiB used: 1.35 GiB 
(4.4%) Init: systemd runlevel: 5 Shell: Bash  
  inxi: 3.2.01  
rd@aura:~$ 




-- 
Rainer Dorsch
http://bokomoko.de/




Re: cups: Empty Basic password

2020-11-19 Thread Rainer Dorsch
Am Donnerstag, 19. November 2020, 22:20:37 CET schrieb l0f...@tuta.io:
> Hi,
> 
> 19 nov. 2020 à 16:20 de m...@bokomoko.de:
> > Is there anything wrong with my setup? As I wrote before, I see no
> > functional problem.
> 
> You have python-cups installed right?

No, neither on cups server, nor on cups client

rd@home:~$ apt-cache policy python-cups
python-cups:
  Installed: (none)
  Candidate: 1.9.73-2+b1
  Version table:
 1.9.73-2+b1 500
500 http://ftp.de.debian.org/debian buster/main armhf Packages
rd@home:~$ logout
Connection to bc closed.
rd@h370:~$ apt-cache policy python-cups
python-cups:
  Installiert:   (keine)
  Installationskandidat: 1.9.73-2+b1
  Versionstabelle:
 1.9.73-2+b1 500
500 http://ftp-stud.hs-esslingen.de/debian buster/main amd64 Packages
rd@h370:~$ 

> What is its version?

Not installed, both systems client and server are Debian buster.

> 
> Has the user been added to lpadmin?
> See https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=667995

Which user? My user on the client yes:

rd@h370:~$ groups
rd adm dialout fax cdrom floppy sudo dip video plugdev users lpadmin scanner 
docker vboxusers i2psvc wireshark sispmctl
rd@h370:~$ 


> > 
> There is also another potential solution
> at https://ubuntuforums.org/archive/index.php/t-2055965.html but I'm not
> sure it's recommended...

Not sure if I understand this one.

The problem became worse, it seems to be intermittent, it is gone right now 
(but I am sure it will eventually come back).

Thanks
Rainer

> Best regards,
> l0f4r0


-- 
Rainer Dorsch
http://bokomoko.de/




cups: Empty Basic password

2020-11-19 Thread Rainer Dorsch
Hello,

I am running a cups server which works as expected, but I just realized that 
the error log show a tremendous amount of entries:

root@home:~# tail /var/log/cups/error_log 
E [19/Nov/2020:16:14:00 +0100] [Client 49726] Empty Basic password. 
E [19/Nov/2020:16:14:00 +0100] [Client 49729] Empty Basic password. 
E [19/Nov/2020:16:14:00 +0100] [Client 49732] Empty Basic password. 
E [19/Nov/2020:16:14:01 +0100] [Client 49735] Empty Basic password. 
E [19/Nov/2020:16:14:01 +0100] [Client 49738] Empty Basic password. 
E [19/Nov/2020:16:14:01 +0100] [Client 49741] Empty Basic password. 
E [19/Nov/2020:16:14:01 +0100] [Client 49744] Empty Basic password. 
E [19/Nov/2020:16:14:01 +0100] [Client 49747] Empty Basic password. 
E [19/Nov/2020:16:14:02 +0100] [Client 49750] Empty Basic password. 
E [19/Nov/2020:16:14:02 +0100] [Client 49753] Empty Basic password. 
root@home:~# 

Digging further, I realized that cupsd keeps one core of the server busy

 PID USER  PR  NIVIRTRESSHR S  %CPU  %MEM TIME+ COMMAND 


 
28032 root  20   0   82452  14572   5828 R  98.0   0.7  50:14.12 cupsd  


  

The error log entries stops, if I poweroff another Debian system with cups 
running as a client

rd@h370:~$ cat /etc/cups/client.conf 
ServerName 192.168.7.1
rd@h370:~$ 

On the client side, I do not see corresponding log entries:

rd@h370:~$ cat /var/log/cups/error_log
E [19/Nov/2020:07:43:29 +0100] Missing value on line 1561 of /var/cache/cups/
job.cache.
E [19/Nov/2020:07:43:29 +0100] Missing value on line 1612 of /var/cache/cups/
job.cache.
E [19/Nov/2020:07:43:29 +0100] Missing value on line 2542 of /var/cache/cups/
job.cache.
E [19/Nov/2020:07:43:29 +0100] Missing value on line 5366 of /var/cache/cups/
job.cache.
E [19/Nov/2020:07:43:29 +0100] Missing value on line 5379 of /var/cache/cups/
job.cache.
E [19/Nov/2020:07:43:29 +0100] Missing value on line 5392 of /var/cache/cups/
job.cache.
E [19/Nov/2020:07:43:29 +0100] Missing value on line 6235 of /var/cache/cups/
job.cache.
E [19/Nov/2020:07:43:29 +0100] Missing value on line 6261 of /var/cache/cups/
job.cache.
E [19/Nov/2020:07:43:29 +0100] Missing value on line 6274 of /var/cache/cups/
job.cache.
E [19/Nov/2020:07:51:45 +0100] [Client 3] Returning IPP client-error-bad-
request for Create-Printer-Subscriptions (/) from localhost.
E [19/Nov/2020:11:59:23 +0100] [Client 5] Returning IPP client-error-bad-
request for Create-Printer-Subscriptions (/) from localhost.
E [19/Nov/2020:14:33:28 +0100] [Client 6] Returning IPP client-error-bad-
request for Create-Printer-Subscriptions (/) from localhost.
E [19/Nov/2020:15:52:09 +0100] [Client 16] Returning IPP client-error-bad-
request for Create-Printer-Subscriptions (/) from localhost.
rd@h370:~$ 

Is there anything wrong with my setup? As I wrote before, I see no functional 
problem.

Any advice or hint is welcome.

Thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




xdg-mime

2020-09-05 Thread Rainer Dorsch
Hi,

is there a way to find out where xdg-mime gets its configuration from?

I have

$ xdg-mime query default application/pdf
gimp.desktop
$ 

but I would have expected okular.

Just wondering if this is a wrong user configuration or if the problem is 
system wide...

Thanks
Rainer





Re: ssh key used for login

2020-08-09 Thread Rainer Dorsch
Am Samstag, 8. August 2020, 02:26:20 CEST schrieb Kushal Kumaran:
> Rainer Dorsch  writes:
> > Hi,
> > 
> > can anybody tell if there is a way to find out the ssh key (out of the
> > ones
> > listed in authorized keys) was used for login to the current session?
> 
> See the environment="NAME=value" part in the authorized_keys(5) manpage.
> You can have each entry in authorized_keys set a different value for
> some variable you pick.
> 
> You may also be able to use command="command" creatively.  This is what
> gitolite does: https://gitolite.com/gitolite/glssh

Many thanks, for your suggestion, that looks promising, I will give it a try.

Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: ssh key used for login

2020-08-07 Thread Rainer Dorsch
Am Freitag, 7. August 2020, 17:47:31 CEST schrieb john doe:
> On 8/7/2020 5:07 PM, Rainer Dorsch wrote:
> > Hi,
> > 
> > can anybody tell if there is a way to find out the ssh key (out of the
> > ones
> > listed in authorized keys) was used for login to the current session?
> 
> Try to increase the log verbosity to 'debug[1|2|3]'.
> 

Thanks for the reply, but it seems my question was not precise enough.

I want to find it out in a script which runs on the server, e.g.

ssh server.domain myscript.sh

Is there a way to find out in myscript.sh which ssh key was used for login. 

There are a number of ssh environment vars, but none of them contains the ssh 
key (or even better the "user label" after the public key):

declare -x SHLVL="1" 
declare -x SSH_CLIENT="192.168.7.203 56018 22" 
declare -x SSH_CONNECTION="192.168.7.203 56018 192.168.7.1 22" 
declare -x SSH_TTY="/dev/pts/2"

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/

ssh key used for login

2020-08-07 Thread Rainer Dorsch
Hi,

can anybody tell if there is a way to find out the ssh key (out of the ones 
listed in authorized keys) was used for login to the current session?

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Best practive for TLS/DNS Setup for exim

2020-05-19 Thread Rainer Dorsch
Am Montag, 18. Mai 2020, 19:58:06 CEST schrieb Dan Ritter:
> Rainer Dorsch wrote:
> > Hi,
> > 
> > I am just wondering how a efficient setup for TLS/DNS for exim looks like:
> > 
> > Right now I have an A entry in the DNS server for smtp. and a
> > letsencrypt certificate as well.
> > 
> > If I setup a new server and call it SMTP2, I need to reconfigure this in
> > all my email clients. If I install the SMTP certificates, testing is
> > somewhat limited, since the DNS entry still points to another server and
> > I would need to fake this.
> > 
> > Does anybody know if I can have a certificate for .
> > and use for smtp a CNAME?
> > 
> > The advantage I would see is that I can have a fully functional config and
> > with disabling the SMTP name on the old system and changing the CNAME in
> > the DNS system, I could be done.
> > 
> > Does anybody now if the standard email clients can handle the situation in
> > which them get as SMTP server a cname and as certificate the 
> > the
> > SMTP cname points to?
> 
> I think you're overcomplicating it.
> 
> Your domain can and should have two or more MX records, with
> different priority levels. The MX records don't even have to
> point to names in your domain.
> 
> Since you're using Let's Encrypt, certificates are free. So,
> for each mail server, set up an A and/or  record. Add those
> to the MX records for your domain. Have LE produce certificates
> for the mail servers under the names they have assigned.
> 
> Any mail sender will try each of your MX records, stopping when
> it gets to a working entry. Some spammers will try in reverse
> order, hoping that you don't have anti-spam measures on your
> secondary mail server.
> 

Just curious, if I have multiple MX records, how would you sync the incoming 
emails (*) ? I can see with an NFS mounted home directory with Maildir 
mailboxes that could work and dovecot could probably run on multiple hosts (or 
at least it would be possible to switch the imap DNS entry if needed). But 
then the NFS server is the single point of failure. Are there better ways to 
sync the mail servers behind the MX records than NFS?

Thanks
Rainer

(*) it would be some fun to present to the user multiple mail boxes and emails 
are "randomly" distributed into them :-D

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Best practive for TLS/DNS Setup for exim

2020-05-19 Thread Rainer Dorsch
Am Dienstag, 19. Mai 2020, 16:15:36 CEST schrieb Dan Ritter:
> Rainer Dorsch wrote:
> > Am Montag, 18. Mai 2020, 20:50:49 CEST schrieb Dan Ritter:
> > > Rainer Dorsch wrote:
> > > > I was more concerned about the outgoing server configured in the email
> > > > clients and used to send main from my domain (at least so far I did
> > > > not
> > > > understand that they can make use of the MX record).
> > > 
> > > It depends on the MTA you choose for your email clients, but
> > > unless you choose the very simplest systems, they can be
> > > configured to look up the MX record and use that. (Postfix has a
> > > fallback_relay option, Exim can accept multiple hosts in a
> > > route_list statement, and so forth.)
> > 
> > Thanks again for your reply.
> > 
> > But what about a client like Thunderbird, kmail or Android mail clients.
> > They need an *outgoing* server.
> > 
> > Do they handle MX records?
> 
> No, if you need high availability for those, you need load
> balancing. DNS is not a good way of doing that; consider
> ldirectord or haproxy or pound, and remember that you will need
> at least two of those machines in a STONITH configuration.
> 
> In any of these cases, you'll configure all your mail servers to
> answer as smtp.domain with the same TLS certificate.

Many thanks, again. No HA was here not my primary motivation here. 

It seems I have to 

1. Setup exim (done by now)
2. copy TLS certificates for smtp. to new server
3. for testing tweak dns for a client to resolve smtp. to the new 
server
4. changing the smtp. entry to new server
5. setup certbot to update the copied smtp TLS certificates

I hoped I get around copying the TLS certificates and then get certbot running 
an tweaking DNS of the client by

1. get TLS certificate for smtp2.
2. Setup exim
3. test with smtp2.
4. change DNS entry to e.g. make smtp CNAME smtp2

I see the last step does not work, but it is not a big hassle overall to 
follow the first procedure (I hope :-) )

Rainer




-- 
Rainer Dorsch
http://bokomoko.de/




Re: Best practive for TLS/DNS Setup for exim

2020-05-18 Thread Rainer Dorsch
Am Montag, 18. Mai 2020, 20:50:49 CEST schrieb Dan Ritter:
> Rainer Dorsch wrote:
> > Am Montag, 18. Mai 2020, 19:58:06 CEST schrieb Dan Ritter:
> > > I think you're overcomplicating it.
> > > 
> > > Your domain can and should have two or more MX records, with
> > > different priority levels. The MX records don't even have to
> > > point to names in your domain.
> > > 
> > > Since you're using Let's Encrypt, certificates are free. So,
> > > for each mail server, set up an A and/or  record. Add those
> > > to the MX records for your domain. Have LE produce certificates
> > > for the mail servers under the names they have assigned.
> > > 
> > > Any mail sender will try each of your MX records, stopping when
> > > it gets to a working entry. Some spammers will try in reverse
> > > order, hoping that you don't have anti-spam measures on your
> > > secondary mail server.
> > 
> > Thanks, Dan, for your quick reply. I was not concerned about incoming mail
> > to my domain using the MX record.
> > 
> > I was more concerned about the outgoing server configured in the email
> > clients and used to send main from my domain (at least so far I did not
> > understand that they can make use of the MX record).
> 
> It depends on the MTA you choose for your email clients, but
> unless you choose the very simplest systems, they can be
> configured to look up the MX record and use that. (Postfix has a
> fallback_relay option, Exim can accept multiple hosts in a
> route_list statement, and so forth.)

Thanks again for your reply.

But what about a client like Thunderbird, kmail or Android mail clients. They 
need an *outgoing* server.

Do they handle MX records?

Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




Re: Best practive for TLS/DNS Setup for exim

2020-05-18 Thread Rainer Dorsch
Am Montag, 18. Mai 2020, 19:58:06 CEST schrieb Dan Ritter:
> Rainer Dorsch wrote:
> > Hi,
> > 
> > I am just wondering how a efficient setup for TLS/DNS for exim looks like:
> > 
> > Right now I have an A entry in the DNS server for smtp. and a
> > letsencrypt certificate as well.
> > 
> > If I setup a new server and call it SMTP2, I need to reconfigure this in
> > all my email clients. If I install the SMTP certificates, testing is
> > somewhat limited, since the DNS entry still points to another server and
> > I would need to fake this.
> > 
> > Does anybody know if I can have a certificate for .
> > and use for smtp a CNAME?
> > 
> > The advantage I would see is that I can have a fully functional config and
> > with disabling the SMTP name on the old system and changing the CNAME in
> > the DNS system, I could be done.
> > 
> > Does anybody now if the standard email clients can handle the situation in
> > which them get as SMTP server a cname and as certificate the 
> > the
> > SMTP cname points to?
> 
> I think you're overcomplicating it.
> 
> Your domain can and should have two or more MX records, with
> different priority levels. The MX records don't even have to
> point to names in your domain.
> 
> Since you're using Let's Encrypt, certificates are free. So,
> for each mail server, set up an A and/or  record. Add those
> to the MX records for your domain. Have LE produce certificates
> for the mail servers under the names they have assigned.
> 
> Any mail sender will try each of your MX records, stopping when
> it gets to a working entry. Some spammers will try in reverse
> order, hoping that you don't have anti-spam measures on your
> secondary mail server.

Thanks, Dan, for your quick reply. I was not concerned about incoming mail to 
my domain using the MX record.

I was more concerned about the outgoing server configured in the email clients 
and used to send main from my domain (at least so far I did not understand 
that they can make use of the MX record).

Thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




Best practive for TLS/DNS Setup for exim

2020-05-18 Thread Rainer Dorsch
Hi,

I am just wondering how a efficient setup for TLS/DNS for exim looks like:

Right now I have an A entry in the DNS server for smtp. and a 
letsencrypt certificate as well.  

If I setup a new server and call it SMTP2, I need to reconfigure this in all my 
email clients. If I install the SMTP certificates, testing is somewhat limited, 
since the DNS entry still points to another server and I would need to fake 
this.

Does anybody know if I can have a certificate for . and 
use for smtp a CNAME?

The advantage I would see is that I can have a fully functional config and with 
disabling the SMTP name on the old system and changing the CNAME in the DNS 
system, I could be done.

Does anybody now if the standard email clients can handle the situation in 
which them get as SMTP server a cname and as certificate the  the 
SMTP cname points to?

Many thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: su does not work anymore

2020-05-02 Thread Rainer Dorsch
Am Samstag, 2. Mai 2020, 06:32:02 CEST schrieb Andrei POPESCU:
> On Vi, 01 mai 20, 22:32:58, Rainer Dorsch wrote:
> > Hello,
> > 
> > I had an accidential / in a
> > 
> > # chown -R install-user /xyz/dfak /
> > 
> > command. Changing the ownership / recursively is certainly not a good
> > idea.
> 
> Ugh. For such situations one should either have good backups or a
> reasonably fast and automated method of reinstalling the system.
> 
> See also http://taobackup.com
> 

Thanks for sharing the nice link, Andrei. Unfortunately, I took the novice 
approach on step 1 for the system files. I do not see any issues on the system 
anymore tough. To be on the saver side, I also did an "apt-get reinstall" of 
the relevant packages. I hope the next "apt-get dist-upgrade" will eliminate 
any so far hidden issues.

Thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




[solved] su does not work anymore

2020-05-01 Thread Rainer Dorsch
Am Freitag, 1. Mai 2020, 22:32:58 CEST schrieb Rainer Dorsch:
> Hello,
> 
> I had an accidential / in a
> 
> # chown -R install-user /xyz/dfak /
> 
> command. Changing the ownership / recursively is certainly not a good idea.
> 
> I did revert this by
> 
> #chown -R root /etc /bin /usr ...
> 
> (all directories why were owned by install-user).
> 
> That was certainly overdone, so I used
> 
> find . \! -user root -print
> 
> on another system with a similar package list to get a list of files which
> are not owned by root.
> 
> What still does not work is "su -".
> 
> The log in /var/log/auth.log is given by
> 
> May  1 22:07:46 h370 unix_chkpwd[12768]: check pass; user unknown
> May  1 22:07:46 h370 unix_chkpwd[12768]: password check failed for user
> (root) May  1 22:07:46 h370 su: pam_unix(su-l:auth): authentication
> failure; logname=rd uid=2809 euid=2809 tty=pts/0 ruser=rd rhost=  user=root
> May  1 22:07:48 h370 su: FAILED SU (to root) rd on pts/0
> 
> root login on a console works.
> 
> Any suggestion to find out what goes wrong (and avoid reinstallation) is
> welcome :-)

https://www.linuxquestions.org/questions/linux-security-4/unix-chkpwd-problem-with-linux-pam-1-1-1-trying-to-run-su-from-shadow-4-1-4-2-a-826418/

had the answer: su has an s flag for the user.

It seems this got lost by a chown.

# find / -perm /4000 -user root

seems to be my friend now to identify other files which have a similar issue 
:-/

Rainer

-- 
Rainer Dorsch
Beatus-Widmann-Str. 5
72138 Kirchentellinsfurt
07157/734133






su does not work anymore

2020-05-01 Thread Rainer Dorsch
Hello,

I had an accidential / in a 

# chown -R install-user /xyz/dfak /

command. Changing the ownership / recursively is certainly not a good idea.

I did revert this by 

#chown -R root /etc /bin /usr ...

(all directories why were owned by install-user).

That was certainly overdone, so I used

find . \! -user root -print

on another system with a similar package list to get a list of files which are 
not owned by root.

What still does not work is "su -".

The log in /var/log/auth.log is given by

May  1 22:07:46 h370 unix_chkpwd[12768]: check pass; user unknown
May  1 22:07:46 h370 unix_chkpwd[12768]: password check failed for user (root)
May  1 22:07:46 h370 su: pam_unix(su-l:auth): authentication failure; 
logname=rd uid=2809 euid=2809 tty=pts/0 ruser=rd rhost=  user=root
May  1 22:07:48 h370 su: FAILED SU (to root) rd on pts/0

root login on a console works.

Any suggestion to find out what goes wrong (and avoid reinstallation) is 
welcome :-)

Thanks
Rainer


-- 
Rainer Dorsch
Beatus-Widmann-Str. 5
72138 Kirchentellinsfurt
07157/734133






Re: python virualenv

2020-05-01 Thread Rainer Dorsch
Am Mittwoch, 29. April 2020, 02:54:04 CEST schrieb Tom Low-Shang:
> On Tue, Apr 28, 2020 at 11:20:04PM +0200, Rainer Dorsch wrote:
> > Here is the full sequence I executed:
> > 
> > rd@h370:~/virtualenv$ virtualenv covidify
> > Running virtualenv with interpreter /usr/bin/python2
> 
> Virtualenv uses python2
> 
> > New python executable in /home/rd/virtualenv/covidify/bin/python2 Also
> > Also creating executable in /home/rd/virtualenv/covidify/bin/python
> > Installing setuptools, pkg_resources, pip, wheel...done.
> > rd@h370:~/virtualenv$ source covidify/bin/activate
> > (covidify) rd@h370:~/virtualenv$ pip3 install covidify
> 
> Pip3 uses python3 which is outside the virtualenv.
> 
> Either run pip, or create the virtualenv with python3, which will
> install pip3.

Many thanks, Tom.

virtualenv -p python3 covidify

indeed solved the issue.

Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Another virtualenv question

2020-04-28 Thread Rainer Dorsch
Hello,

I have another basic virtualenv question:

I install covidify in a virtualenv and if finds the dependency

Requirement already satisfied: docopt in /usr/lib/python3/dist-packages (from 
covidify) (0.6.2)

installed on the system. But later, when I run the python script, it is not 
found:

Traceback (most recent call last):
  File "/home/rd/.local/lib/python3.7/site-packages/covidify/data_prep.py", 
line 17, in 
import docopt
ImportError: No module named docopt

Here is the full log, of what I did:

rd@h370:~/virtualenv$ virtualenv --system-site-packages covidify
Running virtualenv with interpreter /usr/bin/python2
New python executable in /home/rd/virtualenv/covidify/bin/python2
Also creating executable in /home/rd/virtualenv/covidify/bin/python
Installing setuptools, pkg_resources, pip, wheel...done.
rd@h370:~/virtualenv$ source covidify/bin/activate
(covidify) rd@h370:~/virtualenv$ pip3 install covidify
Requirement already satisfied: covidify in /home/rd/.local/lib/python3.7/site-
packages (1.2.0)
Requirement already satisfied: click in /usr/lib/python3/dist-packages (from 
covidify) (7.0)
Requirement already satisfied: xlsxwriter in /usr/lib/python3/dist-packages 
(from covidify) (1.1.2)
Requirement already satisfied: numpy in /usr/lib/python3/dist-packages (from 
covidify) (1.16.2)
Requirement already satisfied: GitPython in /usr/lib/python3/dist-packages 
(from covidify) (2.1.11)
Requirement already satisfied: pillow in /usr/lib/python3/dist-packages (from 
covidify) (5.4.1)
Requirement already satisfied: pyarrow in /home/rd/.local/lib/python3.7/site-
packages (from covidify) (0.17.0)
Requirement already satisfied: pandas in /usr/lib/python3/dist-packages (from 
covidify) (0.23.3+dfsg)
Requirement already satisfied: matplotlib in /usr/lib/python3/dist-packages 
(from covidify) (3.0.2)
Requirement already satisfied: docopt in /usr/lib/python3/dist-packages (from 
covidify) (0.6.2)
Requirement already satisfied: tqdm in /usr/lib/python3/dist-packages (from 
covidify) (4.28.1)
(covidify) rd@h370:~/virtualenv$ export PATH=/home/rd/.local/bin:$PATH
(covidify) rd@h370:~/virtualenv$ covidify run --output=~/tmp.nobackup/covidify 
--country=Germany 
 MESSAGE:  No source given, defaulting to John Hopkin CSSE github repo 
 MESSAGE:  No top countries given, defaulting to top 10 
###
### Job arguments:
###
... ENV: /home/rd/.local/lib/python3.7/site-packages/covidify
... OUTPUT FOLDER: /home/rd/tmp.nobackup/covidify
... DATA SOURCE: JHU
... COUNTRIES: Germany
... TOP INFECTED COUNTRIES: 10
... FORECAST PERIOD: 10
###
### Data Extraction
###
Traceback (most recent call last):
  File "/home/rd/.local/lib/python3.7/site-packages/covidify/data_prep.py", 
line 17, in 
import docopt
ImportError: No module named docopt
(covidify) rd@h370:~/virtualenv$

Any feedback is welcome.

Many thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




python virualenv

2020-04-28 Thread Rainer Dorsch
Hello,

I have a quite basic questions on virtualenv for python/pip:

If I run it as shown in the example below, I see that binaries which come with 
pip installed packages in a virtualenv go into the ~/.local/bin directory and 
not into the /bin directory.  E.g. shown here

 The script plasma_store is installed in '/home/rd/.local/bin' which is not on 
PATH. 
 Consider adding this directory to PATH or, if you prefer to suppress this 
warning, use --no-warn-script-location. 

  

I am just wondering if there is a good reason for that. If all the effort is 
already done, why not storing all parts in virtualenv environment?

Here is the full sequence I executed:

rd@h370:~/virtualenv$ virtualenv covidify 
Running virtualenv with interpreter /usr/bin/python2 
New python executable in /home/rd/virtualenv/covidify/bin/python2 
Also creating executable in /home/rd/virtualenv/covidify/bin/python 
Installing setuptools, pkg_resources, pip, wheel...done. 
rd@h370:~/virtualenv$ source covidify/bin/activate 
(covidify) rd@h370:~/virtualenv$ pip3 install covidify 
Collecting covidify 
 Downloading https://files.pythonhosted.org/packages/21/0a/
2e8e65ce15e3ab2786a55ff5191126aac02185c1a724a59d1abd04185178/covidify-1.2.0-
py2.py3-none-any.whl 
Requirement already satisfied: GitPython in /usr/lib/python3/dist-packages 
(from covidify) (2.1.11) 
Requirement already satisfied: xlsxwriter in /usr/lib/python3/dist-packages 
(from covidify) (1.1.2) 
Requirement already satisfied: docopt in /usr/lib/python3/dist-packages (from 
covidify) (0.6.2) 
Requirement already satisfied: click in /usr/lib/python3/dist-packages (from 
covidify) (7.0) 
Requirement already satisfied: matplotlib in /usr/lib/python3/dist-packages 
(from covidify) (3.0.2) 
Collecting pyarrow (from covidify) 
 Downloading https://files.pythonhosted.org/packages/d6/85/
a763edd24d0e70261726dda48818e2723d9b09cd3c05c238a8f39e7dcfd8/pyarrow-0.17.0-
cp37-cp37m-manylinux1_x86_64.whl (64.5MB) 
   100% || 64.5MB 19kB/s  
Requirement already satisfied: pillow in /usr/lib/python3/dist-packages (from 
covidify) (5.4.1) 
Requirement already satisfied: tqdm in /usr/lib/python3/dist-packages (from 
covidify) (4.28.1) 
Requirement already satisfied: pandas in /usr/lib/python3/dist-packages (from 
covidify) (0.23.3+dfsg) 
Requirement already satisfied: numpy in /usr/lib/python3/dist-packages (from 
covidify) (1.16.2) 
Installing collected packages: pyarrow, covidify 
 The script plasma_store is installed in '/home/rd/.local/bin' which is not on 
PATH. 
 Consider adding this directory to PATH or, if you prefer to suppress this 
warning, use --no-warn-script-location. 

  
 The script covidify is installed in '/home/rd/.local/bin' which is not on 
PATH. 
 Consider adding this directory to PATH or, if you prefer to suppress this 
warning, use --no-warn-script-location. 

  
Successfully installed covidify-1.2.0 pyarrow-0.17.0 
(covidify) rd@h370:~/virtualenv$

Many thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Droidcam: Android phone as Debian webcam

2020-04-20 Thread Rainer Dorsch
yte:~/git/droidcam$




install@gigabyte:~/git/droidcam$ cd linux/
install@gigabyte:~/git/droidcam/linux$ make
gcc -Wall -no-pie -Wno-pointer-to-int-cast -Wno-int-to-pointer-cast src/
droidcam.c src/connection.c src/decoder.c `pkg-config --libs --cflags gtk+-2.0` 
-I/opt/libjpeg-turbo/include /opt/libjpeg-turbo/lib/libturbojpeg.a `pkg-config 
--libs libswscale libavutil` -lm -o droidcam
src/droidcam.c: In function ‘main’:
src/droidcam.c:418:2: warning: ‘gdk_pixbuf_new_from_inline’ is deprecated [-
Wdeprecated-declarations]
  gtk_window_set_icon(GTK_WINDOW(window), gdk_pixbuf_new_from_inline(-1, 
icon_inline, FALSE, NULL));
  ^~~
In file included from /usr/include/gdk-pixbuf-2.0/gdk-pixbuf/gdk-pixbuf.h:34,
 from /usr/include/gtk-2.0/gdk/gdkpixbuf.h:37,
 from /usr/include/gtk-2.0/gdk/gdkcairo.h:28,
 from /usr/include/gtk-2.0/gdk/gdk.h:33,
 from /usr/include/gtk-2.0/gtk/gtk.h:32,
 from src/droidcam.c:16:
/usr/include/gdk-pixbuf-2.0/gdk-pixbuf/gdk-pixbuf-core.h:362:12: note: 
declared here
 GdkPixbuf* gdk_pixbuf_new_from_inline (gint  data_length,
^~
install@gigabyte:~/git/droidcam/linux$ su -
Password: 
root@gigabyte:~# cd /home/install/git/droidcam/linux/
root@gigabyte:/home/install/git/droidcam/linux# ./install 1920 1080
Webcam parameters: '1920' and '1080'
Building v4l2loopback-dc.ko
make: Entering directory '/home/install/git/droidcam/linux/v4l2loopback'
make -C /lib/modules/`uname -r`/build M=`pwd`
make[1]: Entering directory '/usr/src/linux-headers-5.4.0-0.bpo.4-amd64'
  AR  /home/install/git/droidcam/linux/v4l2loopback/built-in.a
  CC [M]  /home/install/git/droidcam/linux/v4l2loopback/v4l2loopback-dc.o
  Building modules, stage 2.
  MODPOST 1 modules
  CC [M]  /home/install/git/droidcam/linux/v4l2loopback/v4l2loopback-dc.mod.o
  LD [M]  /home/install/git/droidcam/linux/v4l2loopback/v4l2loopback-dc.ko
make[1]: Leaving directory '/usr/src/linux-headers-5.4.0-0.bpo.4-amd64'
make: Leaving directory '/home/install/git/droidcam/linux/v4l2loopback'
./install: line 44: mokutil: command not found
Moving driver and executable to system folders
+ cp v4l2loopback/v4l2loopback-dc.ko /lib/modules/5.4.0-0.bpo.4-amd64/kernel/
drivers/media/video/
+ cp droidcam /usr/local/bin/
+ cp droidcam-cli /usr/local/bin/
+ set +x
Registering webcam device
Running depmod
make: Entering directory '/home/install/git/droidcam/linux/v4l2loopback'
make -C /lib/modules/`uname -r`/build M=`pwd` clean
make[1]: Entering directory '/usr/src/linux-headers-5.4.0-0.bpo.4-amd64'
  CLEAN   /home/install/git/droidcam/linux/v4l2loopback/Module.symvers
make[1]: Leaving directory '/usr/src/linux-headers-5.4.0-0.bpo.4-amd64'
make: Leaving directory '/home/install/git/droidcam/linux/v4l2loopback'
Adding uninstall script
Adding driver to /etc/modules
Done
root@gigabyte:/home/install/git/droidcam/linux#


Notes:
--
(default resolution is 640x480)

-- the install script builds the kernel module, i.e. needs to rerun at every 
install


==> Test with guvcview


To uninstall:

# ./uninstall 


There is a pull request which uses dkms for building the kernel module


On Android phone:
- Install droidcam app on Android phone
- Recommended: use usb cable for latency reasons
- Run adb shell and allow computer access to phone
- Exit adb shell again

To run:
- Start droidcam on phone
- Run (for usb cable): droidcam-cli 127.0.0.1 4747 


In case a DD read that far: certainly it would be a big plus if you can make a 
regular Debian package out of it , it seems to be little code, so hopefully 
the effort is limited. :-)

-- 
Rainer Dorsch
http://bokomoko.de/




automounting sshfs

2020-01-18 Thread Rainer Dorsch
Hi,

I followed 

https://unix.stackexchange.com/questions/467081/sshfs-with-on-demand-mounting/
546102

to automount a directory with sshfs.

I added into /etc/fstab

sshfs#fs:/mnt/disk/data/spatzen /home/spatzen/Ablage fuse
noauto,allow_other,x-systemd.automount,_netdev,user,IdentityFile=/home/
spatzen/.ssh/id_rsa,reconnect 0 0

Generated as described on stackexchange a unit file: systemctl daemon-reload

root@nanette:~# systemctl list-unit-files --type automount
UNIT FILE STATE
home-spatzen-Ablage.automount generated
proc-sys-fs-binfmt_misc.automount static   

2 unit files listed.
root@nanette:~# 

Restarted the automount unitfile (even rebooted), but when I try to automount, 
I get a strange error

spatzen@nanette:~$ ls -l /home/spatzen/Ablage/
ls: cannot access '/home/spatzen/Ablage/': Too many levels of symbolic links
spatzen@nanette:~$ 

It seems the system is doing something, but not the right thing. If I mount 
manually  as user spatzen (mount /home/spatzen/Ablage) that works well...

Any idea and hint is welcome.

Thanks
Rainer




Re: KDE file dialog in Libreoffice

2020-01-18 Thread Rainer Dorsch
On Samstag, 18. Januar 2020 21:00:04 CET Rene Engelhard wrote:
> On Sat, Jan 18, 2020 at 06:49:23PM +0100, Rainer Dorsch wrote:
> > is there a way to get the KDE file dialog in libreoffice
> > (buster-backports) ?
> 
> > Installing libreoffice-kde does not seem to be sufficient for me...
> 
> libreoffice-kde5?
> 
> $ rmadison libreoffice-kde
> libreoffice-kde | 1:4.3.3-2+deb8u11| oldoldstable   |
> amd64, armel, armhf, i386 libreoffice-kde | 1:5.2.7-1+deb9u10|
> oldstable  | amd64, arm64, armel, armhf, i386, mips,
> mips64el, mipsel, ppc64el, s390x libreoffice-kde | 1:5.2.7-1+deb9u11   
> | oldstable-proposed-updates | amd64, arm64, armel, armhf, i386, mips,
> mips64el, mipsel, ppc64el, s390x libreoffice-kde | 1:6.1.5-3+deb10u4~bpo9+1
> | stretch-backports  | all libreoffice-kde | 1:6.1.5-3+deb10u5 
>   | stable | all $ rmadison libreoffice-kde5
> libreoffice-kde5 | 1:6.1.5-3+deb10u4~bpo9+1  | stretch-backports | amd64,
> arm64, armel, armhf, i386, mips, mips64el, mipsel, ppc64el, s390x
> libreoffice-kde5 | 1:6.1.5-3+deb10u5 | stable| amd64,
> arm64, armel, armhf, i386, mips, mips64el, mipsel, ppc64el, s390x
> libreoffice-kde5 | 1:6.3.4-2~bpo10+1 | buster-backports  | amd64,
> arm64, armel, armhf, i386, mips, mips64el, mipsel, ppc64el, s390x
> libreoffice-kde5 | 1:6.3.4-2 | testing   | amd64,
> arm64, armel, armhf, i386, mips64el, mipsel, ppc64el, s390x
> libreoffice-kde5 | 1:6.3.4-2 | unstable  | arm64
> libreoffice-kde5 | 1:6.4.0~beta1-0reprotest1 | experimental  | arm64,
> armel, armhf, mips64el, mipsel libreoffice-kde5 | 1:6.4.0~beta1-4  
> | experimental  | amd64, i386, ppc64el, s390x libreoffice-kde5 |
> 1:6.4.0~rc2-2 | unstable  | amd64, armel, armhf, i386,
> mips64el, mipsel, ppc64el, s390x $
> 
> libreoffice-kde is a noop just depending on -kde5 (and not present in
> buster-backports since it was just in buster for stretch->buster updates).
> 

Hi Rene,

thanks for the quick reply. I think the issue is more subtle.

rd@nanette:~$ apt-cache policy libreoffice-kde5 
libreoffice-kde5:
  Installiert:   1:6.3.4-2~bpo10+1
  Installationskandidat: 1:6.3.4-2~bpo10+1
  Versionstabelle:
 *** 1:6.3.4-2~bpo10+1 100
100 http://ftp.de.debian.org/debian buster-backports/main amd64 
Packages
100 /var/lib/dpkg/status
 1:6.1.5-3+deb10u5 500
500 http://ftp.de.debian.org/debian buster/main amd64 Packages
 1:6.1.5-3+deb10u4 500
500 http://security.debian.org buster/updates/main amd64 Packages
rd@nanette:~$ 

was installed, it was a typo on my side, libreoffice-kde was not installed.

And checking carefully, I think it is even the KDE file picker, here they are 
next to each other from kate (KDE editor) and libreoffice

http://scw.bokomoko.de/~rd/file_picker.png

I was looking Ablage in the Section Fremdgerät in the libreoffice file picker 
and 
this not find it. Since I had it on the other KDE apps, I concluded that it is 
another file picker.

Ablage is an sftp:// address. I am wondering, are these not supported by 
libreoffice?

Thanks
Rainer

Thanks
Rainer








KDE file dialog in Libreoffice

2020-01-18 Thread Rainer Dorsch
Hello,

is there a way to get the KDE file dialog in libreoffice (buster-backports) ?

Installing libreoffice-kde does not seem to be sufficient for me...

Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




Re: Print several (small) pages on A4/Letter sheet

2020-01-18 Thread Rainer Dorsch
Am Samstag, 18. Januar 2020, 16:14:45 CET schrieb David Wright:
> On Sat 18 Jan 2020 at 15:42:08 (+0100), Rainer Dorsch wrote:
> > Hi,
> > 
> > I have a pdf file with a page size of 186x65 mm2. If I print that on A4, I
> > get printouts which are mainly white, except the 186x65 mm2.
> > 
> > Is there a good way to get it printed in a compact way (e.g. 4 pages on
> > top of each other on an A4 sheet)? I could not find an option in pdftk,
> > so any advice or hint is welcome...
> 
> I use pdfjam in texlive-extra-utils in functions like these.
> 
> function a4-2up-a4r {
> [ -z "$1" ] && printf '%s\n' "Usage:  $FUNCNAME prints a single A4 
> page
> as 2-up A5 pages on an A4 landscape page for producing A5 hand bills when
> cut up." >&2 && return 1 local Expandedname="$(-addextensionandoldfile "$1"
> "pdf")"
> [ -z "$Expandedname" ] && return
> pdfjam --vanilla --nup '2x1' --landscape --a4paper --outfile
> "${Expandedname/%.pdf/-a4-2up-a4r.pdf}" "$Expandedname" "$Expandedname" }
> 
> function a4-4up-a4 {
> [ -z "$1" ] && printf '%s\n' "Usage:  $FUNCNAME prints a single A4 
> page
> as 4-up A6 pages on an A4 page for producing A6 hand bills when cut up."
> >&2 && return 1 local Expandedname="$(-addextensionandoldfile "$1" "pdf")"
> [ -z "$Expandedname" ] && return
> pdfjam --vanilla --nup '2x2' --no-landscape --a4paper --outfile
> "${Expandedname/%.pdf/-a4-4up-a4.pdf}" "$Expandedname" "$Expandedname"
> "$Expandedname" "$Expandedname" }
> 
> function a4-8up-a4r {
> [ -z "$1" ] && printf '%s\n' "Usage:  $FUNCNAME prints a single A4 
> page
> as 8-up A7 pages on an A4 page for producing A7 tickets when cut up." >&2
> && return 1
> local Expandedname="$(-addextensionandoldfile "$1" "pdf")"
> [ -z "$Expandedname" ] && return
> pdfjam --vanilla --nup '4x2' --landscape --a4paper --outfile
> "${Expandedname/%.pdf/-a4-8up-a4r.pdf}" "$Expandedname" "$Expandedname"
> "$Expandedname" "$Expandedname" "$Expandedname" "$Expandedname"
> "$Expandedname" "$Expandedname" }
> 
> -addextensionandoldfile just adds .pdf if absent, and checks the file
> exists. Then the output file has explanatory info added to its name.
> 
> The pages are prepared for purpose at the appropriate size. You can
> use   --scale n   and   --noautoscale true   if needed for your input.
> 

Many thanks, David.

pdfjam --vanilla --nup '1x4' --no-landscape --a4paper --outfile out.pdf in.pdf

does exactly what I want (perfectly scaled to A4).

Thanks again
Rainer



> Cheers,
> David.


-- 
Rainer Dorsch
http://bokomoko.de/




Print several (small) pages on A4/Letter sheet

2020-01-18 Thread Rainer Dorsch
Hi,

I have a pdf file with a page size of 186x65 mm2. If I print that on A4, I get 
printouts which are mainly white, except the 186x65 mm2.

Is there a good way to get it printed in a compact way (e.g. 4 pages on top of 
each other on an A4 sheet)? I could not find an option in pdftk, so any advice 
or hint is welcome...

Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




Re: dhclient and ipv6 DNS Servers

2020-01-18 Thread Rainer Dorsch
Am Freitag, 17. Januar 2020, 11:12:07 CET schrieb Curt:
> On 2020-01-16, Rainer Dorsch  wrote:
> > Am Mittwoch, 15. Januar 2020, 00:09:16 CET schrieb Pascal Hambourg:
> >> Le 14/01/2020 à 21:14, Rainer Dorsch a écrit :
> >> > prepend dhcp6.name-servers 2001:4860:4860::, 2001:4860:4860::8844;
> >> > 
> >> > avoids the error message, but has no visible effect I can see. The IPv6
> >> > DNS
> >> > servers still do not show in resolv.conf.
> >> 
> >> You may receive IPv6 DNS information from IPv6 Router Advertisements
> >> (RA) with rdnssd, not DHCPv6.
> > 
> > Many thanks, Pascal, that explains the obervations :-)
> > 
> > I have in /etc/network/interfaces
> > 
> > iface eth0.1 inet6 auto
> > 
> >   dhcp 1
> >   request_prefix 1
> > 
> > I could not find a way to overwrite the DNS server for rdnssd, does
> > anybody
> > know if that is possible?
> 
> All above and way beyond me, but from a cursory online examination of
> this affair it appears that beyond disabling rdnssd entirely, it's
> necessary to modify or patch the /etc/rdnssd/merge-hook script to
> prevent rdnssd from overwriting /etc/resolv.conf.
> 
> https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=767071
> 
>  /etc/resolv.conf is handled by a configurable /etc/rdnssd/merge-hook
>  script that users can modify to suit their needs. The stock version
>  upstream has been modified to do what you want for ages:
> 
>  http://git.remlab.net/gitweb/?p=ndisc6.git;a=blob_plain;f=rdnssd/merge-hook
> .in;hb=f7bd3662d2292e248173721d4760c03df39df666

Many thanks for your response, Curt, that helped at least to hack an overwrite 
to the ipv6 DNS server.

I do not understand what the upsteam does which Debian does not (also the bug 
you are refering to is resolved!). Nevertheless, the merge-hook script is a 
good place to look at.

As a quick fix I commented the line

#mv -f $resolvconf.tmp $resolvconf

This at least keeps rdnssd from overwriting the resolv.conf constantly.

I think a better solution would be to check if a e.g. DNS6 variable is defined 
(e.g. in /etc/default/rdnssd) and if yes, ignore the content of

root@home:~# cat /var/run/rdnssd/resolv.conf 
nameserver fe80::d263:b4ff:fe00:325c%eth0.7
nameserver fd38:81d3:9dac::1
nameserver fd22:c2e0:8eb2::1
root@home:~# 

and use the content of the DNS6 variable instead.

Berni,

does that make sense or is there already another mechanism in place for 
overwriting the (ipv6) DNS Server?

I think I could provide you a patch for the script, if that makes sense for 
you to integrate in the Debian package.

Thanks
Rainer






-- 
Rainer Dorsch
http://bokomoko.de/




Re: dhclient and ipv6 DNS Servers

2020-01-16 Thread Rainer Dorsch
Am Mittwoch, 15. Januar 2020, 00:09:16 CET schrieb Pascal Hambourg:
> Le 14/01/2020 à 21:14, Rainer Dorsch a écrit :
> > prepend dhcp6.name-servers 2001:4860:4860::, 2001:4860:4860::8844;
> > 
> > avoids the error message, but has no visible effect I can see. The IPv6
> > DNS
> > servers still do not show in resolv.conf.
> 
> You may receive IPv6 DNS information from IPv6 Router Advertisements
> (RA) with rdnssd, not DHCPv6.

Many thanks, Pascal, that explains the obervations :-)

I have in /etc/network/interfaces

iface eth0.1 inet6 auto
  dhcp 1
  request_prefix 1

I could not find a way to overwrite the DNS server for rdnssd, does anybody 
know if that is possible?


According to the interfaces man page, dhclient should be responsible with the 
dhcp method

iface eth0.1 inet6 dhcp
  request_prefix 1

ifup shows the nameservers in the log

Thu Jan 16 23:15:13 CET 2020: entering /etc/dhcp/dhclient-enter-hooks.d, 
dumping variables.
reason='PREINIT'
interface='eth0.1'
--
Thu Jan 16 23:15:13 CET 2020: entering /etc/dhcp/dhclient-exit-hooks.d, 
dumping variables.
reason='PREINIT'
interface='eth0.1'
--
Thu Jan 16 23:15:14 CET 2020: entering /etc/dhcp/dhclient-enter-hooks.d, 
dumping variables.
reason='REBOOT'
interface='eth0.1'
new_ip_address='192.168.0.30'
new_network_number='192.168.0.0'
new_subnet_mask='255.255.255.0'
new_broadcast_address='192.168.0.255'
new_routers='192.168.0.1'
new_domain_name='bokomoko.de'
new_domain_name_servers='192.168.0.1'
new_ntp_servers='192.168.0.1'
new_dhcp6_name_servers='2001:4860:4860:: 2001:4860:4860::8844'
--
Thu Jan 16 23:15:14 CET 2020: entering /etc/dhcp/dhclient-exit-hooks.d, 
dumping variables.
reason='REBOOT'
interface='eth0.1'
new_ip_address='192.168.0.30'
new_network_number='192.168.0.0'
new_subnet_mask='255.255.255.0'
new_broadcast_address='192.168.0.255'
new_routers='192.168.0.1'
new_domain_name='bokomoko.de'
new_domain_name_servers='192.168.0.1'
new_ntp_servers='192.168.0.1'
new_dhcp6_name_servers='2001:4860:4860:: 2001:4860:4860::8844'
--
Thu Jan 16 23:15:14 CET 2020: entering /etc/dhcp/dhclient-enter-hooks.d, 
dumping variables.
reason='PREINIT6'
interface='eth0.1'
--
Thu Jan 16 23:15:14 CET 2020: entering /etc/dhcp/dhclient-exit-hooks.d, 
dumping variables.
reason='PREINIT6'
interface='eth0.1'
--


but then I do not see an impact on resolv.conf:

nameserver fd38:81d3:9dac::1
nameserver fd22:c2e0:8eb2::1

ifup produces this output

XMT: Forming Solicit, 31050 ms elapsed.
XMT:  X-- IA_NA b4:00:32:5c
XMT:  | X-- Request renew in  +3600
XMT:  | X-- Request rebind in +5400
XMT:  X-- IA_PD b4:00:32:5c
XMT:  | X-- Request renew in  +3600
XMT:  | X-- Request rebind in +5400
XMT:  | X-- Request prefix 2a02:8070:898f:e4fc::/62.
XMT:  | | X-- Request preferred in +7200
XMT:  | | X-- Request valid in +10800
XMT: Solicit on eth0.1, interval 33560ms.
RCV: Advertise message on eth0.1 from fe80::e228:6dff:fe43:5776.
RCV:  X-- Server ID: 00:03:00:01:e0:28:6d:43:57:76
PRC: Lease failed to satisfy.

Any hint is still welcome :-)

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: dhclient and ipv6 DNS Servers

2020-01-14 Thread Rainer Dorsch
-

But neither new_dhcp6_name_servers nor old_dhcp6_name_servers (which are 
identical) matches the content of resolv.conf:

root@home:~# cat /etc/resolv.conf
domain bokomoko.de
search bokomoko.de
nameserver fd38:81d3:9dac::1
nameserver fda0:18e7:afcf::1
nameserver 8.8.8.8
root@home:~# 


Does anybody know which tool sets these variables?

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: dhclient and ipv6 DNS Servers

2020-01-14 Thread Rainer Dorsch
Am Dienstag, 14. Januar 2020, 19:18:01 CET schrieb Greg Wooledge:
> On Tue, Jan 14, 2020 at 12:12:03PM -0500, Bob Weber wrote:
> > Just edit the file /etc/resolv.conf and make it immutable (chattr +i 
> > /etc/resolv.conf).  At least you will know what is in the file and that it
> > can't be changed (mistakes and all).  I use this to keep chrome from
> > changing the google-chrome-beta.list file every time it starts since I use
> > the HTTPS/// option of  apt-cacher-ng to use https transfers outside my
> > LAN.
> That is one of the options given on the wiki page.
> 
> https://wiki.debian.org/resolv.conf
> 
> Be sure you work around bug #860928 if you use this approach.

Thank you for all the good replies to this thread.

prepend dhcp6.name-servers 2001:4860:4860::, 2001:4860:4860::8844;   

avoids the error message, but has no visible effect I can see. The IPv6 DNS 
servers still do not show in resolv.conf.

Unfortunately,

root@home:~# cat /etc/dhcp/dhclient-enter-hooks.d/leave_my_resolv_conf_alone 
make_resolv_conf() { :; }
root@home:~# ls -l /etc/dhcp/dhclient-enter-hooks.d/leave_my_resolv_conf_alone
-rwxr-xr-x 1 root root 26 Jan 14 20:59 /etc/dhcp/dhclient-enter-hooks.d/
leave_my_resolv_conf_alone
root@home:~# 

does not stop the system to overwrite /etc/resolv.conf constantly.

Do I need to restart a service that the change takes effect?

I did an ifdown/ifup eth0.1 ...

Thanks again
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




dhclient and ipv6 DNS Servers

2020-01-14 Thread Rainer Dorsch
Hello,

the ipv6 DNS servers I get supplied from my ISP

nameserver fd38:81d3:9dac::1
nameserver fd22:c2e0:8eb2::1

have problems from time to time.

I tried to switch to other servers, e.g. Google, but this does not work, since

/etc/resolv.conf gets  overwritten with a high frequency

/etc/dhcp/dhclient.conf does not accept ipv6 addresses like, since if I use 
the instructions from

https://developers.google.com/speed/public-dns/docs/using

and add to /etc/dhcp/dhclient.conf

prepend domain-name-servers 2001:4860:4860::, 2001:4860:4860::8844;

dhclient becomes unhappy (during an ifup eth0.1)

/etc/dhcp/dhclient.conf line 26: semicolon expected.
prepend domain-name-servers 2001:
 ^
/etc/dhcp/dhclient.conf line 26: expecting a statement.
prepend domain-name-servers 2001:4860:4860::, 2001:4860:4860::8844;
   ^
/etc/dhcp/dhclient.conf line 26: semicolon expected.

^

prepend domain-name-servers 8.8.8.8;
works, but still comes after the ipv6 nameservers

root@home:~# cat /etc/resolv.conf
domain bokomoko.de 
search bokomoko.de 
nameserver fd38:81d3:9dac::1 
nameserver fd22:c2e0:8eb2::1 
nameserver 8.8.8.8 
nameserver 192.168.0.1 
root@home:~# 

and the slow servers get queried first :-/


Probably unrelated, but today even Murphy seems to be with me, even if I 
switch on my ISP modem to alternate DNS servers, this gets ignored.

Any hint is welcome.

Thanks
Rainer



-- 
Rainer Dorsch
http://bokomoko.de/

Re: Default date output format changed after an upgrade to buster

2019-09-11 Thread Rainer Dorsch
Am Mittwoch, 11. September 2019, 13:57:37 CEST schrieb Michael Stone:
> On Wed, Sep 11, 2019 at 08:36:49AM +0200, Rainer Dorsch wrote:
> >Am Dienstag, 10. September 2019, 22:52:03 CEST schrieb Greg Wooledge:
> >> On Tue, Sep 10, 2019 at 10:06:37PM +0200, Rainer Dorsch wrote:
> >> > after an upgrade from stretch to buster, the date default output
> >> > changed
> >> > on my system
> >> > 
> >> > As an example:
> >> > 
> >> > Tue Sep 10 19:50:26 CEST 2019   (stretch)
> >> > Tue 10 Sep 2019 09:26:33 PM CEST  (buster)
> >> > 
> >> > I am just wondering if this is a known issue or if another
> >> > configuration
> >> > change during the upgrade caused this.
> >> 
> >> https://www.mail-archive.com/debian-user@lists.debian.org/msg741032.html
> >
> >Many thanks for all the replies. Greg, the perfect explanation you already
> >gave here
> >
> >https://www.mail-archive.com/debian-user@lists.debian.org/msg741096.html
> >
> >(that explains why buster behaves differently).
> >
> >I think it would have been worth an entry for apt-listchanges, since it
> >might at least change the output of some local scripts (like it did here).
> apt-listchanges in what? If you run the stretch date on buster, you'll
> get the same output. The change is that the localized string changed to
> something more sensible and date uses the localized string. If a script
> is relying on the output of a program like date without specifying
> either the C locale or a date format, it's almost certainly doing
> something wrong--those strings are expected to change depending on
> things like locale settings, and are for humans to read, not programs.

Don't expect that all my scripts are perfect ... there are quick and dirty 
ones;-) In a logfile a human readable output sounds not a too bad idea 
though...but I understand attaching that change to date does not make sense.

Nevermind, all good for me, I hope that if others are affected by the change 
they find the topic in the list archive.

Thanks again
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Default date output format changed after an upgrade to buster

2019-09-11 Thread Rainer Dorsch
Am Dienstag, 10. September 2019, 22:52:03 CEST schrieb Greg Wooledge:
> On Tue, Sep 10, 2019 at 10:06:37PM +0200, Rainer Dorsch wrote:
> > after an upgrade from stretch to buster, the date default output changed
> > on my system
> > 
> > As an example:
> > 
> > Tue Sep 10 19:50:26 CEST 2019   (stretch)
> > Tue 10 Sep 2019 09:26:33 PM CEST  (buster)
> > 
> > I am just wondering if this is a known issue or if another configuration
> > change during the upgrade caused this.
> 
> https://www.mail-archive.com/debian-user@lists.debian.org/msg741032.html

Many thanks for all the replies. Greg, the perfect explanation you already 
gave here

https://www.mail-archive.com/debian-user@lists.debian.org/msg741096.html

(that explains why buster behaves differently).

I think it would have been worth an entry for apt-listchanges, since it might 
at least change the output of some local scripts (like it did here).

Thanks again
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




Default date output format changed after an upgrade to buster

2019-09-10 Thread Rainer Dorsch
Hi,

after an upgrade from stretch to buster, the date default output changed on my 
system

As an example:

Tue Sep 10 19:50:26 CEST 2019   (stretch)
Tue 10 Sep 2019 09:26:33 PM CEST  (buster)

I am just wondering if this is a known issue or if another configuration change 
during the upgrade caused this.

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: Network Bandwidth issue in VLAN-Router

2019-07-28 Thread Rainer Dorsch
[please follow-up on debian-arm since it is an imx6 specific issue]

Hi,

I found in the meantime

https://boundarydevices.com/i-mx6-ethernet/

describes most likely the issue I see, in particular the transfer rate 
degradation to 3 Mbits/s is what I see

root@linaro-nano:~# tsecs=2 incr=200 ./bwtest.sh
--bandwidth 200
[  4]  0.0- 2.0 sec  48.1 MBytes   203 Mbits/sec   0.061 ms  164/34479 (0.48%)
[  3]  0.0- 2.0 sec  48.3 MBytes   203 Mbits/sec   0.034 ms0/34483 (0%)
--bandwidth 400
[  4]  0.0- 2.0 sec  96.5 MBytes   405 Mbits/sec   0.040 ms   67/68911 
(0.097%)
[  3]  0.0- 1.9 sec  93.9 MBytes   406 Mbits/sec   0.035 ms 1990/68965 (2.9%)
--bandwidth 600
[  4]  0.0- 2.0 sec   110 MBytes   460 Mbits/sec   0.030 ms  234/78615 (0.3%)
[  3]  0.0- 2.3 sec   110 MBytes   410 Mbits/sec  15.672 ms 26703/105262 (25%)
--bandwidth 800
[  4]  0.0- 2.0 sec   110 MBytes   461 Mbits/sec   0.033 ms0/78511 (0%)
[  3]  0.0- 2.2 sec  2.91 MBytes  11.1 Mbits/sec  101.865 ms 140266/142342 
(99%)
--bandwidth 1000
[  4]  0.0- 2.0 sec   110 MBytes   461 Mbits/sec   0.033 ms0/78383 (0%)
[  3]  0.0- 0.2 sec  90.4 KBytes  3.18 Mbits/sec  110.420 ms 141295/141358 
(1e+02%)

in addition, I see

root@home:~# ethtool eth0
Settings for eth0:
Supported ports: [ TP MII ]
Supported link modes:   10baseT/Half 10baseT/Full 
100baseT/Half 100baseT/Full 
1000baseT/Full 
Supported pause frame use: No
Supports auto-negotiation: Yes
Advertised link modes:  10baseT/Half 10baseT/Full 
100baseT/Half 100baseT/Full 
1000baseT/Full 
Advertised pause frame use: No
Advertised auto-negotiation: Yes
Link partner advertised link modes:  10baseT/Half 10baseT/Full 
 100baseT/Half 100baseT/Full 
 1000baseT/Full 
Link partner advertised pause frame use: Symmetric Receive-only
Link partner advertised auto-negotiation: Yes
Speed: 1000Mb/s
Duplex: Full
Port: MII
PHYAD: 0
Transceiver: internal
Auto-negotiation: on
Supports Wake-on: d
Wake-on: d
Link detected: yes
root@home:~# 

shows the same output as in their before scenario causing the bandwidth 
degradation.

Is anybody else seeing this with an imx6 device like the cubox-i?

Thanks
Rainer

PS:
What still puzzles me is that I see this issue only if I leave the subnet. 
Possibly there are other mechanism to limit the traffic in case of overruns on 
a 
local network, but here I am guessing (?)

Am Sonntag, 28. Juli 2019, 05:46:36 CEST schrieb Nicholas Geovanis:
> I can tell you that i have precisely this issue in Chicago. But the fact is
> that for me it was a result of rate-limiting at the IP provider ATT. It is
> not necessarily related directly, but senior citizens :-) may recall the
> differential up/down bandwidth on ISDN.
> At my last apartment i had fiber directly into my bedroom. Here it is over
> copper to the building wiring. I took a 25% hit on bandwidth up and down. I
> yelled at them for a rate reduction, but no dice.
> 
> On Sat, Jul 27, 2019, 8:24 AM Rainer Dorsch  wrote:
> > Hi,
> > 
> > I have a stretch box configured as VLAN router (Cubox -i2ex). There is a
> > drastic difference between the bandwidth of the uplink (VLAN1) and the
> > downlinks (VLAN 2 to 7):
> > 
> > On 192.168.7.1 (VLAN 7: eth0.7) I see arround 9 MB/s in a simple test:
> > rd@home:~$ wget -O /dev/null http://fs/debian-9.3.0-amd64-netinst.iso
> > [...] (9.08 MB/s)
> > rd@home:~$
> > 
> > On 192.168.0.30 (VLAN 1: eth0.1) is see less than 10%:
> > rd@home:~$ wget -O /dev/null
> > https://git.kernel.org/torvalds/t/linux-5.3-rc1.tar.gz
> > --2019-07-27 14:46:38--
> > https://git.kernel.org/torvalds/t/linux-5.3-rc1.tar.gz
> > [...] (339KB/s)
> > 
> > To prove that it has nothing to do with the uplink (there is a Fritzbox
> > 6430)
> > itself, I connected another  machine on same VLAN 1 (192.168.0.203). So
> > overall, the network looks like this
> > 
> > 
> > Internet
> > 
> > 
> > Fritz-Box
> > 
> > |   192.168.0.203
> > |
> > |--- x86
> > |
> > | 192.168.0.30
> > 
> > Cubox i
> > 
> > | 192.168.7.*
> > 
> > Note, the Cubox-i has only 1 physical interface, drawn are the virtual
> > interface.
> > 
> > The x86 machine reaches also a much higher network bandwidth:
> > 
> > rd@h370:~/tmp.nobackup$ wget -O /dev/null
> > https://git.kernel.org/torvalds/t/
> > linux-5.3-rc1.tar.gz
&

Network Bandwidth issue in VLAN-Router

2019-07-27 Thread Rainer Dorsch
 


 
  17 root  20   0   0  0  0 S   0.7  0.0 434:16.89 ksoftirqd/1  


 
  10 root  20   0   0  0  0 R   0.3  0.0  94:31.09 rcu_sched


 
 202 root  20   0   27144   6192   5760 S   0.3  0.3  89:57.07 systemd-
journal 

  
8678 root   0 -20   0  0  0 I   0.3  0.0   0:22.47 kworker/
2:2H-kb 

  
21622 root  20   0   0  0  0 I   0.3  0.0   0:01.57 kworker/
u8:3-ev 

  
32581 root   0 -20   0  0  0 I   0.3  0.0   0:18.03 kworker/
0:1H-kb 

  
   1 root  20   0   26672   5236   3852 S   0.0  0.3   2:42.16 systemd  


 
   2 root  20   0   0  0  0 S   0.0  0.0   0:07.14 kthreadd 


 
   3 root   0 -20   0  0  0 I   0.0  0.0   0:00.00 rcu_gp   


 
   4 root   0 -20   0  0  0 I   0.0  0.0   0:00.00 rcu_par_gp   


 
   8 root   0 -20   0  0  0 I   0.0  0.0   0:00.00 
mm_percpu_wq

  
   9 root  20   0   0  0  0 S   0.0  0.0   4:43.82 ksoftirqd/0  


 
  11 root  20   0   0  0  0 I   0.0  0.0   0:00.00 rcu_bh   


 
  12 root  rt   0   0  0  0 S   0.0  0.0   2:43.11 migration/0  
 

So in summary:
-> The uplink of the cubox to the internet is slow (<10% of available 
bandwidth)
-> The cubox can run on the physical interface (the0) much higher traffic (as 
shown on VLAN 7)
-> Another x86 host can run much higher traffic into the Internet

Any idea on what could restrict the bandwidth on the Cubox uplink is very 
welcome. Also any ideas to diagnose the issue further would be useful for me.

Many thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




neard: nfctool does not find ACR122U

2019-02-24 Thread Rainer Dorsch
Hello,

I am wondering if I am doing something wrong with neard/nfctool: I have 
attached and ACR122U using USB. dmesg finds it, lsusb as well. When an NFC card 
is in reach of the reader, the reader even magically beeps and the color of 
the LED changes from red to green.

But nfctool does not seem to find it (at least the empty Devices section 
implies that(?))...

root@h370:~# dmesg |tail -6 
[121495.757349] usb 1-8: new full-speed USB device number 47 using xhci_hcd 
[121495.913388] usb 1-8: New USB device found, idVendor=072f, idProduct=2200, 
bcdDevice= 2.14 
[121495.913400] usb 1-8: New USB device strings: Mfr=1, Product=2, 
SerialNumber=0 
[121495.913406] usb 1-8: Product: ACR122U PICC Interface 
[121495.913411] usb 1-8: Manufacturer: ACS 
[121495.932344] usb 1-8: NFC: NXP PN532 firmware ver 1.6 now attached 
root@h370:~# lsusb   
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub 
Bus 001 Device 006: ID 046d:0825 Logitech, Inc. Webcam C270 
Bus 001 Device 047: ID 072f:2200 Advanced Card Systems, Ltd ACR122U 
Bus 001 Device 004: ID 2a07:0102   
Bus 001 Device 040: ID 046d:0a44 Logitech, Inc. Headset H390 
Bus 001 Device 039: ID 046d:c00e Logitech, Inc. M-BJ58/M-BJ69 Optical Wheel 
Mouse 
Bus 001 Device 038: ID 046a:0023 Cherry GmbH Keyboard 
Bus 001 Device 037: ID 0409:005a NEC Corp. HighSpeed Hub 
Bus 001 Device 008: ID 04b4:fd13 Cypress Semiconductor Corp. Programmable 
power socket 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub 
root@h370:~# nfctool -l  
nfc0: 
 Tags: [ ] 
 Devices: [ ] 
 Protocols: [ Felica MIFARE Jewel ISO-DEP NFC-DEP ] 
 Powered: No 
 RF Mode: None 
 lto: 150 
 rw: 15 
 miux: 2047 

root@h370:~# 

Similarly, I see that nfcpy also has problems

rd@h370:~/tmp.nobackup/NFC/nfcpy/examples$ ./tagtool.py 
[nfc.clf] searching for reader on path usb
[nfc.clf] no reader available on path usb
[main] no contactless reader found on usb
[main] no contactless reader available
rd@h370:~/tmp.nobackup/NFC/nfcpy/examples$

but I think the problem is in the area of neard...

Documentation in the NFC on Linux area seems to be sparse, so any hint is 
welcome...

Thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/




zoneminder in experimental

2019-01-12 Thread Rainer Dorsch
[copying debian-user that you do not get the same questions multiple times, if 
others have the same question]

Hi Dimitry,

I just saw you manage an incredible amount of Debian packages:

https://qa.debian.org/developer.php?email=onlyjob%40debian.org

Many thanks for that. While looking through the list, I discovered brainparty, 
which I did not know before.

I am using zoneminder here in stretch. I saw you uploaded several new versions 
1.32.x to experimental. I am just wondering if you intend to upload a new 
version to sid before the release of buster or do the versions 1.32.x have 
severe limitations over the version 1.30.4 which is currently in sid and 
buster?

Many thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: /etc/network/interfaces with multiple network interfaces

2019-01-10 Thread Rainer Dorsch
Hi Reco,

works perfectly as you decribe for me.

Many thanks
Rainer

Am Donnerstag, 10. Januar 2019, 05:41:49 CET schrieb Reco:
>   Hi.
> 
> On Wed, Jan 09, 2019 at 11:09:58PM +0100, Rainer Dorsch wrote:
> > Hi,
> > 
> > I have a system with two network interfaces, connecting to two subnets.
> > 
> > For some reason the default route is going through eth0.3, I would want to
> > have it through eth0.7.
> 
> Both of your VLANs are configured by DHCP, and have the same metric (0
> by default).
> 
> > Is the default route determined by the order in /etc/network/interface of
> > the interfaces or is there another algorithm behind?
> 
> What really happens is one default route get replaced by another.
> Whichever happens to be getting the lease last - wins.
> 
> 
> If you need the default route on eno1.7 to appear and to be used -
> assign lower metric to it. Like this (32 and 64 are arbitrary):
> 
> # cam
> auto eno1.3
> allow-hotplug eno1.3
> iface eno1.3 inet dhcp
>   metric 64
> iface eno1.3 inet6 auto
>   accept_ra 0
> 
> # data
> auto eno1.7
> allow-hotplug eno1.7
> iface eno1.7 inet dhcp
>   metric 32
> iface eno1.7 inet6 auto
>   accept_ra 0
> 
> Reco


-- 
Rainer Dorsch
http://bokomoko.de/




/etc/network/interfaces with multiple network interfaces

2019-01-09 Thread Rainer Dorsch
Hi,

I have a system with two network interfaces, connecting to two subnets. 

For some reason the default route is going through eth0.3, I would want to 
have it through eth0.7.

Is the default route determined by the order in /etc/network/interface of the 
interfaces or is there another algorithm behind?

rd@master:~$ cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

auto eno1
allow-hotplug eno1
#iface eno1 inet dhcp
iface eno1 inet6 auto
  accept_ra 0

# cam
auto eno1.3
allow-hotplug eno1.3
iface eno1.3 inet dhcp
iface eno1.3 inet6 auto
  accept_ra 0

# data
auto eno1.7
allow-hotplug eno1.7
iface eno1.7 inet dhcp
iface eno1.7 inet6 auto
  accept_ra 0
rd@master:~$ ip a show
1: lo:  mtu 65536 qdisc noqueue state UNKNOWN group 
default qlen 1
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
   valid_lft forever preferred_lft forever
inet6 ::1/128 scope host 
   valid_lft forever preferred_lft forever
2: eno1:  mtu 1500 qdisc pfifo_fast state UP 
group default qlen 1000
link/ether 18:66:da:20:6f:2d brd ff:ff:ff:ff:ff:ff
inet6 fe80::1a66:daff:fe20:6f2d/64 scope link 
   valid_lft forever preferred_lft forever
3: eno1.3@eno1:  mtu 1500 qdisc noqueue state 
UP group default qlen 1000
link/ether 18:66:da:20:6f:2d brd ff:ff:ff:ff:ff:ff
inet 192.168.3.2/24 brd 192.168.3.255 scope global eno1.3
   valid_lft forever preferred_lft forever
inet6 fe80::1a66:daff:fe20:6f2d/64 scope link 
   valid_lft forever preferred_lft forever
4: eno1.7@eno1:  mtu 1500 qdisc noqueue state 
UP group default qlen 1000
link/ether 18:66:da:20:6f:2d brd ff:ff:ff:ff:ff:ff
inet 192.168.7.2/24 brd 192.168.7.255 scope global eno1.7
   valid_lft forever preferred_lft forever
inet6 fe80::1a66:daff:fe20:6f2d/64 scope link 
   valid_lft forever preferred_lft forever
rd@master:~$ ip r
default via 192.168.3.1 dev eno1.3 
192.168.3.0/24 dev eno1.3 proto kernel scope link src 192.168.3.2 
192.168.7.0/24 dev eno1.7 proto kernel scope link src 192.168.7.2 
rd@master:~$ 


Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




Re: /etc/network/interfaces and IPv6

2019-01-09 Thread Rainer Dorsch
Hi Reco,

many thanks, your answer worked well.

Rainer

Am Mittwoch, 9. Januar 2019, 11:23:46 CET schrieb Reco:
>   Hi.
> 
> On Wed, Jan 09, 2019 at 10:42:27AM +0100, Rainer Dorsch wrote:
> > Hello,
> > 
> > I am just wondering why ipv6 gets configured for enp1s0, even though I do
> > not request that in /etc/network/interfaces (?).
> 
> 
> 
> > 2: enp1s0:  mtu 1500 qdisc pfifo_fast
> > state UP group default qlen 1000
> > 
> > link/ether 74:d4:35:7b:0d:d8 brd ff:ff:ff:ff:ff:ff
> > inet6 2a02:8070:898f:e4fc:76d4:35ff:fe7b:dd8/64 scope global
> > mngtmpaddr dynamic> 
> >valid_lft 14307sec preferred_lft 14307sec
> 
> You've got your IPv6 address via Router Advertisement (mngtmpaddr
> dynamic, limited address lifetime).
> And you don't need anything but a Linux kernel to get it.
> 
> If you don't need IPv6 on that interface for some reason - add the
> following to your /etc/network/interfaces:
> 
> iface enp1s0 inet6 auto
>   accept_ra 0
> 
> Reco


-- 
Rainer Dorsch
http://bokomoko.de/




/etc/network/interfaces and IPv6

2019-01-09 Thread Rainer Dorsch
Hello,

I am just wondering why ipv6 gets configured for enp1s0, even though I do not 
request that in /etc/network/interfaces (?).

I suspect NetworkManager takes care of that, but I always thought, network 
manager does not touch interfaces mentioned in /etc/network/interface?

System is stretch.

[   17.057438] r8169 :01:00.0 enp1s0: link down 
[   17.057440] r8169 :01:00.0 enp1s0: link down 
[   17.057546] IPv6: ADDRCONF(NETDEV_UP): enp1s0: link is not ready 
[   28.782440] r8169 :01:00.0 enp1s0: link up 
[   28.782473] IPv6: ADDRCONF(NETDEV_CHANGE): enp1s0: link becomes ready


root@gigabyte:~# cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

auto enp1s0
allow-hotplug enp1s0
iface enp1s0 inet dhcp
#iface eno1.7 inet6 auto
root@gigabyte:~# ip addr show
1: lo:  mtu 65536 qdisc noqueue state UNKNOWN group 
default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
   valid_lft forever preferred_lft forever
inet6 ::1/128 scope host 
   valid_lft forever preferred_lft forever
2: enp1s0:  mtu 1500 qdisc pfifo_fast state UP 
group default qlen 1000
link/ether 74:d4:35:7b:0d:d8 brd ff:ff:ff:ff:ff:ff
inet 192.168.7.201/24 brd 192.168.7.255 scope global enp1s0
   valid_lft forever preferred_lft forever
inet6 2a02:8070:898f:e4fc:76d4:35ff:fe7b:dd8/64 scope global mngtmpaddr 
dynamic 
   valid_lft 14307sec preferred_lft 14307sec
inet6 fe80::76d4:35ff:fe7b:dd8/64 scope link 
   valid_lft forever preferred_lft forever
root@gigabyte:~# 

Many thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: IPv6 router is not forwarding packets

2019-01-07 Thread Rainer Dorsch
Hi Ulf,

many thank again for your reply. 

Am Sonntag, 6. Januar 2019, 21:40:21 CET schrieb Ulf Volmer:
> Yes, looks weird. I have no idea why this happens.
>
> Just one point, the response times of hop 3 in your second traceroute
> are quite low (instead of hop 2 in the first one). Are you sure that hop
> 3 isn't somewhere in your LAN?

Good observation. I mirrored the traffic to the ISP router (fritz.box) to 
another unused switch port and used tcpdump to record it.

Looks unsuspicious to me. I see the traceroute packets outgoing (three per hop 
limit as from home). The only difference is that the I get an "administratively 
prohibited" type back (probably what traceroute marks with the X).

https://scw.bokomoko.de/~rd/icmpv6.png
shows a screenshot of the first ICPMv6 packet which returns from the "wrong" 
IPv6 address. 

>From your observation on the timings, I would conclude that the packet does 
not leave the IP router (fritz.box). The only surprising thing is that the 
source ipv6 address is not the router address but some other address 
2a02:8070:8900:0:30a0:caa7:42e0:93d2 .

To me it seems almost like an issue of the ISP router (fritz.box). The 
fritzbox documentation contains a section

"Configure the IPv6 router so that it requests its own prefix from the 
FRITZ!Box 
using IPv6 prefix delegation and that it announces its routing information to 
the FRITZ!Box via router advertisement."

https://en.avm.de/service/fritzbox/fritzbox-7390/knowledge-base/publication/
show/1239_Setting-up-an-IPv6-subnet-in-the-FRITZ-Box/

Which routing information does the fritzbox need? Do I need radvd for that?

Thanks
Rainer



-- 
Rainer Dorsch
http://bokomoko.de/




Re: IPv6 router is not forwarding packets

2019-01-06 Thread Rainer Dorsch
> 
> Things are getting weirder now... :-/

Just looking at the differences between the traceroutes from home (stretch 
router) and mohot (endpoint):

rd@home:~$ traceroute6 2a03:4000:6:52b6::
traceroute to 2a03:4000:6:52b6:: (2a03:4000:6:52b6::), 30 hops max, 80 byte 
packets
 1  fritz.box (2a02:8070:898f:e400:e228:6dff:fe43:5776)  0.723 ms  0.608 ms  
0.710 ms
 2  2a02:8070:8900::1 (2a02:8070:8900::1)  13.961 ms  22.110 ms  20.783 ms
 3  2a02:8070:80ff:24dc::1 (2a02:8070:80ff:24dc::1)  21.874 ms  21.751 ms  
21.733 ms
 4  de-fra01b-rc1-lo0-0.v6.aorta.net (2001:730:2d00::5474:8065)  25.916 ms  
29.503 ms  27.045 ms
 5  de-fra01b-ri1-lo0-0.v6.aorta.net (2001:730:2d00::5474:8042)  26.992 ms  
26.815 ms  26.774 ms
 6  2001:730:2d01:21::2 (2001:730:2d01:21::2)  31.834 ms  25.176 ms  26.755 ms
 7  mail.bokomoko.de (2a03:4000:6:52b6::)  26.708 ms  21.379 ms  20.737 ms
rd@home:~$

rd@mohot:~$ traceroute6 2a03:4000:6:52b6::
traceroute to 2a03:4000:6:52b6:: (2a03:4000:6:52b6::), 30 hops max, 80 byte 
packets
 1  2a02:8070:898f:e4f8:d263:b4ff:fe00:325c 
(2a02:8070:898f:e4f8:d263:b4ff:fe00:325c)  0.366 ms  0.306 ms  0.295 ms
 2  fritz.box (2a02:8070:898f:e400:e228:6dff:fe43:5776)  0.929 ms  1.063 ms  
1.182 ms
 3  2a02:8070:8900:0:30a0:caa7:42e0:93d2 
(2a02:8070:8900:0:30a0:caa7:42e0:93d2)  2.620 ms !X  2.584 ms !X  2.539 ms !X
rd@mohot:~$ 

I see after my ISP router (fritz.box) the routes differ.

I am still wondering what happens here

Any hint is welcome
Rainer

Thanks
Rainer



-- 
Rainer Dorsch
http://bokomoko.de/




Re: IPv6 router is not forwarding packets

2019-01-06 Thread Rainer Dorsch
Hi Pascal, Ulf, and Georgi,

many thanks for your replies,  they brought me at least one step further :-)

Am Sonntag, 6. Januar 2019, 20:54:43 CET schrieb Ulf Volmer:
> On 06.01.19 20:47, Rainer Dorsch wrote:
> > does not do automatic stuff. But after a reboot I still get
> > 
> > root@mohot:~# ip -6 a show eth0
> > 2: eth0:  mtu 1500 state UP qlen 1000
> > 
> > inet6 2a02:8070:898f:e400:d263:b4ff:fe00:4dd1/64 scope global dynamic
> > 
> > mngtmpaddr
> > 
> >valid_lft 7126sec preferred_lft 3526sec
> > 
> > inet6 2a02:8070:898f:e4f8:d263:b4ff:fe00:4dd1/64 scope global dynamic
> > 
> > mngtmpaddr
> > 
> >valid_lft 14019sec preferred_lft 14019sec
> > 
> > inet6 fe80::d263:b4ff:fe00:4dd1/64 scope link
> > 
> >valid_lft forever preferred_lft forever
> > 
> > root@mohot:~# ip -6 r
> > 2a02:8070:898f:e400::/64 dev eth0 proto kernel metric 256 pref medium
> > 2a02:8070:898f:e4f8::/64 dev eth0 proto kernel metric 256 pref medium
> > fe80::/64 dev eth0 proto kernel metric 256 pref medium
> > default via fe80::d263:b4ff:fe00:325c dev eth0 proto ra metric 1024
> > hoplimit 64 pref medium
> > default via fe80::e228:6dff:fe43:5776 dev eth0 proto ra metric 1024
> > hoplimit 255 pref medium
> > root@mohot:~#
> > 
> > Is that expected? If yes, is that then dhcpv6 or slaac?
> 
> I think this is slaac. But you still get RAs from VLAN 1 and your ISP
> router. Are you should that your VLAN separating at layer 2 works as
> expected? tcpdump/wireshark is your friend.

I reviewed the VLAN config and indeed mohot still saw untagged traffic from 
VLAN1. 

After removing this, the upstream addresses and routings are gone.

But I (surprisingly) still get addresses and routes. Though they look now 
reasonable for me:

rd@mohot:~$ ip -6 a
1: lo:  mtu 65536 state UNKNOWN qlen 1000
inet6 ::1/128 scope host 
   valid_lft forever preferred_lft forever
2: eth0:  mtu 1500 state UP qlen 1000
inet6 2a02:8070:898f:e4f8:d263:b4ff:fe00:4dd1/64 scope global dynamic 
mngtmpaddr 
   valid_lft 14303sec preferred_lft 14303sec
inet6 fe80::d263:b4ff:fe00:4dd1/64 scope link 
   valid_lft forever preferred_lft forever
rd@mohot:~$ 

Still the problem is the same, I can ssh forth and back between home (stretch 
router) and mohot (endpoint). But I do not reach an internet server (outside 
of my home network):

rd@mohot:~$ ssh 2a03:4000:6:52b6::
ssh: connect to host 2a03:4000:6:52b6:: port 22: Connection refused
rd@mohot:~$ traceroute6 2a03:4000:6:52b6::
traceroute to 2a03:4000:6:52b6:: (2a03:4000:6:52b6::), 30 hops max, 80 byte 
packets
 1  2a02:8070:898f:e4f8:d263:b4ff:fe00:325c 
(2a02:8070:898f:e4f8:d263:b4ff:fe00:325c)  0.361 ms  0.295 ms  0.305 ms
 2  fritz.box (2a02:8070:898f:e400:e228:6dff:fe43:5776)  0.798 ms  0.821 ms  
0.813 ms
 3  2a02:8070:8900:0:30a0:caa7:42e0:93d2 
(2a02:8070:8900:0:30a0:caa7:42e0:93d2)  1.478 ms !X  1.459 ms !X  1.434 ms !X
rd@mohot:~$ 

Things are getting weirder now... :-/

Any hint is welcome
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: IPv6 router is not forwarding packets

2019-01-06 Thread Rainer Dorsch
Am Sonntag, 6. Januar 2019, 20:29:27 CET schrieb Pascal Hambourg:
> You should start with a fully static setup on the host, fix routing, and
> when done you can try to setup SLAAC/DHCPv6.

I agree.

I thought that

iface eth0 inet6 manual

does not do automatic stuff. But after a reboot I still get

root@mohot:~# ip -6 a show eth0
2: eth0:  mtu 1500 state UP qlen 1000
inet6 2a02:8070:898f:e400:d263:b4ff:fe00:4dd1/64 scope global dynamic 
mngtmpaddr 
   valid_lft 7126sec preferred_lft 3526sec
inet6 2a02:8070:898f:e4f8:d263:b4ff:fe00:4dd1/64 scope global dynamic 
mngtmpaddr 
   valid_lft 14019sec preferred_lft 14019sec
inet6 fe80::d263:b4ff:fe00:4dd1/64 scope link 
   valid_lft forever preferred_lft forever
root@mohot:~# ip -6 r
2a02:8070:898f:e400::/64 dev eth0 proto kernel metric 256 pref medium
2a02:8070:898f:e4f8::/64 dev eth0 proto kernel metric 256 pref medium
fe80::/64 dev eth0 proto kernel metric 256 pref medium
default via fe80::d263:b4ff:fe00:325c dev eth0 proto ra metric 1024 hoplimit 64 
pref medium
default via fe80::e228:6dff:fe43:5776 dev eth0 proto ra metric 1024 hoplimit 
255 pref medium
root@mohot:~# 

Is that expected? If yes, is that then dhcpv6 or slaac?

Thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/




Re: IPv6 router is not forwarding packets

2019-01-06 Thread Rainer Dorsch
Am Sonntag, 6. Januar 2019, 19:49:13 CET schrieb Pascal Hambourg:
> Le 06/01/2019 à 19:32, Ulf Volmer a écrit :
> > On 06.01.19 18:36, Rainer Dorsch wrote:
> >> inet6 2a02:8070:898f:e400:d263:b4ff:fe00:4dd1/64 scope global dynamic
> >> mngtmpaddr>> 
> >>valid_lft 7030sec preferred_lft 3430sec
> >> 
> >> inet6 2a02:8070:898f:e4f8:d263:b4ff:fe00:4dd1/64 scope global dynamic
> >> mngtmpaddr>> 
> >>valid_lft 14215sec preferred_lft 14215sec
> > 
> > I'm confused that you have uplink and downlink addresses configured on
> > the client.
> 
> Good catch, didn't spot this. This is of course wrong.
> 
> BTW, I am a bit surprised by the upstream setup. It wastes a full /64
> just for one address.

Do yo mean the 2a02:8070:898f:e400:d263:b4ff:fe00:325c/64 in

root@home:/etc# ip addr show eth0.1
4: eth0.1@eth0:  mtu 1500 qdisc noqueue state 
UP group default qlen 1000
link/ether d0:63:b4:00:32:5c brd ff:ff:ff:ff:ff:ff
inet 192.168.0.30/24 brd 192.168.0.255 scope global eth0.1
   valid_lft forever preferred_lft forever
inet6 2a02:8070:898f:e400:d263:b4ff:fe00:325c/64 scope global mngtmpaddr 
dynamic 
   valid_lft 6676sec preferred_lft 3076sec
inet6 fe80::d263:b4ff:fe00:325c/64 scope link 
   valid_lft forever preferred_lft forever
root@home:/etc# 

?

Isn't the /64 the prefix length and longer prefixes than 64 are not supported 
in 
ipv6?

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: IPv6 router is not forwarding packets

2019-01-06 Thread Rainer Dorsch
Hi Pascal,

Am Sonntag, 6. Januar 2019, 19:41:51 CET schrieb Pascal Hambourg:
> Le 06/01/2019 à 18:36, Rainer Dorsch a écrit :
> > ISP router -> Stretch router (home) -> Endpoint (mohot)
> > 
> > I can ssh from the mohot to home (ssh
> > 2a02:8070:898f:e4f8:d263:b4ff:fe00:325c) and I can ssh from the home to
> > the internet (using IPv6), but I cannot ssh
> > from the mohot (endpoint) to the internet:
> (...)
> 
> > For me it seems that home is dropping the request, if that is the case, is
> > there a good way to find out why that happens?
> 
> Did you run a packet capture on each involved interface ?

Since these are all vlans, I can run wireshark on each interface. That would 
be my next step...

> 
> > Stretch Router:
> > ---
> > 
> > The stretch router has an upstream interface
> > 
> > root@home:/etc# ip addr show dev eth0.1
> > 4: eth0.1@eth0:  mtu 1500 qdisc noqueue
> > state UP group default qlen 1000
> > 
> >  link/ether d0:63:b4:00:32:5c brd ff:ff:ff:ff:ff:ff
> >  inet 192.168.0.30/24 brd 192.168.0.255 scope global eth0.1
> >  
> > valid_lft forever preferred_lft forever
> >  
> >  inet6 2a02:8070:898f:e400:d263:b4ff:fe00:325c/64 scope global
> >  mngtmpaddr
> > 
> > dynamic
> > 
> > valid_lft 6968sec preferred_lft 3368sec
> >  
> >  inet6 fe80::d263:b4ff:fe00:325c/64 scope link
> >  
> > valid_lft forever preferred_lft forever
> > 
> > and a downstream interface
> > 
> > root@home:/etc# ip addr show dev eth0.7
> > 10: eth0.7@eth0:  mtu 1500 qdisc noqueue
> > state UP group default qlen 1000
> > 
> > link/ether d0:63:b4:00:32:5c brd ff:ff:ff:ff:ff:ff
> > inet 192.168.7.1/24 brd 192.168.7.255 scope global eth0.7
> > 
> >valid_lft forever preferred_lft forever
> > 
> > inet6 2a02:8070:898f:e4f8:d263:b4ff:fe00:325c/62 scope global
> 
> Why /62 instead of the standard /64 ?

I think that is the outcome of prefix delegation (I have /56 from the ISP).  
This is implemented by the script in

https://wiki.debian.org/IPv6PrefixDelegation

(at least I am not aware that I specify anywhere /62).

> 
> >valid_lft forever preferred_lft forever
> > 
> > inet6 fe80::d263:b4ff:fe00:325c/64 scope link
> > 
> >valid_lft forever preferred_lft forever
> > 
> > root@home:/etc#
> > 
> > for prefix delegation, I followed the Debian wiki
> > 
> > https://wiki.debian.org/IPv6PrefixDelegation
> > 
> > And routing information:
> > root@home:/etc# ip -6 r
> > 2a02:8070:898f:e400::/64 dev eth0.1 proto kernel metric 256  expires
> > 6974sec pref medium
> > 2a02:8070:898f:e4f8::/62 dev eth0.7 proto kernel metric 256  pref medium
> 
> (...)
> 
> > IPv6 forwarding is enabled:
> > 
> > root@home:/etc# cat /proc/sys/net/ipv6/conf/all/forwarding
> > 1
> > root@home:/etc# cat /proc/sys/net/ipv6/conf/eth0.7/forwarding
> > 1
> > root@home:/etc#
> 
> What about eth0.1 ? Needed to forward incoming reply packets too.

They should be forwarded:

root@home:/etc# cat /proc/sys/net/ipv6/conf/eth0.1/forwarding 
1
root@home:/etc#
 
> > Endpoint:
> > -
> > rd@mohot:~$ ip addr show dev eth0
> > 2: eth0:  mtu 1500 qdisc pfifo_fast state
> > UP group default qlen 1000
> > 
> > link/ether d0:63:b4:00:4d:d1 brd ff:ff:ff:ff:ff:ff
> > inet 192.168.7.31/24 brd 192.168.7.255 scope global eth0
> > 
> >valid_lft forever preferred_lft forever
> > 
> > inet6 2a02:8070:898f:e400:d263:b4ff:fe00:4dd1/64 scope global dynamic
> > 
> > mngtmpaddr
> > 
> >valid_lft 7030sec preferred_lft 3430sec
> > 
> > inet6 2a02:8070:898f:e4f8:d263:b4ff:fe00:4dd1/64 scope global dynamic
> > 
> > mngtmpaddr
> > 
> >valid_lft 14215sec preferred_lft 14215sec
> > 
> > inet6 fe80::d263:b4ff:fe00:4dd1/64 scope link
> > 
> >valid_lft forever preferred_lft forever
> 
> What about IPv6 routes ?

root@mohot:~# ip -6 r
2a02:8070:898f:e400::/64 dev eth0 proto kernel metric 256 pref medium
2a02:8070:898f:e4f8::/64 dev eth0 proto kernel metric 256 pref medium
2a02:8070:898f:e4f8::/62 dev eth0 proto kernel metric 256 pref medium
fe80::/64 dev eth0 proto kernel metric 256 pref medium
default via fe80::d263:b4ff:fe00:325c dev eth0 proto ra metric 1024 hoplimit 64 
pref medium
default via fe80::e228:6dff:fe43:5776 dev eth0 proto ra metric 1024 hoplimit 
255 pref medium
roo

Re: IPv6 router is not forwarding packets

2019-01-06 Thread Rainer Dorsch
Hi Ulf,

Am Sonntag, 6. Januar 2019, 19:32:46 CET schrieb Ulf Volmer:
> On 06.01.19 18:36, Rainer Dorsch wrote:
> > Endpoint:
> > -
> > rd@mohot:~$ ip addr show dev eth0
> > 2: eth0:  mtu 1500 qdisc pfifo_fast state
> > UP group default qlen 1000
> > 
> >link/ether d0:63:b4:00:4d:d1 brd ff:ff:ff:ff:ff:ff
> >inet 192.168.7.31/24 brd 192.168.7.255 scope global eth0
> >
> >   valid_lft forever preferred_lft forever
> >
> >inet6 2a02:8070:898f:e400:d263:b4ff:fe00:4dd1/64 scope global dynamic
> > 
> > mngtmpaddr
> > 
> >   valid_lft 7030sec preferred_lft 3430sec
> >
> >inet6 2a02:8070:898f:e4f8:d263:b4ff:fe00:4dd1/64 scope global dynamic
> > 
> > mngtmpaddr
> > 
> >   valid_lft 14215sec preferred_lft 14215sec
> >
> >inet6 fe80::d263:b4ff:fe00:4dd1/64 scope link
> >
> >   valid_lft forever preferred_lft forever
> 
> I'm confused that you have uplink and downlink addresses configured on
> the client. Anyway, can you also post 'ip -6 r' from the client?

I have not explicitly configured the addresses, but I have a dnsmasq running on 
the server which might be responsible for that, though I do not see how, I 
have in dnsmasq.conf

# Do router advertisements for all subnets where we're doing DHCPv6 


 
# Unless overriden by ra-stateless, ra-names, et al, the router 


 
# advertisements will have the M and O bits set, so that the clients


 
# get addresses and configuration from DHCPv6, and the A bit reset, so the  


 
# clients don't use SLAAC addresses.


 
enable-ra

# Advertise delegated prefix based on the IPv6 address of eth0. 


 
dhcp-range = ::1,constructor:eth0.7,   ra-stateless, ra-names, 4h


The output you requested on the mohot (endpoint):

rd@mohot:~$ ip -6 r
2a02:8070:898f:e400::/64 dev eth0 proto kernel metric 256 pref medium
2a02:8070:898f:e4f8::/64 dev eth0 proto kernel metric 256 pref medium
2a02:8070:898f:e4f8::/62 dev eth0 proto kernel metric 256 pref medium
fe80::/64 dev eth0 proto kernel metric 256 pref medium
default via fe80::d263:b4ff:fe00:325c dev eth0 proto ra metric 1024 hoplimit 64 
pref medium
default via fe80::e228:6dff:fe43:5776 dev eth0 proto ra metric 1024 hoplimit 
255 pref medium
rd@mohot:~$

I do not understand why there is fe80::e228:6dff:fe43:5776. This is the link 
local address of the ISP router, which does not make sense (?).

but even if I delete entry, I do not get it working: 

root@mohot:~# ip r del default via fe80::e228:6dff:fe43:5776 
root@mohot:~# ip -6 r
2a02:8070:898f:e400::/64 dev eth0 proto kernel metric 256 pref medium
2a02:8070:898f:e4f8::/64 dev eth0 proto kernel metric 256 pref medium
2a02:8070:898f:e4f8::/62 dev eth0 proto kernel metric 256 pref medium
fe80::/64 dev eth0 proto kernel metric 256 pref medium
default via fe80::d263:b4ff:fe00:325c dev eth0 proto ra metric 1024 hoplimit 64 
pref medium
root@mohot:~#

does not change anything (visible) and causes timeouts.

What surprises me is that traceroute6 does not even find home (stretch router)

rd@mohot:~$ traceroute6 2a03:4000:6:52b6::  
traceroute to 2a03:4000:6:52b6:: (2a03:4000:6:52b6::), 30 hops max, 80 byte 
packets
 1  * * *
 2  * * *
 3  * * *

but I am not sure how reliable traceroute is.

A direct connection works well:

rd@mohot:~$ ssh fe80::d263:b4ff:fe00:325c%eth0
Linux home 4.18.0-0.bpo.3-armmp #1 SMP Debian 4.18.20-2~bpo9+1 (2018-12-08) 
armv7l

The programs included with the Debian GNU/Linux system are f

IPv6 router is not forwarding packets

2019-01-06 Thread Rainer Dorsch
Hello,

I tried to configure a stretch based IPv6 router.

My setup is:

ISP router -> Stretch router (home) -> Endpoint (mohot)

I can ssh from the mohot to home (ssh 2a02:8070:898f:e4f8:d263:b4ff:fe00:325c) 
and I can ssh from the home to the internet (using IPv6), but I cannot ssh 
from the mohot (endpoint) to the internet:

rd@mohot:~$ ssh -vvv 2a03:4000:6:52b6::
OpenSSH_7.7p1 Debian-3, OpenSSL 1.0.2o  27 Mar 2018
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug2: resolve_canonicalize: hostname 2a03:4000:6:52b6:: is address
debug2: ssh_connect_direct: needpriv 0
debug1: Connecting to 2a03:4000:6:52b6:: [2a03:4000:6:52b6::] port 22.

IPv6 forwarding is enabled on the home (stretch router):

# cat /proc/sys/net/ipv6/conf/all/forwarding 
1
#

For me it seems that home is dropping the request, if that is the case, is 
there a good way to find out why that happens?

Any hint is welcome... 

Here is the interface config and routing configuration:

ISP Router:
---

My upstream connection gives me a dynamic IPv6 prefix: 2a02:8070:898f:e400::/56
and has an IPv6 address 2a02:8070:8900::30a0:caa7:42e0:93d2

Stretch Router:
---

The stretch router has an upstream interface

root@home:/etc# ip addr show dev eth0.1
4: eth0.1@eth0:  mtu 1500 qdisc noqueue state 
UP group default qlen 1000
link/ether d0:63:b4:00:32:5c brd ff:ff:ff:ff:ff:ff
inet 192.168.0.30/24 brd 192.168.0.255 scope global eth0.1
   valid_lft forever preferred_lft forever
inet6 2a02:8070:898f:e400:d263:b4ff:fe00:325c/64 scope global mngtmpaddr 
dynamic 
   valid_lft 6968sec preferred_lft 3368sec
inet6 fe80::d263:b4ff:fe00:325c/64 scope link 
   valid_lft forever preferred_lft forever

and a downstream interface

root@home:/etc# ip addr show dev eth0.7 
10: eth0.7@eth0:  mtu 1500 qdisc noqueue 
state UP group default qlen 1000 
   link/ether d0:63:b4:00:32:5c brd ff:ff:ff:ff:ff:ff 
   inet 192.168.7.1/24 brd 192.168.7.255 scope global eth0.7 
  valid_lft forever preferred_lft forever 
   inet6 2a02:8070:898f:e4f8:d263:b4ff:fe00:325c/62 scope global  
  valid_lft forever preferred_lft forever 
   inet6 fe80::d263:b4ff:fe00:325c/64 scope link  
  valid_lft forever preferred_lft forever 
root@home:/etc# 

for prefix delegation, I followed the Debian wiki

https://wiki.debian.org/IPv6PrefixDelegation

And routing information:
root@home:/etc# ip -6 r
2a02:8070:898f:e400::/64 dev eth0.1 proto kernel metric 256  expires 6974sec 
pref medium
2a02:8070:898f:e4f8::/62 dev eth0.7 proto kernel metric 256  pref medium
fe80::/64 dev eth0 proto kernel metric 256  pref medium
fe80::/64 dev eth0.1 proto kernel metric 256  pref medium
fe80::/64 dev eth0.2 proto kernel metric 256  pref medium
fe80::/64 dev eth0.3 proto kernel metric 256  pref medium
fe80::/64 dev eth0.4 proto kernel metric 256  pref medium
fe80::/64 dev eth0.5 proto kernel metric 256  pref medium
fe80::/64 dev eth0.6 proto kernel metric 256  pref medium
fe80::/64 dev eth0.7 proto kernel metric 256  pref medium
default via fe80::e228:6dff:fe43:5776 dev eth0.1 proto ra metric 1024  expires 
1574sec hoplimit 255 pref medium
root@home:/etc# 

IPv6 forwarding is enabled:

root@home:/etc# cat /proc/sys/net/ipv6/conf/all/forwarding 
1
root@home:/etc# cat /proc/sys/net/ipv6/conf/eth0.7/forwarding 
1
root@home:/etc#


Endpoint:
-
rd@mohot:~$ ip addr show dev eth0 
2: eth0:  mtu 1500 qdisc pfifo_fast state UP 
group default qlen 1000 
   link/ether d0:63:b4:00:4d:d1 brd ff:ff:ff:ff:ff:ff 
   inet 192.168.7.31/24 brd 192.168.7.255 scope global eth0 
  valid_lft forever preferred_lft forever 
   inet6 2a02:8070:898f:e400:d263:b4ff:fe00:4dd1/64 scope global dynamic 
mngtmpaddr  
  valid_lft 7030sec preferred_lft 3430sec 
   inet6 2a02:8070:898f:e4f8:d263:b4ff:fe00:4dd1/64 scope global dynamic 
mngtmpaddr  
  valid_lft 14215sec preferred_lft 14215sec 
   inet6 fe80::d263:b4ff:fe00:4dd1/64 scope link  
  valid_lft forever preferred_lft forever 
rd@mohot:~$ 

Many thanks 
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




No (USB) mouse and keyboard after resume

2018-11-03 Thread Rainer Dorsch
   200704  1
aes_x86_64 20480  1 aesni_intel
libahci40960  1 ahci
crypto_simd16384  1 aesni_intel
cryptd 28672  3 crypto_simd,ghash_clmulni_intel,aesni_intel
xhci_pci   16384  0
glue_helper16384  1 aesni_intel
xhci_hcd  270336  1 xhci_pci
ohci_hcd   61440  1 ohci_pci
ehci_pci   16384  0
i2c_piix4  24576  0
ehci_hcd   94208  1 ehci_pci
libata278528  2 libahci,ahci
usbcore   290816  7 
xhci_hcd,ohci_hcd,ehci_pci,usbhid,ehci_hcd,xhci_pci,ohci_pci
scsi_mod  253952  3 sd_mod,libata,sg
r8169  90112  0
usb_common 16384  1 usbcore
mii16384  1 r8169
rd@blackbox:~$ 

The problem occurs with both the 4.18.0-0.bpo.1-amd64 and 4.9.0-8-amd64 
kernels

The mainboard is a Gigabyte GA-AM1M-S2H.

Any hint or advise is welcome.

Thanks
Rainer



-- 
Rainer Dorsch
http://bokomoko.de/




Re: Tea4CUPS: TEABILLING reports error

2018-08-12 Thread Rainer Dorsch
Hi Daniel,

no unfortunately I have not yet resolved the problem. I still issue the 
prehook manually. But I did not yet dig too deep into this issue... 

If you find the root cause, please let me knowand good to know that this 
is a cross distri issue, even Arch is affected.

Rainer

On Samstag, 11. August 2018 17:29:35 CEST daniel-mailingli...@dadosch.de 
wrote:
> Hey there,
> I'm having this error too, on my KDE Neon System as well as on my (now)
> Arch System. It works most of the times, but not all.
> 
> Did you finally manage to find a solution, Rainer?
> 
> 
> --
> Daniel


-- 
Rainer Dorsch
http://bokomoko.de/




Strange Mouse Issue after Resuming from Suspend

2018-07-30 Thread Rainer Dorsch
Hello,

I have here a Debian Stretch system with a Logitech RX300 mouse (changing the 
mouse does not help)

root@blackbox:~# lsusb
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 006 Device 002: ID 046d:c040 Logitech, Inc. Corded Tilt-Wheel Mouse
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 002: ID 046a:b090 Cherry GmbH 
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
root@blackbox:~# 


and an AMD system

root@blackbox:~# lspci 
00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 16h Processor 
Root Complex
00:01.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] 
Kabini [Radeon HD 8400 / R3 Series]
00:01.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Kabini HDMI/DP 
Audio
00:02.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 16h Processor 
Function 0
00:02.3 PCI bridge: Advanced Micro Devices, Inc. [AMD] Family 16h Processor 
Functions 5:1
00:10.0 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB XHCI 
Controller (rev 01)
00:11.0 SATA controller: Advanced Micro Devices, Inc. [AMD] FCH SATA 
Controller [AHCI mode] (rev 40)
00:12.0 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB OHCI 
Controller (rev 39)
00:12.2 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB EHCI 
Controller (rev 39)
00:13.0 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB OHCI 
Controller (rev 39)
00:13.2 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB EHCI 
Controller (rev 39)
00:14.0 SMBus: Advanced Micro Devices, Inc. [AMD] FCH SMBus Controller (rev 
3a)
00:14.2 Audio device: Advanced Micro Devices, Inc. [AMD] FCH Azalia Controller 
(rev 02)
00:14.3 ISA bridge: Advanced Micro Devices, Inc. [AMD] FCH LPC Bridge (rev 11)
00:18.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 16h Processor 
Function 0
00:18.1 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 16h Processor 
Function 1
00:18.2 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 16h Processor 
Function 2
00:18.3 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 16h Processor 
Function 3
00:18.4 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 16h Processor 
Function 4
00:18.5 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 16h Processor 
Function 5
01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 
PCI Express Gigabit Ethernet Controller (rev 06)
root@blackbox:~# 

After a resume on suspend the USB mouse is gone (at least once also the 
keyboard), lsusb does not list it anymore. Even replugging the mouse does not 
bring it back (!). 

root@blackbox:~# lsusb
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 002: ID 046a:b090 Cherry GmbH 
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
root@blackbox:~# 

dmesg output has at least some traces, e.g.

PM: Device 6-2 failed to resume async: error -22

here is the full dmesg output for the suspend/resume cycle:

[ 1276.214876] usb 6-2: USB disconnect, device number 2
[ 1280.550613] usb 6-2: new low-speed USB device number 3 using ohci-pci
[ 1280.753814] usb 6-2: New USB device found, idVendor=046d, idProduct=c05b
[ 1280.753821] usb 6-2: New USB device strings: Mfr=1, Product=2, 
SerialNumber=0
[ 1280.753824] usb 6-2: Product: USB Optical Mouse
[ 1280.753827] usb 6-2: Manufacturer: Logitech
[ 1280.761623] input: Logitech USB Optical Mouse as /devices/
pci:00/:00:13.0/usb6/6-2/6-2:1.0/0003:046D:C05B.0004/input/input12
[ 1280.761978] hid-generic 0003:046D:C05B.0004: input,hidraw0: USB HID v1.11 
Mouse [Logitech USB Optical Mouse] on usb-:00:13.0-2/input0
[ 1328.365975] PM: suspend entry (deep)
[ 1328.365979] PM: Syncing filesystems ... done.
[ 1328.532151] Freezing user space processes ... (elapsed 0.007 seconds) done.
[ 1328.539259] OOM killer disabled.
[ 1328.539260] Freezing remaining freezable tasks ... (elapsed 0.002 seconds) 
done.
[ 1328.541684] Suspending console(s) (use no_console_suspend to debug)
[ 1328.542837] parport_pc 00:04: disabled
[ 1328.543042] serial 00:03: disabled
[ 1328.562058] sd 0:0:0:0: [sda] Synchronizing SCSI cache
[ 1328.563675] sd 0:0:0:0: [sda] Stopping disk
[ 1328.578140] sd 1:0:0:0: [sdb] Synchronizing SCSI cache
[ 1328.578307] sd 1:0:0:0: [sdb] Stopping disk
[ 1329.345781] ACPI: Preparing to enter system sleep state S3
[ 1329.346668] PM: Saving platform NVS memory
[ 1329.346692] Disabling non-boot CPUs ...
[ 1329.362543] IRQ 37: no longer affine to CPU1
[ 1329.363633] smpboot: CPU 1 is now 

Re: Tea4CUPS: TEABILLING reports error

2018-06-18 Thread Rainer Dorsch
Hi Brian,

thank you for your response and please apologize for my slow response.

On Donnerstag, 31. Mai 2018 20:04:22 CEST Brian wrote:
> Your tea4cups.conf is poorly.  Here is a minimal one which works for me:
>   [Global]
>   debug : yes
>   directory : /var/spool/cups/
>   prehook_sispmctl : sispmctl -ng 4 2> /tmp/SISPMCTL

Hmmmine does not look so much different, I edited them template shipped by 
Debian:

rd@b370:/var/log/cups$ grep -v '^#' /etc/cups/tea4cups.conf |grep -v '^$'
[global]
directory : /var/spool/cups/
prehook_sispmctl : /usr/local/bin/printeron
rd@b370:/var/log/cups$

... 

I had to change [Global]-> [global] in your config (?)

E [18/Jun/2018:21:25:15 +0200] [Job 37] Tea4CUPS (PID 19895) : Traceback (most 
recent call last):
E [18/Jun/2018:21:25:15 +0200] [Job 37] Tea4CUPS (PID 19895) :   File \"/usr/
lib/cups/backend/tea4cups\", line 1503, in 
E [18/Jun/2018:21:25:15 +0200] [Job 37] Tea4CUPS (PID 19895) : returncode 
= wrapper.runBranches()
E [18/Jun/2018:21:25:15 +0200] [Job 37] Tea4CUPS (PID 19895) :   File \"/usr/
lib/cups/backend/tea4cups\", line 1302, in runBranches
E [18/Jun/2018:21:25:15 +0200] [Job 37] Tea4CUPS (PID 19895) : branches = 
self.enumBranches(self.PrinterName, \"prehook\")
E [18/Jun/2018:21:25:15 +0200] [Job 37] Tea4CUPS (PID 19895) :   File \"/usr/
lib/cups/backend/tea4cups\", line 1010, in enumBranches
E [18/Jun/2018:21:25:15 +0200] [Job 37] Tea4CUPS (PID 19895) : raise 
ConfigError, \"Invalid configuration file : %s\" % msg
E [18/Jun/2018:21:25:15 +0200] [Job 37] Tea4CUPS (PID 19895) : ConfigError: 
Invalid configuration file : No section: \'global\'

rd@b370:~$ cat /etc/cups/tea4cups.conf 
[global] 
debug : yes 
directory : /var/spool/cups/ 
prehook_sispmctl : sispmctl -ng 4 2> /tmp/SISPMCTL 
rd@b370:~$ 



> 1. touch /tmp/SISPMCTL

rd@b370:~$ ls -l /tmp/SISPMCTL  
-rw-rw-rw- 1 root root 0 Jun 18 21:29 /tmp/SISPMCTL 
rd@b370:~$ 

> 2. Set up a raw queue:
> 
> lpadmin -p virtq -v tea4cups:// -E -m raw

root@b370:/etc/cups# lpadmin -p virtq -v tea4cups:// -E -m raw 
lpadmin: Raw queues are deprecated and will stop working in a future version 
of CUPS. 
root@b370:/etc/cups#

 
> 3. Print to virtq:
> 
> lp -d virtq /etc/services

root@b370:/etc/cups#  lp -d virtq /etc/services   
Anfrage-ID ist virtq-40 (1 Datei(en)) 
root@b370:/etc/cups#


> 4. cat /tmp/SISPMCTL and look at the error_log.

rd@b370:~$ cat /tmp/SISPMCTL  
rd@b370:~$ 

not sure why this is empty... (?)

but no entry in the error_log

> 5. Test with your original queue and my tea4cups.conf.

same behavior as above, printeron is executed when issuing

lp -d virtq /etc/services 

But when printing on my queue


UUID urn:uuid:2b1f194f-d781-33a6-7340-1b2f4d154ce4
AuthInfoRequired none
Info CP1525NW
MakeModel HP Color LaserJet cp1518ni pcl3, hpcups 3.17.10
DeviceURI tea4cups:/http://hpljwlan:631/ipp/
State Idle
StateTime 1529351306
ConfigTime 1526331301
Reason cups-ipp-conformance-failure-report
Reason cups-ipp-missing-send-document
Type 36892
Accepting Yes
Shared No
JobSheets none none
QuotaPeriod 0
PageLimit 0
KLimit 0
OpPolicy default
ErrorPolicy retry-job
Attribute marker-colors \#00,#FF00FF,#00,#00
Attribute marker-levels 44,46,46,48
Attribute marker-low-levels 6,6,6,7
Attribute marker-high-levels 100,100,100,100
Attribute marker-names Cyan Cartridge HP CE321A,Magenta Cartridge HP 
CE323A,Yellow Cartridge HP CE322A,Black Cartridge HP CE320A
Attribute marker-types toner,toner,toner,toner
Attribute marker-change-time 1527675649


I get the same error_log again:

[18/Jun/2018:21:48:26 +0200] [Job 45] Tea4CUPS (PID 20932) : Traceback (most 
recent call last): 
E [18/Jun/2018:21:48:26 +0200] [Job 45] Tea4CUPS (PID 20932) :   File \"/usr/
lib/cups/backend/tea4cups\", line 1502, in  
E [18/Jun/2018:21:48:26 +0200] [Job 45] Tea4CUPS (PID 20932) : 
wrapper.exportAttributes() 
E [18/Jun/2018:21:48:26 +0200] [Job 45] Tea4CUPS (PID 20932) :   File \"/usr/
lib/cups/backend/tea4cups\", line 1214, in exportAttributes 
E [18/Jun/2018:21:48:26 +0200] [Job 45] Tea4CUPS (PID 20932) : 
os.environ[\"TEABILLING\"] = self.JobBilling or \"\" 
E [18/Jun/2018:21:48:26 +0200] [Job 45] Tea4CUPS (PID 20932) :   File \"/usr/
lib/python2.7/os.py\", line 473, in __setitem__ 
E [18/Jun/2018:21:48:26 +0200] [Job 45] Tea4CUPS (PID 20932) : putenv(key, 
item) 
E [18/Jun/2018:21:48:26 +0200] [Job 45] Tea4CUPS (PID 20932) : TypeError: 
putenv() argument 2 must be string, not int

Is my DeviceURI wrong?



For reference, my printeron:

rd@b370:~$ cat /usr/local/bin/printeron
#!/bin/sh

sispmctl -o 3
date > /tmp/printeron

# Wait until printer is active
while ! nc -vzw 1 hpljwlan 80 2> /dev/null; do
sleep 5
done

date >> /tmp/printeron
rd@b370:~$ 



Thanks
Rainer



-- 
Rainer Dorsch
http://bokomoko.de/




Re: Tea4CUPS: TEABILLING reports error

2018-05-30 Thread Rainer Dorsch
On Mittwoch, 30. Mai 2018 16:44:42 CEST Brian Potkin wrote:
> On Wed 30 May 2018 at 12:40:35 +0200, Rainer Dorsch wrote:
> > I have tea4cups configured to power on my printer before printing. In
> > order to do this, I prepended tea4cups:/ to the DeviceURI in
> > printers.conf (if I remove this and power on the
> > printer manually before printing, everything works as expected):
> I suppose this should work ok if done when cupsd is not running. I'd be
> inclined to modify the existing queue or set up a new one. A virtual
> queue would allow testing Tea4CUPS without wrapping the backend.

I do the modification after a systemd stop cups.service

> The printer is being powered on by some type of electronic switch?

Yes, this one: http://energenie.com/item.aspx?id=7415=en

Works well with the sispmctl package.

> > /etc/cups/printers.conf:
> > DeviceURI tea4cups:/http://hpljwlan:631/ipp/
> 
> http:// is a symlink the ipp backend. It's always useful to know what
> model of printer is being used.

I was not aware of that, I need to dig into more detail here in the next days.

The printer is a HP CP1525NW.

> > I configured the printer power on script:
> > 
> > /etc/cups/tea4cups.conf:
> > 
> > 
> > but I get unfortunately an error in /var/log/cups/error_log
> > 
> > 
> > E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : Traceback
> > (most recent call last):
> > 
> > Is seems something goes wrong while setting the TEABILLING environement
> > variable.
> > 
> > Has anybody an idea why that could be?
> 
> tea4cups.conf is the configuration file for Tea4CUPS. I guess you are
> using a prehook or posthook to activate the printer; we really need to
> know what you have for it (including any associated script). What part
> does TEABILLING play in the process?

Yes, a prehook and the TEABILLING shows in the stack trace, I am not using it 
intentionally at all...

Aaah...now I see what went wrong: My orignal post contained the information, 
but it seems only in the HTML view, not sure why kmail decided to leave out 
this information in the text representation  :-/ Avoided HTML view now in this 
mail, sorry for that.


For easier reference I append the previous post:

I have tea4cups configured to power on my printer before printing. In order to 
do this, I prepended tea4cups:/ to the DeviceURI in printers.conf (if I remove 
this and power on the printer manually before printing, everything works as 
expected):
 
/etc/cups/printers.conf:
DeviceURI tea4cups:/http://hpljwlan:631/ipp/
I configured the printer power on script:
 
/etc/cups/tea4cups.conf:
prehook_sispmctl : /usr/local/bin/printeron
 
but I get unfortunately an error in /var/log/cups/error_log
with every print job and the job is stopped.
 
E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : Traceback (most 
recent call last): 
E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) :   File \"/usr/
lib/cups/backend/tea4cups\", line 1502, in  
E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : 
wrapper.exportAttributes() 
E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) :   File \"/usr/
lib/cups/backend/tea4cups\", line 1214, in exportAttributes 
E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : 
os.environ[\"TEABILLING\"] = self.JobBilling or \"\" 
E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) :   File \"/usr/
lib/python2.7/os.py\", line 473, in __setitem__ 
E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : putenv(key, 
item) 
E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : TypeError: 
putenv() argument 2 must be string, not int

Is seems something goes wrong while setting the TEABILLING environment 
variable. 

Many thank
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Tea4CUPS: TEABILLING reports error

2018-05-30 Thread Rainer Dorsch
Hi,

I have tea4cups configured to power on my printer before printing. In order to 
do this, I 
prepended tea4cups:/ to the DeviceURI in printers.conf (if I remove this and 
power on the 
printer manually before printing, everything works as expected):

/etc/cups/printers.conf:
DeviceURI tea4cups:/http://hpljwlan:631/ipp/

I configured the printer power on script:

/etc/cups/tea4cups.conf:


but I get unfortunately an error in /var/log/cups/error_log


E [30/May/2018:08:51:40 +0200] [Job 16] Tea4CUPS (PID 9689) : Traceback (most 
recent call 
last): 

Is seems something goes wrong while setting the TEABILLING environement 
variable. 

Has anybody an idea why that could be?

Many thanks
Rainer


-- 
Rainer Dorsch
http://bokomoko.de/


Re: adb broken in buster?

2018-05-25 Thread Rainer Dorsch
On Freitag, 25. Mai 2018 02:53:06 CEST Siard wrote:
> Rainer Dorsch wrote:
> > on a buster system, I have trouble with adb and my Nexus 5X:
> > 
> > rd@b370:~$ adb shell
> > error: insufficient permissions for device: verify udev rules.
> >
> >From the description of adb:
> "This package recommends "android-sdk-platform-tools-common" which
> contains the udev rules for Android devices. Without this package, adb
> and fastboot need to be running with root permission."
> 
> Is this package installed?

Many thanks for your response.

Good point, I did not spot this. The place I was looking for documentation was 
/usr/share/doc/android-tools-adb but I did not find there a Readme.Debian or 
similar...

I checked dpkg.log, it seems that android-sdk-platform-tools-common got 
installed with adb.

2018-05-24 23:22:46 status installed android-tools-fsutils:amd64 5.1.1.r38-1.1
2018-05-24 23:22:46 status installed android-libunwind:amd64 7.0.0+r1-4
2018-05-24 23:22:46 status installed android-liblog:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed libf2fs0:amd64 1.10.0-1
2018-05-24 23:22:46 status installed android-libsparse:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed libc-bin:amd64 2.27-3
2018-05-24 23:22:46 status installed android-libf2fs-utils:amd64 7.0.0+r33-1
2018-05-24 23:22:46 status installed man-db:amd64 2.8.3-2
2018-05-24 23:22:46 status installed android-sdk-platform-tools-common:all 
24.0.0+8
2018-05-24 23:22:46 status installed android-libselinux:amd64 7.0.0+r1-2
2018-05-24 23:22:46 status installed android-libbase:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed android-libcutils:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed android-libbacktrace:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed android-libext4-utils:amd64 7.0.0+r33-1
2018-05-24 23:22:46 status installed android-libadb:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed android-libutils:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed adb:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed android-tools-adb:all 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed android-libziparchive:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed fastboot:amd64 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed android-tools-fastboot:all 1:7.0.0+r33-2
2018-05-24 23:22:46 status installed libc-bin:amd64 2.27-3

See my previous mail, now adb works for me, not sure what changed though.

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: adb broken in buster?

2018-05-25 Thread Rainer Dorsch
On Freitag, 25. Mai 2018 00:56:17 CEST Ben Caradoc-Davies wrote:
> On 25/05/18 09:36, Rainer Dorsch wrote:
> > Hello,
> > on a buster system, I have trouble with adb and my Nexus 5X:
> > rd@b370:~$ adb shell
> > error: insufficient permissions for device: verify udev rules.
> > See [http://developer.android.com/tools/device.html] for more information.
> > rd@b370:~$
> > On the referenced website, I understand that I need to be in group plugdev
> > (this is the case).
> > rd@b370:~$ groups
> > rd adm dialout fax cdrom floppy sudo dip video plugdev users lpadmin
> > scanner sispmctl
> > rd@b370:~$
> > is that a known issue? If yes, any hint is welcome ...
> > Thanks
> > Rainer
> 
> adb works with my Nexus 5X on sid over USB:
> 
> $ adb devices -l
> List of devices attached
> [serial]   device usb:1-9 product:bullhead model:Nexus_5X
> device:bullhead
> $ adb shell
> shell@bullhead:/ $
> 
> - Are you connecting over USB?
> 
> - What is the output of "adb devices -l"?
> 
> - Were you in group plugdev at the time the adb server was started? If
> not, please run "adb kill-server" and try again.
> 

Many thanks for your response.

Not sure what went wrong, now it magically works, I still have the non-working 
and the working situation on the same screen:

rd@b370:~$ adb shell
error: insufficient permissions for device: verify udev rules.
See [http://developer.android.com/tools/device.html] for more information.
rd@b370:~$ groups
rd adm dialout fax cdrom floppy sudo dip video plugdev users lpadmin scanner 
sispmctl
rd@b370:~$ apt-cache policy adb
adb:
  Installiert:   1:7.0.0+r33-2
  Installationskandidat: 1:7.0.0+r33-2
  Versionstabelle:
 *** 1:7.0.0+r33-2 500
500 http://ftp-stud.hs-esslingen.de/debian buster/main amd64 Packages
 80 http://ftp.de.debian.org/debian sid/main amd64 Packages
100 /var/lib/dpkg/status
rd@b370:~$ apt-cache show adb  
Package: adb
Source: android-platform-system-core
Version: 1:7.0.0+r33-2
Installed-Size: 189
Maintainer: Android Tools Maintainers 
Architecture: amd64
Replaces: android-tools-adb (<< 6.0~)
Provides: android-tools-adb
Depends: android-libadb (= 1:7.0.0+r33-2), android-libbase, android-libcutils, 
libc6 (>= 2.14), libgcc1 (>= 1:3.0), libstdc++6 (>= 5.2)
Recommends: android-sdk-platform-tools-common
Breaks: android-tools-adb (<< 6.0~)
Description-en: Android Debug Bridge
 A versatile command line tool that lets you communicate with an emulator
 instance or connected Android-powered device.
 .
 This package recommends "android-sdk-platform-tools-common" which contains
 the udev rules for Android devices. Without this package, adb and fastboot 
need
 to be running with root permission.
Description-md5: 4fb58b8688addfd94d32fe9a20c9d2e8
Homepage: https://android.googlesource.com/platform/system/core
Section: devel
Priority: optional
Filename: pool/main/a/android-platform-system-core/adb_7.0.0+r33-2_amd64.deb
Size: 71340
MD5sum: 12c5320af6b4cf797e28851885255aee
SHA256: 59dac73a48922b814baa04e18dd3277e7d060dfcd756d8c630fdecfe1cfa45ad

rd@b370:~$  adb devices -l
List of devices attached
00ab0c0c82c498a8   device usb:1-3.4 product:bullhead model:Nexus_5X 
device:bullhead

rd@b370:~$ adb shell
bullhead:/ $ ^D
rd@b370:~$ 

The system did a suspend/resume cycle in between, but I can hardly imagine 
that this made the difference...

Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




adb broken in buster?

2018-05-24 Thread Rainer Dorsch
Hello,

on a buster system, I have trouble with adb and my Nexus 5X:

rd@b370:~$ adb shell
error: insufficient permissions for device: verify udev rules.
See [http://developer.android.com/tools/device.html] for more information.
rd@b370:~$ 

On the referenced website, I understand that I need to be in group plugdev 
(this is the case).

rd@b370:~$ groups
rd adm dialout fax cdrom floppy sudo dip video plugdev users lpadmin scanner 
sispmctl
rd@b370:~$ 

is that a known issue? If yes, any hint is welcome ...

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/




Re: apt-get: Error: Timeout was reached

2018-04-21 Thread Rainer Dorsch
Hi Tomás,

many thanks for your response :-)

Am Samstag, 21. April 2018, 08:43:20 CEST schrieb to...@tuxteam.de:
> On Fri, Apr 20, 2018 at 10:20:12PM +0200, Rainer Dorsch wrote:
> > Am Freitag, 20. April 2018, 22:13:11 CEST schrieb to...@tuxteam.de:
> > > curl -I http://security.debian.org/debian-security/
> > 
> > root@master:~/tmp# curl -I http://ftp.de.debian.org/debian/
> > HTTP/1.1 200 OK
> > Date: Fri, 20 Apr 2018 20:19:14 GMT
> > Server: Apache/2.4.10 (Debian)
> > Content-Type: text/html;charset=UTF-8
> > 
> > root@master:~/tmp# curl -I http://security.debian.org/debian-security/
> > HTTP/1.1 200 OK
> 
> [...]
> 
> Yeah, that succeeded *once*, but you suggested that your problem
> is intermittent.
> 
> Either your network connection is sometimes down (you might see
> traces of that in your system log) or security.debian.org is
> sometimes down (somewhat less probable, since more folks would
> complain), or "something" in the path between you two is sometimes
> down.
> 
> To catch this "sometimes" you'll have to invest a bit more of
> work.
> 
> I'd start by looking into syslog, around the times your upgrade
> complains. Next, you might want to watch connectivity -- there sure
> are nice programs out there, with graphing and things, but just
> pinging your upstream router every minute might give you a rough
> impression, like so:
> 
>   ping -i 60  > /tmp/connect.log 2>&1 &
> 
> and have look at the result after a day or so.
> 
> If you're on WiFi, check for bad signal quality or too many nearby
> routers (or other sources of noise). If it's Ethernet, flakey cables
> or connectors are known for doing nasty things. And so on.
> 
> It's a bit like hunting :-)

I am on ethernet and all other debian machines in the subnet are doing 
excellent. syslog was an excellent idea, indeed there are many suspicious 
entries:

Apr 21 10:35:13 master kernel: [3019173.333566] IPv6: ipv6_create_tempaddr: 
retry temporary address regeneration
Apr 21 10:36:01 master kernel: [3019221.240105] IPv6: ipv6_create_tempaddr: 
retry temporary address regeneration
Apr 21 10:36:11 master kernel: [3019231.951162] IPv6: ipv6_create_tempaddr: 
retry temporary address regeneration
Apr 21 10:36:35 master kernel: [3019256.044369] IPv6: ipv6_create_tempaddr: 
retry temporary address regeneration
Apr 21 10:37:10 master kernel: [3019290.823572] IPv6: ipv6_create_tempaddr: 
retry temporary address regeneration
Apr 21 10:37:10 master kernel: [3019290.823932] IPv6: ipv6_create_tempaddr: 
retry temporary address regeneration
Apr 21 10:37:10 master kernel: [3019290.824625] IPv6: ipv6_create_tempaddr: 
retry temporary address regeneration
Apr 21 10:37:13 master kernel: [3019293.735943] IPv6: ipv6_create_tempaddr: 
retry temporary address regeneration
Apr 21 10:37:53 master kernel: [3019333.828612] IPv6: ipv6_create_tempaddr: 
retry temporary address regeneration

Also the output of 

root@master:~# ip addr show|wc -l
63614
root@master:~# 

and

root@master:~# ip addr show|head -40
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group 
default qlen 1
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
   valid_lft forever preferred_lft forever
inet6 ::1/128 scope host 
   valid_lft forever preferred_lft forever
2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP 
group default qlen 1000
link/ether 18:66:da:20:6f:2d brd ff:ff:ff:ff:ff:ff
inet 192.168.0.2/24 brd 192.168.0.255 scope global dynamic eno1
   valid_lft 853609sec preferred_lft 853609sec
inet6 fd38:81d3:9dac:0:f0ef:7ae3:c2bf:3bd8/64 scope global temporary 
dynamic 
   valid_lft 604795sec preferred_lft 86240sec
inet6 fd38:81d3:9dac:0:80cd:9129:26ce:bee5/64 scope global temporary 
dynamic 
   valid_lft 604794sec preferred_lft 86239sec
inet6 fd38:81d3:9dac:0:402a:7f5d:c391:9d23/64 scope global temporary 
dynamic 
   valid_lft 604793sec preferred_lft 86238sec
inet6 fd38:81d3:9dac:0:a457:e576:bdd9:84f5/64 scope global temporary 
dynamic 
   valid_lft 604786sec preferred_lft 86231sec
inet6 fd38:81d3:9dac:0:f928:5018:1834:fbc6/64 scope global temporary 
dynamic 
   valid_lft 604783sec preferred_lft 86228sec
inet6 fd38:81d3:9dac:0:8ce6:e31c:4745:e335/64 scope global temporary 
dynamic 
   valid_lft 604783sec preferred_lft 86228sec
inet6 fd38:81d3:9dac:0:818c:c093:8084:fcad/64 scope global temporary 
dynamic 
   valid_lft 604774sec preferred_lft 86219sec
inet6 fd38:81d3:9dac:0:1c74:e734:3319:2ae3/64 scope global temporary 
dynamic 
   valid_lft 604749sec preferred_lft 86194sec
inet6 fd38:81d3:9dac:0:15de:1534:8301:d55d/64 scope global temporary 
dynamic 
   valid_lft 604728sec preferred_lft 86173sec
in

Re: apt-get: Error: Timeout was reached

2018-04-20 Thread Rainer Dorsch
Hi,

I just realized sometimes it also shows in apt-get upgrade:

[...]
Setting up libreoffice-writer (1:5.2.7-1+deb9u4) ...
Setting up libreoffice-base (1:5.2.7-1+deb9u4) ...
Setting up libreoffice-report-builder-bin (1:5.2.7-1+deb9u4) ...
Setting up libreoffice-report-builder (1:5.2.7-1+deb9u4) ...
Setting up libreoffice-help-en-us (1:5.2.7-1+deb9u4) ...
Processing triggers for libc-bin (2.24-11+deb9u3) ...
Error: Timeout was reached
root@master:~#

Am Freitag, 20. April 2018, 22:41:34 CEST schrieb Michael Lange:
> Hi,
> 
> On Fri, 20 Apr 2018 22:20:12 +0200
> 
> Rainer Dorsch <m...@bokomoko.de> wrote:
> > root@master:~# cat /etc/apt/sources.list
> 
> (...)
> 
> > deb http://security.debian.org/debian-security stretch/updates main
> > contrib non-free
> > deb-src http://security.debian.org/debian-security stretch/updates main
> > contrib non-free
> 
> here the entry in sources.list looks slightly different:
> 
> deb http://security.debian.org/ stretch/updates main contrib non-free
> 
> I wouldn't think this makes much difference, but just in case the timeout
> occurs always with the security mirror it might be worth a try.
> 
> > root@master:~/tmp# curl -I http://security.debian.org/debian-security/
> > HTTP/1.1 200 OK
> > Date: Fri, 20 Apr 2018 20:19:23 GMT
> > Server: Apache
> > X-Content-Type-Options: nosniff
> > X-Frame-Options: sameorigin
> > Referrer-Policy: no-referrer
> > X-Xss-Protection: 1
> > Cache-Control: max-age=120
> > Expires: Fri, 20 Apr 2018 20:21:23 GMT
> > X-Clacks-Overhead: GNU Terry Pratchett
> > Content-Type: text/html;charset=UTF-8
> 
> This looks also sightly different here:
> 
> $ curl -I http://security.debian.org/
> HTTP/1.1 302 Found
> Date: Fri, 20 Apr 2018 20:31:36 GMT
> Server: Apache
> X-Content-Type-Options: nosniff
> X-Frame-Options: sameorigin
> Referrer-Policy: no-referrer
> X-Xss-Protection: 1
> Location: https://www.debian.org/security/
> Cache-Control: max-age=120
> Expires: Fri, 20 Apr 2018 20:33:36 GMT
> Content-Type: text/html; charset=iso-8859-1
> 
> At first I thought that one of http://security.debian.org/ and
> http://security.debian.org/debian-security/ was just a symlink to the
> other on the same machine, but maybe the above might indicate that those
> mirrors are actually not identical?
> 
> Just a thought, though.
> 
> Regards
> 
> Michael
> 
> .-.. .. ...- .   .-.. --- -. --.   .- -. -..   .--. .-. --- ... .--. . .-.
> 
> Youth doesn't excuse everything.
>   -- Dr. Janice Lester (in Kirk's body), "Turnabout
>Intruder", stardate 5928.5.


-- 
Rainer Dorsch
http://bokomoko.de/



Re: apt-get: Error: Timeout was reached

2018-04-20 Thread Rainer Dorsch
Am Freitag, 20. April 2018, 22:13:11 CEST schrieb to...@tuxteam.de:
> curl -I http://security.debian.org/debian-security/

root@master:~/tmp# curl -I http://ftp.de.debian.org/debian/
HTTP/1.1 200 OK
Date: Fri, 20 Apr 2018 20:19:14 GMT
Server: Apache/2.4.10 (Debian)
Content-Type: text/html;charset=UTF-8

root@master:~/tmp# curl -I http://security.debian.org/debian-security/
HTTP/1.1 200 OK
Date: Fri, 20 Apr 2018 20:19:23 GMT
Server: Apache
X-Content-Type-Options: nosniff
X-Frame-Options: sameorigin
Referrer-Policy: no-referrer
X-Xss-Protection: 1
Cache-Control: max-age=120
Expires: Fri, 20 Apr 2018 20:21:23 GMT
X-Clacks-Overhead: GNU Terry Pratchett
Content-Type: text/html;charset=UTF-8

root@master:~/tmp# 


-- 
Rainer Dorsch
http://bokomoko.de/



apt-get: Error: Timeout was reached

2018-04-20 Thread Rainer Dorsch
Hi,

I see often the error:
Error: Timeout was reached  
during an apt-get update.

Any idea what could cause this and how to debug it?

The entire configuration is shown below.

root@master:~# apt-get -v
apt 1.4.8 (amd64)
Supported modules:
*Ver: Standard .deb
*Pkg:  Debian dpkg interface (Priority 30)
 Pkg:  Debian APT solver interface (Priority -1000)
 Pkg:  Debian APT planner interface (Priority -1000)
 S.L: 'deb' Debian binary tree
 S.L: 'deb-src' Debian source tree
 Idx: Debian Source Index
 Idx: Debian Package Index
 Idx: Debian Translation Index
 Idx: Debian dpkg status file
 Idx: Debian deb file
 Idx: Debian dsc file
 Idx: Debian control file
 Idx: EDSP scenario file
 Idx: EIPP scenario file
root@master:~# apt-get update
Ign:1 http://ftp.de.debian.org/debian stretch InRelease
Hit:2 http://ftp.de.debian.org/debian stretch Release  
Hit:4 http://security.debian.org/debian-security stretch/updates InRelease
Error: Timeout was reached   
Reading package lists... Done
root@master:~# cat /etc/apt/sources.list
# 

# deb cdrom:[Debian GNU/Linux 9.3.0 _Stretch_ - Official amd64 NETINST 
20171209-12:10]/ stretch main

#deb cdrom:[Debian GNU/Linux 9.3.0 _Stretch_ - Official amd64 NETINST 
20171209-12:10]/ stretch main

deb http://ftp.de.debian.org/debian/ stretch main contrib non-free
deb-src http://ftp.de.debian.org/debian/ stretch main contrib non-free

deb http://security.debian.org/debian-security stretch/updates main contrib 
non-free
deb-src http://security.debian.org/debian-security stretch/updates main 
contrib non-free

# stretch-updates, previously known as 'volatile'
#deb http://ftp.de.debian.org/debian/ stretch-updates main contrib non-free
#deb-src http://ftp.de.debian.org/debian/ stretch-updates main contrib non-
free
root@master:~# ls -l /etc/apt/sources.list.d/
total 0
root@master:~#

Many thanks
Rainer
-- 
Rainer Dorsch
http://bokomoko.de/



Re: Starting powertop --auto-tune from systemd

2018-03-11 Thread Rainer Dorsch
Am Samstag, 10. März 2018, 15:16:29 CET schrieb bw:
> On Sat, 10 Mar 2018, Rainer Dorsch wrote:
> > I followed
> > 
> > https://wiki.archlinux.org/index.php/Powertop#Apply_settings
> > 
> > added
> > 
> > root@master:~# cat /etc/systemd/system/powertop.service
> > [Unit]
> > Description=Powertop tunings
> > 
> > [Service]
> > ExecStart=/usr/bin/powertop --auto-tune
> 
> Yes, the arch wiki often has different paths for tools.  I have been
> bitten by that several times.
> 
> # which powertop
> /usr/sbin/powertop

Many thanks, that indeed solves the problem.

Rainer

-- 
Rainer Dorsch
http://bokomoko.de/



Re: Deleted two partitions, system does not boot anymore

2018-03-11 Thread Rainer Dorsch
Am Sonntag, 11. März 2018, 15:38:37 CET schrieb Rainer Dorsch:
> Hi,
> 
> I deleted two partitions (or better their content)
> 
> dd if=/dev/urandom of=/dev/sdXn
> 
> in order to set them up encrypted (see http://www.andreas-janssen.de/
> cryptodisk.html, sorry for the German)
> 
> I commented both in /etc/fstab (after the first reboot failed).
> 
> Both partitions did not contain any relevant data, I am not aware that they
> have been used in the system beyond the fstab.
> 
> After rebooting the system decided not to boot anymore (hangs right at the
> beginning). The system comes up in the recovery mode and I can even login
> remotely using
> 
> systemctl start network-manager
> systemctl. start ssh
> systemctl default
> 
> >From what I can see in grub.cfg, the only difference for the recovery mode
> >is
> that the boot process stops in single user mode.
> 
> Is there a good way to start unit by unit to get from single user mode to
> normal (multiuser?) mode and check which part is failing?
> 
> Any input is welcome.
> 

Solved: my rc.local script was the causing the issue.

Sorry for the noise.

Rainer


-- 
Rainer Dorsch
http://bokomoko.de/



Deleted two partitions, system does not boot anymore

2018-03-11 Thread Rainer Dorsch
Hi,

I deleted two partitions (or better their content)

dd if=/dev/urandom of=/dev/sdXn

in order to set them up encrypted (see http://www.andreas-janssen.de/
cryptodisk.html, sorry for the German)

I commented both in /etc/fstab (after the first reboot failed).

Both partitions did not contain any relevant data, I am not aware that they 
have been used in the system beyond the fstab.

After rebooting the system decided not to boot anymore (hangs right at the 
beginning). The system comes up in the recovery mode and I can even login 
remotely using 

systemctl start network-manager
systemctl. start ssh
systemctl default

>From what I can see in grub.cfg, the only difference for the recovery mode is 
that the boot process stops in single user mode.

Is there a good way to start unit by unit to get from single user mode to 
normal (multiuser?) mode and check which part is failing?

Any input is welcome.

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/



Starting powertop --auto-tune from systemd

2018-03-10 Thread Rainer Dorsch
[Please follow-up to debian-user]

Hello,

I run

/usr/bin/powertop --auto-tune

to optimize the power consumption of my system. Running it manually works 
nicely. When I try to run from systemd, I see no effect :-/

I followed

https://wiki.archlinux.org/index.php/Powertop#Apply_settings

added

root@master:~# cat /etc/systemd/system/powertop.service 
[Unit]
Description=Powertop tunings

[Service]
ExecStart=/usr/bin/powertop --auto-tune
RemainAfterExit=true

[Install]
WantedBy=multi-user.target
root@master:~# 

enabled it for systemd and got

root@master:~# systemctl status powertop.service 
● powertop.service - Powertop tunings
   Loaded: loaded (/etc/systemd/system/powertop.service; enabled; vendor 
preset: enabled)
   Active: active (exited) (Result: exit-code) since Sat 2018-03-10 18:29:53 
CET; 22min ago
  Process: 642 ExecStart=/usr/bin/powertop --auto-tune (code=exited, 
status=203/EXEC)
 Main PID: 642 (code=exited, status=203/EXEC)
Tasks: 0 (limit: 4915)
   CGroup: /system.slice/powertop.service

Mar 10 18:29:53 master systemd[1]: Started Powertop tunings.
Mar 10 18:29:53 master systemd[1]: powertop.service: Main process exited, 
code=exited, status=203/EXEC
root@master:~# 

powertop still report that the parameters are "Bad". Runnung

# powertop --auto-tune

makes them all good (and reduces the power consumption).

Any idea is welcome :-)

Thanks
Rainer

-- 
Rainer Dorsch
http://bokomoko.de/



  1   2   3   >