Bug 444482 - Check does not play well with Read-Only root filesystems
Summary: Check does not play well with Read-Only root filesystems
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: samba
Version: 9
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Simo Sorce
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-04-28 16:18 UTC by Dolhay Denes
Modified: 2009-07-14 18:21 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-07-14 18:21:52 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Dolhay Denes 2008-04-28 16:18:39 UTC
Description of problem:


in the SMB init script, there is a check: [ -w /etc/samba/smb.conf ] || exit 4
which is not a good check if the fs is in RO state.

I advise to replace this check with the id -u orded

Comment 1 Simo Sorce 2008-04-28 17:09:41 UTC
If the filesystem is in read-only state samba will just fail as it needs to
write in .tdb files to work at all.

Not sure I understand the advice, in any case I think this is intentional and
not a bug, so closing.

Comment 2 Dolhay Denes 2008-04-28 17:28:03 UTC
I am useing Fedora for a server, and the / fs is RO. All other fs -es like var
and tmp are read write. But since the configuration file is in a read only
filesystem, the given test fails, and kills the init script with error code 4.
If I remove this test, Samba works correctly. So since this test is intended to
be a test for that, the caller user is root or not, I suggest to change the
given test to
[ `id -u` = 0 ] || exit 4
So root users wil not be allowed to run the script, and it will return a correct
value if the / fs is RO.

Comment 3 Simo Sorce 2008-04-28 18:29:21 UTC
it's probably easier to remove the check at that point, smbd need to listen on
privileged ports and read root-only oned files, so it will fail anyway if run as
non-root ...

If I change it with a check on the /var/lib/samba and /var/cache/samba
directories to be writable, would this be better ?


Comment 4 Dolhay Denes 2008-04-28 19:38:31 UTC
/var/lib/samba would be the best I think

Thank you for the assistance!

I have a few improvements to fedora to work better with ro / file system
init scripts, etc. Shall I post them (in  a different report)?

Comment 5 Simo Sorce 2008-04-28 21:05:32 UTC
I am renaming this one, feel free to attch them here if they are samba related

Comment 6 Dolhay Denes 2008-04-28 21:38:36 UTC
no, they are not. This issue can be closed now if you think that way too.

Comment 7 Bug Zapper 2008-05-14 10:19:14 UTC
Changing version to '9' as part of upcoming Fedora 9 GA.
More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 8 Bug Zapper 2009-06-10 00:29:57 UTC
This message is a reminder that Fedora 9 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 9.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '9'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 9's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 9 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 9 Bug Zapper 2009-07-14 18:21:52 UTC
Fedora 9 changed to end-of-life (EOL) status on 2009-07-10. Fedora 9 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.


Note You need to log in before you can comment on or make changes to this bug.