Terminal Problem

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read this

Terminal Problem

Postby laurita on Thu Nov 20, 2008 8:57 am

I've written a program in C so i wanted to test it.
I opened the terminal, compiled my code and tried to run it. But the result was not what i was expecting. The program printed almost the half from what i wanted to print.
Then i run again. Now it printed more than before but again not everything. I tried to debug my code and saw that everything was fine. It should be printed normally, but it didn't in the terminal.
I run some other code and had the same problem again.
So i though that my terminal window is'n showing everything and for some reason it stops printing after some hundred lines.
Is there any explanation for this?
Any solution?
Thank you!
laurita
Level 1
Level 1
 
Posts: 10
Joined: Sun Nov 09, 2008 12:44 pm
Location: Greece

Linux Mint is funded by ads and donations.
 

Re: Terminal Problem

Postby Husse on Fri Nov 21, 2008 7:21 am

There is not room for an enormous amount of lines in the terminal window - that's why the commands more an less exist
A better way would be to pipe the output to a file - I think you should know how to do that if you compile C programs of your own
Image
Don't fix it if it ain't broken, don't break it if you can't fix it
Husse
Level 21
Level 21
 
Posts: 19710
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Re: Terminal Problem

Postby laurita on Fri Nov 21, 2008 8:46 am

I'm sure that's not the problem Husse.
In others OSs like Ubuntu and Suse the printing was succesfull.
However this problem got to a solution. I noticed that it was only happening when my notebook was not plugged to AC but when it was working with the battery.
When i plugged it, it worked fine and the printing was the expected one.
Doesn't anyone know why is this happening, thnx!
laurita
Level 1
Level 1
 
Posts: 10
Joined: Sun Nov 09, 2008 12:44 pm
Location: Greece

Re: Terminal Problem

Postby Husse on Fri Nov 21, 2008 9:02 am

Hmm - the umph in the battery was not enough....
However the terminal only puts out a limited number of lines which is easy to fix with | > otp.txt
Image
Don't fix it if it ain't broken, don't break it if you can't fix it
Husse
Level 21
Level 21
 
Posts: 19710
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Re: Terminal Problem

Postby laurita on Fri Nov 21, 2008 2:52 pm

Agreed!
But i told you that in terminals of other OSs i got what i wanted!
In mine too, when it is plugged. But what happens when it isn't?
laurita
Level 1
Level 1
 
Posts: 10
Joined: Sun Nov 09, 2008 12:44 pm
Location: Greece

Re: Terminal Problem

Postby Husse on Fri Nov 21, 2008 5:59 pm

If you only get a limited number of lines in any distro it's a battery capacity problem
If it's only Mint, and possibly the same generation of Ubuntu it must be something in the power management system that flips out, but it's way over my head. Can be that the voltage is dropping and the terminal shut off to preserve battery....
Image
Don't fix it if it ain't broken, don't break it if you can't fix it
Husse
Level 21
Level 21
 
Posts: 19710
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden


Return to Newbie Questions

Who is online

Users browsing this forum: RobertLM78 and 26 guests