Bug 83135 - sysutils/smartmontools -- Does not work with alternate config location
sysutils/smartmontools -- Does not work with alternate config location
Status: Closed FIXED
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s)
Latest
Any Any
: Normal Affects Only Me
Assigned To: FreeBSD ports mailing list
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-07-08 10:50 UTC by freebsd
Modified: 2005-11-17 22:05 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description freebsd 2005-07-08 10:50:19 UTC
	PREFIX/etc/rc.d/smartd.sh allows for users to set 'smartd_flags'
	to whatever they want.  However, when using your own configuration
	file (instead of /usr/local/etc/smartd.conf), via

	smartd_flags="--configfile=/some/place/smartd.conf"

	...the following warning is output and smartd does not start:

	# /usr/local/etc/rc.d/smartd.sh start
	/usr/local/etc/rc.d/smartd.sh: WARNING: /usr/local/etc/smartd.conf is not readable.

	This is due to the required_files="/usr/local/etc/smartd.conf"
	line in smartd.sh.

Fix: 

I've two solutions for this (the latter being recommended);

	1.  Remove the 'required_files' directive from smartd.sh.
	My assumption is that if smartd can't find a config file,
	it'll abort.  This is an assumption on my part though.
	If this is the case, 'required_files' seems superfluous.

	2.  Add a 'smartd_config' variable to smartd.sh.  Set
	required_files to the value of that, which allows
	people to use their own configuration file via

	smartd_config="/some/place/smartd.conf"

	I think this would be a better solution in the long-run.

	If the port maintainer does not want/cannot do the work
	for this, I can submit a patch if asked.  I'm being
	lazy right now.  :-) Let me know.
How-To-Repeat: 	Set smartd_flags="/some/other/smartd.conf" in rc.conf.
	Attempt to start smartd via smartd.sh start.
Comment 1 vs freebsd_committer 2005-08-01 08:28:37 UTC
Dear maintainer, please look into this issue!

Cheers,
   Volker
Comment 2 vs freebsd_committer 2005-08-01 08:28:54 UTC
State Changed
From-To: open->feedback

Forwarded PR to maintainer
Comment 3 martines 2005-09-20 22:10:10 UTC
Sorry, this got lost in my email.  I will look into this shortly.

Ed

Volker Stolz wrote:
> Dear maintainer, please look into this issue!
> 
> Cheers,
>   Volker
Comment 4 mnag freebsd_committer 2005-10-08 15:46:32 UTC
Dear maintainer,

Some news about this problem?

http://www.freebsd.org/cgi/query-pr.cgi?pr=83135

Thanks

-- 
Marcus Alves Grando
marcus(at)corp.grupos.com.br  |  Grupos Internet S/A
  mnag(at)FreeBSD.org         |  FreeBSD.org
Comment 5 Florent Thoumie freebsd_committer 2005-11-17 22:04:47 UTC
State Changed
From-To: feedback->closed

I committed a fix, should be ok now.  Thanks for your report.