Scott Balneaves schrieb am 03. Sep 2008 um 18:07:08 CEST: > On Wed, Sep 03, 2008 at 01:32:17PM +0200, Helmut Lichtenberg wrote: > > Hi, > > I know, there has been a thread discussing this problem, but I didn't see > > any > > solution. > > Well, I suppose the thing to do would be to quantify WHY they're not being > deleted automatically. > > If you look at /usr/sbin/nbdswapd, the last line is: > > rm -f $SWAP > > So, when the nbd-server exits, it should clean up after the swap file. > > The other important file to note is: > > /etc/hosts.allow > > Which should have: > > nbdrootd: ALL: keepalive > nbdswapd: ALL: keepalive > > in it. That way, when you turn off the terminal, after the tcp timeout period > has elapsed, the nbd-server process will exit cleanly, and clean up the file. > > Do you have dead nbd-server processes hanging around?
I have configured the two servers that the first one serves the image and there I have 28 process-pairs of the combo: nobody /bin/sh /usr/sbin/nbdrootd /opt/ltsp/images/i386.img nobody /bin/nbd-server 0 /opt/ltsp/images/i386.img -r -C /dev/null The second server holds the swap files. On this I have 248 pairs of: nobody /bin/sh /usr/sbin/nbdswapd nobody /bin/nbd-server 0 /tmp/tmp.yRYaPc2913 -C /dev/null Obviously the 'rm -f $SWAP' doesn't work quite well. Concerning /etc/hosts.allow: After the ubuntu hardy installation, only the nbdrootd-line was in there. I added the nbdswapd-line now, but this should be part of the installation. I'll see during the next week, if the keepalive options helps. Jan Kunder suggested at Wed, 3 Sep 2008 15:24:47 +0200: > workaround: > crontab (at midnight) ping all clients and if all are down delete all swaps This is not an option. The client are not switched off every night. It's a production environment and people stay logged in or only log out without powering down the machine. So you cannot simply remove all swapfiles. The servers run for months without reboot. In my original post, I mentioned an older discussion, where vagrant at freegeek.org wrote at Wed, 16 May 2007 09:04:56 -0700: > you're free to implement whatever scheme for the filename you like by > putting it in the configuration file /etc/ltsp/nbdswapd.conf: > IP=$(magic_command_to_get_ip) > SWAP=/path/to/your/preferred/swap/file/$IP I personally would prefer, if the swapfiles are named like /tmp/<clientname>.swap, but I have no idea, what the 'magic_command_to_get_ip' could look like. What environment is passed to /usr/sbin/nbdswapd to extract the ip/name of the caller? Helmut -- ------------------------------------------------------------------------- Helmut Lichtenberg <[EMAIL PROTECTED]> Tel.: 05034/871-128 Institut für Nutztiergenetik (FLI) 31535 Neustadt Germany ------------------------------------------------------------------------- ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _____________________________________________________________________ Ltsp-discuss mailing list. To un-subscribe, or change prefs, goto: https://lists.sourceforge.net/lists/listinfo/ltsp-discuss For additional LTSP help, try #ltsp channel on irc.freenode.net