LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
LinkBack Search this Thread
Old 02-16-2013, 03:47 PM   #1
odin_ago
Member
 
Registered: Mar 2011
Posts: 39

Rep: Reputation: 0
How to get more than 40 windows in GNU screen under Debian.


A question for Debian stable users.

I am using the terminal program called screen, which can create several "virtual terminals" in a single "real" terminal (the words "virtual" and "real" here are quite relative, the "real" terminal can be a konsole tab as well, not necessarily tty1-tty6). The problem is that I cannot create more than 40 windows inside a single screen. When I try to create more, screen says "No more windows." After some googling I found that that this is controlled by something called MAXWIN, but I didn't find any information how to modify this MAXWIN. How can I increase the maximal number of windows inside a single screen?

I use Debian squeeze (stable).
 
Old 02-17-2013, 11:11 AM   #2
amani
Senior Member
 
Registered: Jul 2006
Location: Kolkata, India
Distribution: 64-bit GNU/Linux, Kubuntu64, Fedora QA, Slackware,
Posts: 2,754

Rep: Reputation: Disabled
you should write it in the screenrc file and start screen again?
 
Old 02-17-2013, 11:29 AM   #3
mjolnir
Member
 
Registered: Apr 2003
Posts: 654

Rep: Reputation: 62
http://comments.gmane.org/gmane.linu...an.user/426291

"toor | 13 Jan 2012 05:38

Re: gnu screen - 40 windows limit?
I run across this issue as well.

I usually recompile screen to remove it. If you want to do it with
packages, make sure you have the dpkg-dev package installed (you will
need make etc. so also grab build-essential which may or may not be a
dependancy on dpkg-dev) and use 'apt-get source screen' to grab the
source for screen.

Extract the source (screen_4.0.3.orig.tar.gz). Make sure that you run
the patch after the archive is extracted to create the debian package
control files. Edit the config.h.in file and find this near the top:

# define MAXWIN 40

Change the 40 to what ever limit you want.

Rebuild the package using dpkg-buildpackage and then install the .dpkg
file over the top of your current screen installation. This will then
set the window limit to what ever you defined earlier.

On Fri, Jan 13, 2012 at 7:38 AM, Evuraan <evuraan <at> gmail.com> wrote:
> gnu screen seems to let me open upto 40 windows. When I try for more, it
> says "No more windows." - is there a way we can override this limit?
>
> many thanks in advance.
"

I haven't tried this so use at your own risk.
 
Old 02-17-2013, 11:56 AM   #4
amani
Senior Member
 
Registered: Jul 2006
Location: Kolkata, India
Distribution: 64-bit GNU/Linux, Kubuntu64, Fedora QA, Slackware,
Posts: 2,754

Rep: Reputation: Disabled
The manual should be improved.
 
Old 02-17-2013, 12:13 PM   #5
mjolnir
Member
 
Registered: Apr 2003
Posts: 654

Rep: Reputation: 62
Don't get me wrong, if a person wants 40+ windows that's their business but what on earth do you do with all of them? I'm not a sys admin but I use tmux with 5 windows and thought that was overkill.
 
1 members found this post helpful.
Old 02-17-2013, 06:43 PM   #6
odin_ago
Member
 
Registered: Mar 2011
Posts: 39

Original Poster
Rep: Reputation: 0
Thank you for your response, I will try it.
Doesn't anybody know a more "canonical" way of doing that than to recompile the source?
 
Old 02-17-2013, 07:48 PM   #7
ntubski
Senior Member
 
Registered: Nov 2005
Distribution: Debian
Posts: 2,307

Rep: Reputation: 767Reputation: 767Reputation: 767Reputation: 767Reputation: 767Reputation: 767Reputation: 767
Quote:
Originally Posted by odin_ago View Post
Doesn't anybody know a more "canonical" way of doing that than to recompile the source?
If the limit is #defined in the source than the only way around that will be to recompile. I suppose you could also start nesting screen instances, although that could get confusing.
 
Old 02-23-2013, 02:12 PM   #8
odin_ago
Member
 
Registered: Mar 2011
Posts: 39

Original Poster
Rep: Reputation: 0
I tried this. It seems to work ok. But in this case, if Debian maintainers decide to update the package, MAXWIN will become 40 again.

I mean, is it possible, for example, to tell Debian something like "when this package requires updating, its source should be downloaded instead of the binary, then
Code:
sed s/"#define MAXWIN 40"/"#define MAXWIN 400"/g
should be applied to config.h.in, then the package should be compiled?

Or maybe there exist another compiled package where MAXWIN is already larger?
 
Old 02-24-2013, 06:14 AM   #9
odin_ago
Member
 
Registered: Mar 2011
Posts: 39

Original Poster
Rep: Reputation: 0
Moreover, every time I want to update the system, debian "updates" my rebuilt screen to the original one, and I have to rebuild it again.
 
Old 02-24-2013, 07:14 AM   #10
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 1,691

Rep: Reputation: 425Reputation: 425Reputation: 425Reputation: 425Reputation: 425
Don't put the rebuilt version of screen in /usr/bin - put it in /usr/local/bin.

And don't install the debian version, thus updates will not attempt to replace it.
 
Old 02-24-2013, 12:59 PM   #11
descendant_command
Member
 
Registered: Mar 2012
Posts: 679

Rep: Reputation: 133Reputation: 133
Or make a package and pin it to your version in apt/preferences
 
Old 02-24-2013, 10:09 PM   #12
ntubski
Senior Member
 
Registered: Nov 2005
Distribution: Debian
Posts: 2,307

Rep: Reputation: 767Reputation: 767Reputation: 767Reputation: 767Reputation: 767Reputation: 767Reputation: 767
Maybe try tmux instead?
 
Old 02-25-2013, 03:26 AM   #13
odin_ago
Member
 
Registered: Mar 2011
Posts: 39

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by jpollard View Post
And don't install the debian version, thus updates will not attempt to replace it.
I've found a different workaround against Debian's attempts to reinstall the original package every time, even when it was not updated. T have to say
Code:
dch -v 4.0.3-14.asus1
after I modify config.h.in, but before I say
Code:
dpkg-buildpackage
.
 
  


Reply

Tags
debian squeeze, terminal


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
gnu screen - separate windows casperdaghost Linux - Newbie 4 05-28-2011 01:18 PM
Using two GNU Screen windows to double the number of lines displayed jgombos Linux - Software 1 05-12-2011 05:54 AM
installing screen(http://www.gnu.org/software/screen/) dreamlemon Solaris / OpenSolaris 5 09-29-2007 03:36 PM
GNU Screen detach for X-Windows? gurulocu Linux - Software 2 01-28-2006 04:09 PM


All times are GMT -5. The time now is 05:41 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration