Hi there...
Foolish me.... all was going sooooooo well and then I got a wild hair and updated to the latest clamav .92 today.
It is possible I should have just done an rpm update install yet there were some changes in ClamAV lately and I didn't know how well that would go.
up till now I spec'd and rolled my own Clamav RPMs without milter
somewhat recently ClamAV changed from having a clamav-server RPM file to not having it so I went to the magnificent Dag repo and snagged what I needed
I did a yum remove and then a yum localinstall
What I didn't think about was that the clamav user and group would be deleted and then re-created... which I think poor package management design, yet what do I know.
Anyways, would some kind soul point me in the right direction or help me create a script that will traverse the proper parts of the filesystem and grep for files with UID and/or GID 46 please?
Ive been fighting this for a coupla hours just scrounging around and fixing what I knew needed to be chown'd based upon errors in the logfiles etc...
;->
Phew!!!
Thanks for pointers in advance
- rh
On Sat, Jan 19, 2008 at 10:21:48PM -0800, Robert - elists alleged:
Anyways, would some kind soul point me in the right direction or help me create a script that will traverse the proper parts of the filesystem and grep for files with UID and/or GID 46 please?
find / ( -uid 46 -o -gid 46 ) -print0 | xargs -0 chown clamav:clamav
On Sat, Jan 19, 2008 at 11:38:18PM -0800, Robert - elists alleged:
find / ( -uid 46 -o -gid 46 ) -print0 | xargs -0 chown clamav:clamav
Garrick,
Thank you, that is pretty slick
I haven't checked the man page for find like forever...
Didn't recall ever seeing find via uid or gid
Feel free to dress it up with specific paths and flags like -xdev.
on 1/19/2008 10:21 PM Robert - elists spake the following:
Hi there...
Foolish me.... all was going sooooooo well and then I got a wild hair and updated to the latest clamav .92 today.
It is possible I should have just done an rpm update install yet there were some changes in ClamAV lately and I didn't know how well that would go.
up till now I spec'd and rolled my own Clamav RPMs without milter
somewhat recently ClamAV changed from having a clamav-server RPM file to not having it so I went to the magnificent Dag repo and snagged what I needed
I did a yum remove and then a yum localinstall
What I didn't think about was that the clamav user and group would be deleted and then re-created... which I think poor package management design, yet what do I know.
Anyways, would some kind soul point me in the right direction or help me create a script that will traverse the proper parts of the filesystem and grep for files with UID and/or GID 46 please?
Ive been fighting this for a coupla hours just scrounging around and fixing what I knew needed to be chown'd based upon errors in the logfiles etc...
;->
Phew!!!
Thanks for pointers in advance
- rh
Sounds like a broken script in the package. Did you report it to Dag?
- rh
Sounds like a broken script in the package. Did you report it to Dag?
No, I didn't report to Dag
His package was doing what it was supposed to do after my yum remove of clamav, and so it created a clamav user and group because it was a new install... of course it didn't use the same uid and gid, yet how could it know.
;->
He is on the list, and maybe I should pop an email to the request list or related support list to see if I would have chosen the upgrade path if it would have dealt properly with the change in that one clamav-server to just clamav package part of it.
I think it is easier to ask here first since Centos 4 is the base.
Is that normal behavior for a user and group to be deleted when removing a package like clamav with yum ???
Even it is is hand rolled?
I know it was hand rolled starting a long time ago... so I can dig 2 to 3 years back in my notes if you need more info.
Im guessing it is, yet I do not necessarily agree with it.
Maybe yum does yet rpm a more correct way would not or?
Thanks in advance :-)
- rh
on 1/21/2008 9:10 AM Robert - elists spake the following:
- rh
Sounds like a broken script in the package. Did you report it to Dag?
No, I didn't report to Dag
His package was doing what it was supposed to do after my yum remove of clamav, and so it created a clamav user and group because it was a new install... of course it didn't use the same uid and gid, yet how could it know.
;->
He is on the list, and maybe I should pop an email to the request list or related support list to see if I would have chosen the upgrade path if it would have dealt properly with the change in that one clamav-server to just clamav package part of it.
I think it is easier to ask here first since Centos 4 is the base.
Is that normal behavior for a user and group to be deleted when removing a package like clamav with yum ???
Even it is is hand rolled?
I know it was hand rolled starting a long time ago... so I can dig 2 to 3 years back in my notes if you need more info.
Im guessing it is, yet I do not necessarily agree with it.
Maybe yum does yet rpm a more correct way would not or?
Thanks in advance :-)
- rh
I must have missed your mention of yum-remove first. My bad!
I think if a package adds its own user, then removing that user is a sound process also during a remove. Most of the time when packages are upgraded, you don't have that problem. Since you rolled it yourself, your spec file would have all the commands run during install and remove in it.
Scott Silva wrote:
I think if a package adds its own user, then removing that user is a sound process also during a remove. Most of the time when packages are upgraded, you don't have that problem. Since you rolled it yourself, your spec file would have all the commands run during install and remove in it.
I think it shouldn't remove the user.
When you remove a package only the files which are contained in that package are removed. But many programs running under a certain user id also write files with that user id. And those won't get removed automatically, if you remove the package - maybe you want to keep them for further inspection.
Now if a package removes the user it created, the next package creating that user might get the same uid when creating its user. And suddenly it can read the files your old application left over.
Removing users should be done by the administrator.
Ralph