PDA

View Full Version : Restart Slimserver from Command line



pc4ever1
2006-09-20, 10:53
I'm having problems having version SS 6.5.1 stop when I'm playing music remotely. This doesn't happen all the time but when it does I would like to use the command line to "restart" slimserver. I'm currently using VNC to do this but I want to simplify this process by using the command line.

Background:
**************
I have OpenSSH installed on my Windows XP system


I have tried to use some commands via "putty/ssh" and got the following errors.

C:\Program Files\SlimServer\server>slim.exe -remove
OpenSCManager failed: Access is denied

C:\Program Files\SlimServer\server>slim.exe
2006-09-20 10:43:47.2052 C:\Program Files\SlimServer\server\Cache\my.cnf: Permission denied at /PerlApp/Slim/Utils/MySQLHelper.pm line 164.

Could someone tell me what I can do to correct this.

Is there a direct command to "restart" slimserver from the command line?

I have printed out all the commands from slim.exe --help and didn't recognize anything to restart slimserver.

TIA

JJZolx
2006-09-20, 11:20
Is there a direct command to "restart" slimserver from the command line?

I have printed out all the commands from slim.exe --help and didn't recognize anything to restart slimserver.
Does SlimServer running as a service on your system? If so, you'll want to start up the SlimServer service.

net start slimvc

To restart a running server, you'd need to stop it first with

net stop slimsvc

But you may get the same error message that you get when running slim.exe directly. My guess is that the crashing SlimServer is somehow leaving a lock on the my.cnf file (which I believe SlimServer rewrites when it starts up). You can try to delete the file before restarting SlimServer, but inadvertent file locks can sometimes be a PITA to deal with.

Paul_B
2006-09-20, 12:30
For locked files in XP have a look at unlocker, http://ccollomb.free.fr/unlocker/ or ProcessXP (not for the faint hearted) http://www.sysinternals.com/Utilities/ProcessExplorer.html