I am at loss on this mysterious file permission issue. I cannot move the file
out of the directory, but I can rename it. I cannot read the file.
It is not open by any processes, the filesystem is in read write mode. I am
logged in as root.
[root@localhost /]# dir /var/named/backup.tgz
-rwxrwxrwx 1 root root 6651 Nov 11 11:32 /var/named/backup.tgz
[root@localhost /]# setfacl -b /var/named/backup.tgz
[root@localhost /]# dir /var/named/backup.tgz
-rwxrwxrwx 1 root root 6651 Nov 11 11:32 /var/named/backup.tgz
[root@localhost /]# getfacl /var/named/backup.tgz
getfacl: Removing leading '/' from absolute path names
# file: var/named/backup.tgz
# owner: root
# group: root
user::rwx
group::rwx
other::rwx
[root@localhost /]# mv /var/named/backup.tgz ~
mv: cannot open `/var/named/backup.tgz' for reading: Permission denied
[root@localhost /]# mount
<redact>
No readonly mounts
</redact>
[root@localhost /]# df -h
<redact>
Each filessytem has plenty of free space
</redact>
[root@localhost /]# dir /var/named/
total 72
drwxr-x--- 6 root named 4096 Nov 11 11:32 .
drwxr-xr-x 24 root root 4096 Apr 1 2010 ..
-rwxrwxrwx 1 root root 6651 Nov 11 11:32 backup.tgz
drwxr-x--- 6 root named 4096 Nov 11 11:48 chroot
drwxrwx--- 2 named named 4096 Jan 18 2010 data
drwx------ 2 root named 16384 Feb 4 2009 lost+found
drwxrwx--- 2 named named 4096 Jan 18 2010 slaves
[root@localhost named]# /etc/init.d/named stop
Stopping named: . [ OK ]
[root@localhost named]# mv backup.tgz foo
[root@localhost named]# mv foo backup.tgz
[root@localhost named]# mv backup.tgz ~
mv: cannot open `backup.tgz' for reading: Permission denied
[root@localhost named]# lsof | grep backup.tgz
[root@localhost named]#
--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- -
- Jason Pyeron PD Inc. http://www.pdinc.us -
- Principal Consultant 10 West 24th Street #100 -
- +1 (443) 269-1555 x333 Baltimore, Maryland 21218 -
- -
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
This message is copyright PD Inc, subject to license 20080407P00.
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
11-11-2010, 05:01 PM
"Jason Pyeron"
FW: Permissions issue
> -----Original Message-----
> From: centos-bounces@centos.org
> [mailto:centos-bounces@centos.org] On Behalf Of Jason Pyeron
> Sent: Thursday, November 11, 2010 12:48
> To: 'CentOS mailing list'
> Subject: [CentOS] FW: Permissions issue
>
> I am at loss on this mysterious file permission issue. I
> cannot move the file out of the directory, but I can rename
> it. I cannot read the file.
> It is not open by any processes, the filesystem is in read
> write mode. I am logged in as root.
>
More information:
Files can be deleted.
This happens for every file that is created by a tar czf command.
If you do a tar cz | cat > file.tgz the file is "normal"
I am very confused now.
>
> [root@localhost /]# tar cvzf ~/named.201011111228.tgz
> --one-file-system /etc/named.conf /var/named/
> tar: Removing leading `/' from member names /etc/named.conf
> /var/named/ /var/named/data/ /var/named/lost+found/ /var/named/slaves/
> tar: /var/named/backup.tgz: Cannot open: Permission denied
> /var/named/chroot/ /var/named/chroot/etc/
> /var/named/chroot/etc/named.caching-nameserver.conf
> <snip/>
> tar: Error exit delayed from previous errors [root@localhost
> /]# dir /var/named/backup.tgz
> -rw------- 1 root root 6651 Nov 11 11:32
> /var/named/backup.tgz [root@localhost /]# stat /var/named/backup.tgz
> File: `/var/named/backup.tgz'
> Size: 6651 Blocks: 24 IO Block: 4096
> regular file
> Device: fd04h/64772d Inode: 98312 Links: 1
> Access: (0600/-rw-------) Uid: ( 0/ root) Gid: (
> 0/ root)
> Access: 2010-11-11 12:28:33.000000000 -0500
> Modify: 2010-11-11 11:32:03.000000000 -0500
> Change: 2010-11-11 11:32:03.000000000 -0500 [root@localhost
> /]# mv /var/named/backup.tgz ~
> mv: cannot open `/var/named/backup.tgz' for reading:
> Permission denied [root@localhost /]# chmod 777
> /var/named/backup.tgz [root@localhost /]# mv /var/named/backup.tgz ~
> mv: cannot open `/var/named/backup.tgz' for reading:
> Permission denied [root@localhost /]# getfacl /var/named/backup.tgz
> getfacl: Removing leading '/' from absolute path names #
> file: var/named/backup.tgz # owner: root # group: root
> user::rwx group::rwx other::rwx
>
> [root@localhost /]# dir /var/named/backup.tgz -rwxrwxrwx 1
> root root 6651 Nov 11 11:32 /var/named/backup.tgz
> [root@localhost /]# setfacl -b /var/named/backup.tgz
> [root@localhost /]# dir /var/named/backup.tgz -rwxrwxrwx 1
> root root 6651 Nov 11 11:32 /var/named/backup.tgz
> [root@localhost /]# getfacl /var/named/backup.tgz
> getfacl: Removing leading '/' from absolute path names #
> file: var/named/backup.tgz # owner: root # group: root
> user::rwx group::rwx other::rwx
>
> [root@localhost /]# mv /var/named/backup.tgz ~
> mv: cannot open `/var/named/backup.tgz' for reading:
> Permission denied [root@localhost /]# mount <redact> No
> readonly mounts </redact> [root@localhost /]# df -h <redact>
> Each filessytem has plenty of free space </redact>
> [root@localhost /]# dir /var/named/ total 72
> drwxr-x--- 6 root named 4096 Nov 11 11:32 .
> drwxr-xr-x 24 root root 4096 Apr 1 2010 ..
> -rwxrwxrwx 1 root root 6651 Nov 11 11:32 backup.tgz
> drwxr-x--- 6 root named 4096 Nov 11 11:48 chroot
> drwxrwx--- 2 named named 4096 Jan 18 2010 data
> drwx------ 2 root named 16384 Feb 4 2009 lost+found
> drwxrwx--- 2 named named 4096 Jan 18 2010 slaves
> [root@localhost named]# /etc/init.d/named stop
> Stopping named: . [ OK ]
> [root@localhost named]# mv backup.tgz foo [root@localhost
> named]# mv foo backup.tgz [root@localhost named]# mv backup.tgz ~
> mv: cannot open `backup.tgz' for reading: Permission denied
> [root@localhost named]# lsof | grep backup.tgz
> [root@localhost named]#
>
--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- -
- Jason Pyeron PD Inc. http://www.pdinc.us -
- Principal Consultant 10 West 24th Street #100 -
- +1 (443) 269-1555 x333 Baltimore, Maryland 21218 -
- -
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
This message is copyright PD Inc, subject to license 20080407P00.
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
11-11-2010, 05:20 PM
JohnS
FW: Permissions issue
On Thu, 2010-11-11 at 13:01 -0500, Jason Pyeron wrote:
>
> > -----Original Message-----
> > From: centos-bounces@centos.org
> > [mailto:centos-bounces@centos.org] On Behalf Of Jason Pyeron
> > Sent: Thursday, November 11, 2010 12:48
> > To: 'CentOS mailing list'
> > Subject: [CentOS] FW: Permissions issue
> >
> > I am at loss on this mysterious file permission issue. I
> > cannot move the file out of the directory, but I can rename
> > it. I cannot read the file.
> > It is not open by any processes, the filesystem is in read
> > write mode. I am logged in as root.
> >
>
>
> More information:
>
> Files can be deleted.
>
> This happens for every file that is created by a tar czf command.
>
> If you do a tar cz | cat > file.tgz the file is "normal"
>
> I am very confused now.
---
rpm verify the tar package and the gzip package is yours.
John
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
11-11-2010, 05:23 PM
"Jason Pyeron"
FW: Permissions issue
> -----Original Message-----
> From: centos-bounces@centos.org
> [mailto:centos-bounces@centos.org] On Behalf Of JohnS
> Sent: Thursday, November 11, 2010 13:21
> To: CentOS mailing list
> Subject: Re: [CentOS] FW: Permissions issue
>
>
> On Thu, 2010-11-11 at 13:01 -0500, Jason Pyeron wrote:
> >
> > > -----Original Message-----
> > > From: centos-bounces@centos.org
> > > [mailto:centos-bounces@centos.org] On Behalf Of Jason Pyeron
> > > Sent: Thursday, November 11, 2010 12:48
> > > To: 'CentOS mailing list'
> > > Subject: [CentOS] FW: Permissions issue
> > >
> > > I am at loss on this mysterious file permission issue. I
> cannot move
> > > the file out of the directory, but I can rename it. I cannot read
> > > the file.
> > > It is not open by any processes, the filesystem is in read write
> > > mode. I am logged in as root.
> > >
> >
> >
> > More information:
> >
> > Files can be deleted.
> >
> > This happens for every file that is created by a tar czf command.
> >
> > If you do a tar cz | cat > file.tgz the file is "normal"
> >
> > I am very confused now.
> ---
> rpm verify the tar package and the gzip package is yours.
>
Both verify nicely.
--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- -
- Jason Pyeron PD Inc. http://www.pdinc.us -
- Principal Consultant 10 West 24th Street #100 -
- +1 (443) 269-1555 x333 Baltimore, Maryland 21218 -
- -
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
This message is copyright PD Inc, subject to license 20080407P00.
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
11-11-2010, 06:50 PM
JohnS
FW: Permissions issue
On Thu, 2010-11-11 at 13:23 -0500, Jason Pyeron wrote:
> > > This happens for every file that is created by a tar czf command.
> > >
> > > If you do a tar cz | cat > file.tgz the file is "normal"
> > >
> > > I am very confused now.
> > ---
> > rpm verify the tar package and the gzip package is yours.
> >
>
> Both verify nicely.
----
What does "lsattr" say on the file?
John
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
11-11-2010, 07:10 PM
Les Mikesell
FW: Permissions issue
On 11/11/2010 12:23 PM, Jason Pyeron wrote:
>
>> -----Original Message-----
>> From: centos-bounces@centos.org
>> [mailto:centos-bounces@centos.org] On Behalf Of JohnS
>> Sent: Thursday, November 11, 2010 13:21
>> To: CentOS mailing list
>> Subject: Re: [CentOS] FW: Permissions issue
>>
>>
>> On Thu, 2010-11-11 at 13:01 -0500, Jason Pyeron wrote:
>>>
>>>> -----Original Message-----
>>>> From: centos-bounces@centos.org
>>>> [mailto:centos-bounces@centos.org] On Behalf Of Jason Pyeron
>>>> Sent: Thursday, November 11, 2010 12:48
>>>> To: 'CentOS mailing list'
>>>> Subject: [CentOS] FW: Permissions issue
>>>>
>>>> I am at loss on this mysterious file permission issue. I
>> cannot move
>>>> the file out of the directory, but I can rename it. I cannot read
>>>> the file.
>>>> It is not open by any processes, the filesystem is in read write
>>>> mode. I am logged in as root.
>>>>
>>>
>>>
>>> More information:
>>>
>>> Files can be deleted.
>>>
>>> This happens for every file that is created by a tar czf command.
>>>
>>> If you do a tar cz | cat> file.tgz the file is "normal"
>>>
>>> I am very confused now.
>> ---
>> rpm verify the tar package and the gzip package is yours.
>>
>
> Both verify nicely.
Is SELinux enabled?
--
Les Mikesell
lesmikesell@gmail.com
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos