Byobu: Behind the folding screen


Article from Issue 175/2015

The Byobu window manager and terminal multiplexer lets you open multiple screens to compartmentalize tasks performed at the command line and helps keep track of the status of your systems.

Byobu [1] is a hybrid utility. On one hand, it provides a practical setup for those who need to work from more than one command prompt at a time. On the other hand, it provides a wealth of basic system information in abbreviated form. With this double benefit, Byobu solves two problems with screen space at the same time.

Originally conceived at the 2008 Ubuntu Developer Summit, Byobu is intended primarily for administrators who need to view multiple servers. In addition to providing multiple prompts within the same window, Byobu also displays two customizable status lines for monitoring systems. The program runs as a text-based window manager on top of either tmux [2] or GNU Screen [3], two earlier multiplexers, making it usable without a desktop (Figure 1). The name comes from the Japanese word for a folding screen, a metaphor whose origin becomes obvious the first time you see Byobu in use.

Figure 1: Byobu running with three separate prompts on top of tmux (note title bar).

Basic Orientation

Byobu is available from the repositories of major distributions. It starts with the command byobu, which includes no options of its own. You might configure it to run the options of either tmux or GNU screen, but most of these options are either obsolete on a modern system – on which, for example, you can usually take UTF-8 character support for granted – or conflict with Byobu's own configuration settings.

Instead of command options, Byobu uses a cluster of commands with similar names. In particular, if you want Byobu to run at each text login, use the command byobu-enable (Figure 2). If Byobu is already is enabled, you disable it with byobu-disable or suppress it for remote sessions with:

ssh -T REMOTEHOST bash
Figure 2: Toggling Byobu to run at a text login.

Along the bottom of the screen are two status lines. The Ubuntu documentation [4] refers to the top status line as the Caption and the bottom as Hard Stats, although these terms are not used in the Byobu man page or anywhere on the interface. Whatever you call the status lines, the top line lists multiple prompts – called windows – on the left, numbering them by default, as well as such information as the username and hostname. By contrast, the bottom line shows symbols and abbreviations that give information about the local machine, such as the operating system, uptime, and cores.

You can hide the bottom status line by running byobu-quiet and hide both lines with byobu-silent. Adding the option --undo to either of these commands reverses the command, toggling the hidden status lines.

You manipulate Byobu's windows (multiple prompts) entirely with keystrokes. The basic commands are shown in Table 1; for a complete list of key-based commands, see the Ubuntu community help [4] or press F9 and select the Quick Start Guide.

Table 1

Working with Byobu Windows




Go to the previous window


Go to the next window


Refresh status notifications


Display window separately


Rename current window in status line


Scroll through window's history


Scroll forward through this window's history


Split current window horizontally


Split current window vertically


Close all windows, leaving one


Reconnect SSH/GPG sockets or agents

Collections of windows in Byobu are called screens. You can save screens with the command byobu-layout save [NAME]. To open a layout at any time, including when starting Byobu, use byobu-layout restore [NAME].

Configuring Status Lines

Byobu began as a collection of status indicators. Its multiplexing quickly became just as important, but the status lines are still in use, mainly because you can customize Byobu's status lines with 39 different status indicators. Obviously, you cannot use as many as half of the indicators before they become illegible, so choose the ones you prefer or need. Even then, memorizing colors and other elements of the indicators will make using them easier.

To edit, press F9 to get the Configuration Menu (Figure 3), select Toggle status notifications, and choose the desired indicators from the list (Figure 4). Table 2 shows the available indicators, but refer to the Byobu manual [5] for full details, especially about indicators that have custom settings.

Figure 3: Byobu Configuration Menu.
Figure 4: Choose from among 39 status indicators.

Table 2

Status Notifications



Color and Location

Lower Status Bar


A pending crash report is available.

To the left, black on orange.


System architecture

To the left, default colors.


Battery power

On the right, green, yellow, and red indicate battery state.


CPU temperature

Toward the right, yellow on black.


The number of CPUs or cores on the system

Displayed in default colors toward the right.


CPU frequency

Toward the right, white on blue.


User-defined custom scripts

Default colors unless indicated in script.


Date in YYYY-MM-DD format

Far right in the default colors.


Total disk space available and total used on root directory

Displayed on far right, white on purple.


Instantaneous read/write throughput in kBps or MBps over the last three seconds

Displayed toward the right, white on purple in white.



Black on gray.


Estimation of the cost of the current system boot using Amazon EC2 billing model

Toward the right, green on black.


System's current entropy in bytes

Toward the right, yellow on dark gray.


CPU or system fan speed

Toward the right, black on gray.


System load average over the last one minute

Toward the right, black on yellow.


Current operating system's logo

Far left.


System mail for current user

Toward the left, black on gray.


Percentage of memory available and used

Toward the right, white on green.


Indicates menu

Far right.


Upload/download bandwidth over last three seconds

Toward the left, white text on purple.


Send on-screen notification messages to screen's notification buffer


Number of processes running on system

White text on dark yellow.


Blinks at RAID failure

Red on white.


Cost of the current boot of the system in terms of the Rackspace Cloud Server billing model

Toward the right, green on black.


Whether rebooted needed after system update

White on blue.


Name of distro's current release

Black on gray.


User-defined list of services to monitor users can configure a list of services to monitor

Toward the center, cyan on white,


Byobu session name (with tmux only)

On the left, underlined black on white.


Swap space used

Toward the right, white on light green.


Time in HH:MM:SS format

On the far right, default colors.


Time in binary (GNU Screen)

Far right, default colors background colors.


The UTC system time in HH:MM format

Far right, dark text on a light background.


Number of updates available

Toward the right, white on red.


System uptime

Toward the right, blue on gray.


Number of remote users logged in via sshd

Toward the right, red on gray.


Connection rate and signal quality of WiFi connection

Toward the right, black on cyan.

Top Status Bar*



Far right, black on gray.


IPv4 address of the system in dotted decimal form

Far right, black on gray.


IPv6 address of the system

Far right, black text on gray background.


Current user

Far right, black on gray.

*Note: The far left of the status bar is reserved for windows (prompts), with the current window highlighted in gray.

Many indicators have set colors and approximate positions on the status bars defined. Other settings used by indicators are detected automatically or defined in the file ~/.byobu/statusrc (Figure 5), or, occasionally, another file under ~/.byobu, and can be altered in a text editor.

Figure 5: The general Byobu configuration file, statusrc.

Similarly, to edit the background color of the status line, edit ~/.byobu/color when running Byobu with GNU Screen or ~/color.tmux when running Byobu with tmux. Colors are defined in hexademical web format. The key combination Ctrl+Shift+F5 changes the background to a randomly selected color when Byobu uses tmux. To return to the default colors, delete the file in which the color is set.

Ordinarily, Byobu defaults to using tmux, using GNU Screen only if tmux is not installed. However, you can edit its configuration to use GNU Screen, either with the command byobu-select-backend, or by editing directly the line BYOBU_BACKEND=tmux in the file ~/.byobu/backend. Use the back-end file if you want to run either tmux or GNU Screen with options, although every option for the two commands may not be relevant in a modern system or have any noticeable effect

Multiplexers or Status-Seekers

In my experience, users of Byobu fall into two categories: those who want multiple prompts, and those who want a quick system summary. Both groups benefit from as large a monitor as possible because after a few divisions into more than a few prompts, the screens quickly become too small to be useful. Similarly, those who want information need as wide a screen as possible to squeeze as many indicators onto the status lines while keeping each legible.

That point aside, Byobu is an elegant program, similar to Gnome tools in the simplicity of its multiplexing, yet similar to KDE in the completeness of its status indicators. It combines the best of both design philosophies, guaranteeing its usefulness.

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Byobu

    The Byobu session manager extends the shell, adding a range of useful functions, such as splitting the screen, running programs in the background, or organizing programs in tabs. In particular, administrators who rely on SSH will appreciate Byobu.

  • Multi-Tasking

    Operate multiple terminal sessions in a single window.

comments powered by Disqus

Direct Download

Read full article as PDF:

Price $2.95