Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I am trying to change default log location ( var/svc/logs/) of each and every SMF registered processes and append to particular file (/opt/smf.log).

share|improve this question

migrated from stackoverflow.com Mar 1 '11 at 5:34

This question came from our site for professional and enthusiast programmers.

    
@Banti are you referring to this Service Management Facility ? SMF is an ambiguous acronym, which also means Simple Machines Forum. –  xenoterracide Mar 1 '11 at 10:17
    
@xenoterracide Actually i had posted this question in solaris so, SMF should be considered as Service management facility :) –  user5229 Mar 1 '11 at 11:26
    
@Gyan answers are not comments ;) . I migrated it. –  xenoterracide Mar 1 '11 at 14:18
add comment

1 Answer 1

That file path appears to be compiled into svc.startd:

myhostname# strings /lib/svc/bin/svc.startd |grep '/var/svc/log'
/var/svc/log/
/var/svc/log/
/var/svc/log/
/var/svc/log/

I suppose you could try changing the location of the directory to somewhere else, and make /var/svc/log a symlink to the new location, but I don't believe it's possible to make the services all log to one file -- that's just not how SMF was designed to work. And since svc.startd starts early in the boot process, before /var is even mounted read-write, linking /var/svc/log to some other -- possibly even unmounted -- partition may cause trouble.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.