Link to home
Start Free TrialLog in
Avatar of Josh Barton
Josh BartonFlag for United States of America

asked on

electric sheep

I use Gentoo and Windows XP SP 2 in the same computer. It is bootable either way thanks to GRUB. The problem is that recently I installed http://electricsheep.org/ in my windows partition and its fine and dandy however I would also like to put these screensaver for my linux machine. The window manager i utilize is E16 (watiing for E17)-enlightenment. I want Linux to run electricsheep as well but I don't want to start from scratch and download videos I already have! I want to use those in my windows partition. My windows partition is always mounted at the beginning. I am not sure if any of you can help me in my quest to use electricsheep of windows for both, and to as well (when my machine is idle in linux) to store the information in that same folder. C:\WINDOWS\SYSTEM32\electricsheep-cache\mpeg - that is the name for windows for linux it is \mount\windows\WINDOWS\SYSTEM32\electricsheep-cache\mpeg

well thanks .
Avatar of sr75
sr75
Flag of United States of America image

I don't use gentoo, so I don't know if there are NTFS drivers included with that.  If there is, great.  If not just download them from:

http://www.linux-ntfs.org/

It is read only, so any downloads would have to be in Windows.  Also, electricsheep.org does have the source available for gentoo so that you can install it.  You would just need to have your windows partition mounted and point that app at the proper location for the data.
Avatar of Josh Barton

ASKER

ntfs? My problem is not that i cant read my drive. Is that I dont know how to setup electricsheep that way. I can read the mount directory fine.  My partitions are fat32. I hate ntfs.

in Gentoo all you work with is portage.
what i would want to know is how to configure electricsheep and where so i can do so i can "point that app at the proper location for the data."
Avatar of Tim_Utschig
Tim_Utschig

I see in the man page that it has a --data-dir option.  This sounds like it might be what you want.
so i chould use --data-dir and type the address of what I want? My problem is also that in gentoo the way I install is via portage by emerging. Does anybody know how to use --configure there? I mean normally I would in slackware but never done it in gentoo. Any gentoo users?
I don't use Gentoo, but the --data-dir is not a compile-time option.
then explain.
The man page can explain better than I can.  I've never used electricsheep.  Install it and then run "man electricsheep" or read:  http://electricsheep.org/doc/manpage.html
do you use gentoo?
Yes, I do use gentoo...
But it doesn't matter anyway....

To install electricsheep just do (as root):
emerge electricsheep

After installing, you have to tell electricsheep which directory to use for all the dynamic stuff it needs and generates. On linux this is ~/.sheep by default. Under windows: I don't have a clue, probably it's somewhere in Documents & Settings. Try to search for a directory called "sheep" under windows. Once you have located the windows sheep-directory, you can easily link ~/.sheep to the (mounted) windows sheep directory.
 Let's assume, the windows sheep-directory is C:\Documents & Settings\user\ApplicationData\electricsheep and your C:\-drive is automatically mounted on /mnt/windows/C, then you could easily do the following:

- Logon into your user account
cd ~
rm -rf .sheep
ln -s /mnt/windows/C/Documents & Settings\user\ApplicationData\electricsheep .sheep

That should be all....


HTH,

-XoF-
electricsheep is masked by the keyword "~amd64" should i still continue? (btw what was the script to enable the keywords "~amd64" i forgot :( )
oh i just remembered ill install it even though it is masked.
.sheep does not exist!!!!
OK,
logon as normal user, start your X11 session and configure electric sheep to be the screensaver. Then wait until the screensaver starts (or use the test-button).
Going that way on my box, electricsheep created the .sheep directory in my homedir.
Remember: My suggestion was only a quick shot, since I don't know anything about electricsheep (just installed it today 'cause you made me curious).... I only tried to put one and one together...

Cheers,

-XoF-
well not sure how to establsih electricsheep as screensaver. because in XScreenSaver it doesnt appear as an option











         
soryy for all the white space in lynx it appeared like that. well the thing is taht i am not sure how electricsheep works out in linuxl. i typed as a code electricsheep and nothing. i tried to use data dir and it takes too long and nothing. i tried everyhing and nothing. and in XScreensaver which is supposed to be the place where i choose my screensaver (even though the deamon was not running since the start of *nix session) it doesnt show electricsheep as an option please explain to me how u did it. thanks a lot
> well not sure how to establsih electricsheep as screensaver. because in XScreenSaver it doesnt appear as an option

How did you install electric sheep?  Did you emerge it?
accept_keyword="~amd64" emerge electricsheep that is what i did
Did it install this file?:
    /usr/share/xscreensaver/config/electricsheep.xml

To check what files it installed, use the command (emerge gentoolkit if you don't have it already):
    equery files electricsheep
/usr/share/xscreensaver/config/electricsheep.xml it idid install that file
I see no reason for it not to show up in xscreensaver-demo then.
want me to download some other app?
> want me to download some other app?

No.

If you run xscreensaver-demo from an eterm, does it print any messages?

If not, try adding the --debug option.
alvaro@misantropo ~ $ xscreensaver-demo --debug
xscreensaver-demo: using config directory "/usr/share/control-center/screen
s"
xscreensaver: 16:19:28: DISPLAY=:0.0
xscreensaver: 16:19:28: added "/usr/lib/xscreensaver" to $PATH
xscreensaver-demo: 16:19:28: scheduling preview "fontglide -root -page"
xscreensaver-demo: 16:19:28: image_directory => "(null)"
xscreensaver-demo: 16:19:28: wrote /home/alvaro/.xscreensaver
xscreensaver-demo: 16:19:28: scheduling preview "fontglide -root -page"
xscreensaver-demo: 16:19:29: xscreensaver-gl-helper says the GL visual is 0
xscreensaver-demo: 16:19:29: using default visual 0x21
xscreensaver-demo: 16:19:29: window id 0xA00024 -> 0xA0008E
xscreensaver-demo: 16:19:29: XSCREENSAVER_WINDOW=0xA0008E
xscreensaver-demo: 16:19:29: forked 24650 (fontglide)
xscreensaver-demo: 16:19:29: scheduling check
xscreensaver-demo: 16:19:29: timer: pid 24650 (fontglide) is alive
xscreensaver-demo: 16:19:29: timer: pid 24650 (fontglide) is alive
xscreensaver-demo: 16:19:30: timer: pid 24650 (fontglide) is alive
xscreensaver-demo: 16:19:30: timer: pid 24650 (fontglide) is alive
xscreensaver-demo: 16:19:30: timer: pid 24650 (fontglide) is alive
xscreensaver-demo: 16:19:30: timer: pid 24650 (fontglide) is alive
xscreensaver-demo: 16:19:30: timer: pid 24650 (fontglide) is alive
xscreensaver-demo: 16:19:31: timer: pid 24650 (fontglide) is alive
xscreensaver-demo: 16:19:31: timer: pid 24650 (fontglide) is alive
xscreensaver-demo: 16:19:31: image_directory => "(null)"
xscreensaver-demo: 16:19:31: wrote /home/alvaro/.xscreensaver
xscreensaver-demo: 16:19:33: timer: pid 24650 (fontglide) is alive


that is what i get with --debug electricsheep does not appear in xscreensaver-demo.
Try moving your ~/.xscreensaver out of the way and see if it regenerates the list with electricsheep in it:

  mv ~/.xscreensaver ~/.xscreensaver-bad
  xscreensaver-demo
perhaps all my xscreensaver stuff shouldnt be in /usr/share/xscreensaver/config because in that folder the only file is electricsheep


--i did what you told me and it did not generate electricsheep.
> in that folder the only file is electricsheep

Then how did you install xscreensaver?  Gentoo's xscreensaver package installs LOTS of files there.
equery files xscreensaver | grep config
that command did not display anything. isnt there like a locate command?
what files do u have in your config folder?
> that command did not display anything.

That means you didn't install xscreensaver the Gentoo way.

> isnt there like a locate command?

emerge slocate
updatedb
locate xscreensaver/config

> what files do u have in your config folder?

A lot.
ill uninstall and re-emerge xscreensaver as well as electricsheep
Don't forget to:

   emerge --sync
   emerge --update --deep world

Before doing so.  When's the last time you did that?

   emerge --update --deep world
 ? why that.
detected another electricsheep process.
using read only access, ie disabling downloading of sheep.
/home/alvaro/.sheep/overlay_fifo: Operation not permitted
Terminated


i got it to work but got that error. not sure what it means.
>   emerge --update --deep world
> ? why that.

Otherwise your currently installed packages will never be updated.

> detected another electricsheep process.

You'll get this message if you try to "Preview" electricsheep from xscreensaver-demo, since there will be another copy already running to display inside of xscreensaver-demo's window.

> /home/alvaro/.sheep/overlay_fifo: Operation not permitted

If you created ~/.sheep as a symlink like XoF showed you, then it's trying to create a fifo on NTFS.  NTFS doesn't support special file types like fifos, sockets, device files, etc.

Since it appears that electricsheep only creates a fifo when there is more than one process running, just don't do that.  If you want to test it, set it as the screen saver, close xscreensaver-demo, and run this from an eterm:

  sleep 1; xset s activate


i use fat32 not ntfs. i will try what u said. i did how XoF showed me, what is your way?
> i use fat32 not ntfs.

Same difference.  Neither support any of the special types of files.

> i will try what u said. i did how XoF showed me, what is your way?

What XoF showed you is correct.  I didn't say it was incorrect.

Then again...

Looks like my installation finally downloaded a couple mpegs.  Now it created the overlay_fifo.  Bad news for you since you can't have that on FAT32.

I checked the man page again and it looks like I was wrong about --data-dir.  The right option is --save-dir.  To set this option, run xscreensaver-demo, select ElectricSheep, click "Settings...", click "Advanced >>", and add " --save-dir /mnt/windows/path/to/electricsheep/data/dir" to the Command Line.  I tested this by creating ~/.sheep_data and mv'ing all the mpg's there.  So it looks like that is the final answer.
One more thing to note.  The --save-dir option I added disappears when I go back into xscreensaver-demo, however it is still there (inside ~/.xscreensaver), and it works fine.
ASKER CERTIFIED SOLUTION
Avatar of Tim_Utschig
Tim_Utschig

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
cp -s?
i know cp but not the -s command. i do not want to waste memory when the info already exists.
cp -s creates symlinks.  It doesn't copy the files themselves.
ok i understand that i need to

   cp -s /mnt/windows/path/to/electricsheep/data/dir/*.mpg ~/.sheep/

but should i uninstall electricsheep and delete all files in the current ~./sheep (which are all the movies with the fifo error)?
> should i uninstall electricsheep and delete all files in the current ~./sheep

No.  Just do the cp -s.  If an mpg file gets removed by cp to put a symlink in it's place, that's fine because it means you already have that one on your Windows partition.

> (which are all the movies with the fifo error)?

The fifo error has nothing to do with the movie files.
cd ~
rm -rf .sheep
ln -s /mnt/windows/C/Documents & Settings\user\ApplicationData\electricsheep .sheep

what would be the difference between those lines above and doing. sorry for the ignorance.

 cd ~/.sheep/
   find -type l -name "*.mpg" -print0 | xargs -0 rm -f
   mv *.mpg /mnt/windows/path/to/electricsheep/data/dir/
   cp -s /mnt/windows/path/to/electricsheep/data/dir/*.mpg ./
They are entirely different.

The first creates a symlink ~/.sleep which points to a directory on your Windows partition.

The second creates symlinks of all the *.mpg files from a directory on your Windows partition inside your ~/.sheep directory.
If ~/.sheep is a symlink right now, rm it and mkdir ~/.sheep
ok i just did as you told me by removing the directory and did
cp -s /mnt/windows/path/to/electricsheep/data/dir/*.mpg ~/.sheep/
it even works faster!!!
so there is no way to make both in the same folder, well it doesnt matter ill have to move files around. i could still make it so save--data-dir is in the windows partition so it is easier and instead of doing

   find -type l -name "*.mpg" -print0 | xargs -0 rm -f
   mv *.mpg /mnt/windows/path/to/electricsheep/data/dir/

(which by the way i dont understand) i could just delete all files with rm *.mpg and then cp -s mnt/...../*.mpg ~/.sheep/

what was the reason fifo was not working?
oh and by the way how do i make xscreensaver default at the beginning of stuff like SAMBA? (i forgot :( ) in some seconds i am clicking "accept" to your wonderful solution
> (which by the way i dont understand) i could just delete all files with rm *.mpg and then cp -s mnt/...../*.mpg ~/.sheep/

But then you'd lose all the new mpg's downloaded while running on Linux.  That's why I used the find command to delete only the symlinks named *.mpg, and then mv the remaining *.mpg files (which are actual files) over to the Windows partition.

> what was the reason fifo was not working?

FAT32 doesn't support special file types like fifos, sockets, device files, etc.
do u have an answer so xscreensaver starts at default?
> do u have an answer so xscreensaver starts at default?

The answer to that depends on how you're starting enlightenment.  Are you running it from gdm? xdm? kdm? startx? something else?

Basically you just need to execute "xscreensaver &" before enlightenment gets executed.

If you're using gdm, the easiest way to do this is to create a ~/.xsession and put this in it:

#!/bin/sh
xscreensaver &
enlightenment

Then run: chmod +x ~/.xsession
And then before you login, click "Session", and select "Custom Session".  This will make it execute your ~/.xsession script.