source: server/tftpboot/grub/default @ 0fd42f4

918-git-images-111dconfigfileconfigure-oglivegit-imageslgromero-new-oglivemainmaint-cronmount-efivarfsmultivmmultivm-ogboot-installerogClonningEngineogboot-installer-jenkinsoglive-ipv6test-python-scriptsticket-301ticket-50ticket-50-oldticket-577ticket-585ticket-611ticket-612ticket-693ticket-700ubu24tplunification2use-local-agent-oglivevarios-instalacion
Last change on this file since 0fd42f4 was 137ceb4, checked in by Irina Gómez <irinagomez@…>, 6 years ago

#802 #888 PXE templates for UEFI: 'default' and '1hd' support secure boot for 'rEFInd'. 'default' searches for installed boot loaders and displays a menu. 'ogLiveAdmin' only starts from the network (not from the cache)

  • Property mode set to 100644
File size: 1.7 KB
Line 
1# Busca cargadores existentes por orden de prioridad e
2#    inicia el primero que encuentra.
3# Si no existe ningún cargador de arranque muestre mensaje de error.
4set timeout=5
5
6set detectado='no'
7# Compruebo si existen distintos cargadores.
8echo "Searching rEFInd"
9search --file --set rootRefind /EFI/refind/shimx64.efi.signed
10if [ "$rootRefind" != "" ]; then
11    set detectado='si'
12    menuentry "rEFInd" {
13        root="$rootRefind"
14        chainloader /EFI/refind/shimx64.efi.signed
15}
16fi
17
18echo "Searching Part-01-02"
19search --file --set rootP2 /EFI/Part-01-02/Boot/ogloader.efi
20if [ "$rootP2" != "" ]; then
21    set detectado='si'
22    menuentry "Part-01-02" {
23        root="$rootP2"
24        chainloader /EFI/Part-01-02/Boot/ogloader.efi
25    }
26fi
27
28echo "Searching Part-01-03"
29search --file --set rootP3 /EFI/Part-01-03/Boot/ogloader.efi
30if [ "$rootP3" != "" ]; then
31    set detectado='si'
32    menuentry "Part-01-03" {
33        root="$rootP3"
34        chainloader /EFI/Part-01-03/Boot/ogloader.efi
35    }
36fi
37
38echo "Searching Microsoft"
39search --file --set rootMS /EFI/Microsoft/Boot/bootmgfw.efi
40if [ "$rootMS" != "" ]; then
41    set detectado='si'
42    menuentry "Microsoft" {
43        root="$rootMS"
44        chainloader /EFI/Microsoft/Boot/bootmgfw.efi
45    }
46fi
47
48echo "Searching Ubuntu"
49search --file --set rootUb /EFI/ubuntu/grubx64.efi
50if [ "$rootUb" != "" ]; then
51    set detectado='si'
52    menuentry "Ubuntu"
53        root="$rootUb"
54        chainloader /EFI/ubuntu/grubx64.efi
55    }
56fi
57
58
59# Si no hay ningún sistam operativo muestro mensaje.
60if [ $detectado == 'no' ]; then
61    menuentry "OpenGnsys no ha detectado ningún sistema operativo" {
62        # para evitar mensajes de error.
63        set root="(hd0,gpt1)"
64    }
65fi
Note: See TracBrowser for help on using the repository browser.