PDA

View Full Version : won't give up, SC on SME7



yank
2008-03-19, 09:30
Evening..
Just tried to install Squeezecenter on a SME7.3, install went allright, however all the directories are owned by root, and that's a bad, isn't it?
When calling the homepage, it isn't found. Tried the yum approach and the rpm -Uvh.
perl -v mentioned 5.8.5 and the box is up to date. The earlier slimserver 5.6 was running without any probs before the update, and yes, I've followed the install page!
Now I'm stuck, any help would be welcome..
--

mherger
2008-03-19, 09:38
> Just tried to install Squeezecenter on a SME7.3, install went allright,
> however all the directories are owned by root, and that's a bad, isn't
> it?

That's fine. I have been running SC7 on 7.3 for a few months now.

> Now I'm stuck, any help would be welcome..

/var/log/squeezecenter/server.log would be of great help

--

Michael

yank
2008-03-19, 09:58
> Just tried to install Squeezecenter on a SME7.3, install went allright,
> however all the directories are owned by root, and that's a bad, isn't
> it?

That's fine. I have been running SC7 on 7.3 for a few months now.

> Now I'm stuck, any help would be welcome..

/var/log/squeezecenter/server.log would be of great help

--

Michael

Yes, of course. But the directory is empty.
Just tried to remove the package and did a second install as root, with the same result.No log..
Message log OK: Mar 19 17:49:18 hell yum: Installed: squeezecenter.noarch 7.0-1
--

Mark Miksis
2008-03-19, 10:03
Yes, of course. But the directory is empty.

That means it's not starting at all. How are you trying to start it?

mherger
2008-03-19, 10:08
> Yes, of course. But the directory is empty.
> Just tried to remove the package and did a second install as root, with
> the same result.

You never mentioned you actually tried to start squeezecenter. Does it crash immediately? What happens?

What would happen if you "chmod squeezecenter:squeezecenter" the various SC folders?

--

Michael

Mark Miksis
2008-03-19, 10:11
What would happen if you "chmod squeezecenter:squeezecenter" the various SC folders?

That really shouldn't be necessary.

yank
2008-03-19, 10:36
> Yes, of course. But the directory is empty.
> Just tried to remove the package and did a second install as root, with
> the same result.

You never mentioned you actually tried to start squeezecenter. Does it crash immediately? What happens?

What would happen if you "chmod squeezecenter:squeezecenter" the various SC folders?

--

Michael

Oops! my mistake, trying to start service squeezecenter, but that isn't the right way anymore..

[root@hell init.d]# ./squeezecenter start
Starting SqueezeCenter: [ OK ]

And the beast is running..
LOL, me stupid

But to enforce squeezecenter to run on startup/boot, do you have a startup script? Or is it taken care by the install? No dedicated SME script on the wiki pages..
--

Mark Miksis
2008-03-19, 10:47
Oops! my mistake, trying to start service squeezecenter, but that isn't the right way anymore..

Yes, it should be (assuming that SME has the /sbin/service command like all other RH derivatives). "/sbin/service squeezecenter start" should do the same thing as "/etc/init.d/squeezecenter start".


But to enforce squeezecenter to run on startup/boot, do you have a startup script? Or is it taken care by the install? No dedicated SME script on the wiki pages..

The /etc/init.d/squeezecenter script installed by the RPM should be fine and should set squeezecenter to automatically start on boot. If you reboot your SME server, does SC start?

Can you confirm that SME has the following commands:
/sbin/service
/sbin/chkconfig

mherger
2008-03-19, 10:51
> [root@hell init.d]# ./squeezecenter start
> Starting SqueezeCenter: [ OK ]
>
> And the beast is running..

Well done :-)

> But to enforce squeezecenter to run on startup/boot, do you have a
> startup script? Or is it taken care by the install?

Don't you have something like /etc/rc7.d/S98SqueezeCenter? I'm not sure whether it should be created automatically by the .rpm file (my installation dates back a few months). In case it didn't:

ln -s /etc/init.d/squeezecenter /etc/rc7.d/S98SqueezeCenter

should do the trick.

--

Michael

Mark Miksis
2008-03-19, 10:58
Don't you have something like /etc/rc7.d/S98SqueezeCenter? I'm not sure whether it should be created automatically by the .rpm file (my installation dates back a few months). In case it didn't:

ln -s /etc/init.d/squeezecenter /etc/rc7.d/S98SqueezeCenter

should do the trick.

The RPM runs chkconfig during %post to create the proper runlevel symlinks.

yank
2008-03-19, 11:08
Yes, it should be (assuming that SME has the /sbin/service command like all other RH derivatives). "/sbin/service squeezecenter start" should do the same thing as "/etc/init.d/squeezecenter start".



The /etc/init.d/squeezecenter script installed by the RPM should be fine and should set squeezecenter to automatically start on boot. If you reboot your SME server, does SC start?

Can you confirm that SME has the following commands:
/sbin/service
/sbin/chkconfig

Confirmed!
[root@hell /]# /sbin/service
Usage: service < option > | --status-all | [ service_name [ command | --full-restart ] ]
[root@hell /]# /sbin/chkconfig
chkconfig version 1.3.13.5.EL4 - Copyright (C) 1997-2000 Red Hat, Inc.
This may be freely redistributed under the terms of the GNU Public License.

usage: chkconfig --list [name]
chkconfig --add <name>
chkconfig --del <name>
chkconfig [--level <levels>] <name> <on|off|reset>
[root@hell /]
But after reboot, no service running!, have to start the squeezecenter manual, trying to start the service;
/sbin/service squeezecenter start
results in
'squeezecenter' is not a valid service name
(/etc/init.d/squeezecenter start is good)

How to make squeezecenter running as a service, that's the question..

And yes; all other things are running as services, mail, clamav and the whole lot..

And thank you, the both of you..
--
Edit:
> Don't you have something like /etc/rc7.d/S98SqueezeCenter?
No, but;
lrwxrwxrwx 1 root root 27 Sep 13 2007 S99slimserver -> /etc/rc.d/init.d/slimserver
Is that the one? Looks like something wrong with the soup?
--

Mark Miksis
2008-03-19, 11:18
But after reboot, no service running!, have to start the squeezecenter manual, trying to start the service;
/sbin/service squeezecenter start
results in
'squeezecenter' is not a valid service name
(/etc/init.d/squeezecenter start is good)

How to make squeezecenter running as a service, that's the question..

Weird. Were there any errors during the RPM install? Does it work properly if (as root) you run "/sbin/chkconfig --add squeezecenter"?

I've tested the RPM on CC4.2 and CentOS4, but not SME. I'll install it this weekend and do some testing.

yank
2008-03-19, 11:40
Weird. Were there any errors during the RPM install? Does it work properly if (as root) you run "/sbin/chkconfig --add squeezecenter"?

I've tested the RPM on CC4.2 and CentOS4, but not SME. I'll install it this weekend and do some testing.

Hmm.. thank you again..
Could it be, by NOT stopping the (old) running slimserver, before the SC install, this could happen?
No errors after the RPM install attemp, nor after the Yum install. But I did NOT check the server.log after the RPM install. Both gave me the same result, so I thought it had to do with the old issue on access restrictions on the squeeze dirs.
(Somewhere on the forum, reading thread on difference slimserver/squeezecenter user etc etc.)

and /sbin/chkconfig --add squeezecenter doesn't result in output, no

Mark Miksis
2008-03-19, 11:46
Hmm.. thank you again..
Could it be, by NOT stopping the (old) running slimserver, before the SC install, this could happen?
No errors after the RPM install attemp, nor after the Yum install. But I did NOT check the server.log after the RPM install. Both gave me the same result, so I thought it had to do with the old issue on access restrictions on the squeeze dirs.
(Somewhere on the forum, reading thread on difference slimserver/squeezecenter user etc etc.)

When the old slimserver RPM is removed, it should stop itself and then run chkconfig to remove the old symlinks. It seems that for some reason the "chkconfig --del slimserver" from the old RPM and the "chkconfig --add squeezecenter" from the new RPM both failed to run.


and /sbin/chkconfig --add squeezecenter doesn't result in output, no

I'm not sure if there's any out put on success. But, does "/sbin/service squeezecenter start" now work, and does it now start on reboot?

yank
2008-03-19, 12:38
When the old slimserver RPM is removed, it should stop itself and then run chkconfig to remove the old symlinks. It seems that for some reason the "chkconfig --del slimserver" from the old RPM and the "chkconfig --add squeezecenter" from the new RPM both failed to run.



I'm not sure if there's any out put on success. But, does "/sbin/service squeezecenter start" now work, and does it now start on reboot?

yes, it does start on reboot, the file S98SqueezeCenter is created, however 'sbin/service squeezecenter start' still gives a
"'squeezecenter' is not a valid service name" as result. The old S99slimserver is still flashing, not shure about that..

Mark Miksis
2008-03-19, 12:50
yes, it does start on reboot, the file S98SqueezeCenter is created, however 'sbin/service squeezecenter start' still gives a
"'squeezecenter' is not a valid service name" as result.

Hrm. It should be S80squeezecenter. Any chance you previously installed a different squeezecenter RPM from a different source? Or manually installed a different squeezecenter init script? Take a look at /etc/init.d/squeezecenter and see if it has a line like this:


# chkconfig: 345 80 30

yank
2008-03-19, 13:14
Hrm. It should be S80squeezecenter. Any chance you previously installed a different squeezecenter RPM from a different source? Or manually installed a different squeezecenter init script? Take a look at /etc/init.d/squeezecenter and see if it has a line like this:


# chkconfig: 345 80 30

check!
[root@hell init.d]# more squeezecenter
#!/bin/bash
#
# squeezecenter Startup script for the SqueezeCenter Music Server
#
# chkconfig: 345 80 30

And after a few cups of strong and bitter coffee; Yes I did tried an early SC7 once, but ran into all kinds of problems, some time ago, while still in beta stage. Removed the whole package and went on with the trusty 6.5. So sorry for not telling all of the story, but this left my mind a long time ago...

Mark Miksis
2008-03-19, 13:49
OK, thanks. It looks like it's mostly working as expected for you.

I still can't image how an early version of the RPM could cause chkconfig to create a S98SqueezeCenter file. I'll see if I can reproduce any of this and report back.

yank
2008-03-19, 14:11
OK, thanks. It looks like it's mostly working as expected for you.

I still can't image how an early version of the RPM could cause chkconfig to create a S98SqueezeCenter file. I'll see if I can reproduce any of this and report back.

Looking forward,
again; thanks for all the trouble..
--

mherger
2008-03-19, 15:13
>> I still can't image how an early version of the RPM could cause
>> chkconfig to create a S98SqueezeCenter file.

You mean because I have it? Don't worry about my installation: maybe I did
the first 7.0 installation _before_ you reworked the rpm. Possibly I even
had to create that link myself, and it survived ever since?

Michael

Mark Miksis
2008-03-21, 12:52
OK, I see the problem. I would have noticed it earlier if I had read Michael's post more carefully - sorry I missed the reference to rc7.d. The root cause of the problem is that SME uses runlevel 7 - which is unusual. The RPM sets the service to start in runlevels 3, 4 and 5. But, the RPM and chkconfig make no attempt to do anything with runlevel 7 (which doesn't exist on most systems anyway).

I'll assume that any symlinks you have to SC or SS in rc7.d were created manually. The workaround, as Michael suggested earlier in the discussion, is to add a symlink to start SC in runlevel 7. To be consistent with the other symlinks that the RPM creates automatically, I suggest:


ln -s /etc/init.d/squeezecenter /etc/rc7.d/S80squeezecenter

The necessary K symlink in rc6.d should already be there.

Some googling suggests that when manually adding a service something like this is also required:


db configuration set squeezecenter service status enabled

I'm not sure what that does and it seems to work fine for me without it. Can either of you SME users explain what that does?

I should be able to add a couple of lines to the RPM to detect SME and create the runlevel 7 symlink (and remove it on uninstall).

Mark Miksis
2008-03-24, 10:12
Michael, yank,

Can either of you comment on my question above about the possible need for the "db configuration..." command? I'm planning to add an SME-specific fix to the 7.0.1 RPM, but I'd like to understand that part first.

mherger
2008-03-24, 13:22
Some googling suggests that when manually adding a service something like this is also required:


db configuration set squeezecenter service status enabled

I'm not sure what that does and it seems to work fine for me without it. Can either of you SME users explain what that does?

Most of SME's configuration is driven by its own config file management. In fact, most of the files in /etc/ are created using some scripts and templates. /home/e-smith/db/configuration is the most important configuration file which is used to create the files in /etc/. Thus I would imagine that the above line will make sure, SME would re-create the link whenever the configuration scripts are run (after updates, re-configuration etc.). It's the SME way of configuring the system.

Mark Miksis
2008-03-27, 10:50
OK, change 18095 (in 7.0/trunk) should take care of setting up the symlinks automatically (and removing them on uninstall). I won't have time to test until tomorrow, but it's trivial enough that I checked it in so it'll be in tomorrow's 7.0.1 RPM.

FYI, if you've created any rc7.d symlinks manually, you should delete them before switching to the new RPM. Otherwise you may have multiple symlinks which will try to start SC multiple times.

widman
2008-03-27, 11:47
> [root@hell init.d]# ./squeezecenter start
> Starting SqueezeCenter: [ OK ]
>
> And the beast is running..

Well done :-)

> But to enforce squeezecenter to run on startup/boot, do you have a
> startup script? Or is it taken care by the install?

Don't you have something like /etc/rc7.d/S98SqueezeCenter? I'm not sure whether it should be created automatically by the .rpm file (my installation dates back a few months). In case it didn't:

ln -s /etc/init.d/squeezecenter /etc/rc7.d/S98SqueezeCenter

should do the trick.

--

Michael

I upgraded to SC7 a couple of weeks ago on my SME box and creating the symlink as shown above worked for me.

pete

yank
2008-03-30, 14:25
I upgraded to SC7 a couple of weeks ago on my SME box and creating the symlink as shown above worked for me.

pete

Back in town; sorry for the delay, Easter hollidays are over.
But back to reality; Server crashed due to shortage of disc space, so I did a fresh SME7 install and SC on new disc. As mentioned by pete, the only thing I had to do was to add the symlink.
So previous problems, on my side, lied somewhere in the leftovers from earlier SC7Beta installs, I see no other reason.

But what the heck, server up and running, but backup? what backup...?
Well, time to refresh the music collection!
Thanks for all the help, much appreciated..
--