DEC3860 mini-USB Console

Started by Mbl, May 22, 2022, 07:35:18 PM

Previous topic - Next topic
Hmmm just checked one of the latest backup files and have found this:

<disableconsolemenu>1</disableconsolemenu>

Looks like I have disabled console once in the past (even if I don't why I should have done this  ::) )

Shouldn't that just present a login prompt instead of the menu?

Franco?
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)

Quote from: pmhausen on May 24, 2022, 06:41:11 PM
Shouldn't that just present a login prompt instead of the menu?

Franco?

Yes you're probably right. But I don't even get the promt

Quote from: Mbl on May 24, 2022, 06:38:45 PM
Hmmm just checked one of the latest backup files and have found this:

<disableconsolemenu>1</disableconsolemenu>

Looks like I have disabled console once in the past (even if I don't why I should have done this  ::) )

@Franco, is there a way (hack) to enable console without web or SSH access?

May 25, 2022, 11:35:39 AM #19 Last Edit: May 25, 2022, 11:37:39 AM by franco
Look, login(1) doesn't work. Whether it lets you auto-login or prompt for a user/password both of these things don't work if login(1) doesn't have a console to attach to. It could even be that the /etc/login.conf is trashed which is rare but it can happen. Manual recovery or troubleshoot of damaged file systems is difficult. Reinstall from an image with config import is a quick and easy recovery mechanism.

Still the question is if 22.4 serial stick behaves the same way and if maybe a 21.10 stick would not have these issues (different FreeBSD version).

And to stress that point: the "serial" image use is important here.


Cheers,
Franco

You could still boot single user and try to find out what's disabling the login prompt. You'll need quite a bit of FreeBSD experience, though, and I doubt this can be solved by question/answer ping pong via the forum in a reasonable amount of time.

Booting from an install/live medium to check if the serial console works *at all* is probably a good idea. And a way to a rescue procedure - boot into live mode, manually mount the installed system drive, copy the config.xml and look for hints what went wrong. Then sanitize the XML config, reinstall, reimport ...
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do. (Isaac Asimov)

Thanks for your replay Franco - very appreciated!

I have booted from serial USB image and console works well.

I know whats wrong on the config.xml to make the system working again. So would it not be possible to mount the local disk into the USB life environment or single user (as pmhausen mentioned), make manual changes on config.xml and boot again from local disk?

What type of device should I look at for the local disk on the DEC3860?

When having booted the stick go to console (option 8) and type

# opnsense-importer -m

It'll list the devices to attach to and mount it for you and execute  a shell for manual repair. It's going to tell you where the disk is mounted. Inside that directory under $DIR/conf/config.xml is the file to edit. Then type "exit" and reboot the stick. If it was the config.xml change the system should come back fine.

If not there are backups under $DIR/conf/backup/ that might help shed some light on what change was done when.

In any case fingers crossed. :)


Cheers,
Franco

System up and running!  :)

I have SSH and web access to the firewall again.

Strange that console is still not working. In config.xml I have chnaged <disableconsolemenu>1</disableconsolemenu> to "0". Looking at the GUI (see attached print screen) it should be enabled from my point of view.

BIOS has been set to UART Configuration Options --> UART 0 Legacy Options. Going to remove "hw.uart.console" and reboot and will report back...




Was to fast. hw.uart.console does not even exist on my system

USB-base serial ports setting is wrong. This is for directly connected USB consoles, not adapters that expose USB connectivity.

Pretty sure that's the issue (image defaults to off).


Cheers,
Franco

Quote from: franco on May 25, 2022, 02:20:07 PM
USB-base serial ports setting is wrong.

This did the trick. It's working now...

Thanks again for your superbe support!

Yay, happy to help :)


Cheers,
Franco