# rc.conf only enables certain daemons.  FBSD 7.2 beta



## dejamuse (Apr 9, 2009)

I've been playing around with PCBSD 7.1 RC1 lately and generally find it quite stable, but there are a few bugs typical of a beta release.

For example, PCBSD ignores new entries into rc.conf for autostarting apache, webmin, mysql, etc. when installed from packages/ports.

But installing Webmin, for example, from PBI, autostarts ok.

The new rc.conf entries are:
Code:
webmin_enable="YES"
mysql_enable="YES"
apache22_enable="YES"

System entries, such as ifconfig, pf firewall, powerd, samba, and the moused work fine. Weird.

I have to manually start these 3 daemons with their rc.d scripts.

This is a new fresh install of PCBSD 7.1 - RC1 which is FBSD 7.2 beta under the hood.

Anybody have an idea what's wrong?  Could be a system configuration goof by PCBSD, but I'm looking for any hint as to what FBSD might be doing to cause this.

Tnx, Jeff


----------



## ale (Apr 9, 2009)

What is the output of `$ grep ^local\.startup /etc/defaults/rc.conf /etc/rc.conf` ?


----------



## SirDice (Apr 9, 2009)

For any of the ports have a look at the scripts in /usr/local/etc/rc.d/ that's where they all get started.


----------



## dejamuse (Apr 9, 2009)

I can manually start any of the daemons using the rc.d scripts so they are all fine.  The output of grep is:

% grep ^local\.startup /etc/defaults/rc.conf /etc/rc.conf

/etc/defaults/rc.conf:local_startup="/usr/local/etc/rc.d" # startup script dirs.


----------



## ale (Apr 9, 2009)

Is there anything meaningful in the logs?


----------



## dejamuse (Apr 9, 2009)

Nothing in the logs, but I also couldn't figure out if the logs would record anything during boot.  I tried to create one with various reporting options but nothing showed up.  Watching the console output fly by, I can't see the 3 daemons starting.  Seems to me there is a way to single step through that process, but I can't remember how to do it.


----------



## ale (Apr 9, 2009)

Start with `$ dmesg -a | grep Starting`


----------



## danger@ (Apr 9, 2009)

I've read that PCBSD folks have somehow separated the PBI and ports packages from the system in the recent beta version. I suspect this might be a bug, I would recommend you to go to their forums and report it there.


----------



## dejamuse (Apr 10, 2009)

Yes, you are right and I suspected as much.  They did change the setup.  Here's the explanation:

If you install apps via ports, you need to make a sym-link from /usr/local/etc/rc.d/<script> -> /PCBSD/local/etc/rc.d/

The problem is that we don't parse /usr/local/etc/rc.d by default, since if you have duplicate scripts in /PCBSD/local/etc/rc.d and /usr/local/etc/rc.d, both will get run, often with disastrous results


----------



## dejamuse (Apr 10, 2009)

This is emblematic of a larger issue exclusive of PCBSD I've discovered.

Amarok and Akonadi both use MySQL. If you happen to be running a development server as I do (Drupal) you will install MySQL configured the way you want it, but you may not be aware that MySQL is already installed and running, by KDE.  You then start everything up and it's fine but you don't realize that since the KDE version of MySQL started first (you manually started the 2nd version but it didn't actually start or complain), the socket and port for the first instance of MySQL gets used.  

The solution is to run the whole Drupal environment in a jail.  Just a side note - PCBSD has a very convenient PBI called the Warden that is a simple GUI interface to jail setup and management.  It's not yet available in ports.


----------

