MasterCorneilous

where to put the iso file

Sep 3rd, 2025
14
0
Never
3
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.28 KB | None | 0 0
  1. #
  2. # DO NOT EDIT THIS FILE
  3. #
  4. # It is automatically generated by grub2-mkconfig using templates
  5. # from /etc/grub.d and settings from /etc/default/grub
  6. #
  7.  
  8. ### BEGIN /etc/grub.d/00_header ###
  9. set pager=1
  10.  
  11. if [ -f ${config_directory}/grubenv ]; then
  12. load_env -f ${config_directory}/grubenv
  13. elif [ -s $prefix/grubenv ]; then
  14. load_env
  15. fi
  16. if [ "${next_entry}" ] ; then
  17. set default="${next_entry}"
  18. set next_entry=
  19. save_env next_entry
  20. set boot_once=true
  21. else
  22. set default="${saved_entry}"
  23. fi
  24.  
  25. if [ x"${feature_menuentry_id}" = xy ]; then
  26. menuentry_id_option="--id"
  27. else
  28. menuentry_id_option=""
  29. fi
  30.  
  31. export menuentry_id_option
  32.  
  33. if [ "${prev_saved_entry}" ]; then
  34. set saved_entry="${prev_saved_entry}"
  35. save_env saved_entry
  36. set prev_saved_entry=
  37. save_env prev_saved_entry
  38. set boot_once=true
  39. fi
  40.  
  41. function savedefault {
  42. if [ -z "${boot_once}" ]; then
  43. saved_entry="${chosen}"
  44. save_env saved_entry
  45. fi
  46. }
  47.  
  48. function load_video {
  49. if [ x$feature_all_video_module = xy ]; then
  50. insmod all_video
  51. else
  52. insmod efi_gop
  53. insmod efi_uga
  54. insmod ieee1275_fb
  55. insmod vbe
  56. insmod vga
  57. insmod video_bochs
  58. insmod video_cirrus
  59. fi
  60. }
  61.  
  62. terminal_output console
  63. if [ x$feature_timeout_style = xy ] ; then
  64. set timeout_style=menu
  65. set timeout=5
  66. # Fallback normal timeout code in case the timeout_style feature is
  67. # unavailable.
  68. else
  69. set timeout=5
  70. fi
  71. ### END /etc/grub.d/00_header ###
  72.  
  73. ### BEGIN /etc/grub.d/00_tuned ###
  74. set tuned_params=""
  75. export tuned_params
  76. set tuned_initrd=""
  77. export tuned_initrd
  78. ### END /etc/grub.d/00_tuned ###
  79.  
  80. ### BEGIN /etc/grub.d/01_users ###
  81. if [ -f ${prefix}/user.cfg ]; then
  82. source ${prefix}/user.cfg
  83. if [ -n "${GRUB2_PASSWORD}" ]; then
  84. set superusers="root"
  85. export superusers
  86. password_pbkdf2 root ${GRUB2_PASSWORD}
  87. fi
  88. fi
  89. ### END /etc/grub.d/01_users ###
  90.  
  91. ### BEGIN /etc/grub.d/08_fallback_counting ###
  92. insmod increment
  93. # Check if boot_counter exists and boot_success=0 to activate this behaviour.
  94. if [ -n "${boot_counter}" -a "${boot_success}" = "0" ]; then
  95. # if countdown has ended, choose to boot rollback deployment,
  96. # i.e. default=1 on OSTree-based systems.
  97. if [ "${boot_counter}" = "0" -o "${boot_counter}" = "-1" ]; then
  98. set default=1
  99. set boot_counter=-1
  100. # otherwise decrement boot_counter
  101. else
  102. decrement boot_counter
  103. fi
  104. save_env boot_counter
  105. fi
  106. ### END /etc/grub.d/08_fallback_counting ###
  107.  
  108. ### BEGIN /etc/grub.d/10_linux ###
  109. insmod part_gpt
  110. insmod ext2
  111. set root='hd0,gpt2'
  112. if [ x$feature_platform_search_hint = xy ]; then
  113. search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2 b20560cb-96e1-447f-a4f0-ba8d610c8931
  114. else
  115. search --no-floppy --fs-uuid --set=root b20560cb-96e1-447f-a4f0-ba8d610c8931
  116. fi
  117. insmod part_gpt
  118. insmod fat
  119. set boot='hd0,gpt1'
  120. if [ x$feature_platform_search_hint = xy ]; then
  121. search --no-floppy --fs-uuid --set=boot --hint-bios=hd0,gpt1 --hint-efi=hd0,gpt1 --hint-baremetal=ahci0,gpt1 3054-6E73
  122. else
  123. search --no-floppy --fs-uuid --set=boot 3054-6E73
  124. fi
  125.  
  126. # This section was generated by a script. Do not modify the generated file - all changes
  127. # will be lost the next time file is regenerated. Instead edit the BootLoaderSpec files.
  128. #
  129. # The blscfg command parses the BootLoaderSpec files stored in /boot/loader/entries and
  130. # populates the boot menu. Please refer to the Boot Loader Specification documentation
  131. # for the files format: https://systemd.io/BOOT_LOADER_SPECIFICATION/.
  132.  
  133. # The kernelopts variable should be defined in the grubenv file. But to ensure that menu
  134. # entries populated from BootLoaderSpec files that use this variable work correctly even
  135. # without a grubenv file, define a fallback kernelopts variable if this has not been set.
  136. #
  137. # The kernelopts variable in the grubenv file can be modified using the grubby tool or by
  138. # executing the grub2-mkconfig tool. For the latter, the values of the GRUB_CMDLINE_LINUX
  139. # and GRUB_CMDLINE_LINUX_DEFAULT options from /etc/default/grub file are used to set both
  140. # the kernelopts variable in the grubenv file and the fallback kernelopts variable.
  141. if [ -z "${kernelopts}" ]; then
  142. set kernelopts="root=UUID=c5880c36-9b5f-425a-bf3b-bbec2fc0608a ro rootflags=subvol=root rhgb quiet "
  143. fi
  144.  
  145. insmod blscfg
  146. blscfg
  147. ### END /etc/grub.d/10_linux ###
  148.  
  149. ### BEGIN /etc/grub.d/10_reset_boot_success ###
  150. # Hiding the menu is ok if last boot was ok or if this is a first boot attempt to boot the entry
  151. if [ "${boot_success}" = "1" -o "${boot_indeterminate}" = "1" ]; then
  152. set menu_hide_ok=1
  153. else
  154. set menu_hide_ok=0
  155. fi
  156. # Reset boot_indeterminate after a successful boot
  157. if [ "${boot_success}" = "1" ] ; then
  158. set boot_indeterminate=0
  159. # Avoid boot_indeterminate causing the menu to be hidden more than once
  160. elif [ "${boot_indeterminate}" = "1" ]; then
  161. set boot_indeterminate=2
  162. fi
  163. # Reset boot_success for current boot
  164. set boot_success=0
  165. save_env boot_success boot_indeterminate
  166. ### END /etc/grub.d/10_reset_boot_success ###
  167.  
  168. ### BEGIN /etc/grub.d/12_menu_auto_hide ###
  169. if [ x$feature_timeout_style = xy ] ; then
  170. if [ "${menu_show_once}" ]; then
  171. unset menu_show_once
  172. save_env menu_show_once
  173. set timeout_style=menu
  174. set timeout=60
  175. elif [ "${menu_auto_hide}" -a "${menu_hide_ok}" = "1" ]; then
  176. set orig_timeout_style=${timeout_style}
  177. set orig_timeout=${timeout}
  178. if [ "${fastboot}" = "1" ]; then
  179. # timeout_style=menu + timeout=0 avoids the countdown code keypress check
  180. set timeout_style=menu
  181. set timeout=0
  182. else
  183. set timeout_style=hidden
  184. set timeout=1
  185. fi
  186. fi
  187. fi
  188. ### END /etc/grub.d/12_menu_auto_hide ###
  189.  
  190. ### BEGIN /etc/grub.d/14_menu_show_once ###
  191. if [ x$feature_timeout_style = xy ]; then
  192. if [ "${menu_show_once_timeout}" ]; then
  193. set timeout_style=menu
  194. set timeout="${menu_show_once_timeout}"
  195. unset menu_show_once_timeout
  196. save_env menu_show_once_timeout
  197. fi
  198. fi
  199. ### END /etc/grub.d/14_menu_show_once ###
  200.  
  201. ### BEGIN /etc/grub.d/20_linux_xen ###
  202.  
  203. ### END /etc/grub.d/20_linux_xen ###
  204.  
  205. ### BEGIN /etc/grub.d/20_ppc_terminfo ###
  206. ### END /etc/grub.d/20_ppc_terminfo ###
  207.  
  208. ### BEGIN /etc/grub.d/25_bli ###
  209. if [ "$grub_platform" = "efi" ]; then
  210. if [ ! insmod bli ]; then
  211. echo "bli module not available"
  212. fi
  213. fi
  214. ### END /etc/grub.d/25_bli ###
  215.  
  216. ### BEGIN /etc/grub.d/30_os-prober ###
  217. ### END /etc/grub.d/30_os-prober ###
  218.  
  219. ### BEGIN /etc/grub.d/30_uefi-firmware ###
  220. if [ "$grub_platform" = "efi" ]; then
  221. if [ fwsetup --is-supported ]; then
  222. menuentry 'UEFI Firmware Settings' $menuentry_id_option 'uefi-firmware' {
  223. fwsetup
  224. }
  225. fi
  226. fi
  227. ### END /etc/grub.d/30_uefi-firmware ###
  228.  
  229. ### BEGIN /etc/grub.d/35_fwupd ###
  230. ### END /etc/grub.d/35_fwupd ###
  231.  
  232. ### BEGIN /etc/grub.d/40_custom ###
  233. # This file provides an easy way to add custom menu entries. Simply type the
  234. # menu entries you want to add after this comment. Be careful not to change
  235. # the 'exec tail' line above.
  236. ### END /etc/grub.d/40_custom ###
  237.  
  238. ### BEGIN /etc/grub.d/41_custom ###
  239. if [ -f ${config_directory}/custom.cfg ]; then
  240. source ${config_directory}/custom.cfg
  241. elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
  242. source $prefix/custom.cfg
  243. fi
  244. ### END /etc/grub.d/41_custom ###
Advertisement
Comments
  • MasterCorneilous
    91 days (edited)
    # text 0.02 KB | 0 0
    1. matsaman you there?
  • # text 0.25 KB | 0 0
    1. on 40_custom all it says is this #!/usr/bin/sh
    2. exec tail -n +3 $0
    3. # This file provides an easy way to add custom menu entries. Simply type the
    4. # menu entries you want to add after this comment. Be careful not to change
    5. # the 'exec tail' line above.
  • # text 0.51 KB | 0 0
    1. ok it looks like this
    2.  
    3. exec tail -n +3 $0
    4. menuentry "Debian" --class fedora --class gnu-linux --class gnu --class os {
    5. set iso_path="/home/bruh/Downloads/debian-live-13.0.0-amd64-cinnamon.iso"
    6. export iso_path
    7. search --set=root --file $iso_path
    8. loopback loop (hd0,2)/$iso_path
    9. probe --set isolabel --label (loop)
    10. linux (loop)/isolinux/vmlinuz root=live:CDLABEL=${isolabel} rd.live.image verbose iso-scan/filename=${iso_path}
    11. initrd (loop)/isolinux/initrd.img
Add Comment
Please, Sign In to add comment