#931 Issue closed: PXE Support for null is not implemented yet

Labels: support / question, fixed / solved / done

RolfWeilen opened issue at 2016-07-20 07:16:

Relax-and-Recover (rear) Issue Template

Please fill in the following items before submitting a new issue:

  • rear version (/usr/sbin/rear -V):
    Relax-and-Recover 1.18 / Git
  • OS version (cat /etc/rear/os.conf or lsb_release -a):
  OS_VENDOR=RedHatEnterpriseServer
  OS_VERSION=7
  • rear configuration files (cat /etc/rear/site.conf or cat /etc/rear/local.conf):
  OUTPUT=PXE
  OUTPUT_URL=file:/var/lib/rear/output/
  OUTPUT_PREFIX_PXE=rearboot
  ISO_DEFAULT=manuel
  OUTPUT_URL=null
  BACKUP=TSM
  TIMESYNC=NTP
  TSM_RESULT_SAVE=n
  TSM_RESULT_FILE_PATH=""
  USE_DHCLIENT=y
  USE_STATIC_NETWORKING=n
   # Include only rootvg
  ONLY_INCLUDE_VG=(res9915vg00)
  # Add an group Entry

  GRUB_RESCUE=n

pmr_info.txt

  • Brief description of the issue
    When generate the pxe files:
  2016-07-19 09:34:34.597905922 Created pxelinux config 'rear-res9915' and symlinks for MAC adresses in /var/lib/rear/output
  2016-07-19 09:34:34.601938126 Including output/PXE/default/82_copy_to_net.sh
  2016-07-19 09:34:34.606798591 ERROR: BUG BUG BUG!  Support for null is not implemented yet. 
  === Issue report ===
  Please report this unexpected issue at: https://github.com/rear/rear/issues
  Also include the relevant bits from /var/log/rear/rear-res9915.log
  • Work-around, if any
    It works not workaround is needed

jsmeix commented at 2016-07-20 08:15:

I find 'Support for .* is not implemented yet' in
usr/share/rear/output/PXE/default/82_copy_to_net.sh
usr/share/rear/output/RAMDISK/Linux-i386/90_copy_ramdisk.sh
usr/share/rear/output/default/95_copy_result_files.sh
as

case "$scheme" in
    ...
    (*) BugError "Support for $scheme is not implemented yet.";;

This shows that the root cause is your incorrect URL

OUTPUT_URL=file:/var/lib/rear/output/
...
OUTPUT_URL=null

and the incorrect duplicate setting of OUTPUT_URL.

See the rear documentation and the general RFC
how a URL must look like, e.g.:

nfs://lucky/temp/backup
cifs://lucky/temp
usb:///dev/sdb1
tape:///dev/nst0
file:///path
iso://backup/
sshfs://user@host/G/rear/
ftpfs://user:password@host/rear/ (the password part is optional)

I will fix the misleading error message.

jsmeix commented at 2016-07-20 09:22:

With https://github.com/rear/rear/pull/932
rear now errors out instead of a BugError
for not implemented URI schemes because
it is not a bug in rear when some functionality
is not yet implemented.

FYI:
BugError is usually meant for things like

some code that is known to do "something" reliably
# success is mandatory to proceed (any failure is unexpected)
if not "something" then BugError "Failed to do something"

Another example is in lib/_input-output-functions.sh

BugError "Forbidden use of trap with '$@'. Use AddExitTask instead."

which detects a real programming bug.

jsmeix commented at 2016-07-21 07:47:

@RolfWeilen
FYI
how to test current rear GitHub master code:

# git clone https://github.com/rear/rear.git
# cd rear
# vi etc/rear/local.conf
# usr/sbin/rear -d -D mkbackup

i.e. configure and run rear from within the directory
whereto the rear master code was cloned from GitHub.


[Export of Github issue for rear/rear.]