LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   random crashes of programs...... (https://www.linuxquestions.org/questions/linux-software-2/random-crashes-of-programs-55317/)

vyeperman3001 04-16-2003 11:18 AM

random crashes of programs......
 
alright i am on redhat 8.0 and when i double click and a program icon for it to start nothing happens so i tried opening it through terminal and i got to see what it was doing all this code came up for about a half a second and then POOF! terminal shut down which would explain why i never saw the program this happens with a few of them i know there are some games that don't start the clock settings won't start....what is all this can someone help me out on what could be the problem i would have pasted the error but it was up and gone so fast and it happens over and over again but just to fast for me to see or even copy sorry.....if you can help that would be wonderful thanks in advance.......!:newbie: :newbie:

jpbarto 04-16-2003 11:24 AM

uhh... missing library maybe? anyone?

next time you go to run a program from the command prompt run it like this...
$ <program-name> 2>&1 > output.txt

this will dump all output to a text file (output.txt) that can be reviewed later on... you could also try an strace on that same program... it will give you more debug information.

vyeperman3001 04-16-2003 01:06 PM

[root@localhost root]# $<program-Date & Time> 2>&1 >output.txt
bash: syntax error near unexpected token `2'
_______________________________________________________________
any idea's......cuz that didn't work......thanks in advance.....

Proud 04-16-2003 01:12 PM

Dont log in as root for normal working.

Try the_name_of_the_program > output.txt
I think the &1 bit mean any arguements you were passing to the program when trying to load it, eg maybe a url or something. :)

jpbarto 04-16-2003 02:07 PM

example:

ls 2>&1 1> output.txt

what the '2>&1' does is feed any error messages into standard output stream (1). if you just typed
ls 1> output.txt
then you would get all output from standard output into output.txt and any errors (which are written to standard error) would be lost after printed to the screen.
but you could also type
ls 1> output.txt 2>errors.txt
and that would put standard output (like the directory listing) into output.txt and if any errors occurred then they would get written to errors.txt.

so by typing 2>&1 you are telling both standard output AND standard error to be written to standard output. then standard output is redirected to output.txt with 1>output.txt

Proud 04-16-2003 02:09 PM

My bad. Learn something new everyday :)

jpbarto 04-16-2003 02:15 PM

no prob... I guess too many '>'s and '<'s really can get in the way of an explanation though huh.


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