A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: Function create_function() is deprecated

Filename: geshi/geshi.php

Line Number: 4751

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

ZFS Snapshot tool - mcpaste

ZFS Snapshot tool

Von MC, 8 Jahre vorher, geschrieben in Bash, aufgerufen 1'477 mal.
URL https://mcpaste.de/view/f82eaab3 Einbetten
Paste herunterladen oder Rohtext anzeigen
  1. #!/bin/sh
  2.  
  3. if [ "$(id -u)" != "0" ]
  4. then
  5.     echo "Please run as root"
  6.     exit
  7. fi
  8.  
  9.  
  10.  
  11. getName(){
  12.  
  13. RES=$1
  14.  
  15. # show an inputbox
  16. name=`dialog --title "Snapshot Tool" \
  17. --backtitle "Aufgabe 6" \
  18. --inputbox "Please enter the name for the shotsnap " 8 60 3>&1 1>&2 2>&3`
  19. eval $RES="'$name'"
  20.  
  21. }
  22.  
  23. getDataSet(){
  24.         RES=$1
  25.         LIST=`zfs list | awk 'BEGIN { c=0; }NR>1{printf("%s %i off ",$1,c);c++;}'`
  26.         ANSWER=`dialog --radiolist "Please choose the pool to snapshot" 15 50 8 $LIST 3>&1 1>&2 2>&3`
  27.         eval $RES="'$ANSWER'"
  28. }
  29.  
  30.  
  31. getDataSet SET
  32.  
  33. getName NAME
  34.  
  35. zfs snapshot $SET@$NAME
  36.  
  37. ALLSNAPS=`zfs list -t snapshot | awk '{c=0;}{if(NR < 2){next;} printf("%s %i off ",$1,c);c++;}'`
  38.  
  39. ROLLBACK=`dialog --radiolist "Please choose the a snapshot to rollback to" 15 50 8 $ALLSNAPS 3>&1 1>&2 2>&3`
  40.  
  41. zfs rollback -r $ROLLBACK
  42.  
  43. dialog --msgbox "Successfully roled back to $ROLLBACK" 25 35
  44.  
  45.  
  46.  

Antwort auf "ZFS Snapshot tool"

Hier kannst Du auf den Paste von oben antworten

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876