WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: postfix file permissions wrong on read only filesystem  (Read 5935 times)

Offline ananix

  • Full Member
  • ***
  • Posts: 174
postfix file permissions wrong on read only filesystem
« on: November 10, 2012, 04:37:36 PM »
Im not sure if its supposed to be like that but the extension from the repo loads files into memory with wrong file permissions for postfix making postfix failing mail delivery.

A second opinion anyone?

I wonder what the theory would be behind using the extension like that if its supposed to be like that?

For now im thinking about marking the extension as copy to fs at boot and then fix permissions?

Offline ananix

  • Full Member
  • ***
  • Posts: 174
Re: postfix file permissions wrong on read only filesystem
« Reply #1 on: November 12, 2012, 12:41:25 PM »
am i the only one using postfix from the repo?

what does other people use beside sendmail?

Offline gutmensch

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 605
  • I can make it disappear, have no fear!
    • remembrance blog
Re: postfix file permissions wrong on read only filesystem
« Reply #2 on: November 19, 2012, 01:58:37 PM »
since I am the maintainer I kindly ask for a detailed description of what is failing and besides that I'm not using postfix actively ;) what is exactly "wrong file permissions"? what directory? mode? user? thanks for clarification!
If I seem unduly clear to you, you must have misunderstood what I said. (Alan Greenspan)

Offline ananix

  • Full Member
  • ***
  • Posts: 174
Re: postfix file permissions wrong on read only filesystem
« Reply #3 on: November 20, 2012, 05:01:24 AM »
sorry for not leaving much info just needed clarification first.

Do you have it working though?

A made a scientific linux solution that was better fit for the the overall task of the server anyway.

It cant write to the mail queue, my guess is it needs something like below...
chmod g+s /usr/local/sbin/postdrop
chmod g+s /usr/local/sbin/postqueue
chgrp postdrop /usr/local/sbin/postqueue
chgrp postdrop /usr/local/sbin/postdrop

Offline gutmensch

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 605
  • I can make it disappear, have no fear!
    • remembrance blog
Re: postfix file permissions wrong on read only filesystem
« Reply #4 on: November 20, 2012, 05:18:19 AM »
No problem! I checked a bit into it yesterday and found that the owner and permissions of the mentioned files are not correctly transfered into the squashfs archive, although I was setting them before... should be an issue with my build script ;) besides that also the init script didn't have +x, so quite a few bugs - will upload a reworked version in the evening, thanks for the pointer! Unfortunately I'm not using postfix at all and building it reminds me of the 80s, so no surprise for me that there are problems. I'll post here again on update and I would really appreciate testing!
If I seem unduly clear to you, you must have misunderstood what I said. (Alan Greenspan)

Offline ananix

  • Full Member
  • ***
  • Posts: 174
Re: postfix file permissions wrong on read only filesystem
« Reply #5 on: November 20, 2012, 07:03:52 AM »
c001, also when one copies to virtual filesystem instead of running it from loop device some path\s seems to be hardcoded maybe doing compile, forcing it to look in /tmp/loop/postfix.

Offline gutmensch

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 605
  • I can make it disappear, have no fear!
    • remembrance blog
Re: postfix file permissions wrong on read only filesystem
« Reply #6 on: November 20, 2012, 12:35:33 PM »
yeah unfortunately that's true IIRC, because postfix has some crazy checks for those files and breaks when they are only symlinks. I tried to avoid any hardcoding, but then postfix just refuses to use the files. So the changes within /usr/local/libexec/postfix/postfix-script to postqueue and postdrop were necessary... but lets fix the "normal" way with the permissions and then this shouldn't matter anymore. Copying postfix to the RAM rootfs is normally not the nice TC way ;)
If I seem unduly clear to you, you must have misunderstood what I said. (Alan Greenspan)

Offline ananix

  • Full Member
  • ***
  • Posts: 174
Re: postfix file permissions wrong on read only filesystem
« Reply #7 on: November 20, 2012, 03:45:11 PM »
  Copying postfix to the RAM rootfs is normally not the nice TC way ;)

  Not to argue with your decision on how to implement your extension i think for the scope of it your decision is right, but i would argue that copying postfix to RAM fs is not a nice TC way. I think the recommendations is meant for PC/NC like implementations (fast boot, ~dynamic extensions, ~slow access) but the feature is perfect for small single purpose servers (~slow boot, ~static extensions, fast access) and i beleave the features is also very much within the scope of TCL's main usages.
 I actualy more see mounting squasedfs to loop devices as a hack way to make it fit for PC/NC usage and "copy to fs" to be the real/nice way ;)

  Anyway good work thanks, keep it up :)

  -- Regards Andreas

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: postfix file permissions wrong on read only filesystem
« Reply #8 on: November 20, 2012, 04:19:50 PM »
Regardless of your views, loop mounting is the supported method.
Copy2fs is not supported for all extensions.

Offline ananix

  • Full Member
  • ***
  • Posts: 174
Re: postfix file permissions wrong on read only filesystem
« Reply #9 on: November 20, 2012, 05:00:33 PM »
Regardless of your views, loop mounting is the supported method.
Copy2fs is not supported for all extensions.

  ok thanks for stating, i will not raise a flag then if i come across one, one day :)

Offline tinypoodle

  • Hero Member
  • *****
  • Posts: 3857
Re: postfix file permissions wrong on read only filesystem
« Reply #10 on: November 20, 2012, 10:30:23 PM »
[
  Not to argue with your decision on how to implement your extension i think for the scope of it your decision is right, but i would argue that copying postfix to RAM fs is not a nice TC way. I think the recommendations is meant for PC/NC like implementations (fast boot, ~dynamic extensions, ~slow access) but the feature is perfect for small single purpose servers (~slow boot, ~static extensions, fast access) and i beleave the features is also very much within the scope of TCL's main usages.
 I actualy more see mounting squasedfs to loop devices as a hack way to make it fit for PC/NC usage and "copy to fs" to be the real/nice way ;)


Define: "PC/NC"
websearch is unconclusive...
"Software gets slower faster than hardware gets faster." Niklaus Wirth - A Plea for Lean Software (1995)

Offline gutmensch

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 605
  • I can make it disappear, have no fear!
    • remembrance blog
Re: postfix file permissions wrong on read only filesystem
« Reply #11 on: November 21, 2012, 04:03:28 AM »
btw I uploaded an update of postfix yesterday, so you can try it out by updating the extension ;)
If I seem unduly clear to you, you must have misunderstood what I said. (Alan Greenspan)

Offline ananix

  • Full Member
  • ***
  • Posts: 174
Re: postfix file permissions wrong on read only filesystem
« Reply #12 on: November 21, 2012, 04:05:21 AM »
[
  Not to argue with your decision on how to implement your extension i think for the scope of it your decision is right, but i would argue that copying postfix to RAM fs is not a nice TC way. I think the recommendations is meant for PC/NC like implementations (fast boot, ~dynamic extensions, ~slow access) but the feature is perfect for small single purpose servers (~slow boot, ~static extensions, fast access) and i beleave the features is also very much within the scope of TCL's main usages.
 I actualy more see mounting squasedfs to loop devices as a hack way to make it fit for PC/NC usage and "copy to fs" to be the real/nice way ;)


Define: "PC/NC"
websearch is unconclusive...

Personal computer/Net computer

Offline ananix

  • Full Member
  • ***
  • Posts: 174
Re: postfix file permissions wrong on read only filesystem
« Reply #13 on: November 21, 2012, 09:33:37 AM »
Sorry had another server with controller problems on my workbench which i had to work on, but ill defently give it a try when i can :)