PDA

View Full Version : weird home directory creation on Linux



Jason Diamond
2005-03-24, 13:01
Hi.

I just downloaded the Perl source for SlimServer 6.0b3 to run from my
Ubuntu (Hoary Hedgehog) workstation. Running slimserver.pl --daemon
started the server and my SqueezeBox1 is finding it with no issues.

The weird thing is this new home directory I have in my real home
directory.

Here's what I did: I extracted the tarball to my home directory which
put everything in /home/jason/SlimServer_v6.0b3. I started the daemon
and told it where my MP3 files were (/home/jason/mp3) by using the web
interface and that's all I did.

There's now a directory in my home directory called home. In that new
home directory is a directory called jason and in that new directory is
another SlimServer_v6.0b3 directory. In that directory are two
directories: HTML and Plugins. So the full path to these new directories
is /home/jason/home/jason/SlimServer_v6.0b3/.

What is this? I saw the same thing when I downloaded beta 2 but I just
ignored it. When I downloaded beta 3, I deleted the new home directory
but it reappeared as soon as I started the new daemon.

Since I'm not creating a /etc/slimserver.config file, is weird things
happening?

What's the preferred way to "install" SlimServer on Linux? I imagine
using the RPM would be easiest but I'm running Ubuntu which uses DEBs
instead of RPMs. (Maybe there's a way to get Ubuntu to install an RPM
but I'm not that Linux-savvy to know what that is).

Thanks.

-- Jason

kdf
2005-03-24, 13:07
Quoting Jason Diamond <jason (AT) injektilo (DOT) org>:

> directories: HTML and Plugins. So the full path to these new directories
> is /home/jason/home/jason/SlimServer_v6.0b3/.
>
> What is this? I saw the same thing when I downloaded beta 2 but I just
> ignored it. When I downloaded beta 3, I deleted the new home directory
> but it reappeared as soon as I started the new daemon.

that's the cache for the Template Toolkit files. All the html is rendered from
the templates and cached in that tree.

> Since I'm not creating a /etc/slimserver.config file, is weird things
> happening?

edit cachedir in the prefs file ~/slimserver.pref
or start with slimserver.pl --cachedir /path/to/my_preferred_cachelocation

-kdf

jacobdp
2005-03-24, 13:11
On Thu, 24 Mar 2005 12:07:15 -0800, kdf <slim-mail (AT) deane-freeman (DOT) com> wrote:
> Quoting Jason Diamond <jason (AT) injektilo (DOT) org>:
>
> > directories: HTML and Plugins. So the full path to these new directories
> > is /home/jason/home/jason/SlimServer_v6.0b3/.
> >
> > What is this? I saw the same thing when I downloaded beta 2 but I just
> > ignored it. When I downloaded beta 3, I deleted the new home directory
> > but it reappeared as soon as I started the new daemon.
>
> that's the cache for the Template Toolkit files. All the html is rendered from
> the templates and cached in that tree.

I just checked and this happens to me as well.
/home/jacob/home/jacob/trunk/server/HTML/etc. Not quite the Right
Thing...

- Jacob

Jason Diamond
2005-03-24, 13:22
On Thu, 2005-03-24 at 12:07 -0800, kdf wrote:
> edit cachedir in the prefs file ~/slimserver.pref
> or start with slimserver.pl --cachedir /path/to/my_preferred_cachelocation

I just looked in my ~/slimserver.pref file and I see this line:

cachedir = /home/jason

Is that option being "combined" with another option so that the full
path is ending up being /home/jason/home/jason/SlimServer_v6.0b3? I'm
not able to see something that might be a likely suspect in my pref
file.

It would be nice if it defaulted to the directory containing the rest of
the SlimServer code (unless overridden with a pref/config file, of
course).

Thanks.

-- Jason

kdf
2005-03-24, 13:23
Quoting Jason Diamond <jason (AT) injektilo (DOT) org>:

> On Thu, 2005-03-24 at 12:07 -0800, kdf wrote:
> > edit cachedir in the prefs file ~/slimserver.pref
> > or start with slimserver.pl --cachedir /path/to/my_preferred_cachelocation
>
> I just looked in my ~/slimserver.pref file and I see this line:
>
> cachedir = /home/jason
>
> Is that option being "combined" with another option so that the full
> path is ending up being /home/jason/home/jason/SlimServer_v6.0b3? I'm
> not able to see something that might be a likely suspect in my pref
> file.

the tempalte creates an absolute tree. Thus if your cachedir is /home/jason,
and yoru slimserver files are located in /home/jason/Slimserver_v6.03/HTML, etc
then this is what you see.

if you had installed slimserver in a /usr/local/slimserver (as the RPM does),
youd see a cachedir that looked like: /home/jason/usr/local/slimserver/...

-kdf

Jason Diamond
2005-03-24, 13:38
On Thu, 2005-03-24 at 12:23 -0800, kdf wrote:
> the tempalte creates an absolute tree. Thus if your cachedir is /home/jason,
> and yoru slimserver files are located in /home/jason/Slimserver_v6.03/HTML, etc
> then this is what you see.
>
> if you had installed slimserver in a /usr/local/slimserver (as the RPM does),
> youd see a cachedir that looked like: /home/jason/usr/local/slimserver/...

OK, I think I understand. Template Toolkit takes the cachedir preference
and combines that with the absolute path for each template it's
evaluating? And the templates are located
in /home/jason/SlimServer_v6.0b3/HTML/... so I wouldn't want to just set
my cachedir to / because that would overwrite the templates themselves
but I could do something like set my cachedir
to /home/jason/SlimServer_v6.0b3/Cache so I can get it out of my home
directory, right?

I found a message saying that you guys are working on packaging up
SlimServer in a DEB so I'll wait until that's released instead of trying
to "install" by hand it like the RPM does. Hopefully that will end up in
Ubuntu's repository.

Thanks.

-- Jason

kdf
2005-03-24, 13:42
Quoting Jason Diamond <jason (AT) injektilo (DOT) org>:

> On Thu, 2005-03-24 at 12:23 -0800, kdf wrote:
> > the tempalte creates an absolute tree. Thus if your cachedir is
> /home/jason,
> > and yoru slimserver files are located in /home/jason/Slimserver_v6.03/HTML,
> etc
> > then this is what you see.
> >
> > if you had installed slimserver in a /usr/local/slimserver (as the RPM
> does),
> > youd see a cachedir that looked like: /home/jason/usr/local/slimserver/...
>
> OK, I think I understand. Template Toolkit takes the cachedir preference
> and combines that with the absolute path for each template it's
> evaluating? And the templates are located
> in /home/jason/SlimServer_v6.0b3/HTML/... so I wouldn't want to just set
> my cachedir to / because that would overwrite the templates themselves
> but I could do something like set my cachedir
> to /home/jason/SlimServer_v6.0b3/Cache so I can get it out of my home
> directory, right?

yup, that sounds right :)

>
> I found a message saying that you guys are working on packaging up
> SlimServer in a DEB so I'll wait until that's released instead of trying
> to "install" by hand it like the RPM does. Hopefully that will end up in
> Ubuntu's repository.

I've seen a couple people mention it. There is a bit of wrestling with
binaries, since Debian seems to not like them. Hopefully they are watchign
this thread and will be able to provide a better status report than I.

-kdf

Mike Hartley
2005-03-24, 13:57
Given all of the discussion of skipping, wireless network performance, etc.
some of you, especially those actually developing the server SW, may find
this article that discusses delivering multimedia via wireless interesting.

Mike

http://www.extremetech.com/article2/0,1558,1778957,00.asp