Re: Q about: OpenBSD policy is to never update files under /etc automatically

2009-05-28 Thread Stuart Henderson
On 2009/05/29 00:15, Cem Kayali wrote:

 Hello!

 According to OpenBSD porting policy, it is OpenBSD policy is to never 
 update files under /etc automatically. Ports that need some specific  
 boot setup should advise the administrator about what to do instead of 
 blindly installing files.


It _does_ create new files under /etc automatically,
it _does not_ update existing files under /etc automatically.

(There is a small exception, if a package installs a file under
/etc, and the user doesn't modify it themselves, upgrading the
package to a newer version can upgrade this untouched file too).



Re: Q about: OpenBSD policy is to never update files under /etc automatically

2009-05-28 Thread Chris Kuethe
On Thu, May 28, 2009 at 3:15 PM, Cem Kayali cemkay...@eticaret.com.tr wrote:

 Hello!

 According to OpenBSD porting policy, it is OpenBSD policy is to never
 update files under /etc automatically. Ports that need some specific boot
 setup should advise the administrator about what to do instead of blindly
 installing files.


 Well, i have noticed that 'privoxy' and 'tor' install their configuration
 files into /etc automatically. _Forgive me, if i misunderstand_, but does
 not this policy cover 'it does not create folders under /etc automatically'?
 Is it just simple 'it does not touch ANY FILE under /etc though be aware it
 populates /etc with new folders'?

adding a sample default configuration file is different from changing
/etc/rc* to start your new daemon. if you change the sample default
configuration file, the package system notices it and a) won't remove
it at uninstall time, and b) won't replace it at upgrade, because it
is now part of your custom system configuration.

 I was expecting something similar to that: config files are at ie;
 /usr/local/somewhere/etc/privoxy and we advise you to copy them to
 /etc/privoxy, and add these lines to rc.local...

many packages do have just such an install-time message, suggesting a
way to activate this new software, but the installation won't modify
your system configuration automatically.

 For example, installing  mysql through ports cleanly advises administrator
 to add configuraion files.

Mysql ships with a number of differently tuned configuration files -
it's tough to pick the right default one to install. Other ports
(avrdude, for example) have a single default configuration, making the
selection trivial.

CK

-- 
GDB has a 'break' feature; why doesn't it have 'fix' too?



Re: Q about: OpenBSD policy is to never update files under /etc automatically

2009-05-28 Thread Cem Kayali


Thanks for 'clean' reply. This just looks -to me- it is a bit harder to 
follow which port installs which config files, especially if it is 
installed as dependency.


I'm not criticizing, just trying to adopt OpenBSD way as an (old) NetBSD 
user. ;))


Regards,




Chris Kuethe, 05/29/09 01:30:

On Thu, May 28, 2009 at 3:15 PM, Cem Kayali cemkay...@eticaret.com.tr wrote:
  

Hello!

According to OpenBSD porting policy, it is OpenBSD policy is to never
update files under /etc automatically. Ports that need some specific boot
setup should advise the administrator about what to do instead of blindly
installing files.


Well, i have noticed that 'privoxy' and 'tor' install their configuration
files into /etc automatically. _Forgive me, if i misunderstand_, but does
not this policy cover 'it does not create folders under /etc automatically'?
Is it just simple 'it does not touch ANY FILE under /etc though be aware it
populates /etc with new folders'?



adding a sample default configuration file is different from changing
/etc/rc* to start your new daemon. if you change the sample default
configuration file, the package system notices it and a) won't remove
it at uninstall time, and b) won't replace it at upgrade, because it
is now part of your custom system configuration.

  

I was expecting something similar to that: config files are at ie;
/usr/local/somewhere/etc/privoxy and we advise you to copy them to
/etc/privoxy, and add these lines to rc.local...



many packages do have just such an install-time message, suggesting a
way to activate this new software, but the installation won't modify
your system configuration automatically.

  

For example, installing  mysql through ports cleanly advises administrator
to add configuraion files.



Mysql ships with a number of differently tuned configuration files -
it's tough to pick the right default one to install. Other ports
(avrdude, for example) have a single default configuration, making the
selection trivial.

CK

  




Re: Q about: OpenBSD policy is to never update files under /etc automatically

2009-05-28 Thread Stuart Henderson
On 2009/05/29 02:42, Cem Kayali wrote:

 Thanks for 'clean' reply. This just looks -to me- it is a bit harder 
 to follow which port installs which config files, especially if it is  
 installed as dependency.

either pkg_info -E /etc/filename, or copy pkglocatedb from an ftp
packages directory and point locate(1) at it.




Re: Q about: OpenBSD policy is to never update files under /etc automatically

2009-05-28 Thread Matthias Kilian
On Fri, May 29, 2009 at 02:42:33AM +0300, Cem Kayali wrote:
 Thanks for 'clean' reply. This just looks -to me- it is a bit harder to 
 follow which port installs which config files, especially if it is 
 installed as dependency.

FWIW, if you want to know to which package a config file belongs,
you can use pkg_info(1). For example:

$ pkg_info -E /etc/mpd.conf
mpd-0.13.2p3Music Player Daemon

But be aware that it's slow, because it has to scan all plists of
all installed packages. And it won't help for config files that are
*not* automatically copied to /etc by pkg_add(8) (i.e. no matching
@sample entry in the plist).

Ciao,
Kili



Re: Q about: OpenBSD policy is to never update files under /etc automatically

2009-05-28 Thread Jacob Meuser
On Fri, May 29, 2009 at 02:42:33AM +0300, Cem Kayali wrote:
 
 Thanks for 'clean' reply. This just looks -to me- it is a bit harder to 
 follow which port installs which config files, especially if it is 
 installed as dependency.

pkg_info -E sems to work well.

$ grep \...@sample /usr/ports/databases/mysql/pkg/PLIST-*
/usr/ports/databases/mysql/pkg/PLIST-server:@sample ${SYSCONFDIR}/my.cnf
$ ls /etc/my.cnf
/etc/my.cnf
$ pkg_info -E /etc/my.cnf
/etc/my.cnf: mysql-server-5.0.81
mysql-server-5.0.81 multithreaded SQL database (server)
$ 


 I'm not criticizing, just trying to adopt OpenBSD way as an (old) NetBSD 
 user. ;))
 
 Regards,
 
 
 
 
 Chris Kuethe, 05/29/09 01:30:
 On Thu, May 28, 2009 at 3:15 PM, Cem Kayali cemkay...@eticaret.com.tr 
 wrote:
   
 Hello!
 
 According to OpenBSD porting policy, it is OpenBSD policy is to never
 update files under /etc automatically. Ports that need some specific boot
 setup should advise the administrator about what to do instead of blindly
 installing files.
 
 
 Well, i have noticed that 'privoxy' and 'tor' install their configuration
 files into /etc automatically. _Forgive me, if i misunderstand_, but does
 not this policy cover 'it does not create folders under /etc 
 automatically'?
 Is it just simple 'it does not touch ANY FILE under /etc though be aware 
 it
 populates /etc with new folders'?
 
 
 adding a sample default configuration file is different from changing
 /etc/rc* to start your new daemon. if you change the sample default
 configuration file, the package system notices it and a) won't remove
 it at uninstall time, and b) won't replace it at upgrade, because it
 is now part of your custom system configuration.
 
   
 I was expecting something similar to that: config files are at ie;
 /usr/local/somewhere/etc/privoxy and we advise you to copy them to
 /etc/privoxy, and add these lines to rc.local...
 
 
 many packages do have just such an install-time message, suggesting a
 way to activate this new software, but the installation won't modify
 your system configuration automatically.
 
   
 For example, installing  mysql through ports cleanly advises administrator
 to add configuraion files.
 
 
 Mysql ships with a number of differently tuned configuration files -
 it's tough to pick the right default one to install. Other ports
 (avrdude, for example) have a single default configuration, making the
 selection trivial.
 
 CK
 
   
 

-- 
jake...@sdf.lonestar.org
SDF Public Access UNIX System - http://sdf.lonestar.org