I have had some issues lately with upgrades overwriting config files (postfix, apache2). Should I create a ticket for these issues, or is this being fixed in this ticket: I noticed this ticket: http://trac.macports.org/projects/macports/ticket/2365 ? /matzon
Hi Brian,
I have had some issues lately with upgrades overwriting config files (postfix, apache2). Should I create a ticket for these issues, or is this being fixed in this ticket: I noticed this ticket: http://trac.macports.org/projects/macports/ ticket/2365
The ticket you mention is a proposal for an addition to the MacPorts core, and it appears that it will need significant work before it can be closed. The current procedure is for individual port maintainers to rename configuration files that should not be overwritten on upgrade (e.g. by appending ".sample" to the end of the filename); people who install those ports then create a file without the suffix, possibly using the example file as a template, and this latter file is used as the local configuration file. The port should at least give you information at installation time about which files this applies to. I can thus see two potential causes for your problem. The first is that you mistakenly made the "*.sample" files your configuration files, in which case there may be a documentation problem, and you could help us by pointing out where you think such documentation ought to go. (We are currently completely re-writing the old MacPorts guide, so if you could take a look at the current unofficial development version [1], suggestions would be most welcome.) The second is that the port misses some configuration files that should be made examples, in which case fixing any such failures would the province of the individual port maintainers, and it would be best for you to file individual tickets in Trac, addressing the Cc: field to both yourself and the port maintainer. If you're not sure as to which of the above is occurring, or if you think that the problem might be of another kind, please indicate which files are being overwritten on upgrade and we'll see what we can suggest. I hope that this helps. Kind regards, Maun Suang [1] http://geeklair.net/new_macports_guide -- Boey Maun Suang (Boey is my surname) Email: boeyms at macports dot org
On Aug 16, 2007, at 16:15, Brian Matzon wrote:
I have had some issues lately with upgrades overwriting config files (postfix, apache2). Should I create a ticket for these issues, or is this being fixed in this ticket: I noticed this ticket: http://trac.macports.org/projects/macports/ ticket/2365
That ticket is 3 years old and is for general MacPorts functionality to support non-volatile default config files. Since it's so old, I doubt anything is being done with it at the moment. I'm also not convinced any functionality needs to be added to MacPorts base to support this. Many ports already handle this themselves. apache2 does, for the httpd.conf file. For the extra configs in apache2, a bug has already been filed: http://trac.macports.org/projects/macports/ticket/8605 It should be easy to fix, but nobody has done so yet. If you would like to submit a patch, that would help move things along. I don't personally use postfix, and I don't see a ticket filed for that. You could contact the maintainer, or file a ticket with more details. And of course a patch there would be welcome as well.
Ryan Schmidt wrote:
I have had some issues lately with upgrades overwriting config files (postfix, apache2). Should I create a ticket for these issues, or is this being fixed in this ticket: I noticed this ticket: http://trac.macports.org/projects/macports/ticket/2365
That ticket is 3 years old and is for general MacPorts functionality to support non-volatile default config files. Since it's so old, I doubt anything is being done with it at the moment. I'm also not convinced any functionality needs to be added to MacPorts base to support this.
The ticket mentions the need to have install/uninstall scripts (i.e. not do it in activate/deactivate since that only works with images), and that functionality is needed in order for the *.sample approach to be useful. It's another old ticket, though: http://trac.macports.org/projects/macports/ticket/1068 For the configuration files, it would be a great benefit to the packaging targets if there was a way to specify which ones are conffiles. Probably something like "destroot.conffiles", similar to the existing "destroot.keepdirs". This would signify that the files in question are *not* to be overwritten... So all these Tickets are related (#777 is another one), and the implementation of these missing features should be taken to the macports-dev list. So to me, it seems that at least two new pieces of functionality are needed to be added to the MacPorts base in order to support this ? --anders
On Aug 17, 2007, at 02:47, Anders F Björklund wrote:
Ryan Schmidt wrote:
Brian Matzon wrote:
I have had some issues lately with upgrades overwriting config files (postfix, apache2). Should I create a ticket for these issues, or is this being fixed in this ticket: I noticed this ticket: http://trac.macports.org/projects/macports/ ticket/2365
That ticket is 3 years old and is for general MacPorts functionality to support non-volatile default config files. Since it's so old, I doubt anything is being done with it at the moment. I'm also not convinced any functionality needs to be added to MacPorts base to support this.
The ticket mentions the need to have install/uninstall scripts (i.e. not do it in activate/deactivate since that only works with images), and that functionality is needed in order for the *.sample approach to be useful. It's another old ticket, though: http:// trac.macports.org/projects/macports/ticket/1068
I don't see how #1068 is related to Brian's request. Don't see why install/uninstall scripts are necessary for anything.
For the configuration files, it would be a great benefit to the packaging targets if there was a way to specify which ones are conffiles. Probably something like "destroot.conffiles", similar to the existing "destroot.keepdirs". This would signify that the files in question are *not* to be overwritten...
Don't see why that's necessary. I think we're doing just fine with individual portfiles installing their sample conf files with *.sample or *.default names.
So all these Tickets are related (#777 is another one), and the implementation of these missing features should be taken to the macports-dev list. So to me, it seems that at least two new pieces of functionality are needed to be added to the MacPorts base in order to support this ?
#777 seems to be a "nice to have" rather than a requirement: http://trac.macports.org/projects/macports/ticket/777 "If a port installs a foo.cf.sample it might want to copy foo.cf.sample to foo.cf iff foo.cf doesn't exist. This is probably common enough that the port author shouldn't be forced to write an on- install foo.cf.sample [ ! -f foo.cf ] && cp foo.cf.sample foo.cf" I don't understand what functionality requested by Brian cannot be met by MacPorts 1.5.2 as it is today.
Ryan Schmidt wrote:
The ticket mentions the need to have install/uninstall scripts (i.e. not do it in activate/deactivate since that only works with images), and that functionality is needed in order for the *.sample approach to be useful. It's another old ticket, though: http://trac.macports.org/projects/macports/ticket/1068
I don't see how #1068 is related to Brian's request. Don't see why install/uninstall scripts are necessary for anything.
Necessary and necessary... They are a convenience for users, so that you don't have to do anything extra in order to use the default configuration ? Maybe this concrete configuration example from FreeBSD's Ports helps: http://www.freebsd.org/doc/en/books/porters-handbook/plist-config.html
For the configuration files, it would be a great benefit to the packaging targets if there was a way to specify which ones are conffiles. Probably something like "destroot.conffiles", similar to the existing "destroot.keepdirs". This would signify that the files in question are *not* to be overwritten...
Don't see why that's necessary. I think we're doing just fine with individual portfiles installing their sample conf files with *.sample or *.default names.
It is great when not installing (port install), such as when using the binary packages... For instance both RPM and DEB have built-in facilities for handling configs when upgrading.
So all these Tickets are related (#777 is another one), and the implementation of these missing features should be taken to the macports-dev list. So to me, it seems that at least two new pieces of functionality are needed to be added to the MacPorts base in order to support this ?
#777 seems to be a "nice to have" rather than a requirement:
http://trac.macports.org/projects/macports/ticket/777
"If a port installs a foo.cf.sample it might want to copy foo.cf.sample to foo.cf iff foo.cf doesn't exist. This is probably common enough that the port author shouldn't be forced to write an on-install foo.cf.sample [ ! -f foo.cf ] && cp foo.cf.sample foo.cf"
I don't understand what functionality requested by Brian cannot be met by MacPorts 1.5.2 as it is today.
It's an enhancement alright, but I think that it would fit in great with the need of packages to signify which files are configuration ? In essence doing "port install/uninstall" and binary archives/packages have different needs, but I think it would be great to have features for both of them. And I do prefer simply listing the conffiles, rather than having to write any such install/uninstall scripts manually. --anders
Anders F Björklund <afb@macports.org> writes:
"If a port installs a foo.cf.sample it might want to copy foo.cf.sample to foo.cf iff foo.cf doesn't exist. This is probably common enough that the port author shouldn't be forced to write an on-install foo.cf.sample [ ! -f foo.cf ] && cp foo.cf.sample foo.cf"
I don't understand what functionality requested by Brian cannot be met by MacPorts 1.5.2 as it is today.
It's an enhancement alright, but I think that it would fit in great with the need of packages to signify which files are configuration ? In essence doing "port install/uninstall" and binary archives/packages have different needs, but I think it would be great to have features for both of them. And I do prefer simply listing the conffiles, rather than having to write any such install/uninstall scripts manually.
I think having 'dodoc' and 'dobin' macros or some such like Gentoo would be very nice. I'm not sure what I 'doconf' would do but it could be useful. Mark
Hello, I want to use macports (v 1.520) to maintain and switch between versions of php & mysql (client & server), ideally wih the stock OS X httpd (using 10.4.10). I had previously used .dmg installers from entropy.ch and mysql.com, but love macports and keep things together... Command used: % sudo port -v install php5 +mysql5 Installation was fine, but it looks like some post-installation instructions got cut-off. (bunch of stuff deleted) ---> Installing php5 5.2.3_0+darwin_8+macosx+mysql5 If this is your first install, you might want ---> Activating php5 5.2.3_0+darwin_8+macosx+mysql5 ---> Cleaning php5 ---> Removing build directory for php5 What are the approved post-install steps to get php to work with /usr/sbin/httpd, assuming the preceeding was correct? or where do i find more info on port AMP variants? thanks in advance, isao
i5ao@hotmail.com writes:
I want to use macports (v 1.520) to maintain and switch between versions of php & mysql (client & server), ideally wih the stock OS X httpd (using 10.4.10). I had previously used .dmg installers from entropy.ch and mysql.com, but love macports and keep things together...
Command used:
% sudo port -v install php5 +mysql5
Installation was fine, but it looks like some post-installation instructions got cut-off.
(bunch of stuff deleted) ---> Installing php5 5.2.3_0+darwin_8+macosx+mysql5
If this is your first install, you might want ---> Activating php5 5.2.3_0+darwin_8+macosx+mysql5 ---> Cleaning php5 ---> Removing build directory for php5
What are the approved post-install steps to get php to work with /usr/sbin/httpd, assuming the preceeding was correct? or where do i find more info on port AMP variants?
thanks in advance,
I filed patches for that 2 months ago, but no one has committed them yet. http://trac.macosforge.org/projects/macports/ticket/12108 See if looking at the patchfile helps. Mark
On Aug 17, 2007, at 21:10, isao wrote:
I want to use macports (v 1.520) to maintain and switch between versions of php & mysql (client & server), ideally wih the stock OS X httpd (using 10.4.10). I had previously used .dmg installers from entropy.ch and mysql.com, but love macports and keep things together...
Command used:
% sudo port -v install php5 +mysql5
You haven't built php5 with any apache support; you've just got the command-line interpreter. You probably wanted instead to do: sudo port install mysql5 +server sudo port install php5 +apache +mysql5 Soon, "mysql5 +server" will be replaced with "mysql5_server"; there is a ticket for this.
Installation was fine, but it looks like some post-installation instructions got cut-off.
(bunch of stuff deleted) ---> Installing php5 5.2.3_0+darwin_8+macosx+mysql5
If this is your first install, you might want ---> Activating php5 5.2.3_0+darwin_8+macosx+mysql5 ---> Cleaning php5 ---> Removing build directory for php5
What are the approved post-install steps to get php to work with /usr/sbin/httpd, assuming the preceeding was correct? or where do i find more info on port AMP variants?
participants (6)
-
Anders F Björklund
-
Boey Maun Suang
-
Brian Matzon
-
isao
-
markd@macports.org
-
Ryan Schmidt