            .read(false)
            .write(true)
            .mode(nix::libc::S_IWUSR | nix::libc::S_IRUSR)
            .open("/dev/kmsg")
            .map_err(|io| {
                printable_error(PROGRAM_NAME, format!("unable to open /dev/kmsg: {}", io))
            })?;
        Ok(Self(file))