Operating System - HP-UX
1837035 Members
2917 Online
110111 Solutions
New Discussion

New filesystem, created files are owned by root

 
Joshua M. Miller
Frequent Advisor

New filesystem, created files are owned by root

Hello!

I have an interesting problem. I am running HP-UX 11.0 and I have just created a new VG with a single LV and a vxfs filesystem on that LV. The funny thing is, whenever the DBA runs a backup script as the sybase user, the backup is created as a file owned by root on this new filesystem.

There are no su or sudo commands in this backup script, it simply runs some isql and compress commands.

Also, I can 'su - sybase' and create files that are properly owned by sybase, so I dont understand what's going on here.

Why would the files be created with root ownership and how can I fix this?

TIA,
Joshua M. Miller
7 REPLIES 7
Berd
Trusted Contributor

Re: New filesystem, created files are owned by root

Hi Joshua,

Have you tried running the script with a -x option to aid debugging. YOu maybe able to see where/when this change of ownership is occuring.

HTH
Berd
Joshua M. Miller
Frequent Advisor

Re: New filesystem, created files are owned by root

Thanks, Berd.

I will try that shortly when the DBA stops all of the processes that I have started through my testing.
Joshua M. Miller
Frequent Advisor

Re: New filesystem, created files are owned by root

I have verified that it's not the filesystem doing the permission change, I redirected the script output to another volume and received the same result as before: the files are owned by root:sys.
Berd
Trusted Contributor

Re: New filesystem, created files are owned by root

Are you able to post the output from when script is run with -x ?
Berd
Peter Nikitka
Honored Contributor

Re: New filesystem, created files are owned by root

Hi,

check, if the file creating program - or one of its child programs - has owner root and s-Bit set!

mfG Peter
The Universe is a pretty big place, it's bigger than anything anyone has ever dreamed of before. So if it's just us, seems like an awful waste of space, right? Jodie Foster in "Contact"
Joshua M. Miller
Frequent Advisor

Re: New filesystem, created files are owned by root

I will run with -x shortly and report results. Still waiting on the DBA.
Joshua M. Miller
Frequent Advisor

Re: New filesystem, created files are owned by root

It turns out that the permission issue was caused by the Sybase backup server running as root.

Thank you Berd and Peter for your responses, especially the '-x' tip Berd!