Re: [Server-devel] [XSCE] systemd-udevd timeout error while running the set of scripts using usbmount

2014-07-25 Thread Adam Holt
Saintly souls helping OLE Nepal install XSCE 5.0 -- Sumit asks that we copy
the solution below (and original question at bottom), for the benefit of
all-

On Thu, Jul 24, 2014 at 5:52 PM, James Cameron qu...@laptop.org wrote:

 On Thu, Jul 24, 2014 at 03:50:47AM -0700, Sumit Acharya wrote:
  Thanks for all of your suggestions.
  I worked around the solution to the problem something like this:
 
  1. Created a udev rule that starts a new service when external
  hard-drive is detected
 
  KERNEL==sd?1, SUBSYSTEMS==scsi, DRIVERS==sd, ACTION==add,
 RUN+=/usr/
  bin/systemctl --no-block start nexc@%k.service

 For further optimisation in future, this might be reduced to the
 SYSTEMD_WANTS or SYSTEMD_USER_WANTS keyword.  I've not tested, but
 that's the keyword I saw mentioned by other people in the same
 situation.

  2. From the service called the update-script to run.
 
  [Unit]
  Description=Installs NEXC content to the system
  BindsTo=dev-%i.device
 
  [Service]
  Type=simple
  ExecStart=/root/nexc-update.sh %I

 Good work!

 --
 James Cameron
 http://quozl.linux.org.au/



From: Sumit Acharya sumit.acha...@olenepal.org
Date: Tue, Jul 22, 2014 at 8:30 AM
Subject: [XSCE] systemd-udevd timeout error while running the set of
scripts using usbmount
To: xsce-de...@googlegroups.com

Dear all,

I am currently working in migrating epustakalaya (digital library system)
from XS-0.7 based schoolserver to fedora-18/XSCE-5.0 based system. So far
all the contents are running well in the new system. I am facing a problem
in auto-installing the contents from external hard-drive to the system.

As similar to the earlier NEXS versions, I am trying to use the usbmount
feature. While the script is running and the contents are being  installed,
'systemd-udevd' genarates a timeout error (after 30 secs of the usb drive
plugged in) and the process gets terminated. I find a timeout value to be
30 inside /sys/devices/pci:00/:
00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/host6/target6:0:0/6:0:0:0/. Therefore, I
added a udev rule to change the timeout value of the device, but that
didn't  work.

udev rule:
81-nexc.rules
KERNEL==sdb, SUBSYSTEMS==scsi, DRIVERS==sd, ACTION==add,
RUN+=/root/NEXC-timeout.sh

NEXC-timeout.sh
#!/bin/bash
test=`echo $(udevadm info -q path -n /dev/sdb1) | sed
's/\/block\/sdb\/sdb1//g'`
echo 120  /sys$test/timeout

Next, I tried to modify the timeout value by adding following lines to
/usr/share/usbmount/usbmount script right after mounting the external
drive, but that doesn't seem to work either.
echo 60  /sys$DEVPATH/../device/timeout

The timeout values in both cases replace the respective default values, but
has no effect in operation.

What may be the possible ways of fixing this bug or working around the
problem?
Is there some other ways of auto-updating the contents from external
hard-drive to the schoolserver in XSCE 5.0 ?

Thanks in advance.
Sumit

Complete error message:
Jul 22 17:15:06 schoolserver.test.xsce systemd-udevd[368]: worker [3055]
/devices/pci:00/:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/host6/target6:0:0/6:0:0:0/block/sdb/sdb1
timeout; kill it
Jul 22 17:15:06 schoolserver.test.xsce systemd-udevd[368]: seq 2284
'/devices/pci:00/:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/host6/target6:0:0/6:0:0:0/block/sdb/sdb1'
killed
Jul 22 17:15:06 schoolserver.test.xsce systemd-udevd[368]: worker [3055]
terminated by signal 9 (Killed)
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


[Server-devel] iiab on xo-4

2014-07-25 Thread Tim Moody
We switched xsce to using pip instead of rpms to install iiab in order to get 
the latest version.  However, during the install process on an xo-4 I get 
IOError: [Errno 28] No space left on device.  I notice that /tmp has 0 bytes 
available.  It’s contents are

drwxr-xr-x 17 root root 340 Jul 25 21:03 pip-build-root
drwx--  2 root root  60 Jul 25 21:02 pip-nd2tVc-unpack
drwx--  3 root root  60 Jul 25 20:56 systemd-private-Dn2ozM
drwx--  3 root root  60 Jul 25 20:56 systemd-private-m5Or2z

Any suggestions?  We didn’t get this error when using rpms.  Is there an easy 
way to build the rpms?

I tried cloning https://github.com/braddockcg/internet-in-a-box.git

and running internet-in-a-box/scripts/build_rpms.sh

but I got

iiab_id_rsa private key must be in current directory

Tim___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] [IIAB] iiab on xo-4

2014-07-25 Thread Braddock Gaskill
Hi Tim,
pip builds its packages in /tmp by default.  You can specify a different
directory where you have enough disk space.

See
http://stackoverflow.com/questions/10617198/pip-creates-build-directories

pip install -b customized_build_directory to specify another directory as
build base directory, for example /tmp




On Fri, Jul 25, 2014 at 2:20 PM, Tim Moody t...@timmoody.com wrote:

   We switched xsce to using pip instead of rpms to install iiab in order
 to get the latest version.  However, during the install process on an xo-4
 I get IOError: [Errno 28] No space left on device.  I notice that /tmp has
 0 bytes available.  It’s contents are

 drwxr-xr-x 17 root root 340 Jul 25 21:03 pip-build-root
 drwx--  2 root root  60 Jul 25 21:02 pip-nd2tVc-unpack
 drwx--  3 root root  60 Jul 25 20:56 systemd-private-Dn2ozM
 drwx--  3 root root  60 Jul 25 20:56 systemd-private-m5Or2z

 Any suggestions?  We didn’t get this error when using rpms.  Is there an
 easy way to build the rpms?

 I tried cloning https://github.com/braddockcg/internet-in-a-box.git

 and running internet-in-a-box/scripts/build_rpms.sh

 but I got

 iiab_id_rsa private key must be in current directory

 Tim

___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] iiab on xo-4

2014-07-25 Thread James Cameron
On OLPC OS the /tmp directory is a tmpfs, with a limited size.

See df /tmp

Disabling that feature or changing the size is a step in my checklist
before serious use of the OS as a server platform.

But there will be other things to bite you later.  It's not default
Fedora.  You could be using olpc-os-builder to make a build without
optimisations for personal use and power management that we added.

I agree with Braddock, tell pip to use another directory.

-- 
James Cameron
http://quozl.linux.org.au/
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] [IIAB] iiab on xo-4

2014-07-25 Thread Tim Moody
this looks promising

Tim

From: Braddock Gaskill 
Sent: Friday, July 25, 2014 5:25 PM
To: Internet In a Box Working Group 
Cc: XSCE/xsce ; server-devel 
Subject: Re: [IIAB] iiab on xo-4

Hi Tim, 
pip builds its packages in /tmp by default.  You can specify a different 
directory where you have enough disk space.

See http://stackoverflow.com/questions/10617198/pip-creates-build-directories

pip install -b customized_build_directory to specify another directory asbuild 
base directory, for example /tmp








On Fri, Jul 25, 2014 at 2:20 PM, Tim Moody t...@timmoody.com wrote:

  We switched xsce to using pip instead of rpms to install iiab in order to get 
the latest version.  However, during the install process on an xo-4 I get 
IOError: [Errno 28] No space left on device.  I notice that /tmp has 0 bytes 
available.  It’s contents are

  drwxr-xr-x 17 root root 340 Jul 25 21:03 pip-build-root
  drwx--  2 root root  60 Jul 25 21:02 pip-nd2tVc-unpack
  drwx--  3 root root  60 Jul 25 20:56 systemd-private-Dn2ozM
  drwx--  3 root root  60 Jul 25 20:56 systemd-private-m5Or2z

  Any suggestions?  We didn’t get this error when using rpms.  Is there an easy 
way to build the rpms?

  I tried cloning https://github.com/braddockcg/internet-in-a-box.git

  and running internet-in-a-box/scripts/build_rpms.sh

  but I got

  iiab_id_rsa private key must be in current directory

  Tim
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel