spacer
spacer search

SwissCenter

Search
spacer
Main Menu
Home
Documentation + FAQ
Screenshots
Downloads
Forums
Bug Tracking
History
Login
Username

Password

Remember me
?
No account yet?

Locations of visitors to this page

 
Home arrow Forums

SwissCenter Forums  


swisscenter works on synology NAS - 2006/09/16 11:09 Recently, www.synology.com has released new firmwares for their NAS (even old models) that (among others) added the following functionality: webserver with php and mysql support. I have then tried to install the swisscenter on my DS-101 - and it worked!!

However some patching was necessary.

I'd like to tell you what I had to patch and what specialities come with the DS-101 regarding the swisscenter.

Synology DS-101 firmware:

v2.0.1-.3.0371


php info

file included


mysql info

server version 4.1.15


media locations

use the following paths for media locations on the built-in hdd:
/volume1/share/path
replace "share" with the name of your share (i.e. "public")
replace "path" with the actual path


shell_exec

does not work on the DS-101. but exec() works ok. the function php_cli_location() which uses shell_exec had to be hacked. I replaced the line "$location = trim(shell_exec("which php php4 | grep '^/' | head -1"));"
by the following "$location= '/usr/syno/bin/php';"
NOTE: there is no file at this location.


php cli-version / media search

there is no cli-version of php on the DS-101. only mod_php5 seems to be present. for the media search process, I have called http://host/media_search.php manually. Since there is no cli-version of php, you could implement the same with wget:
exec('wget -bnv --read-timeout=86400 http://diskstation/media_search.php');


streaming

the symbolic links in the "media" folder worked ok for the php process. But the webserver did not follow these symlinks. I have made a quick and dirty hack to stream.php which worked for my Neuston MC-500 client:
Instead of redirecting the client to the symlinked file, I made a hardlink to the requested file and redirected to it instead.

replace the following line:
"header ("location: ".$server.$redirect_url);"

by the following 3 lines:
"
$dest= sprintf('temp/file%s', $req_ext);
exec(sprintf('ln -f %s %s', escapeshellarg($location), escapeshellarg($dest)));
header ("location: ".$server.make_url_path($dest));
"

To make this work for other users, they had to create a folder "temp" in the root of swisscenter.

the quick part: only 3 lines need to be inserted.
the dirty part: you cannot access more than one file of each type simultaneously. Only 1 client at one given time is supported. But it shouldn't be difficult to develop a decent solution for this.


general note:
my unzip application (tugzip 3.3 freeware) didn't extract the empty folders from the swisscenter package. I had to create the "log" folder myself to make http://host/config work - it showed only a cryptic error message before that. maybe you could place a dummy file in that empty folder to ensure extraction.


finally, I'd like to thank you very much for that fine swisscenter! I would be happy if my informations above are useful to you. I can give you additional information. Just contact me.

Kind regards
Michael
File Attachment:
File name: phpinfo.pdf
File size:74191 bytes
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/09/18 12:26 For performance reasons, one should remove the following lines in base/media.php when using a slow NAS:

send_to_log(6,'Pre-caching thumbnail');
precache($dir.$file, convert_x(THUMBNAIL_X_SIZE), convert_y(THUMBNAIL_Y_SIZE) );

On my ds-101, each picture took approx. 3-4 minutes...

Since the DS-101 comes with the photo-station (a built-in web application) which implements a much faster thumbnail generation I will try to make the swisscenter use it instead of the GDlib.

Greetings,
Michael
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/09/26 14:00 If you figure out how to get the "photo-station" to generate thumbnails then let me know how it works and I could incorporate some code specifically for the DS-101. Player : Pinnacle Showcenter 200 and 1000 (wired ethernet)
Server : Windows XP Pro running on an Athlon XP 2200, 768 Mb RAM, 1.8 Tb storage.

  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/10/01 10:31 I've just had a deeper look at the thumbnail generation that the Synology Diskstation (DS-101) uses for its photo web application.

Synology uses the (binary) utility "synothumb" for that purpose.

location: /usr/syno/bin/synothumb

syntax:

synothumb -size heightxwidth [ height2xwidth2 ] -type -src path/to/file.jpg [ another/file.jpg ... ] -pnum nr

width, height, width2, height2: desired width and height of thumbnails.
type: small, big, smallbig, bigsmall
path/to/file.jpg: source file
nr: the number of parallel process creating thumbnails

what it does:

synothumb generates smaller versions of images. synothumb is much faster than p.e. ImageMagick. This performance gain has a down side: synothumb cannot generate thumbnails of arbitrary width and height as ImageMagick does. Instead it divides the original width and height by multiples of 2. (The calculation of the resized images is much simpler this way).
so p.e. if your source image is 1024x768: synothumb could create the following thumbnails for you: 512x384, 256x192, 128x96, etc.
synothumb tries to generate the smallest possible thumbnail that is not smaller than the dimensions you specify.
General: The synology photo web application divides the task of creating thumbnails between server and client. the server with very limited cpu power tries to reduce the image size as much as possible and as fast as possible, while the browser of the client has to handle the rest (resizing the generated thumbnail to the exact dimensions)

destination files:

synothumb creates the folder "@eaDir" in the folder of the source file(s). Within "@eaDir" it creates another folder named after the source filename p.e. "file.jpg". Within "file.jpg" it creates one or two thumbnails named SYNOPHOTO:THUMB_B.jpg (the "big" thumb) and SYNOPHOTO:THUMB_S.jpg (the "small" thumb) respectively.

Once the folder "file.jpg" exists, synothumb won't recreate the thumbnails - even if you specify other dimensions. You have to delete the folder "file.jpg" containing the thumbnail(s) to force synothumb to go to work.

meaning of parameter "type":
if you specify "-small": synothumb expects width and height and creates the thumb SYNOPHOTO:THUMB_S.jpg
if you specify "-big": synothumb expects width and height and creates the thumb SYNOPHOTO:THUMB_B.jpg
if you specify "-smallbig": synothumb expects width, height, width2 and height2 and creates the thumbs SYNOPHOTO:THUMB_S.jpg (using width and height) and SYNOPHOTO:THUMB_B.jpg (using width2 and height2)
if you specify "-bigsmall": synothumb expects width, height, width2 and height2 and creates the thumbs SYNOPHOTO:THUMB_S.jpg (using width2 and height2) and SYNOPHOTO:THUMB_B.jpg (using width and height)

example:
> rm -r /volume1/public/thumbtest/@eaDir/pic.jpg
> /usr/syno/bin/synothumb -size 50x100 200x300 -smallbig -src /volume1/public/thumbtest/pic.jpg -pnum 1


Image file support:
jpg (24bit color, non progressive): works
png: partly (thumbnails have the same size as the original)
everything else: untested

Note: The aspect ratio of the source file is constrained

I hope that helps. If you need more information, just drop a line

Kind regards
Michael
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/10/14 07:03 Appologies in advance if I'm seem supremely thick, but here goes.

I've been running SwissCenter on a windows machine for about a year without any issues.

I took delivery of a Synology 106e & want to move SwissCenter to it. I downloaded the latest Linux version, setup the web server,php & MySQL to run on it. Everything is at default, share name etc.

I've installed SC into the root of the web folder, & I think/hope, I've edited the correct files from the info in this post

shell_exec

does not work on the DS-101. but exec() works ok. the function php_cli_location() which uses shell_exec had to be hacked. I replaced the line "$location = trim(shell_exec("which php php4 | grep '^/' | head -1"));"
by the following "$location= '/usr/syno/bin/php';"
NOTE: there is no file at this location.


Is this the /base/file.php ? If so, then I've edited correctly.

replace the following line:
"header ("location: ".$server.$redirect_url);"

by the following 3 lines:
"
$dest= sprintf('temp/file%s', $req_ext);
exec(sprintf('ln -f %s %s', escapeshellarg($location), escapeshellarg($dest)));
header ("location: ".$server.make_url_path($dest));
"


Is this /stream.php ? If so, done it correct.

media locations

use the following paths for media locations on the built-in hdd:
/volume1/share/path
replace "share" with the name of your share (i.e. "public")
replace "path" with the actual path


I've left the defaults, so my share is named public & the media is in a sub directory called TV. Full path /volume1/public/TV

Here's my problems, I can access the SC config page. BUT, when I try to put ANY location in for the media I get errors.

The first error which appears across the top of the media location page when I submit the location is

Warning: unlink(/volume1/web/media/1) [function.unlink]: No such file or directory in /volume1/web/config/config_dirs.php on line 134

Warning: symlink() [function.symlink]: open_basedir restriction in effect. File(/volume1/public/media/TV) is not within the allowed path(s): (/volume1/web:/volume2/web:/volume3/web:/volume4/web:/volume1/photo:/volume2/photo:/volume3/photo:/ volume4/photo:/usr/syno/synoman/phpsrc:/etc:/var/run:/tmp:/var/spool/php:/volume1/@tmp/php) in /volume1/web/config/config_dirs.php on line 135


???? It then says in green that the location has been added?

php cli-version / media search

there is no cli-version of php on the DS-101. only mod_php5 seems to be present. for the media search process, I have called http://host/media_search.php manually. Since there is no cli-version of php, you could implement the same with wget:
exec('wget -bnv --read-timeout=86400 http://diskstation/media_search.php');


When I run the media_search, there is disc activity on the 106, so something is happening. Yet, when I access the SC, there are no media catagories listed, no files listed to play. The SC is totally devoid of any media to play? Yet, in the TV folder there are avi files to play.

Any ideas?

Also, is it posible to use storage on another machine for storing media files on? How do you add those locations? For example, on my media center I have another hard drive, shared with films on it. The windows UNC location is

\\Mediactr\mediactr-f-media\Movies

If I try to enter that or

//Mediactr/mediactr-f-media/Movies

I get the error that the location doesn't exists?

Cheers

Neo
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/10/15 04:59 Neophyte wrote:
shell_exec

does not work on the DS-101. but exec() works ok. the function php_cli_location() which uses shell_exec had to be hacked. I replaced the line "$location = trim(shell_exec("which php php4 | grep '^/' | head -1"));"
by the following "$location= '/usr/syno/bin/php';"
NOTE: there is no file at this location.


Is this the /base/file.php ? If so, then I've edited correctly.


You only have to do this when you have no "which" on your DS". I IpKg'ed "which" and just changed the shell_exec to exec. Works but which doesn't find a PHP CLI as there is none on the DS. The installation check of SC detects this but works anyway. You just have to update the media manually. Anyone know anyway to get a PHP CLI on the DS?

replace the following line:
"header ("location: ".$server.$redirect_url);"

by the following 3 lines:
"
$dest= sprintf('temp/file%s', $req_ext);
exec(sprintf('ln -f %s %s', escapeshellarg($location), escapeshellarg($dest)));
header ("location: ".$server.make_url_path($dest));
"


For me this hack didn't work. I then tried the original code and it worked instantly.

Warning: unlink(/volume1/web/media/1) [function.unlink]: No such file or directory in /volume1/web/config/config_dirs.php on line 134

Warning: symlink() [function.symlink]: open_basedir restriction in effect. File(/volume1/public/media/TV) is not within the allowed path(s): (/volume1/web:/volume2/web:/volume3/web:/volume4/web:/volume1/photo:/volume2/photo:/volume3/photo:/ volume4/photo:/usr/syno/synoman/phpsrc:/etc:/var/run:/tmp:/var/spool/php:/volume1/@tmp/php) in /volume1/web/config/config_dirs.php on line 135


php only processes files within the folders defined in the variable open_basedir (in php.ini). You either have to use one of these folders (or make a subfolder there) or you can edit open_basedir to contain your mediafolder as well. /volume1/public isn't in open_basedir by default. I made a subfolder there and included it.

???? It then says in green that the location has been added?

This seems to be normal for SC. Delete those fake entries, fix open_basedir and add them again. They are only added if there's no error message. That why the media-search doesn't find anything.

php cli-version / media search
Also, is it posible to use storage on another machine for storing media files on? How do you add those locations? For example, on my media center I have another hard drive, shared with films on it. The windows UNC location is

If you can link it into the linux filesystem of the DS it should work. Just remember that the open_basedir fix has to be applied here as well.

Crowley
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/10/15 14:13 Hi mbuergi !

Thanks a lot for your topic about Swisscenter on a Synology NAS.

I have a Syno 101j and a Neuston MC500.
I followed every step in your tread, but still it doesnt work the way it should.

When i install Swisscenter in the web root (volume1/web) everything is extreeeeemly slow ! When i hit "FILME", it takes about 5min until the next submenu appears...
If i install swisscenter in a subfolder, it runs quickly, but there are no images (background and icons) visible.

AND ... the badest part ... NO Media is displayed.
I have jpegs, movies in different subfolders, but NONE of them are displayed...

I checked the Media Folders ... everything is okay ...

Did you have any trouble when installing swisscenter on your Syno ?

Thannks a lot for any help !

Best wishes from Switzerland !
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/10/30 08:28 Thanks for the reply Crowley, but this is way over my head. I've no idea what

"You only have to do this when you have no "which" on your DS". I IpKg'ed "which" and just changed the shell_exec to exec"

means

The best I got was the SwissCenter to display on my LiteOn 2010, but none of the media files worked, everything was an invalid link. That was with & without the symbolic?? link patch.

I've taken it off the DS & will watch to see if anyone gets it to work properly with a simple install guide for us none Linux Guru's.

Thanks again..

Neo

Incidentally, I tried OpenShowcenter as well, that had the same symlink problem, & I'm now trying TwonkyVision & having similar problems with media not being found. The DS has the latest firmware, standard setup & it seems that everyone has problems trying to get anything to work on them. Looks like I paid a lot of money for a plastic box with a noisey fan in it....
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/10/30 09:08 Hi Neo,

the problem isn't with the DS or the swisscenter.
It's a security feature of PHP, so that php scripts aren't allowed to run wild on your system. You have to put your media files in a folder that ist covered by "open_basedir" in the file php.ini. All php functions (Swisscenter is written in PHP) are only allowed to process folders and files that are defined in this variable. If you choose a media folder that is not in open_basedir php will block the access and swisscenter MUST fail.

You either make a subfolder under /web like /volume1/web/TV (which would be the simplest) and put your media there. This works because /volume1/web is already covered by open_basedir, so every subfolder of it will be covered as well.
Or if you want to keep your media folder, you have to include it's path in open_basedir.
This isn't too difficult and it would solve your main problem.

I can imagine that OpenShowcenter didn't work for the same reason.

The part about "which" isn't really important. The fix mentioned in the first post works well enough.

All I can say is: There are some tricky things about SwissCenter on the DS but it works in the end and the DS can even stream full DVD VOB-files via WLAN to the LS-2010 without any problem, so it's worth the while...

If you want to take another try, feel free to post the exact error/problem and I will try to help you.

Crowley
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/10/31 07:00 Hi Crowley, here goes..

I did a fresh install of SC onto the DS, all the Swiss stuff placed in the root of the web folder - see image

http://homepage.ntlworld.com/netfreak/Swiss/SCTree.jpg

I created a sub folder called Data within that subfolders for all my moveis, music etc - 4 locations in total -you can see that on the image. I put 1 film in the Horror sub folder of Films, 1 episode of CSI in the TV series, a small collection of photo's (79) in the photos & an album of mp3 music (41) in music

On the DS I enabled Web station & added port 8000 as the extra port. MySQL is enabled but I didn't enable the PHP global thingy? Do I need to?

That allowed me to access SC, but when I tried to create a database it had the exec errors, so I modified the file.php as advised above & that cleared that error up & it created a database without errors.

I then added the media loacations as you can see in this image

http://homepage.ntlworld.com/netfreak/Swiss/SCLoc.jpg

I manually ran the media_search-php which ran ok & media added to the SC as you can see in this SC support page

http://homepage.ntlworld.com/netfreak/Swiss/SwissCenter%20Config.htm

However, if you look at the support page, the photo count has doubled, it also says there are 4 photo albums when there is only 1? The MP's are correct, the video count, which should be the movie & CSI episode is 3 when there are only 2?

When I access the SC I can get to browse folders & see the film, or TV episode & all the MP3's & Photo's listed - great - NOT.

If I click a movie link (I'm testing through my PC) I get the m3u link, that I choose to open - media player launches & returns the error that it cannot contact the server? The M3U is formatted as below

http://192.168.1.100:8000/media/2/Horror/White%20Noise.avi

http://192.168.1.100:8000/media/4/CSI/Miami/CSI.Miami.S05E01.Rio.avi

As you can see, they point somewhere else to where the files are?

I patched the stream.php as advised above, but that made no differance, the M3U's were formatted the same.

If I choose a music file, I get the M3U again, & choose to open it, media player lauches & advises me that I'm low on memory!!!!???? P4 Prescott, WinXP Pro & 1 gig or Ram, it's joking, yeah?

When I browse the photo's I can browse them in list view, choose a photo & nothing happens, nothing is displayed no matter how long I wait. If I choose thumbnail view reduced sized images of the photo's appear, but again, clicking on there link & nothing appears - the same happens if I try the slideshow - nothing happens.

Incidentally, if I leave the Photo browser in thumbnail view it just about kills of the SC, because it seems to freeze up & won't leave the page or load any other pages. I have to make sure I select list view before leaving the photo browser.

When testing the SC on the Lite-On I can browse to the files, the film & TV give Invalid Link error. The music appears to load the track as the track name appears on the screen, but no music plays & it goes back to the file listing after a few seconds. Not bothered with photo's, they can wait....

PHP info page

http://homepage.ntlworld.com/netfreak/Swiss/phpinfo().htm

Cheers

Neo...
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/10/31 11:23 As a footnote to my previous reply, I've done a little more testing with the Photo's, I applied the patch described earlier in the thread & it's made no difference. However, changing the view from list, to compact, shows smaller sized icons of the photo's - BUT - the best part is, it now opens the photo's full size for viewing - yaeh! Still doesn't work in list or thumbnail views tho

As said before, if I leave the photo browser in ANYTHING but list view, it seems to break the whole SC center as it won't allow you to browse any catagory. When you click on the browse file system for any catagory with compact or thumbnail views selected in photo browser, there is a flurry of hard drive activity, this dies down & eventually the browser times out. This is true if using my PC or Lite-On.

Bearing that in mind, can anyone tell me a way to restore the list view without having to re-install SC again? Yep, I forgot to switch views back in all the excitement of the photo's working in compact view. Now I can't get back into any catagory - including photo's to put it back in list view - DOH!!!!
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/11/01 16:49 Sorry I haven't had time to read & reply to your comments yet. It might be some time before I can, because we've had a major disaster here at work and I'm busy trying to put our systems back together

However, I saw your comment about restoring the viewing mode without reinstalling, and yes it is possible - open the following page up in a web browser on your PC and it'll reset it to the list view:

http://localhost:8080/music_browse.php?thumbs=NO&DIR=

(obviously you'll need to change "localhost" to the ip address of your DS)
Player : Pinnacle Showcenter 200 and 1000 (wired ethernet)
Server : Windows XP Pro running on an Athlon XP 2200, 768 Mb RAM, 1.8 Tb storage.

  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/11/02 02:02 Hi Neo,

could you please make a playlist for mp3s as well and tell me, whether it looks the same as the playlist for videos?

Which version of SC are you using, the latest (1.15.4)?

What errors/problems do the configuration checks of the SC (DS/config) mention?

Your screenshots don't show owners and user rights of the folders. Everything concerning SC should be changed to owner "nobody". User rights should be 644 for files and 750 for folders.

The format of the playlist is obviously "wrong", in the sense that the webserver of the DS doesn't accept them. This is probably a special problem of the latest version of SC, where the generating of playlists for movies was changed because of some trouble with subtitles.
Take a look at gen_playlist.php and search for "if ($media_type == 3 )".
Try to comment the 3 lines from "If" to "Else" out so that the format with "stream.php" is used for movie files as well.
This should give you the correct format in the playlist and maybe even let's you playback your movies.

Try and let me know, if it works.

Crowley
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/11/02 05:46 Thanks Admin, that did the trick & I can use the SC again

Crowley, I edited the gen_playlist.php & ran some tests. the results are below. Hope some of this means something to you, I'm in way over my head here. Hopefully using the latest version as I downloaded the zip file last weekend, but the setup screen only shows V1.15? Anyway to verify?

Here's a screen shot of the SC install on the DS using Telnet, it's in two parts but shows the full tree & permissions, I hope. Sorry, I don't know what 644 & 750 means or how to find it out.

http://homepage.ntlworld.com/netfreak/Swiss/Telnet1.jpg

http://homepage.ntlworld.com/netfreak/Swiss/Telnet2.jpg

Here's a screen shot of the Syno config screen showing users/permissions

http://homepage.ntlworld.com/netfreak/Swiss/Syno1.jpg


I enabled full log output on the SC & ran 3 test runs at video & mp3 playing, here's the keystroke, M3U file link's created & log file for each test. I've not done the photo's as I'm not too concerned about them, just yet - LOL

I forced SC to create a fresh log for each test by renaming the old log after each test.

Main Menu

Watch Video
Films
Browse File System
Horror
White Noise


M3U file format

http://192.168.1.100:8000/stream.php?session_id=c9db7afdb3c88978d5a454a6e7c605f1&media_type=3&file_id=3&ext=.avi


File did not play, server not found error returned by Media Player.

Log Created

Removed to shorten post

Main Menu

Watch Video
TV Series
Browse File System
CSI
Miami
CSI.Miami.S05E01.Rio.avi


File did not play, server not found error returned by Media Player.


M3U created

http://192.168.1.100:8000/stream.php?session_id=c9db7afdb3c88978d5a454a6e7c605f1&media_type=3&file_id=4&ext=.avi


Log File

Removed to shorten post
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/11/02 06:06 Here's the rest of that last post

Main Menu

Watch Video
Listen To Music
Music
Browse File System
Albums
Dance Mania 2006
Dance Mania 2006 CD1
01-Mega Mix-Dance Mania 2006.mp3


M3U Created

http://192.168.1.100:8000/stream.php?session_id=c9db7afdb3c88978d5a454a6e7c605f1&media_type=1&file_id=42&ext=.mp3


File did not play, Windows Media player returned low on system memory error?

Log Created

Log removed to shorten post


Cheers

Neo
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/11/02 10:36 Hi Neo,

maybe you should edit your last post and delete the log stuff. The thread has become far too long. Takes some time for me to load it.

BTW: Maybe we should change the discussion to PMs as it will be becoming more and more specific and long.
We could post a summary here when we accomplish something.

Mails would allow us to attach screenshots and logs without problems.

Crowley
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/11/04 06:34 Hi Neo,

this is what a playlist looks like for me (video or music doesn't matter):
http://192.168.1.100:8080/stream.php?media_type=1&file_id=316&ext=.mp3
http://192.168.1.100:8080/stream.php?media_type=1&file_id=317&ext=.mp3

BUT:
I'm still using the original 1.15 version whereas you are probably using 1.15.4.
There obviously have been some important changes.

Problem is, I tried the 1.15.4 but it gave me all sorts of trouble, didn't even show the complete config screen, gave lots of errors when trying to established database. Therefore i reverted back to the 1.15 which works well for me and has all features I need. I plan to give the 1.15.4 another shot sometime when I have more spare time on my hands.

You could try to call one of the links created by your SC with the session_id stuff left out but this probably won't work? Should it work, try to change the code in gen_playlist to leave out the session_id.

Apart from that you could use the original 1.15. I don't think you can download it still but I could send you the original zip file.

Crowley
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/11/05 12:17 I may have identified a problem with the video playback. The odd string has been noted in another thread, "swisscenter on LinkStation ". The URL generated does NOT point to the correct media location:

5/Humor/Robin.avi\" target=\"_new\">http://192.168.1.77:81/media/5/Humor/Robin.avi

(The correct file location is /mnt/media/Videos/Humor.Robin.avi)

I was wondering where this path was derived and poked around to discover that this path is under the swisscenter directory! There are links to the media here.

The script incorrectly builds the link location rather than the actual path to the video files.

How can this be tweaked? Will it finally allow video playback?? Everything else seems to work!

Matt
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/11/06 07:13 Hi Matt,

this is by design.
The webserver is bound to the base directory of the SC. It can't just take a file from anywhere on your NAS. That wouldn't be a good idea for security reasons.

Try it yourself: Just enter a link with the direct path to one of your media files into your webbrowser. I don't think this will work.

Therefore SC works with symbolic links inside it's own directory that are mapped to the original location to the media files.

The problem with NSAs like LinkStation or Diskstation seems to be that the webserver won't accept symbolic links. Therefore playlists with such links won't work. But playlists using stream.php should work.

If you can playback music files, you should try the workaround I proposed some posts ago in this thread (about commenting out the special playlist handling for movies files in 1.15.4).
This should give you the same playlists for video as for music and maybe allow video playback. You probably won't have subtitles though.

To maybe understand the problem better: Use your webbrowser to get and save one playlist for music and one for video and open both in a texteditor. You will see the difference.

Crowley
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2006/11/06 12:54 Thanks, I had tried your earlier suggestion, however the videos still did not play with the streaming URL either. I don't understand why. Music and photos all play pretty well (a little audio chopping at the end of tracks (VBR MP3s)). Internet radio and weather work; I'm happy except no video playback.

I wish I could figure out what is going on. I looked at Buffalo's PCast media server (on the LinkStation) and found that it uses port 8000 and the video links look (in a Mac Firefox browser) like URLs with that port:

http://192.168.1.77:8000/Videos/Humor/Robin.avi

Maybe the Linktheater gets a different kind of playlist from PCast than a computer or the LinkTheater client software (ugh!)?

Any suggestions would be much appreciated, as SC seems like a great program that can get even better.

Matt
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2007/02/23 09:20 Today SwissCenter stopped playing music via stream.php. At all. Videos play fine, and editing gen_playlist.php to not use stream.php for music works, although then I get long pauses between VBR tracks.

Does anybody have an idea what could be wrong and how to fix it?

I'm using 1.15.4
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2007/02/23 10:00 OK, I figured it out. The problem lied in DS-101's weird safe mode and my tweaking of php.ini for another script. SC's large_filesize function in file.php tried to exec ls command from /bin, which wasn't allowed. I symlinked /bin/ls to /usr/syno/bin/ls, and it works.
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2007/02/24 15:16 To solve the symlink problem on Diskstation, simply edit the /usr/syno/apache/conf/httpd.conf-user file, and make sure all relevant <Directory> sections have FollowSymLinks in the Options line, like this: "Options Indexes FollowSymLinks".

Restart Apache by typing "/usr/syno/etc.defaults/rc.d/S97apache-user.sh restart" (without quotes).

You can leave the original SwissCenter php code if you have this enabled for Apache.

Of course, you need telnet or ssh enabled to do it.
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2007/02/25 10:04 Does anybody have an idea how to get anything but a blank screen when using SwissCenter on a Synology NAS?

Apparently, the Web Station's PHP installation is missing a module to transfer text to image, so the "Now playing" screen is missing. I've no idea whether it's possible to add necessary functionality to PHP.

However, there should be a simpler way - when streaming movies, stream.php isn't used, and SwissCenter simply redirects the browser to the video files. When this happens, I can press the "?" button on my ShowCenter remote and can get all the info I need. A rather primitive Oxyl server does the same with mp3 tracks, and it works, and I guess it shoud be fairly easy to modify stream.php. I just don't know whether this information is sent via headers, as a separate stream or whatever.

Anyone?
  | | The administrator has disabled public write access.
Re:swisscenter works on synology NAS - 2007/03/01 15:28 vangrieg wrote:
To solve the symlink problem on Diskstation, simply edit the /usr/syno/apache/conf/httpd.conf-user file, and make sure all relevant <Directory> sections have FollowSymLinks in the Options line, like this: "Options Indexes FollowSymLinks".

Restart Apache by typing "/usr/syno/etc.defaults/rc.d/S97apache-user.sh restart" (without quotes).

You can leave the original SwissCenter php code if you have this enabled for Apache.

Of course, you need telnet or ssh enabled to do it.


Hello vangrieg,
I need a little help !
One question about the httpd.conf-user file.
Is ist right, that I must type all my own dirs in this file?
For exap. (print of the httpd.conf-user file)
# DocumentRoot: The directory out of which you will serve your
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
#
#DocumentRoot "/volume1/web"

#
# Each directory to which Apache has access, can be configured with respect
# to which services and features are allowed and/or disabled in that
# directory (and its subdirectories).
#
# First, we configure the "default" to be a very restrictive set of
# permissions.
#
<Directory /volume1/web/Data/Filme>
Options Indexes FollowSymLinks
AllowOverride None
</Directory>
#
# Note that from this point forward you must specifically allow
# particular features to be enabled - so if something's not working as
# you might expect, make sure that you have specifically enabled it
# below.
#

#
# This should be changed to whatever you set DocumentRoot to.
#
<Directory /volume1/web/Data/Filme>
Options Indexes FollowSymLinks

Is this all ok??
/volume1/web/Data/Filme is my main folder to the movies.
Music is not so important
I did this procedure, but no movie playing. Browser stopps at the dialog of browse filesystem - nothing happes !!

Thank you very much for your help !!
Hardware: Syn DS-106e

Greetings
giantnrs







  | | The administrator has disabled public write access.
Re: Re:swisscenter works on synology NAS - 2007/06/17 08:01 Hi to everyone who's got swisscenter running on the synology NAS. Hope someone will still look at this thread....

I installed swisscentere on NAS and folowed the instructions in the first post. It functions and it found the media. However it is impossible to use because it is SLOW! I can browse menus and listen to the internet radio, look at weather. If I want to look at pictures it takes about 2 min to pull up the first one. The music and movies are impossible - the Showcenter times out. When I telnet in and run "top" during requests from Showcenter - the httpd and mysqld take 100% CPU for a long long time.

The only difference is that I have the media in the Syno's recommended locations and I modified added /volume1/video, /volume1/photo and volume1/music to the "safe" list.

Any suggestions?

Thanks,
Misha
  | | The administrator has disabled public write access.
Re: Re:swisscenter works on synology NAS - 2007/06/17 11:58 giantnrs, You should remove the "#" signs in the beginning of the <Directory> lines.
  | | The administrator has disabled public write access.
Re: Re:swisscenter works on synology NAS - 2007/06/17 12:01 Misha, the Diskstation hardware is just too weak to resize images in the fly. I'd forget about it.
  | | The administrator has disabled public write access.
Re: Re:swisscenter works on synology NAS - 2007/06/19 12:05 vangrieg,

I commented off the resizing on the fly. Anyway I don't think the slow CPU is the problem - for video and music all it needs to do is stream the file and it's a piece of cake in a built-in media server mode. Even the swisscenter pages pull up very slow (on both Showcenter and a PC browser. But a web Photostation built into the NAS works fine. I think there's a setting that makes php processing very slow, but I don't know what it is. The httpd and the mysqld do take 100% CPU, so it cannot be the process priority...

Any other ideas?

Thanks....
Misha
  | | The administrator has disabled public write access.
Re: Re:swisscenter works on synology NAS - 2007/06/20 04:18 Dear Misha

Depending on the initial image configuration settings of swisscenter, it tries to pre-generate a thumbnail of each image found during media scan. As vangrieg noted, the hardware is too weak for resampling images. (it takes several minutes per image!). Even if you commented out the responsible code, swisscenter might still be in the process of pre-generating those thumbnails. You should restart httpd.

greetings
Mike
  | | The administrator has disabled public write access.
spacer
 

Screenshots

www.flickr.com
This is a Flickr badge showing public photos from swisscenter. Make your own badge here.


 

Mambo is Free Software released under the GNU/GPL License.
spacer