Changeset 580
- Timestamp:
- 11/21/09 12:58:51 (2 years ago)
- Location:
- main/linuxmuster-linbo/branches/testing
- Files:
-
- 4 edited
-
debian/changelog (modified) (1 diff)
-
linbo/init.sh (modified) (3 diffs)
-
linbo/linbo_cmd.sh (modified) (2 diffs)
-
share/rsync-post.sh (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
main/linuxmuster-linbo/branches/testing/debian/changelog
r572 r580 1 linuxmuster-linbo (1.99.13-0) unstable; urgency=low 2 3 * linbofs: 4 - linbo_cmd.sh, start(): moved killing ctorrent processes to earlier position in start process. 5 - init.sh: 6 o handling new parameter autostart=<int> 7 autostart=0 suppresses autostart generally in start.conf, 8 autostart=<nr> sets autostart for OS number nr in start.conf. 9 * server side scripting: 10 - rsync-post.sh: sync time for image and torrent files otherwise bittorrent gets confused 11 if uploaded torrent file time is in future. 12 13 -- Thomas Schmitt <schmitt@lmz-bw.de> Sat, 21 Nov 2009 12:01:54 +0100 14 1 15 linuxmuster-linbo (1.99.12-1) unstable; urgency=low 2 16 -
main/linuxmuster-linbo/branches/testing/linbo/init.sh
r530 r580 40 40 # Utilities 41 41 42 # test if variable is an integer 43 isinteger () { 44 [ $# -eq 1 ] || return 1 45 case $1 in 46 *[!0-9]*|"") return 1;; 47 *) return 0;; 48 esac 49 } 50 42 51 # DMA 43 52 enable_dma(){ … … 301 310 fi 302 311 echo "$RET" 312 } 313 314 # handle autostart from cmdline 315 set_autostart() { 316 # count [OS] entries 317 local counts="$(grep -ci ^"\[OS\]" /start.conf)" 318 # return if autostart value is greater than number of OS entries 319 [ $autostart -gt $counts -o $autostart -lt 0 ] && return 320 # return if autostart shall be suppressed generally 321 if [ "$autostart" = "0" ]; then 322 # set all autostart parameters to no 323 sed -e 's|^[Aa][Uu][Tt][Oo][Ss][Tt][Aa][Rr][Tt].*|Autostart = no|g' -i /start.conf 324 return 325 fi 326 # autostart OS at start.conf position given by autostart parameter 327 local c=0 328 local found=0 329 local line="" 330 while read -r line; do 331 if echo "$line" | grep -qi ^"\[OS\]"; then 332 let c=+1 333 [ "$autostart" = "$c" ] && found=1 334 fi 335 # suppress autostart for other OS entries 336 echo "$line" | grep -qi ^autostart || echo "$line" >> /start.conf.new 337 # write autostart line for specific OS 338 if [ "$found" = "1" ]; then 339 echo "Autostart = yes" >> /start.conf.new 340 found=0 341 fi 342 done </start.conf 343 mv /start.conf.new /start.conf 303 344 } 304 345 … … 354 395 # modify cache in start.conf if cache was given and no extra start.conf was defined 355 396 [ -z "$extra" -a -b "$cache" ] && modify_cache /start.conf 397 # set autostart if given on cmdline 398 isinteger "$autostart" && set_autostart 356 399 # remove reboot flag 357 400 rmlinboreboot -
main/linuxmuster-linbo/branches/testing/linbo/linbo_cmd.sh
r565 r580 598 598 return 1 599 599 fi 600 # kill torrents if any 601 ps w | grep ctorrent | grep -v grep &> /dev/null && killall -9 ctorrent 600 602 601 603 # No more timer interrupts … … 609 611 610 612 umount /mnt 2>/dev/null 611 # kill torrents if any612 ps w | grep ctorrent | grep -v grep && { killall ctorrent; sleep 3; }613 613 sendlog 614 614 umount /cache || umount -l /cache 2>/dev/null -
main/linuxmuster-linbo/branches/testing/share/rsync-post.sh
r518 r580 43 43 timage="$(btshowmetainfo "$LINBODIR/${FILE##*/}" | grep ^"file name" | awk '{ print $3 }')" 44 44 echo "Torrent file for $timage detected. Restarting bittorrent service." >&2 45 # sync time for image and torrent files otherwise bittorrent gets confused 46 # if uploaded torrent file time is in future 47 touch "${timage}*" 45 48 /etc/init.d/linbo-bittorrent restart >&2 46 49 /etc/init.d/bittorrent restart >&2
Note: See TracChangeset
for help on using the changeset viewer.
