On 5/30/05, Valdis.Kletnieks@vt.edu Valdis.Kletnieks@vt.edu wrote:
On Mon, 30 May 2005 08:30:49 CDT, Justin Conover said:
Right, but why did it not let me created a file system with selinux=1? I did a fresh install of fc4t3 on this box too, with the same results.
If you didn't already post the avc messages that mkfs generated (I've already deleted the first few msgs of this thread), could you do so? They'd be in /var/log/messages (if you have a default syslog config and aren't using auditd) or in /var/log/audit/audit.log if you have auditd running....
Although I'm suspecting the problem is, as others have mentioned, that your system needs to be relabeled, and that an improper label on something broke the mkfs.
Ok, still have problems, set "enforcing=0" and relabeled and here is all the bits.
# sestatus SELinux status: enabled SELinuxfs mount: /selinux Current mode: enforcing Mode from config file: enforcing Policy version: 19 Policy from config file: targeted
<SNIP>
# mkdir /lvm_test_dir
# vgdisplay --- Volume group --- VG Name VolGroup00 System ID Format lvm2 Metadata Areas 4 Metadata Sequence No 11 VG Access read/write VG Status resizable MAX LV 0 Cur LV 9 Open LV 9 Max PV 0 Cur PV 4 Act PV 4 VG Size 135.28 GB PE Size 32.00 MB Total PE 4329 Alloc PE / Size 1408 / 44.00 GB Free PE / Size 2921 / 91.28 GB VG UUID TxPt55-hDYK-lJmC-Aohb-LbGe-glnr-7046hW
# lvcreate -L2G -nLogVol10 VolGroup00 Logical volume "LogVol10" created
# mkfs.ext3 /dev/VolGroup00/LogVol10 mke2fs 1.37 (21-Mar-2005) Could not stat /dev/VolGroup00/LogVol10 --- Permission denied
# grep mkfs audit/audit.log type=SYSCALL msg=audit(1117397418.851:206892): arch=40000003 syscall=195 success=no exit=-13 a0=bf8aebdf a1=bf8605d8 a2=838ff4 a3=0 items=1 pid=2247 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 comm="mkfs.ext3" exe="/sbin/mkfs.ext3" type=AVC msg=audit(1117397418.851:206892): avc: denied { getattr } for pid=2247 comm="mkfs.ext3" name=fedora.img dev=dm-7 ino=12 scontext=root:system_r:fsadm_t tcontext=root:object_r:file_t tclass=file type=SYSCALL msg=audit(1117397783.921:261196): arch=40000003 syscall=195 success=no exit=-13 a0=bf856bdf a1=bf7eed58 a2=bc7ff4 a3=0 items=1 pid=2308 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 comm="mkfs.ext3" exe="/sbin/mkfs.ext3" type=AVC msg=audit(1117397783.921:261196): avc: denied { getattr } for pid=2308 comm="mkfs.ext3" name=fedora.img dev=dm-7 ino=12 scontext=root:system_r:fsadm_t tcontext=root:object_r:file_t tclass=file type=SYSCALL msg=audit(1117470602.109:1094349): arch=40000003 syscall=195 success=no exit=-13 a0=bf87fc52 a1=bf87e7a8 a2=a1dff4 a3=0 items=1 pid=4009 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 comm="mkfs.ext3" exe="/sbin/mkfs.ext3" type=AVC msg=audit(1117470602.109:1094349): avc: denied { getattr } for pid=4009 comm="mkfs.ext3" name=VolGroup00-LogVol10 dev=tmpfs ino=56551 scontext=root:system_r:fsadm_t tcontext=root:object_r:device_t tclass=blk_file