Page MenuHomeVyOS Platform

The op-mode command run show history does not work from configuration mode
Closed, ResolvedPublicBUG

Description

The op-mode command run show history does not work from configuration mode

vyos@r14# run show history 
sudo: set: command not found
[edit]
vyos@r14#

From op-mode level works, but we see unexpected sudo: set: command not found

vyos@r14:~$ show history 
sudo: set: command not found
    1  2026-04-10T14:39:52+0000 conf
    2  2026-04-10T14:39:52+0000 conf
    3  2026-04-10T14:39:56+0000 run show history 
    4  2026-04-10T14:41:01+0000 exit
    5  2026-04-10T14:41:03+0000 show history 
vyos@r14:~$

https://github.com/vyos/vyos-1x/blob/6576c362e8ad461c34d1b1f9b4c23c6c99b8f024/op-mode-definitions/show-history.xml.in#L9

Details

Version
VyOS 2026.04.10-0031-rolling
Is it a breaking change?
Perfectly compatible
Issue type
Bug (incorrect behavior)

Event Timeline

Viacheslav triaged this task as Normal priority.
natali-rs1985 changed the task status from Open to In progress.Apr 16 2026, 12:05 PM
natali-rs1985 claimed this task.
natali-rs1985 changed Is it a breaking change? from Unspecified (possibly destroys the router) to Perfectly compatible.

In Circinus and Sagitta, show history works correctly in op-mode but breaks in config mode. The #timestamp lines from .bash_history are displayed as separate entries instead of being parsed as metadata, and all entries show the same timestamp.

vyos@vyos:~$ show history brief 
    1  2026-04-17T11:22:38+0000 conf
    2  2026-04-17T11:22:38+0000 conf
    3  2026-04-17T11:22:42+0000 run show history 
    4  2026-04-17T11:22:50+0000 exit
    5  2026-04-17T11:22:55+0000 show history 
    6  2026-04-17T11:23:10+0000 show history brief 
vyos@vyos:~$ conf
[edit]
vyos@vyos# run show history brief 
    1  2026-04-17T11:23:40+0000 #1776424958
    2  2026-04-17T11:23:40+0000 conf
    3  2026-04-17T11:23:40+0000 #1776424958
    4  2026-04-17T11:23:40+0000 conf
    5  2026-04-17T11:23:40+0000 #1776424962
    6  2026-04-17T11:23:40+0000 run show history 
    7  2026-04-17T11:23:40+0000 #1776424970
    8  2026-04-17T11:23:40+0000 exit
    9  2026-04-17T11:23:40+0000 #1776424975
   10  2026-04-17T11:23:40+0000 show history 
   11  2026-04-17T11:23:40+0000 #1776424990
   12  2026-04-17T11:23:40+0000 show history brief 
   13  2026-04-17T11:23:40+0000 #1776425011
   14  2026-04-17T11:23:40+0000 conf
[edit]
Viacheslav moved this task from Need Triage to Completed on the VyOS Rolling board.