pxe boot, advanced menu with login isn't working



  • Added a few iso files to the PXE boot menu (UBCD, Hiren, Ect) and they work great when assigned to “All Hosts”. I would like to put them under the advanced menu with login section. When I do this choosing advanced login I get the prompt to login, which I do, then I can see it loading boot.php and advanced.php. At this point it exits and boots the host’s hard drive.

    Below is what is shown from the GUI going > iPXE Menu Customization > fog.advancedlogin which as far as I know hasn’t been edited.

    login\r\nparams\r\nparam mac0 ${net0/mac}\r\nparam arch ${arch}\r\nparam username ${username}\r\nparam password ${password}\r\nparam advLog 1\r\nisset ${net1/mac} && param mac1 ${net1/mac} || goto bootme\r\nisset ${net2/mac} && param mac2 ${net2/mac} || goto bootme
    

    Here is what I’m using for one of the isos.

    :Hirens\r\ninitrd http://${fog-ip}/${fog-webroot}/isos/hirens.iso\r\nchain memdisk iso raw ||\r\nboot
    

    I don’t see anything in the apache log for this.
    SVN: 5419 currently, saw issue on the past couple as well



  • @Tom-Elliott said:

    @Scott-B right but you don’t have anything in the advanced items. There is the login and it is working fine. But the advanced menu is its own configuration setting that you put your needs in.

    Ah… okay. I thought that was just called from fog.advancedlogin.


  • Senior Developer

    @Scott-B right but you don’t have anything in the advanced items. There is the login and it is working fine. But the advanced menu is its own configuration setting that you put your needs in.



  • @Tom-Elliott said:

    @Scott-B What is the same result?

    After checking box for “Advanced Login Required” > saving > booting > choosing advanced menu with login > entering login > loads default.php and advanced.php > then just moves on to the local hard disk. If there is an error between loading advanced.php and booting the loca disk, I can’t see it.


  • Senior Developer

    @Scott-B What is the same result?



  • @Tom-Elliott said:

    @Scott-B It’s becasue the link is set to All hosts for the “show with”.

    Please change this back to “Advanced Login Required” and you should see the proper advanced menu work.

    Same result.


  • Senior Developer

    @Scott-B It’s becasue the link is set to All hosts for the “show with”.

    Please change this back to “Advanced Login Required” and you should see the proper advanced menu work.



  • @Tom-Elliott

    I did not (knowingly) make a custome advanced menu login. I did make an entry for each ISO.

    0_1447943264900_checkbox3.PNG


  • Senior Developer

    @Scott-B Did you create your own advanced login custom meny?



  • @Tom-Elliott said:

    @Scott-B Advanced login requires you to login first. Try unchecking the advanced login checkbox and save, and see if that helps you out.

    The advanced checkbox here? If so, still there.

    0_1447942953678_checkbox.PNG

    0_1447942957745_checkbox2.PNG


  • Senior Developer

    @Scott-B Advanced login requires you to login first. Try unchecking the advanced login checkbox and save, and see if that helps you out.



  • @Tom-Elliott said:

    I saw it and fixed in in the current trunk.

    SVN: 5441

    I get the login under the advanced menu, but it still just boots the first drive. Is my advanced login setup wrong somehow (I thought it was default)? Looks different to the one posted by @CLAUDE GIRARD in the link he posted.

    login
    params
    param mac0 ${net0/mac}
    param arch ${arch}
    param username ${username}
    param password ${password}
    param advLog 1
    isset ${net1/mac} && param mac1 ${net1/mac} || goto bootme
    isset ${net2/mac} && param mac2 ${net2/mac} || goto bootme
    

  • Senior Developer

    I saw it and fixed in in the current trunk.



  • @Tom-Elliott said:

    @Scott-B where are the \r\n lines doing? Or was this file edited/opened by Windows?

    They show up in place of spaces after making a change and then going back into the menu item. I get the thing in the host description when doing an inventory extract as well. What I put into each of my added it menu items should show up below. Each one is their own menu choice item.

    :sysrescue
    initrd http://${fog-ip}/${fog-webroot}/isos/systemrescuecd.iso
    chain memdisk iso raw ||
    boot
    
    
    :ultimate
    initrd http://${fog-ip}/${fog-webroot}/isos/ubcd535.iso
    chain memdisk iso raw ||
    boot
    
    :DBAN
    kernel ${boot_url}/fog/isos/dban/dban.bzi nuke="dwipe --autonuke" silent vga=785
    boot
    
    :Hirens
    initrd http://${fog-ip}/${fog-webroot}/isos/hirens.iso
    chain memdisk iso raw ||
    boot
    

  • Senior Developer

    I’ve updated the files now and i now replace the \r\n lines with the simple \n which will print as a “new line”.

    I also an decoding the html entities now to ensure the & is displayed as just the & symbol (or any of the encoded items are displayed as their relative symbol).



  • @Tom-Elliott said:

    @Scott-B where are the \r\n lines doing? Or was this file edited/opened by Windows?

    Hi Tom

    I think this is because of escaped characters again.
    May I open a specific thread for these problems ?

    I have these \r\n for example in image description when I write this text on several lines, with return between each one.

    I saw escaped problems in:
    snapins fields
    PXE menu
    host or image description

    Maybe could be the same in other fields

    And what is problematic:
    french accents é, à , ê, etc …
    antislashes
    &
    Line feed and/or carriage return
    Maybe more … :-(

    Sometimes I can see that in database, but not in FOG interface (for example \r\n isn’t visible in fog interface but is in database)
    Sometimes I can see in both (for example for french accents)


  • Senior Developer

    @Scott-B where are the \r\n lines doing? Or was this file edited/opened by Windows?



  • Can you verify in fog database, GLobal settings table, settingkey FOG_PXE_ADVANCED, and see if these lines are the same in database ?

    Maybe same problem than:
    https://forums.fogproject.org/topic/5752/new-client-some-snapins-doesn-t-work-ok-with-legacy-client/15

    where && become &\amp;

    I remember that advanced menu didn’t work and host booted on hard drive



366
Online

38976
Users

10712
Topics

101675
Posts

Looks like your connection to FOG Project was lost, please wait while we try to reconnect.