Can't detatch from byobu session without disconnecting

Bug #604931 reported by Iain Lane
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
byobu
Fix Released
Wishlist
Unassigned
byobu (Ubuntu)
Fix Released
Wishlist
Unassigned

Bug Description

Hiya,

  Installed: 2.82-0ubuntu1

In Lucid, I could ctrl-a, d to detatch from a byobu session and drop to a plain ssh prompt. I can't do this any more; I just get disconnected. Please could this behaviour be restored?

The reason I want this is because I'm often attached to byobu at home on the console of the machine, but don't necessarily remember to detatch before going elsewhere and needing to connect through ssh. When two places connect at once, the size of the terminal is often messed up. I used to detatch and then byobu -rAad to get to a session with a sane size. I don't appear to be able to do this any more.

Cheers.

Related branches

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

Okay, do this ...

Press <F9> and go to the menu. Toggle off, and then back on the "launch by default" option. It should be the last in the menu. This will re-write the last line of your ~/.profile with the latest incantation.

Look in your ~/.profile. Do you see a line that looks like this?
  case "$-" in *i*) byobu-launcher && exit 0; esac;

Edit ~/.profile and change that line to say:
  case "$-" in *i*) byobu-launcher; esac;

ie, drop the "&& exit 0" part.

Now try your use case again. Does it now do what you want?

If so, let me know. I can try to add a configuration option to make this behavior toggle-able too.

:-Dustin

Changed in byobu:
status: New → Triaged
importance: Undecided → Wishlist
Revision history for this message
Iain Lane (laney) wrote : Re: [Bug 604931] Re: Can't detatch from byobu session without disconnecting

Heya Dustin,

Thanks a lot for your reply.

On Mon, Aug 02, 2010 at 11:07:04PM -0000, Dustin Kirkland wrote:
>Okay, do this ...
>
>Press <F9> and go to the menu. Toggle off, and then back on the "launch
>by default" option. It should be the last in the menu. This will re-
>write the last line of your ~/.profile with the latest incantation.
>
>Look in your ~/.profile. Do you see a line that looks like this?
> case "$-" in *i*) byobu-launcher && exit 0; esac;

Yeah.

>Edit ~/.profile and change that line to say:
> case "$-" in *i*) byobu-launcher; esac;
>
>ie, drop the "&& exit 0" part.
>
>Now try your use case again. Does it now do what you want?

This doesn't seem to change the behaviour. Detaching or killing the
screen session with c-d still gives me

,----
| [detached from 6780.byobu]
| Connection to home.orangesquash.org.uk closed.
`----

btw, another way to fix my use case would be an option to have byobu
detach other attached sessions when I connect from somewhere else.

Cheers,
Iain

Revision history for this message
Iain Lane (laney) wrote :

Hi again.

On Tue, Aug 03, 2010 at 09:28:53AM +0100, Iain Lane wrote:
>Heya Dustin,
>
>Thanks a lot for your reply.
>
>On Mon, Aug 02, 2010 at 11:07:04PM -0000, Dustin Kirkland wrote:
>>Okay, do this ...
>>
>>Press <F9> and go to the menu. Toggle off, and then back on the "launch
>>by default" option. It should be the last in the menu. This will re-
>>write the last line of your ~/.profile with the latest incantation.
>>
>>Look in your ~/.profile. Do you see a line that looks like this?
>> case "$-" in *i*) byobu-launcher && exit 0; esac;
>
>Yeah.
>
>>Edit ~/.profile and change that line to say:
>> case "$-" in *i*) byobu-launcher; esac;
>>
>>ie, drop the "&& exit 0" part.
>>
>>Now try your use case again. Does it now do what you want?
>
>This doesn't seem to change the behaviour. Detaching or killing the
>screen session with c-d still gives me
>
>,----
>| [detached from 6780.byobu]
>| Connection to home.orangesquash.org.uk closed.
>`----
>
>btw, another way to fix my use case would be an option to have byobu
>detach other attached sessions when I connect from somewhere else.

Actually, it does work. I'm running zsh so had to edit ~/.zprofile
instead of ~/.profile.

Thanks!

Iain

Revision history for this message
Dustin Kirkland  (kirkland) wrote : Re: [Bug 604931] Re: Can't detatch from byobu session without disconnecting

On Tue, Aug 3, 2010 at 4:49 AM, Iain Lane <email address hidden> wrote:
> Actually, it does work. I'm running zsh so had to edit ~/.zprofile
> instead of ~/.profile.

Okay, so perhaps I just need to put together an interface in the gui
config and let you select this behavior.

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

How does this verbage sound?

I'll try to add a option in the byobu-config that says something like:

======================
When detaching from a remote session (choose one):
 [detach to a shell prompt on the remote system]
 [detach and log out of the remote system entirely]
======================

Revision history for this message
Iain Lane (laney) wrote : Re: [Bug 604931] Re: Can't detatch from byobu session without disconnecting

On Fri, Aug 20, 2010 at 11:42:01PM -0000, Dustin Kirkland wrote:
>How does this verbage sound?
>
>I'll try to add a option in the byobu-config that says something like:
>
>======================
>When detaching from a remote session (choose one):
> [detach to a shell prompt on the remote system]
> [detach and log out of the remote system entirely]
>======================

Not bad, but I think that “remote” sounds weird — it's not necessarily
a remote session. I'd probably just say “session” or “byobu session”.

Iain

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

Got it, thanks!

Revision history for this message
Stephen H. (stephenherr) wrote :

Any progress on this Wishlist item?

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

Well, I dropped a whole bunch of new functionality in 3.7 and decided that I needed to cut a release before Natty Alpha1.

I haven't worked on it yet.

In the mean time, just change one line in your ~/.profile:

-case "$-" in *i*) byobu-launcher && exit 0; esac;
+case "$-" in *i*) byobu-launcher; esac;

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

I added an option for -n|--no-logout to byobu-launcher-install.

You can call it like this:
 byobu-launcher-install -n

This will be in byobu-3.20. Thanks!

Changed in byobu:
status: Triaged → Fix Committed
Changed in byobu (Ubuntu):
status: New → Fix Committed
importance: Undecided → Wishlist
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package byobu - 3.20-0ubuntu1

---------------
byobu (3.20-0ubuntu1) natty; urgency=low

  * usr/lib/byobu/network: drop unnecessary unit=kbps
  * usr/bin/byobu: allow for -xS or the like, LP: #684926
  * usr/bin/byobu-select-session, usr/share/man/man1/byobu.1,
    usr/share/man/man1/byobu-select-session.1: support "hiding"
    sessions, by prepending a "." to the session name, LP: #599334
  * usr/share/man/man1/byobu-launcher.1: update documentation
  * usr/bin/byobu-launcher-install, usr/share/man/man1/byobu-launcher-
    install.1, usr/share/man/man1/byobu-launcher-uninstall.1,
    usr/share/man/man1/Makefile.am:
    - add an option for -n|--no-logout to byobu-launcher-install,
      document changes in new manpages, LP: #604931
  * usr/lib/byobu/cpu_temp: find the temp monitor, LP: #676080
  * usr/lib/byobu/battery, usr/share/man/man1/byobu.1: allow for
    overriding detected BATTERY, LP: #693560
  * usr/lib/byobu/cpu_temp: test that file exists, is readable, and has
    size > 0, LP: #696071
 -- Dustin Kirkland <email address hidden> Tue, 28 Dec 2010 00:05:13 -0600

Changed in byobu (Ubuntu):
status: Fix Committed → Fix Released
Changed in byobu:
status: Fix Committed → Fix Released
Changed in byobu (Ubuntu):
status: Fix Released → In Progress
Changed in byobu (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package byobu - 3.30-0ubuntu1

---------------
byobu (3.30-0ubuntu1) natty; urgency=low

  [ Dustin Kirkland ]
  * usr/share/applications/byobu.desktop: fix description
  * usr/bin/byobu-status-detail: make a couple of minor modifications
    noticed while investigating the already-fixed LP: #750887
  * usr/lib/byobu/raid: fix grep that changed recently in Linux's
    md driver's printing to /proc/mdstat, LP: #760693
  * usr/share/byobu/profiles/common: preserve splits across detach/reattach,
    LP: #760696
  * usr/bin/byobu-launcher: don't disrupt work flow, but rather inform
    user about launching byobu in a nested screen session, LP: #747649
  * usr/bin/byobu-launch, usr/bin/byobu-launcher-install: fix handling
    of logout behavior, when dpkg-configured globally by the sysadmin,
    LP: #741281
  * usr/share/byobu/profiles/common: fix bold color intensity, LP: #727466
  * usr/bin/byobu-janitor, usr/bin/byobu-launch, usr/bin/byobu-launcher-
    install, usr/bin/byobu-launcher-uninstall,
    usr/share/byobu/keybindings/f-keys,
    usr/share/byobu/keybindings/screen-escape-keys,
    usr/share/man/man1/byobu.1:
    - add a more permanent fix for LP: #604931
    - update documentation
  * usr/share/byobu/keybindings/f-keys,
    usr/share/byobu/keybindings/screen-escape-keys:
    - fix ctrl-f5
  * debian/source/format, === removed directory debian/source: remove these
    until bzr builddeb bug gets fixed
  * usr/bin/byobu, usr/share/byobu/profiles/byoburc,
    usr/share/byobu/profiles/Makefile.am,
    usr/share/byobu/profiles/screenrc: support using ~/.byoburc, instead of
    ~/.screenrc, if present; some users seem to want to use byobu and screen
    separately, and keep their profiles separate, LP: #731529
  * usr/bin/byobu-janitor: use greadlink on Mac OSX, LP: #740370
  * usr/bin/byobu-select-session: fix broken path to screen, affects users
    who build/install byobu locally only, LP: #758177

  [ Chaskiel Grundman ]
  * debian/postinst: correctly fix old-school screen-profiles era diversions
    of /usr/bin/screen, LP: #727738
 -- Dustin Kirkland <email address hidden> Sun, 27 Feb 2011 10:29:53 -0600

Changed in byobu (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.