LUA ERROR: Can not open /boot/lua/loader.lua

Looking at the numerous bug reports I get the impression that the new bootstrap code possibly in some cases might order CAM devices incorrectly, maybe due to some confusion/bug in hardware recognition, and in this case booting fails.

It might also be an issue with particular optical drives, as I some time ago had to try multiple DVD drives from my storage until booting the ISO succeeded. (I suspected some problem with the drives, as they were used but refurbished. But, further examination of the drives 'rejected' by FreeBSD DVD only showed perfect functional state, not downgraded in any way.)

There are several reports in the PR linked in your link that look like as if unplugging the optical drive and installing via USB stick could be a work-around to make FreeBSD work.

In this case, instead of an internal optical drive, one probably would need an external one that can be unplugged while booting.
Another alternative might be installing a switch on the front plate, so you can power on the internal optical drive after boot-up.
Sadly, both options are not viable for me.
 
Does the trick to replace the lua bootloader with the old (11.2) one no longer work?
I ask, because, reading back more in this thread and <self-censored>, I am really considering to add the option "Remove Lua bootloader" in my postinstaller.
 
I have downloaded FreeBSD-13.0-RELEASE-amd64-disc1.iso today, 18-Oct-21, burnt it to a disk and booted from it (on an old AMD-64 system which has been running Linux for many years).
I get this same old error: LUA ERROR: Cannot open /boot/lua/loader.lua: no such file or directory
Did anybody find a solution for this? Or is FreeBSD just not supported on older hardware now?
 
Getting this with the 13.1 RC1 both on an 13.0 install after a freebsd-update upgrade as well as on a clean install.
 
Having this while trying to pxe-boot a Orange Pi Zeo. It drops to a pre-boot prompt. The "missing" file does exist, however, there's no filesystem yet. ls / doesn't work. It looks related...
Code:
console comconsole failed to initialize
Consoles: EFI console
    Reading loader env vars from /efi/freebsd/loader.env
FreeBSD/arm EFI loader, Revision 1.1

   Command line arguments: l
   Image base: 0x5adee000
   EFI version: 2.90
   EFI Firmware: Das U-Boot (rev 8226.1792)
   Console: efi,comconsole (0)
   Load Path: /\boot\loader_lua.efi
   Load Device: /VenHw(e61d73b9-a384-4acc-aeab-82e828f3628b)/MAC(02429082c74f,1)
Setting currdev to net0:
net0: cannot set rx. filters (status=3)
Setting currdev to net0:
ERROR: cannot open /boot/lua/loader.lua: no such file or directory.


Type '?' for a list of commands, 'help' for more detailed help.
OK ls /
open '/' failed: no such file or directory
OK

What are rx. filters?

Due to lack of information, I'm not sure how it should be done, but it's supposed to work. I've seen people mentioning the partitioning scheme MBR vs GPT of the boot-volume could be cause, but this is PXE with nfs. The nfs-server is a Qemu virtual machine with a UFS root filesystem. Sounds far fetched...
Also the host's BIOS/UEFI settings are supposed to be relevant, but this is a ARM7 board that I boot while watching the serial output. No such thing as bios-settings.
 
Just a note: this does not look right to me.
This is the /boot directory of the FreeBSD arm7 image. (The system partition #2, not the FAT32 #1 that most of these boards require for configuration)
There's pxeboot, that doesn't do anything. I may be wrong but I think it's only for PC systems. Then there are various loader_*.efi files. Currently trying them out.
 
Software:
FreeBSD-13.3-BETA1-i386-dvd1

Hardware:
Laptop Acer Travelmate 2480
BIOS v1.3211
Intel Celeron M 430 1.73GHz
IDE HDD
IDE CDROM

In my case "lua-problem" while installing os with cdrom & dvd-iso was solved by removing/disabling from boot-order-list in BIOS every item except CDROM.
 
I am probably way off the precise topic here, but I have been dual booting Windows and FreeBSD for a few years. At some point, I started using reFind and still do. At another point, I suddenly started getting the "lua error". For the last year or two, I worked around it by configuring grub in Ubuntu (the third OS on my Lenovo E14) and was able to start FreeBSD from the grub menu. (I also have a desktop with Windows and FreeBSD which reFind handles with no problem).

After doing the release upgrade to FreeBSD 15.0, I decided that the Ubuntu on the laptop was not being used and I needed the disk space for the Windows and FreeBSD os's, but removing Ubuntu meant no grub and being unable to boot FreeBSD because of the "lua error".

The main point I want to share in case it helps any body is that I finally realized that the "lua error" was leaving me in the "boot prompt". Not being so knowledgable, I was unable to make use of the boot prompt until yesterday when I realized that I could use the following two commands at the boot prompt:

set currdev=disk0p5
chain /boot/loader.efi

disk0p5 is the partition on which FreeBSD is installed obtained from, say, "gpart show" and "lsdev". With these two commands, FreeBSD started normally without any need for resorting to grub. Although this may not be relevant in more complex situations, but to me it was a relief to find this method of starting FreeBSD from the boot prompt without grub, so I just share it in case its useful to anybody.
 
Back
Top