Re: [systemd-devel] udev remove event no longer contains ID_VENDOR_ID/ID_MODEL_ID

2023-08-22 Thread Matt Turner
On Thu, Aug 17, 2023 at 11:09 AM Matt Turner wrote: > > Hello, > > I'm working on updating ChromeOS's ancient udev-225 + 24 patches to > udev-249.9. > > In the course of testing, we discovered that udev remove events no > longer contain ID_VENDOR_ID or ID_MODEL_ID. Apparently this change >

Re: [systemd-devel] udev rule, continue to next rule only if preb failed

2023-05-26 Thread daggs
Greetings, > Sent: Friday, May 26, 2023 at 12:02 PM > From: "daggs" > To: "Lennart Poettering" > Cc: systemd-devel@lists.freedesktop.org > Subject: Re: [systemd-devel] udev rule, continue to next rule only if preb > failed > > Greetings Lennart,

Re: [systemd-devel] udev rule, continue to next rule only if preb failed

2023-05-26 Thread daggs
Greetings Lennart, > Sent: Friday, May 26, 2023 at 11:23 AM > From: "Lennart Poettering" > To: "daggs" > Cc: systemd-devel@lists.freedesktop.org > Subject: Re: [systemd-devel] udev rule, continue to next rule only if preb > failed > > On Do,

Re: [systemd-devel] udev rule, continue to next rule only if preb failed

2023-05-26 Thread Lennart Poettering
On Do, 25.05.23 20:25, daggs (da...@gmx.com) wrote: > Greetings, > > I'm trying to implement the following behavior: > if a usb is added ot removed, run a script before all other existing rules > but continue to existing iff the script failed > I've added the following rule to

Re: [systemd-devel] udev and btrfs multiple devices

2021-02-04 Thread Chris Murphy
On Thu, Feb 4, 2021 at 6:28 AM Lennart Poettering wrote: > > On Mi, 03.02.21 22:32, Chris Murphy (li...@colorremedies.com) wrote: > > It doesn't. It waits indefinitely. > > > > [* ] A start job is running for > > /dev/disk/by-uuid/cf9c9518-45d4-43d6-8a0a-294994c383fa (12min 36s / no > >

Re: [systemd-devel] udev and btrfs multiple devices

2021-02-04 Thread Lennart Poettering
On Mi, 03.02.21 22:32, Chris Murphy (li...@colorremedies.com) wrote: > On Thu, Jan 28, 2021 at 7:18 AM Lennart Poettering > wrote: > > > > On Mi, 27.01.21 17:19, Chris Murphy (li...@colorremedies.com) wrote: > > > > > Is it possible for a udev rule to have a timeout? For example: > > >

Re: [systemd-devel] udev and btrfs multiple devices

2021-02-03 Thread Chris Murphy
On Wed, Feb 3, 2021 at 10:32 PM Chris Murphy wrote: > > On Thu, Jan 28, 2021 at 7:18 AM Lennart Poettering > wrote: > > > > On Mi, 27.01.21 17:19, Chris Murphy (li...@colorremedies.com) wrote: > > > > > Is it possible for a udev rule to have a timeout? For example: > > >

Re: [systemd-devel] udev and btrfs multiple devices

2021-02-03 Thread Chris Murphy
On Thu, Jan 28, 2021 at 7:18 AM Lennart Poettering wrote: > > On Mi, 27.01.21 17:19, Chris Murphy (li...@colorremedies.com) wrote: > > > Is it possible for a udev rule to have a timeout? For example: > > /usr/lib/udev/rules.d/64-btrfs.rules > > > > This udev rule will wait indefinitely for a

Re: [systemd-devel] udev blkid check on mmcblk0boot0 and boot1

2021-02-02 Thread Alan Perry
On 2/2/21 2:13 PM, Jeremy Linton wrote: Hi, On 2/2/21 1:46 PM, Alan Perry wrote: On 2/2/21 1:55 AM, Lennart Poettering wrote: On Mo, 01.02.21 16:36, Alan Perry (al...@snowmoose.com) wrote: Hi, Per the udev rules, the blkid builtin is run on mmcblk*boot* devices to look for partition and

Re: [systemd-devel] udev blkid check on mmcblk0boot0 and boot1

2021-02-02 Thread Jeremy Linton
Hi, On 2/2/21 1:46 PM, Alan Perry wrote: On 2/2/21 1:55 AM, Lennart Poettering wrote: On Mo, 01.02.21 16:36, Alan Perry (al...@snowmoose.com) wrote: Hi, Per the udev rules, the blkid builtin is run on mmcblk*boot* devices to look for partition and filesystem. Those devices contain

Re: [systemd-devel] udev blkid check on mmcblk0boot0 and boot1

2021-02-02 Thread Lennart Poettering
On Di, 02.02.21 11:46, Alan Perry (al...@snowmoose.com) wrote: > > On 2/2/21 1:55 AM, Lennart Poettering wrote: > > On Mo, 01.02.21 16:36, Alan Perry (al...@snowmoose.com) wrote: > > > Hi, Per the udev rules, the blkid builtin is run on mmcblk*boot* > > > devices to look for partition and

Re: [systemd-devel] udev blkid check on mmcblk0boot0 and boot1

2021-02-02 Thread Alan Perry
On 2/2/21 1:55 AM, Lennart Poettering wrote: On Mo, 01.02.21 16:36, Alan Perry (al...@snowmoose.com) wrote: Hi, Per the udev rules, the blkid builtin is run on mmcblk*boot* devices to look for partition and filesystem. Those devices contain hardware-specific boot information and are unlikely

Re: [systemd-devel] udev blkid check on mmcblk0boot0 and boot1

2021-02-02 Thread Lennart Poettering
On Mo, 01.02.21 16:36, Alan Perry (al...@snowmoose.com) wrote: > > Hi, > > Per the udev rules, the blkid builtin is run on mmcblk*boot* devices to look > for partition and filesystem. Those devices contain hardware-specific boot > information and are unlikely to have anything on them that blkid

Re: [systemd-devel] udev and btrfs multiple devices

2021-01-28 Thread Lennart Poettering
On Mi, 27.01.21 17:19, Chris Murphy (li...@colorremedies.com) wrote: > Is it possible for a udev rule to have a timeout? For example: > /usr/lib/udev/rules.d/64-btrfs.rules > > This udev rule will wait indefinitely for a missing device to > appear. Hmm, no, that's a mis understaning. "rules"

Re: [systemd-devel] udev and btrfs multiple devices

2021-01-28 Thread Greg KH
On Thu, Jan 28, 2021 at 01:32:03AM -0700, Chris Murphy wrote: > On Thu, Jan 28, 2021 at 1:03 AM Greg KH wrote: > > > > On Wed, Jan 27, 2021 at 05:19:38PM -0700, Chris Murphy wrote: > > > > > > Next, is it possible to enhance udev so that it can report the number > > > of devices expected for a

Re: [systemd-devel] udev and btrfs multiple devices

2021-01-28 Thread Chris Murphy
On Thu, Jan 28, 2021 at 1:03 AM Greg KH wrote: > > On Wed, Jan 27, 2021 at 05:19:38PM -0700, Chris Murphy wrote: > > > > Next, is it possible to enhance udev so that it can report the number > > of devices expected for a Btrfs file system? This information is > > currently in the Btrfs superblock

Re: [systemd-devel] udev and btrfs multiple devices

2021-01-28 Thread Greg KH
On Wed, Jan 27, 2021 at 05:19:38PM -0700, Chris Murphy wrote: > > Next, is it possible to enhance udev so that it can report the number > of devices expected for a Btrfs file system? This information is > currently in the Btrfs superblock found on each device in the > num_devices field. >

Re: [systemd-devel] Udev rules for interfaces

2020-12-25 Thread Greg KH
On Fri, Dec 25, 2020 at 11:01:47AM +0200, Adi Ml wrote: > Hi, > > I am trying to generate rules in udev to block mass storage. It seems like > it only checks the device itself (its class is 00), but not its interface > classes (one of those is 08, a mass storage). It seems like there is only >

Re: [systemd-devel] Udev rules on reboot

2020-12-20 Thread Mantas Mikulėnas
On Sun, Dec 20, 2020, 21:37 Adi Ml wrote: > Yes. Thats exactly what I mean (what mantas said)- ATTR{authorized}="0". > I would like to have a usb whitelist via udev and want it to be enforced on > devices which connected pre boot too. > > authorized_default=0- it seems the same like >

Re: [systemd-devel] Udev rules on reboot

2020-12-20 Thread Adi Ml
Yes. Thats exactly what I mean (what mantas said)- ATTR{authorized}="0". I would like to have a usb whitelist via udev and want it to be enforced on devices which connected pre boot too. authorized_default=0- it seems the same like ATTR{authorized}="0", isnt it? בתאריך יום א׳, 20 בדצמ׳ 2020,

Re: [systemd-devel] Udev rules on reboot

2020-12-20 Thread Mantas Mikulėnas
On Sun, Dec 20, 2020 at 3:49 PM Lennart Poettering wrote: > On Sa, 19.12.20 15:37, Adi Ml (maladi1...@gmail.com) wrote: > > > I see. so if I have a rule against a certain usb in udev, it should be > > blocked automatically during the boot. > > Hmm, "blocked"? What do you mean by that? I am not

Re: [systemd-devel] Udev rules on reboot

2020-12-20 Thread Lennart Poettering
On Sa, 19.12.20 15:37, Adi Ml (maladi1...@gmail.com) wrote: > I see. so if I have a rule against a certain usb in udev, it should be > blocked automatically during the boot. Hmm, "blocked"? What do you mean by that? I am not following... > > בתאריך שבת, 19 בדצמ׳ 2020, 15:31, מאת Lennart

Re: [systemd-devel] Udev rules on reboot

2020-12-19 Thread Adi Ml
I see. so if I have a rule against a certain usb in udev, it should be blocked automatically during the boot. בתאריך שבת, 19 בדצמ׳ 2020, 15:31, מאת Lennart Poettering ‏< lenn...@poettering.net>: > On Sa, 19.12.20 15:26, Adi Ml (maladi1...@gmail.com) wrote: > > > Hi, > > > > Is there a way to

Re: [systemd-devel] Udev rules on reboot

2020-12-19 Thread Lennart Poettering
On Sa, 19.12.20 15:26, Adi Ml (maladi1...@gmail.com) wrote: > Hi, > > Is there a way to enforce udev rules on all connected devices (which were > connected pre-boot) after a reboot? > I have tried udevadm trigger and seems like its not working udevadm trigger is invoked atuomatically at boot,

Re: [systemd-devel] udev ATTR can have double dots and help writing a rule

2020-12-19 Thread Lennart Poettering
On Di, 01.12.20 02:17, Konomi (konomikit...@gmail.com) wrote: > So this is the eventual rule I ended up writing after having a lot of > trouble writing a udev rule: > > `ACTION=="add", SUBSYSTEM=="ata_port", KERNEL=="ata[0-9]", > TEST=="../../power/control" ATTR{../../power/control}="auto"` > >

Re: [systemd-devel] Udev hardening

2020-12-16 Thread Lennart Poettering
On Mo, 14.12.20 14:54, Adi Ml (maladi1...@gmail.com) wrote: > Hi, > > I would like to harden my udev service with the > SystemCallFilter option. What systemcalls should be permitted/allowed in > order to secure it and avoid irrelevant system calls? We apply system call filters to all long

Re: [systemd-devel] Udev hardening

2020-12-14 Thread Greg KH
On Mon, Dec 14, 2020 at 06:18:24PM +0200, Adi Ml wrote: > I guess that udev can block devices from userspace only, so from there. > > Of course, you are right-whitelist is better. > > As for usbguard, I thought about using seccomp and filterring system calls > in my udev service based on their

Re: [systemd-devel] Udev hardening

2020-12-14 Thread Adi Ml
I guess that udev can block devices from userspace only, so from there. Of course, you are right-whitelist is better. As for usbguard, I thought about using seccomp and filterring system calls in my udev service based on their code - I have seen that they list a group of system calls and

Re: [systemd-devel] Udev hardening

2020-12-14 Thread Greg KH
On Mon, Dec 14, 2020 at 05:31:17PM +0200, Adi Ml wrote: > I am using udev in order to create a kiosk mode. I want to block devices > which fit a certain vid pid. Block devices from where? The kernel or userspace? udev runs _after_ the kernel has seen the device and bound to it. And usb

Re: [systemd-devel] Udev hardening

2020-12-14 Thread Adi Ml
I am using udev in order to create a kiosk mode. I want to block devices which fit a certain vid pid. I want to filter system calls anyway because I dont know which devices are entered and I want to avoid devices which will do unusual things like rubber ducky. What do you mean by filtering system

Re: [systemd-devel] Udev hardening

2020-12-14 Thread Greg KH
On Mon, Dec 14, 2020 at 04:30:58PM +0200, Adi Ml wrote: > Hi, > Is there some way to detect which system calls, I am using in udev (in > order to filter it)? I don't understand, if you don't know what system calls you are needing, why do you need to filter anything? Do you not trust udev to work

Re: [systemd-devel] Udev hardening

2020-12-14 Thread Adi Ml
Hi, Is there some way to detect which system calls, I am using in udev (in order to filter it)? I do not use any script, I just echo 0 to the authorized file in the device connected in order to disable it when it is not the wanted device (the match is based on serial number, vid, pid) Thank you

Re: [systemd-devel] Udev hardening

2020-12-14 Thread Greg KH
On Mon, Dec 14, 2020 at 02:54:31PM +0200, Adi Ml wrote: > Hi, > > I would like to harden my udev service with the > SystemCallFilter option. What systemcalls should be permitted/allowed in > order to secure it and avoid irrelevant system calls? It all depends on what type of scripts/programs you

Re: [systemd-devel] [udev] Scanner rule not applied during boot

2020-10-21 Thread Marcin Kocur
W dniu 21.10.2020 o 08:52, Lennart Poettering pisze: On Di, 20.10.20 23:16, Marcin Kocur (marcin2...@gmail.com) wrote: Lennart, I'm using outdated lxdm with Xfce. I just disabled lxmd, copied fresh /etc/X11/xinit/xinitrc to ~/.xinitrc (adding my environment exec command there) and started my

Re: [systemd-devel] [udev] Scanner rule not applied during boot

2020-10-21 Thread Lennart Poettering
On Di, 20.10.20 23:16, Marcin Kocur (marcin2...@gmail.com) wrote: > Lennart, > > I'm using outdated lxdm with Xfce. > > I just disabled lxmd, copied fresh /etc/X11/xinit/xinitrc to ~/.xinitrc > (adding my environment exec command there) and started my environment from > startx: ACLs didn't

Re: [systemd-devel] [udev] Scanner rule not applied during boot

2020-10-20 Thread Marcin Kocur
W dniu 20.10.2020 o 20:05, Lennart Poettering pisze: On Di, 20.10.20 18:47, Marcin Kocur (marcin2...@gmail.com) wrote: I don't how how this uaccess tag works, but I can assume that my scanner which is libsane_matched (as set by /usr/lib/udev/rules.d/49-sane.rules) gets ACL permission added

Re: [systemd-devel] [udev] Scanner rule not applied during boot

2020-10-20 Thread Lennart Poettering
On Di, 20.10.20 18:47, Marcin Kocur (marcin2...@gmail.com) wrote: > I don't how how this uaccess tag works, but I can assume that my scanner > which is libsane_matched (as set by > /usr/lib/udev/rules.d/49-sane.rules) gets ACL permission added somewhere > later thanks to this uaccess tag. > > The

Re: [systemd-devel] [udev] Scanner rule not applied during boot

2020-10-20 Thread Marcin Kocur
W dniu 20.10.2020 o 13:44, Lennart Poettering pisze: On Mo, 19.10.20 21:19, Marcin Kocur (marcin2...@gmail.com) wrote: Hello systemd devs and users, I need an advice regarding USB scanner which rule is not(?) processed at boot time. When I trigger it manually, the scanner device file gets

Re: [systemd-devel] [udev] Scanner rule not applied during boot

2020-10-20 Thread Lennart Poettering
On Mo, 19.10.20 21:19, Marcin Kocur (marcin2...@gmail.com) wrote: > > Hello systemd devs and users, > > I need an advice regarding USB scanner which rule is not(?) processed at > boot time. When I trigger it manually, the scanner device file gets proper > permissions. > > Here's the rule: > > cat

Re: [systemd-devel] udev and probing of eMMC partition devices

2020-10-01 Thread Lennart Poettering
On Mi, 30.09.20 13:57, Alan Perry (al...@snowmoose.com) wrote: > > > On 9/23/20 9:29 AM, Lennart Poettering wrote: > > On Di, 22.09.20 10:06, Alan Perry (al...@snowmoose.com) wrote: > > > > > > > device add events will get stuck at the probe step. > > > > "Get stuck"? What does that mean? What is

Re: [systemd-devel] udev and probing of eMMC partition devices

2020-09-30 Thread Alan Perry
On 9/23/20 9:29 AM, Lennart Poettering wrote: On Di, 22.09.20 10:06, Alan Perry (al...@snowmoose.com) wrote: device add events will get stuck at the probe step. "Get stuck"? What does that mean? What is it actually doing? What does a stack trace say? Anything in the logs? When this

Re: [systemd-devel] udev and probing of eMMC partition devices

2020-09-23 Thread Lennart Poettering
On Di, 22.09.20 10:06, Alan Perry (al...@snowmoose.com) wrote: > > > device add events will get stuck at the probe step. > > "Get stuck"? What does that mean? What is it actually doing? What does > > a stack trace say? Anything in the logs? > > When this happens, the last thing seen in the log

Re: [systemd-devel] udev and probing of eMMC partition devices

2020-09-22 Thread Alan Perry
On 9/22/20 7:44 AM, Lennart Poettering wrote: On Mo, 21.09.20 19:03, Alan Perry (al...@snowmoose.com) wrote: Hi, I am trying to understand behavior that I am seeing with udev and eMMC partition devices and was hoping that someone here could help. The system that I am running has an eMMC

Re: [systemd-devel] udev and probing of eMMC partition devices

2020-09-22 Thread Lennart Poettering
On Mo, 21.09.20 19:03, Alan Perry (al...@snowmoose.com) wrote: > > Hi, > > I am trying to understand behavior that I am seeing with udev and eMMC > partition devices and was hoping that someone here could help. > > The system that I am running has an eMMC device with something like 7-8 >

Re: [systemd-devel] Udev Regex

2020-05-06 Thread Lennart Poettering
On Mi, 06.05.20 12:15, Boyce, Kevin P [US] (AS) (kevin.bo...@ngc.com) wrote: > Good Morning List, > > Does anyone know how complicated of a regular expression can be > utilized in a udev rule? udev supports shell-style globbing for matching, but no regular expressions. The man page says that

Re: [systemd-devel] Udev Regex

2020-05-06 Thread Andrei Borzenkov
On Wed, May 6, 2020 at 3:23 PM Boyce, Kevin P [US] (AS) wrote: > > Good Morning List, > > > > Does anyone know how complicated of a regular expression can be utilized in a > udev rule? > I would ask udev manual page :) > > > For instance I have a system with a lot of drives (sda through z

Re: [systemd-devel] UDEV popen/system returns error if called from the program (RUN option)

2020-03-03 Thread Ilya Matveychikov
> On Mar 3, 2020, at 3:43 PM, Josef Moellers wrote: > > On 03.03.20 12:26, Ilya Matveychikov wrote: >> Dear Lennart, >> >> Thank you for the reply. >> >>> On Mar 3, 2020, at 12:54 PM, Lennart Poettering >>> wrote: >>> >>> On Mo, 02.03.20 00:35, Ilya Matveychikov (matvejchi...@gmail.com)

Re: [systemd-devel] UDEV popen/system returns error if called from the program (RUN option)

2020-03-03 Thread Josef Moellers
On 03.03.20 12:26, Ilya Matveychikov wrote: > Dear Lennart, > > Thank you for the reply. > >> On Mar 3, 2020, at 12:54 PM, Lennart Poettering >> wrote: >> >> On Mo, 02.03.20 00:35, Ilya Matveychikov (matvejchi...@gmail.com) wrote: >> >>> Hey guys, >>> >>> I’m not sure is it the right place to

Re: [systemd-devel] UDEV popen/system returns error if called from the program (RUN option)

2020-03-03 Thread Ilya Matveychikov
Dear Lennart, Thank you for the reply. > On Mar 3, 2020, at 12:54 PM, Lennart Poettering > wrote: > > On Mo, 02.03.20 00:35, Ilya Matveychikov (matvejchi...@gmail.com) wrote: > >> Hey guys, >> >> I’m not sure is it the right place to ask about the UDEV or not. >> >> Anyways, I have a

Re: [systemd-devel] UDEV popen/system returns error if called from the program (RUN option)

2020-03-03 Thread Lennart Poettering
On Mo, 02.03.20 00:35, Ilya Matveychikov (matvejchi...@gmail.com) wrote: > Hey guys, > > I’m not sure is it the right place to ask about the UDEV or not. > > Anyways, I have a problem with running custom program from the UDEV rule > (RUN+= option). > The problem is somehow related to fork/exec,

Re: [systemd-devel] udev can fail to read stdout of processes spwaned in udev_event_spawn

2019-11-03 Thread Paul Davey
On Fri, 2019-11-01 at 10:13 +0100, Michal Sekletar wrote: > On Fri, Nov 1, 2019 at 1:49 AM Paul Davey > wrote: > > > > > What is the best way to fix this issue?  I have locally had success > > just calling the on_spawn_io callback in the process success branch > > of > > on_spawn_sigchld, but I

Re: [systemd-devel] udev can fail to read stdout of processes spwaned in udev_event_spawn

2019-11-01 Thread Michal Sekletar
On Fri, Nov 1, 2019 at 1:49 AM Paul Davey wrote: > What is the best way to fix this issue? I have locally had success > just calling the on_spawn_io callback in the process success branch of > on_spawn_sigchld, but I am unsure if this is an acceptable fix. In the callback, we call read() only

Re: [systemd-devel] udev: Access permission of fw character device in which fw node includes unit handled by ALSA

2019-06-18 Thread Takashi Sakamoto
Hi Lennart, Thanks for your reply, and notice to this legacy and minor issue ;) On Mon, Jun 17, 2019, at 22:26, Lennart Poettering wrote: > On Mo, 20.05.19 21:27, Takashi Sakamoto (o-taka...@sakamocchi.jp) wrote: > > > Hi all, > > > > I'm an ALSA developer, mainly committing to drivers for

Re: [systemd-devel] udev: Access permission of fw character device in which fw node includes unit handled by ALSA

2019-06-17 Thread Lennart Poettering
On Mo, 20.05.19 21:27, Takashi Sakamoto (o-taka...@sakamocchi.jp) wrote: > Hi all, > > I'm an ALSA developer, mainly committing to drivers for audio and > music units on IEEE 1394 bus (yes, it's legacy FireWire). I have a > concern about access permission for fw character device. I am not sure I

Re: [systemd-devel] udev - device nodes removed even if created/copied from /lib/udev/devices/

2019-04-08 Thread Mantas Mikulėnas
On Mon, Apr 8, 2019, 20:15 Dr. Todor Dimitrov wrote: > > Support for /lib/dev/devices has been removed in systemd 183, see NEWS > > file, i.e. in 2012, seven years ago. > > > > Support for "ignore_remove" has been removed in udev 152, nine years > > ago, see its announcement back then. > > We

Re: [systemd-devel] udev - device nodes removed even if created/copied from /lib/udev/devices/

2019-04-08 Thread Dr. Todor Dimitrov
> Support for /lib/dev/devices has been removed in systemd 183, see NEWS > file, i.e. in 2012, seven years ago. > > Support for "ignore_remove" has been removed in udev 152, nine years > ago, see its announcement back then. We are working with a system from 2010 (kernel 2.6.34, udev 161).

Re: [systemd-devel] udev - device nodes removed even if created/copied from /lib/udev/devices/

2019-04-08 Thread Lennart Poettering
On Mo, 08.04.19 15:59, Dr. Todor Dimitrov (dimit...@technology.de) wrote: > Hello, > > we are observing a weird problem with udev, where the nodes > /dev/ttyUSB* are removed as soon as the corresponding devices are > unplugged, although they have been statically created using >

Re: [systemd-devel] udev “PROGRAM/RUN” command not working properly for “REMOVE” action

2019-02-05 Thread Lennart Poettering
On Di, 05.02.19 13:08, Martin Wilck (mwi...@suse.de) wrote: > On Mon, 2019-02-04 at 13:19 +0100, Lennart Poettering wrote: > > > > reading sysfs attrs is problematics from "remove" rules, as the sysfs > > device is likely to have vanished by then, as rules are executed > > asynchronously to the

Re: [systemd-devel] udev “PROGRAM/RUN” command not working properly for “REMOVE” action

2019-02-05 Thread Martin Wilck
On Mon, 2019-02-04 at 13:19 +0100, Lennart Poettering wrote: > > reading sysfs attrs is problematics from "remove" rules, as the sysfs > device is likely to have vanished by then, as rules are executed > asynchronously to the events they are run for. > > udev will import the udev db from the

Re: [systemd-devel] udev “PROGRAM/RUN” command not working properly for “REMOVE” action

2019-02-05 Thread Ziemowit Podwysocki
On 04.02.2019 13:19, Lennart Poettering wrote: > On Do, 31.01.19 14:46, Ziemowit Podwysocki > (ziemowit.podwyso...@globallogic.com) wrote: > >> Hello, >> >> I have multiple exactly same USB devices. Each device enumerates >> multiply ttyACM ports under /dev directory. Each port has it unique >>

Re: [systemd-devel] udev “PROGRAM/RUN” command not working properly for “REMOVE” action

2019-02-04 Thread Lennart Poettering
On Do, 31.01.19 14:46, Ziemowit Podwysocki (ziemowit.podwyso...@globallogic.com) wrote: > Hello, > > I have multiple exactly same USB devices. Each device enumerates > multiply ttyACM ports under /dev directory. Each port has it unique > purpose, one is for handling some commands, another is

Re: [systemd-devel] udev “PROGRAM/RUN” command not working properly for “REMOVE” action

2019-02-01 Thread Martin Wilck
On Thu, 2019-01-31 at 14:46 +0100, Ziemowit Podwysocki wrote: > > ACTION=="remove", SUBSYSTEM=="usb", DRIVER=="usb", > ATTRS{idVendor}=="1244", ATTRS{idProduct}=="206d", RUN+="/bin/touch > /home/user/udev/%k" > > This one suppose to create file named after "KERNEL" param of the > device.

Re: [systemd-devel] udev script can't resolve host name

2018-08-15 Thread Jonathan Kamens
Thanks for the pointer. It turns out that Ubuntu puts IPAddressDeny=all in systemd-udevd.service. I suppose I could remove that (reducing protection, as you note) or add an IPAddressAllow setting to allow access to the DNS server and remote URL I want to hit, but then I have to worry about

Re: [systemd-devel] udev script can't resolve host name

2018-08-15 Thread Michael Biebl
Am Mi., 15. Aug. 2018 um 11:09 Uhr schrieb Jonathan Kamens : > > Hi, > > If I understand correctly, this mailing list can be used for questions about > udev as well as about systemd. If that's not correct, somebody please let me > know and I will go elsewhere (and if you know where that

Re: [systemd-devel] udev script can't resolve host name

2018-08-15 Thread Sietse van Zanen
Jonathan, Yes that is exactly the case. Look inside he unit filre, systemd-udevd.service. It contains lines like: PrivateMounts=yes MemoryDenyWriteExecute=yes RestrictRealtime=yes RestrictAddressFamilies=AF_UNIX AF_NETLINK AF_INET AF_INET6 SystemCallFilter=@system-service @module @raw-io

Re: [systemd-devel] Udev rules

2018-01-25 Thread Dmitry Torokhov
On Tue, Jan 23, 2018 at 2:08 AM, Michael wrote: > Hi > why can't the Udev rules be automated or removed? As described here users > only need to paste infos from lsusb etc. > https://forums.x-plane.org/index.php?/forums/topic/72733-writing-and-debugging-udev-rules/=2 > But

Re: [systemd-devel] Udev rules

2018-01-23 Thread Lennart Poettering
On Di, 23.01.18 10:08, Michael (scrat_h...@yahoo.com) wrote: > Hiwhy can't the Udev rules be automated or removed? As described > here users only need to paste infos from lsusb > etc.https://forums.x-plane.org/index.php?/forums/topic/72733-writing-and-debugging-udev-rules/=2But > such a huge pain

Re: [systemd-devel] udev

2017-11-01 Thread David Henderson
On 11/1/17, Mike Gilbert wrote: > On Wed, Nov 1, 2017 at 10:49 AM, David Henderson > wrote: >> On 11/1/17, Greg KH wrote: >>> On Wed, Nov 01, 2017 at 10:36:16AM -0400, David Henderson wrote: Is there a place to

Re: [systemd-devel] udev

2017-11-01 Thread Mike Gilbert
On Wed, Nov 1, 2017 at 10:49 AM, David Henderson wrote: > On 11/1/17, Greg KH wrote: >> On Wed, Nov 01, 2017 at 10:36:16AM -0400, David Henderson wrote: >>> Is there a place to just get the udev code instead of all of systemD? >> >> No. >>

Re: [systemd-devel] udev

2017-11-01 Thread David Henderson
On 11/1/17, Greg KH wrote: > On Wed, Nov 01, 2017 at 10:36:16AM -0400, David Henderson wrote: >> Is there a place to just get the udev code instead of all of systemD? > > No. > >> I tried looking online, but it appears that the only solo versions are >> old. I guess

Re: [systemd-devel] udev

2017-11-01 Thread David Henderson
On 11/1/17, Lennart Poettering wrote: > On Di, 31.10.17 14:49, David Henderson (dhender...@digital-pipe.com) wrote: > >> Good afternoon all. So is there another place I can get help for >> this problem? > > Sorry, but this isn't really the right forum for help regarding >

Re: [systemd-devel] udev

2017-11-01 Thread Greg KH
On Wed, Nov 01, 2017 at 10:04:19AM -0400, David Henderson wrote: > Good morning Lennart, thanks for the follow-up! At this point I am > only interested in building a particular program (udev) from the > systemD collection, not help building a distribution. And I think if > I tried to contact LFS

Re: [systemd-devel] udev

2017-11-01 Thread Lennart Poettering
On Di, 31.10.17 14:49, David Henderson (dhender...@digital-pipe.com) wrote: > Good afternoon all. So is there another place I can get help for > this problem? Sorry, but this isn't really the right forum for help regarding building your distribution. Most of us just base our work on the work

Re: [systemd-devel] udev

2017-10-31 Thread David Henderson
Good afternoon all. So is there another place I can get help for this problem? Thanks, Dave On 10/30/17, David Henderson wrote: > Good morning all! Just following up with this! > > Thanks, > Dave > > > On 10/26/17, David Henderson

Re: [systemd-devel] udev

2017-10-30 Thread David Henderson
Good morning all! Just following up with this! Thanks, Dave On 10/26/17, David Henderson wrote: > On 10/26/17, David Henderson wrote: >> So I am using the compile flags as suggested, however, I have noticed >> two errors. I tried

Re: [systemd-devel] udev

2017-10-26 Thread David Henderson
On 10/26/17, David Henderson wrote: > So I am using the compile flags as suggested, however, I have noticed > two errors. I tried passing '--enable-static' to 'configure' and end > up with: > > checking if libtool supports shared libraries... yes > checking whether

Re: [systemd-devel] udev

2017-10-26 Thread David Henderson
So I am using the compile flags as suggested, however, I have noticed two errors. I tried passing '--enable-static' to 'configure' and end up with: checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries...

Re: [systemd-devel] udev

2017-10-26 Thread David Henderson
On 10/26/17, Mantas Mikulėnas wrote: > On Thu, Oct 26, 2017, 18:26 David Henderson > wrote: > >> Good afternoon all! I have been looking for the udev source code to >> compile the library and utilities and it appears it is bundled in the >>

Re: [systemd-devel] udev

2017-10-26 Thread David Henderson
lol thanks for the links Mike! Using the build system I developed, I more or less have hooks to external scripts that can be called to perform various tasks during the build process. Once I get the profile built, I can give it to you if you are interested to see how it works. Compiling is as

Re: [systemd-devel] udev

2017-10-26 Thread Mike Gilbert
On Thu, Oct 26, 2017 at 11:45 AM, Mantas Mikulėnas wrote: > On Thu, Oct 26, 2017, 18:26 David Henderson > wrote: >> >> Good afternoon all! I have been looking for the udev source code to >> compile the library and utilities and it appears it is

Re: [systemd-devel] udev

2017-10-26 Thread Mantas Mikulėnas
On Thu, Oct 26, 2017, 18:26 David Henderson wrote: > Good afternoon all! I have been looking for the udev source code to > compile the library and utilities and it appears it is bundled in the > systemd software. I have run autoreconf to generate a configure >

Re: [systemd-devel] udev hwdb add unknown button

2017-06-16 Thread Lennart Poettering
On Fri, 09.06.17 10:23, Floris (jkflo...@dds.nl) wrote: 1;4602;0c > I have an older ASUS R2E UMPC[1], which has a couple of media buttons. One > button isn't recognized and print: > > asus_laptop: Unknown key 9a pressed > > I tried to add this button with an udev hwdb rule in >

Re: [systemd-devel] udev rule to mount ext4 with data=journal

2017-06-14 Thread Pascal K
To clear things up a bit: I build a Image using Buildroot running Busybox on top. I have SystemVinit. Is there something else commonly used out there? Otherwise I just create my own daemon. Best regards, Pascal Lennart Poettering schrieb am Mi., 14. Juni 2017 um 11:23

Re: [systemd-devel] udev rule to mount ext4 with data=journal

2017-06-14 Thread Lennart Poettering
On Wed, 14.06.17 08:44, Pascal K (pascalkra...@gmail.com) wrote: > As I am on a embedded device I am trying to avoid the usage of systemd due > to serveral reasons. Not sure I follow the logic in the above, but if you don't want to use systemd, then you should probably run something else that

Re: [systemd-devel] udev rule to mount ext4 with data=journal

2017-06-14 Thread Michael Biebl
2017-06-14 10:44 GMT+02:00 Pascal K : > As I am on a embedded device I am trying to avoid the usage of systemd due > to serveral reasons. Does that mean you are not using systemd as PID 1? -- Why is it that all of the instruments seeking intelligent life in the universe

Re: [systemd-devel] udev rule to mount ext4 with data=journal

2017-06-14 Thread Pascal K
As I am on a embedded device I am trying to avoid the usage of systemd due to serveral reasons. @Lennart I try to follow your point: > Note that we run udevd in its own mount namespace through MountFlags=, > and this means no mounts will ever appear on the host anyway. Am I right that this

Re: [systemd-devel] udev rule to mount ext4 with data=journal

2017-06-14 Thread Lennart Poettering
On Wed, 14.06.17 08:11, Pascal K (pascalkra...@gmail.com) wrote: > I try to achieve that regardless the device plugged to my embedded system > the mount will be in folder /media/"name_of_volume". > > If I understand correctly for the usage of fstab I have to give a static > name for the mount

Re: [systemd-devel] udev rule to mount ext4 with data=journal

2017-06-14 Thread Lennart Poettering
On Wed, 14.06.17 07:30, Pascal K (pascalkra...@gmail.com) wrote: > Hello everyone, > > I am new to this list and to udev (used mdev before). > > My goal: Mount a CFast card partioned with 2 partitions one FAT32 and one > EXT4, the EXT4 I would like to mount with option "data=journal" > > The

Re: [systemd-devel] udev rule to mount ext4 with data=journal

2017-06-14 Thread Pascal K
I try to achieve that regardless the device plugged to my embedded system the mount will be in folder /media/"name_of_volume". If I understand correctly for the usage of fstab I have to give a static name for the mount point. Thanks for pointing out the "nofail" option. Best regards, Pascal

Re: [systemd-devel] udev rule to mount ext4 with data=journal

2017-06-14 Thread Michał Zegan
Hmm, why not to place such things in /etc/fstab? W dniu 14.06.2017 o 09:30, Pascal K pisze: > Hello everyone, > > I am new to this list and to udev (used mdev before). > > My goal: Mount a CFast card partioned with 2 partitions one FAT32 and > one EXT4, the EXT4 I would like to mount with

Re: [systemd-devel] udev - ignore/hide persistent storage

2017-03-31 Thread Lennart Poettering
On Fri, 31.03.17 11:30, lejeczek (pelj...@yahoo.co.uk) wrote: > > > sorry guys to bother you, but > > > I'll see myself going slowly mad next week, for I've been reading and > > > tryingand trying.. > > > > > > and I fail to tell udev to ignore a device and not to create symlinks. > > > I need

Re: [systemd-devel] udev - ignore/hide persistent storage

2017-03-31 Thread lejeczek
On 31/03/17 08:00, Lennart Poettering wrote: On Thu, 30.03.17 21:40, lejeczek (pelj...@yahoo.co.uk) wrote: sorry guys to bother you, but I'll see myself going slowly mad next week, for I've been reading and tryingand trying.. and I fail to tell udev to ignore a device and not to create

Re: [systemd-devel] udev - ignore/hide persistent storage

2017-03-31 Thread Lennart Poettering
On Thu, 30.03.17 21:40, lejeczek (pelj...@yahoo.co.uk) wrote: > sorry guys to bother you, but > I'll see myself going slowly mad next week, for I've been reading and > tryingand trying.. > > and I fail to tell udev to ignore a device and not to create symlinks. > I need someone to 100% confirm

Re: [systemd-devel] udev virtio by-path naming

2017-03-01 Thread Viktor Mihajlovski
On 01.03.2017 20:23, Viktor Mihajlovski wrote: > On 01.03.2017 19:44, Daniel P. Berrange wrote: > [...] > replying on the list, a bit lengthy >> >> Ok, my guest has 4 disks >> >> - sda - virtio-scsi, over virtio-pci transport >> - sdb - virtio-scsi, over virtio-mmio transport >> - vda -

Re: [systemd-devel] udev virtio by-path naming

2017-03-01 Thread Viktor Mihajlovski
On 01.03.2017 19:44, Daniel P. Berrange wrote: [...] replying on the list, a bit lengthy > > Ok, my guest has 4 disks > > - sda - virtio-scsi, over virtio-pci transport > - sdb - virtio-scsi, over virtio-mmio transport > - vda - virtio-scsi, over virtio-pci transport > - vdb - virtio-scsi,

Re: [systemd-devel] udev virtio by-path naming

2017-03-01 Thread Daniel P. Berrange
On Wed, Mar 01, 2017 at 07:28:46PM +0100, Viktor Mihajlovski wrote: > On 01.03.2017 16:58, Daniel P. Berrange wrote: > > given a basic Fedora 25 guest, with a virtio-mmio disk added as per the > > guide above... > > > > looking at device > >

Re: [systemd-devel] udev virtio by-path naming

2017-03-01 Thread Viktor Mihajlovski
On 01.03.2017 16:58, Daniel P. Berrange wrote: > On Wed, Mar 01, 2017 at 04:02:53PM +0100, Viktor Mihajlovski wrote: >> On 01.03.2017 04:30, Zbigniew Jędrzejewski-Szmek wrote: >>> On Tue, Feb 28, 2017 at 09:47:42AM +0100, Viktor Mihajlovski wrote: One could argue about back-level

Re: [systemd-devel] udev virtio by-path naming

2017-03-01 Thread Daniel P. Berrange
On Wed, Mar 01, 2017 at 03:58:12PM +, Daniel P. Berrange wrote: > On Wed, Mar 01, 2017 at 04:02:53PM +0100, Viktor Mihajlovski wrote: > > If wanted, I can take a stab at virtio-mmio, but would need the output > > of udevadm -a /dev/vda from a virtio-mmio system. > > Presumably you mean

Re: [systemd-devel] udev virtio by-path naming

2017-03-01 Thread Daniel P. Berrange
On Wed, Mar 01, 2017 at 04:02:53PM +0100, Viktor Mihajlovski wrote: > On 01.03.2017 04:30, Zbigniew Jędrzejewski-Szmek wrote: > > On Tue, Feb 28, 2017 at 09:47:42AM +0100, Viktor Mihajlovski wrote: > >> One could argue about back-level compatibility, but virtio by-path > >> naming has

Re: [systemd-devel] udev virtio by-path naming

2017-03-01 Thread Viktor Mihajlovski
On 01.03.2017 04:30, Zbigniew Jędrzejewski-Szmek wrote: > On Tue, Feb 28, 2017 at 09:47:42AM +0100, Viktor Mihajlovski wrote: >> One could argue about back-level compatibility, but virtio by-path >> naming has changed multiple times. We have seen virtio-pci-virtio >> (not predictable),

  1   2   3   4   >