PDA

View Full Version : SB connect probs w/ FC7



bucketbanger
2007-07-18, 18:16
rI'm having a host of problems, probably all interrelated.

1) Slimserver will not run as daemon or root but will run from my command line. Trying to start from root (to get error messages) produces:
# ./slimserver.pl --diag
2007-07-18 21:04:22.6851 ERROR: Cannot write to preferences file /root/slimserver.pref, any changes made will not be preserved for the next startup of the server

2007-07-18 21:04:22.6853 Use of uninitialized value in negation (-) at /usr/local/slimserver/Slim/Utils/Misc.pm line 1155.
2007-07-18 21:04:22.6858 Use of uninitialized value in join or string at /usr/lib/perl5/5.8.8/File/Spec/Unix.pm line 81.
2007-07-18 21:04:22.6859 Use of uninitialized value in join or string at /usr/lib/perl5/5.8.8/File/Spec/Unix.pm line 81.
2007-07-18 21:04:22.7951 Use of uninitialized value in join or string at /usr/lib/perl5/5.8.8/File/Spec/Unix.pm line 81.
2007-07-18 21:04:22.7953 Use of uninitialized value in join or string at /usr/lib/perl5/5.8.8/File/Spec/Unix.pm line 81.
2007-07-18 21:04:22.7954 Use of uninitialized value in join or string at /usr/lib/perl5/5.8.8/File/Spec/Unix.pm line 81.
2007-07-18 21:04:22.7955 Use of uninitialized value in join or string at /usr/lib/perl5/5.8.8/File/Spec/Unix.pm line 81.
2007-07-18 21:04:22.7956 Use of uninitialized value in join or string at /usr/lib/perl5/5.8.8/File/Spec/Unix.pm line 81.
Uncaught exception from user code:
mkdir /MySQL: Permission denied at /usr/local/slimserver/Slim/Utils/MySQLHelper.pm line 156
at /usr/lib/perl5/5.8.8/File/Path.pm line 168
File::Path::mkpath('/MySQL') called at /usr/local/slimserver/Slim/Utils/MySQLHelper.pm line 156
Slim::Utils::MySQLHelper::createConfig('Slim::Util s::MySQLHelper', 'undef') called at /usr/local/slimserver/Slim/Utils/MySQLHelper.pm line 98
Slim::Utils::MySQLHelper::init('Slim::Utils::MySQL Helper') called at ./slimserver.pl line 360
main::init() called at ./slimserver.pl line 443
main::main() called at ./slimserver.pl line 1069
Use of uninitialized value in sprintf at /usr/local/slimserver/Slim/Utils/MySQLHelper.pm line 467.

Trying to start SS as daemon fails silently. Starting SS manually works just fine and the web interface pops up with no problems, except:

2) SB3 cannot find SS. It's not a network problem, since I can connect to SqueezeNetwork just fine. Netstat doesn't seem to indicate a problem:

$ netstat -na | grep 9000
tcp 0 0 0.0.0.0:9000 0.0.0.0:* LISTEN
tcp 0 0 127.0.0.1:9000 127.0.0.1:36002 ESTABLISHED
tcp 0 0 127.0.0.1:9000 127.0.0.1:36001 ESTABLISHED
tcp 0 0 127.0.0.1:36002 127.0.0.1:9000 ESTABLISHED
tcp 0 0 127.0.0.1:36001 127.0.0.1:9000 ESTABLISHED

My hunch is that this is related to SELinux, since I was having problems with that earlier. Any advice?

thanks,
Paul

bucketbanger
2007-07-20, 14:54
OK, so I've determined the connection problem is the firewall. For some reason System/Administration/Firewall and SELinux doesn't actually take down the firewall, even though there's the button that says "Disable Firewall". Stopping the iptables services actually does bring down the firewall, allowing the connection. Now I just need to amend my iptables chains manually--anyone got any advice on that?

Still don't understand why I can't run in daemon mode.

mikeruss
2007-07-22, 03:46
Have you tried disabling selinux?

vi etc/selinux/config


# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - SELinux is fully disabled.
SELINUX=disabled
# SELINUXTYPE= type of policy in use. Possible values are:
# targeted - Only targeted network daemons are protected.
# strict - Full SELinux protection.
SELINUXTYPE=targeted

# SETLOCALDEFS= Check local definition changes
SETLOCALDEFS=0

You will then need to reboot from memory.

Robin Bowes
2007-07-22, 04:26
mikeruss wrote:
> Have you tried disabling selinux?
>
> vi etc/selinux/config
>
>
> # This file controls the state of SELinux on the system.
> # SELINUX= can take one of these three values:
> # enforcing - SELinux security policy is enforced.
> # permissive - SELinux prints warnings instead of enforcing.
> # disabled - SELinux is fully disabled.
> SELINUX=disabled
> # SELINUXTYPE= type of policy in use. Possible values are:
> # targeted - Only targeted network daemons are protected.
> # strict - Full SELinux protection.
> SELINUXTYPE=targeted
>
> # SETLOCALDEFS= Check local definition changes
> SETLOCALDEFS=0

A less invasive way of trying it without SELinux is to execute:

setenforce 0

....and then start slimserver.

Better yet, install audit (if not already installed):

yum install audit
service auditd start
chkconfig auditd on

Start slimserver, and check /var/log/audit/audit.log for errors. e.g.:

audit2allow -i /var/log/audit/audit.log -l

R.