On 04/26, Dave Anderson wrote: > > > Even if this module was loaded and /dev/crash existed before I start /bin/crash? > > > > # ll /dev/crash ... > > # crash ../VMLINUX ... > > # ll /dev/crash > > ls: cannot access /dev/crash: No such file or directory > > > > doesn't look friendly. > > > > And I can't use /bin/crash without root even if I do "chmod a+r /dev/crash" on my > > machine. > > > > Is it all intentional? > > Yes. The whole /dev/crash driver bullshit was put in place because of CONFIG_STRICT_DEVMEM. > So we pretty much had to work around it by creating the read-only /dev/crash driver. > Anyway, in the original discussions, the security folks didn't want /dev/crash hanging > around unless it was actively being used by a root-only live crash session. Later on it > was decided that the driver should be built into the kernel. I understand the problems with /dev/crash. But I don't think /bin/crash should remove the file created by me. > Please, just leave it be... ;-) OK. But why /bin/crash REMOVES /dev/crash even if this file was NOT created at startup time? Why get_live_memory_source() doesn't even check file_exists("/dev/crash") if /lib/modules/%s/kernel/drivers/char/crash.ko exists? Why I can't use /bin/crash on MY machine as non-root user even if I have the permission to read /dev/crash? OK, I'll probably keep the patch below for myself. It doesn't really fix the problems, but it allows me to use "crash /dev/crash" on my machine without root. Oleg. --- x/filesys.c +++ x/filesys.c @@ -3859,8 +3859,7 @@ create_memory_device(dev_t dev) /* * It already exists -- just use it. */ - if ((stat.st_mode == MEMORY_DRIVER_DEVICE_MODE) && - (stat.st_rdev == dev)) + if (S_ISCHR(stat.st_mode) && (stat.st_rdev == dev)) return TRUE; /* -- Crash-utility mailing list Crash-utility@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/crash-utility